public abstract class AbstractLMRS extends AbstractLaneBasedTacticalPlanner
Copyright (c) 2013-2016 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
Modifier and Type | Field and Description |
---|---|
static org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeAcceleration |
A_LAT
Maximum comfortable acceleration in the lateral direction.
|
static org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeDouble |
DCOOP
Cooperative lane change desire threshold.
|
static org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeDouble |
DFREE
Free lane change desire threshold.
|
static org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeDouble |
DSYNC
Synchronized lane change desire threshold.
|
static org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeDuration |
DT
Fixed model time step.
|
Constructor and Description |
---|
AbstractLMRS(CarFollowingModel carFollowingModel)
Constructor setting the car-following model.
|
Modifier and Type | Method and Description |
---|---|
void |
addMandatoryIncentive(MandatoryIncentive incentive)
Adds a mandatory incentive.
|
void |
addVoluntaryIncentive(VoluntaryIncentive incentive)
Adds a voluntary incentive.
|
protected org.djunits.value.vdouble.scalar.Acceleration |
considerSpeedLimitTransitions(org.opentrafficsim.core.gtu.behavioralcharacteristics.BehavioralCharacteristics behavioralCharacteristics,
org.djunits.value.vdouble.scalar.Speed speed,
SpeedLimitProspect speedLimitProspect,
AbstractCarFollowingModel carFollowingModel)
Acceleration for speed limit transitions.
|
void |
disableLaneChanges()
Disables lane changes by clearing all incentives and setting a dummy incentive as mandatory incentive.
|
protected void |
exponentialHeadwayRelaxation(org.opentrafficsim.core.gtu.behavioralcharacteristics.BehavioralCharacteristics bc)
Updates the desired headway following an exponential shape approximated with fixed time step DT.
|
abstract Set<MandatoryIncentive> |
getDefaultMandatoryIncentives()
Returns a set of default mandatory incentives.
|
abstract Set<VoluntaryIncentive> |
getDefaultVoluntaryIncentives()
Returns a set of default voluntary incentives.
|
Set<MandatoryIncentive> |
getMandatoryIncentives()
Returns a defensive copy of the mandatory incentives.
|
Set<VoluntaryIncentive> |
getVoluntaryIncentives()
Returns a defensive copy of the voluntary incentives.
|
protected org.djunits.value.vdouble.scalar.Acceleration |
limitDeceleration(org.djunits.value.vdouble.scalar.Acceleration a,
org.djunits.value.vdouble.scalar.Acceleration b)
Limits the supplied acceleration to a given maximum deceleration.
|
org.djunits.value.vdouble.scalar.Acceleration |
minOf(org.djunits.value.vdouble.scalar.Acceleration a1,
org.djunits.value.vdouble.scalar.Acceleration a2)
Returns the minimum of two accelerations.
|
void |
setDefaultIncentives()
Sets the default lane change incentives.
|
buildLaneListForwardXXX, buildLanePathInfo, buildLanePathInfo, buildLanePathInfo, buildLinkListForward, connectsToPath, determineNextSplit, getCarFollowingModel, getReferenceLane, noLaneDrop, setCarFollowingModel
public static final org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeDuration DT
public static final org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeDouble DFREE
public static final org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeDouble DSYNC
public static final org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeDouble DCOOP
public static final org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterTypeAcceleration A_LAT
public AbstractLMRS(CarFollowingModel carFollowingModel)
carFollowingModel
- Car-following model.public final void addMandatoryIncentive(MandatoryIncentive incentive)
incentive
- Incentive to add.public final void addVoluntaryIncentive(VoluntaryIncentive incentive)
incentive
- Incentive to add.public final void setDefaultIncentives()
public abstract Set<MandatoryIncentive> getDefaultMandatoryIncentives()
public abstract Set<VoluntaryIncentive> getDefaultVoluntaryIncentives()
public final void disableLaneChanges()
protected final org.djunits.value.vdouble.scalar.Acceleration limitDeceleration(org.djunits.value.vdouble.scalar.Acceleration a, org.djunits.value.vdouble.scalar.Acceleration b)
a
- Acceleration to limit.b
- Maximum deceleration to limit to.public final org.djunits.value.vdouble.scalar.Acceleration minOf(org.djunits.value.vdouble.scalar.Acceleration a1, org.djunits.value.vdouble.scalar.Acceleration a2)
a1
- First acceleration.a2
- Second acceleration.public final Set<MandatoryIncentive> getMandatoryIncentives() throws org.opentrafficsim.core.gtu.plan.operational.OperationalPlanException
org.opentrafficsim.core.gtu.plan.operational.OperationalPlanException
- If there is no mandatory incentive. The model requires at least one.public final Set<VoluntaryIncentive> getVoluntaryIncentives()
protected final void exponentialHeadwayRelaxation(org.opentrafficsim.core.gtu.behavioralcharacteristics.BehavioralCharacteristics bc) throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
bc
- Behavioral characteristics.org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
- In case of a parameter exception.protected final org.djunits.value.vdouble.scalar.Acceleration considerSpeedLimitTransitions(org.opentrafficsim.core.gtu.behavioralcharacteristics.BehavioralCharacteristics behavioralCharacteristics, org.djunits.value.vdouble.scalar.Speed speed, SpeedLimitProspect speedLimitProspect, AbstractCarFollowingModel carFollowingModel) throws org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
approachTargetSpeed()
of the abstract car-following model implementation. All remaining transitions happen in the
default manner, i.e. deceleration and acceleration after the speed limit change and governed by the car-following model.behavioralCharacteristics
- behavioral characteristicsspeed
- current speedspeedLimitProspect
- speed limit prospectcarFollowingModel
- car following modelorg.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
- if a required parameter is not foundCopyright © 2014–2016 Delft University of Technology. All rights reserved.