public class LaneBasedCFLCTacticalPlanner 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.djunits.value.vdouble.scalar.Length |
GETOFFTHISLANENOW
Return value of suitability when a lane change is required right now.
|
static org.djunits.value.vdouble.scalar.Length |
NOLANECHANGENEEDED
Return value of suitability when no lane change is required within the time horizon.
|
Constructor and Description |
---|
LaneBasedCFLCTacticalPlanner(GTUFollowingModelOld carFollowingModel,
LaneChangeModel laneChangeModel,
LaneBasedGTU gtu)
Instantiated a tactical planner with GTU following and lane change behavior.
|
Modifier and Type | Method and Description |
---|---|
protected org.djunits.value.vdouble.scalar.Length |
computeSuitabilityWithLaneChanges(Lane startLane,
double remainingDistance,
Map<Lane,org.djunits.value.vdouble.scalar.Length> suitabilities,
int totalLanes,
org.opentrafficsim.core.network.LateralDirectionality direction,
org.opentrafficsim.core.gtu.GTUType gtuType)
Compute the suitability of a lane from which lane changes are required to get to the next point on the Route.
This method weighs the suitability of the nearest suitable lane by (m - n) / m where n is the number of lane changes required and m is the total number of lanes in the CrossSectionLink. |
protected int |
countCompatibleLanes(CrossSectionLink link,
org.opentrafficsim.core.gtu.GTUType gtuType)
Determine how many lanes on a CrossSectionLink are compatible with a particular GTU type.
TODO: this method should probably be moved into the CrossSectionLink class |
org.opentrafficsim.core.gtu.plan.operational.OperationalPlan |
generateOperationalPlan(org.djunits.value.vdouble.scalar.Time startTime,
nl.tudelft.simulation.language.d3.DirectedPoint locationAtStartTime) |
String |
toString() |
buildLanePathInfo, buildLanePathInfo, buildLinkListForward, buildPlanFromSimplePlan, connectsToPath, determineNextSplit, getCarFollowingModel, getGtu, getPerception, noLaneDrop, setCarFollowingModel
public static final org.djunits.value.vdouble.scalar.Length NOLANECHANGENEEDED
public static final org.djunits.value.vdouble.scalar.Length GETOFFTHISLANENOW
public LaneBasedCFLCTacticalPlanner(GTUFollowingModelOld carFollowingModel, LaneChangeModel laneChangeModel, LaneBasedGTU gtu)
carFollowingModel
- Car-following model.laneChangeModel
- Lane change model.gtu
- GTUpublic final org.opentrafficsim.core.gtu.plan.operational.OperationalPlan generateOperationalPlan(org.djunits.value.vdouble.scalar.Time startTime, nl.tudelft.simulation.language.d3.DirectedPoint locationAtStartTime) throws org.opentrafficsim.core.gtu.plan.operational.OperationalPlanException, org.opentrafficsim.core.network.NetworkException, org.opentrafficsim.core.gtu.GTUException, org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
org.opentrafficsim.core.gtu.plan.operational.OperationalPlanException
org.opentrafficsim.core.network.NetworkException
org.opentrafficsim.core.gtu.GTUException
org.opentrafficsim.core.gtu.behavioralcharacteristics.ParameterException
protected final org.djunits.value.vdouble.scalar.Length computeSuitabilityWithLaneChanges(Lane startLane, double remainingDistance, Map<Lane,org.djunits.value.vdouble.scalar.Length> suitabilities, int totalLanes, org.opentrafficsim.core.network.LateralDirectionality direction, org.opentrafficsim.core.gtu.GTUType gtuType)
startLane
- Lane; the current lane of the GTUremainingDistance
- double; distance in m of GTU to first branchsuitabilities
- Map<Lane, Double>; the set of suitable lanes and their suitabilitytotalLanes
- integer; total number of lanes compatible with the GTU typedirection
- LateralDirectionality; the direction of the lane changes to attemptgtuType
- GTUType; the type of the GTUprotected final int countCompatibleLanes(CrossSectionLink link, org.opentrafficsim.core.gtu.GTUType gtuType)
link
- CrossSectionLink; the linkgtuType
- GTUType; the GTU typeCopyright © 2014–2016 Delft University of Technology. All rights reserved.