Package org.planit.route.choice
Class StochasticRouteChoice
- java.lang.Object
-
- org.djutils.event.EventProducer
-
- org.planit.trafficassignment.TrafficAssignmentComponent<RouteChoice>
-
- org.planit.route.choice.RouteChoice
-
- org.planit.route.choice.StochasticRouteChoice
-
- All Implemented Interfaces:
Serializable
,org.djutils.event.EventProducerInterface
public class StochasticRouteChoice extends RouteChoice
Stochastic route choice component. Stochasticity is reflected by the fact that the route choice is applied by means of a logit model, to be configured here. Also, due to being stochastic the route can/must be provided beforehand. This is also configured via this class- Author:
- markr
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected LogitChoiceModel
logitChoiceModel
The registered logit choice modelprotected TrafficAssignmentComponentFactory<LogitChoiceModel>
logitChoiceModelFactory
logit choice model factory to create logit models to direct the probabilities of choosing pathsprotected ODRouteMatrix
odRouteSet
The registered od route set instance-
Fields inherited from class org.planit.trafficassignment.TrafficAssignmentComponent
groupId, id, trafficComponentType
-
-
Constructor Summary
Constructors Constructor Description StochasticRouteChoice(IdGroupingToken groupId, InputBuilderListener trafficComponentCreateListener)
Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LogitChoiceModel
createAndRegisterLogitModel(String canonicalName)
create and register the logit model of choicevoid
RegisterODRouteMatrix(ODRouteMatrix odRouteSet)
Register a fixed od route set to use in the form of an ODPathMatrix-
Methods inherited from class org.planit.trafficassignment.TrafficAssignmentComponent
getId, getIdGroupingtoken, getSourceId, getTrafficComponentType
-
Methods inherited from class org.djutils.event.EventProducer
addListener, addListener, addListener, addListener, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, fireTimedEvent, getEventTypesWithListeners, hasListeners, numberOfListeners, removeAllListeners, removeAllListeners, removeListener
-
-
-
-
Field Detail
-
logitChoiceModelFactory
protected final TrafficAssignmentComponentFactory<LogitChoiceModel> logitChoiceModelFactory
logit choice model factory to create logit models to direct the probabilities of choosing paths
-
logitChoiceModel
protected LogitChoiceModel logitChoiceModel
The registered logit choice model
-
odRouteSet
protected ODRouteMatrix odRouteSet
The registered od route set instance
-
-
Constructor Detail
-
StochasticRouteChoice
public StochasticRouteChoice(IdGroupingToken groupId, InputBuilderListener trafficComponentCreateListener)
Constructor- Parameters:
groupId
- contiguous id generation within this group for instances of this classtrafficComponentCreateListener
- thelistener to fire notify of create events when we create a logit choice model
-
-
Method Detail
-
createAndRegisterLogitModel
public LogitChoiceModel createAndRegisterLogitModel(String canonicalName) throws PlanItException
create and register the logit model of choice- Parameters:
canonicalName
- name of the class to be instantiated- Returns:
- the logit choice model that is registered
- Throws:
PlanItException
- thrown if error
-
RegisterODRouteMatrix
public void RegisterODRouteMatrix(ODRouteMatrix odRouteSet)
Register a fixed od route set to use in the form of an ODPathMatrix- Parameters:
odRouteSet
- the fixed od route set in the shape of an od path matrix
-
-