Package org.opentrafficsim.demo.sdm
Class SdmSimulation
- java.lang.Object
-
- org.opentrafficsim.swing.script.AbstractSimulationScript
-
- org.opentrafficsim.demo.sdm.SdmSimulation
-
- All Implemented Interfaces:
Serializable
,EventListener
,Checkable
,EventListenerInterface
public class SdmSimulation extends AbstractSimulationScript
Script to run a simulation with the Stochastic Distraction Model.Copyright (c) 2013-2020 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.- Version:
- $Revision$, $LastChangedDate$, by $Author$, initial version 5 nov. 2018
- Author:
- Alexander Verbraeck, Peter Knoppers, Wouter Schakel
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
SdmSimulation()
Constructor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addTabs(OTSSimulatorInterface sim, OTSSimulationApplication<?> animation)
void
check()
double
getBetaT()
Duration
getDt()
IdmOptions
getIdmOptions()
double
getSaMax()
double
getSaMin()
double
getTc()
Duration
getTrMax()
double
getTsCrit()
double
getTsMax()
static void
main(String... args)
Start a simulation.protected void
onSimulationEnd()
protected OTSRoadNetwork
setupSimulation(OTSSimulatorInterface sim)
-
Methods inherited from class org.opentrafficsim.swing.script.AbstractSimulationScript
animateNetwork, getGtuColorer, getNetwork, getSeed, getSimulationTime, getSimulator, getStartTime, getWarmupTime, isAutorun, notify, setAnimationToggles, setGtuColorer, setupDemo, start
-
-
-
-
Method Detail
-
main
public static void main(String... args)
Start a simulation.- Parameters:
args
- String...; command line arguments
-
check
public void check() throws Exception
- Specified by:
check
in interfaceCheckable
- Overrides:
check
in classAbstractSimulationScript
- Throws:
Exception
-
setupSimulation
protected OTSRoadNetwork setupSimulation(OTSSimulatorInterface sim) throws Exception
- Specified by:
setupSimulation
in classAbstractSimulationScript
- Throws:
Exception
-
addTabs
protected void addTabs(OTSSimulatorInterface sim, OTSSimulationApplication<?> animation)
- Overrides:
addTabs
in classAbstractSimulationScript
-
onSimulationEnd
protected void onSimulationEnd()
- Overrides:
onSimulationEnd
in classAbstractSimulationScript
-
getIdmOptions
public IdmOptions getIdmOptions()
- Returns:
- idmOptions.
-
getDt
public Duration getDt()
- Returns:
- dt.
-
getSaMin
public double getSaMin()
- Returns:
- saMin.
-
getSaMax
public double getSaMax()
- Returns:
- saMax.
-
getTc
public double getTc()
- Returns:
- tc.
-
getTsCrit
public double getTsCrit()
- Returns:
- tsCrit.
-
getTsMax
public double getTsMax()
- Returns:
- tsMax.
-
getTrMax
public Duration getTrMax()
- Returns:
- trMax.
-
getBetaT
public double getBetaT()
- Returns:
- betaT.
-
-