16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-18 03:09:18 +02:00

Better calculation when slipping with disabled inverters

This commit is contained in:
Królik Uszasty
2020-10-31 22:42:21 +01:00
committed by tmj-fstate
parent 83606bc6ca
commit 6582370484

View File

@@ -4813,6 +4813,11 @@ void TMoverParameters::ComputeTotalForce(double dt) {
Power > 0 ?
TractionForce( dt ) :
0 );
double FT_factor = 1.0;
if (EngineType == TEngineType::ElectricInductionMotor && InvertersRatio > 0.0) {
FT_factor = 1.0 / InvertersRatio;
FTrain *= FT_factor;
}
Fb = BrakeForce(RunningTrack);
// poslizg
@@ -4867,6 +4872,7 @@ void TMoverParameters::ComputeTotalForce(double dt) {
FStand += Fb;
// doliczenie składowej stycznej grawitacji
FTrain /= FT_factor;
FTrain += TotalMassxg * RunningShape.dHtrack;
//!niejawne przypisanie zmiennej!
FTotal = FTrain - Sign(V) * FStand;