From a8faa63aba2d6378f64e2a4736fe95980733c78e Mon Sep 17 00:00:00 2001 From: Markus Quaritsch <markus.quaritsch@tugraz.at> Date: Thu, 9 May 2019 13:48:53 +0200 Subject: [PATCH] clear shiftlossenergy if remaining shift time is non-negative; check TC operating point if possibe for engine (case creeping) --- .../Models/SimulationComponent/Impl/ATGearbox.cs | 4 +++- .../SimulationComponent/Impl/ATShiftStrategy.cs | 2 +- .../SimulationComponent/Impl/TorqueConverter.cs | 13 +++++++++++-- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/VectoCore/VectoCore/Models/SimulationComponent/Impl/ATGearbox.cs b/VectoCore/VectoCore/Models/SimulationComponent/Impl/ATGearbox.cs index 7ba29d28ac..51da402b0e 100644 --- a/VectoCore/VectoCore/Models/SimulationComponent/Impl/ATGearbox.cs +++ b/VectoCore/VectoCore/Models/SimulationComponent/Impl/ATGearbox.cs @@ -303,8 +303,10 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl var avgEngineSpeed = (DataBus.EngineSpeed + outAngularVelocity * effectiveRatio) / 2; powershiftLoss = aliquotEnergyLoss / dt / avgEngineSpeed; inTorque += powershiftLoss; - + //inTorque += CurrentState.PowershiftLossEnergy; + } else { + _powershiftLossEnergy = null; } } diff --git a/VectoCore/VectoCore/Models/SimulationComponent/Impl/ATShiftStrategy.cs b/VectoCore/VectoCore/Models/SimulationComponent/Impl/ATShiftStrategy.cs index 40e1c4a434..a2a7fae5b8 100644 --- a/VectoCore/VectoCore/Models/SimulationComponent/Impl/ATShiftStrategy.cs +++ b/VectoCore/VectoCore/Models/SimulationComponent/Impl/ATShiftStrategy.cs @@ -245,7 +245,7 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl var nextGearboxInTorque = outTorque / nextGear.TorqueConverterRatio; var shiftLosses = _gearbox.ComputeShiftLosses(outTorque, outAngularVelocity, gear + 1) / ModelData.PowershiftShiftTime / nextGearboxInSpeed; nextGearboxInTorque += shiftLosses; - var tcOperatingPoint = _gearbox.TorqueConverter.FindOperatingPoint(nextGearboxInTorque, nextGearboxInSpeed); + var tcOperatingPoint = _gearbox.TorqueConverter.FindOperatingPoint(absTime, dt, nextGearboxInTorque, nextGearboxInSpeed); var engineSpeedOverMin = tcOperatingPoint.InAngularVelocity.IsGreater(minEngineSpeed); var avgSpeed = (DataBus.EngineSpeed + tcOperatingPoint.InAngularVelocity) / 2; diff --git a/VectoCore/VectoCore/Models/SimulationComponent/Impl/TorqueConverter.cs b/VectoCore/VectoCore/Models/SimulationComponent/Impl/TorqueConverter.cs index e26ffc6ceb..80fa01293c 100644 --- a/VectoCore/VectoCore/Models/SimulationComponent/Impl/TorqueConverter.cs +++ b/VectoCore/VectoCore/Models/SimulationComponent/Impl/TorqueConverter.cs @@ -102,7 +102,7 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl Second absTime, Second dt, NewtonMeter outTorque, PerSecond outAngularVelocity, bool dryRun = false) { - var operatingPoint = FindOperatingPoint(outTorque, outAngularVelocity); + var operatingPoint = FindOperatingPoint(absTime, dt, outTorque, outAngularVelocity); var inTorque = CalculateAverageInTorque(operatingPoint); if (dryRun) { @@ -316,7 +316,7 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl return retVal; } - protected internal TorqueConverterOperatingPoint FindOperatingPoint( + protected internal TorqueConverterOperatingPoint FindOperatingPoint(Second absTime, Second dt, NewtonMeter outTorque, PerSecond outAngularVelocity) { @@ -324,6 +324,15 @@ namespace TUGraz.VectoCore.Models.SimulationComponent.Impl if (operatingPointList.Count == 0) { Log.Debug("TorqueConverter: Failed to find torque converter operating point, fallback: creeping"); var tqOperatingPoint = ModelData.FindOperatingPoint(DataBus.EngineIdleSpeed, outAngularVelocity); + + var engineResponse = (ResponseDryRun) + NextComponent.Request(absTime, dt, tqOperatingPoint.InTorque, tqOperatingPoint.InAngularVelocity, true); + + var engineOK = engineResponse.DeltaDragLoad.IsGreaterOrEqual(0) && engineResponse.DeltaFullLoad.IsSmallerOrEqual(0); + if (!engineOK) { + tqOperatingPoint = ModelData.FindOperatingPoint(VectoMath.Max(DataBus.EngineIdleSpeed, DataBus.EngineSpeed * 0.9), outAngularVelocity); + } + tqOperatingPoint.Creeping = true; return tqOperatingPoint; } -- GitLab