Code development platform for open source projects from the European Union institutions :large_blue_circle: EU Login authentication by SMS has been phased out. To see alternatives please check here

Skip to content
Snippets Groups Projects
Commit 3cc86d7b authored by Markus Quaritsch's avatar Markus Quaritsch
Browse files

distance run: avoid short initial simulation intervals if the vehicle speed is very low.

parent ff4f26cc
Branches
Tags
No related merge requests found
......@@ -47,9 +47,11 @@ namespace TUGraz.VectoCore.Models.Simulation.Impl
IterationStatistics.StartIteration();
// estimate distance to be traveled within the next TargetTimeInterval
var ds = Container.VehicleSpeed.IsEqual(0)
var ds = Container.VehicleSpeed.IsEqual(0.KMPHtoMeterPerSecond(), 0.01.SI<MeterPerSecond>())
? Constants.SimulationSettings.DriveOffDistance
: Constants.SimulationSettings.TargetTimeInterval * Container.VehicleSpeed;
: VectoMath.Max(
Constants.SimulationSettings.TargetTimeInterval * Container.VehicleSpeed,
Constants.SimulationSettings.DriveOffDistance);
var loopCount = 0;
IResponse response;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment