mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-22 00:54:59 +01:00
Brake force table: take the rapid step threshold from the distributor
TMoverParameters::BrakeForceR() halves the force of a vehicle set to R below 40 km/h. That is one approximation for every distributor, but a NESt3/ESt4 distributor with a rapid relay engages the step above 70 km/h and keeps it down to 50 km/h (TNESt3::GetPF, RapidStatus), and below that its cylinder pressure is divided by the relay's own multiplier (TRapid, RapidMult). For a vehicle braking from speed the full force therefore lasts down to 50 km/h, not 40. The AI builds its consist brake table (fBrake_a0/a1) from BrakeForceR(), so between 40 and 50 km/h it expected twice the force the wagons actually deliver. Add TBrake::GetRapidRatio(), which keeps the old approximation as the default, and override it in TNESt3 with the relay's threshold and multiplier. The brake itself is unchanged; only the prediction is.
This commit is contained in:
@@ -324,6 +324,17 @@ void TNESt3::Init( double const PP, double const HPP, double const LPP, double c
|
||||
RapidStaly = false;
|
||||
}
|
||||
|
||||
double TNESt3::GetRapidRatio(double const Vel) const
|
||||
{
|
||||
// ESt3 has no rapid relay, and with disc brakes the rapid step stays engaged at all speeds
|
||||
if( ( PrzekRapid == nullptr ) || ( true == RapidStaly ) ) {
|
||||
return 1.0;
|
||||
}
|
||||
// a braking vehicle comes from above, so the step is still engaged down to the speed
|
||||
// at which GetPF() drops it, not the one at which it engages
|
||||
return ( Vel < 50.0 ? 1.0 / PrzekRapid->GetRapidMult() : 1.0 );
|
||||
}
|
||||
|
||||
double TNESt3::GetCRP()
|
||||
{
|
||||
return CntrlRes->P();
|
||||
|
||||
Reference in New Issue
Block a user