Class AttentionMatrix
java.lang.Object
org.opentrafficsim.road.gtu.lane.perception.mental.channel.AttentionMatrix
This class describes attention over channels, based on task demand per channel. Transition probabilities are based on demand
per channel, where drivers are assumed to keep perceiving the same channel by the demand of that channel alone. When total
demand is above 1, this means that the probability of switching to another channel is reduced. All transition probabilities
together result in an overall steady-state, which describes what fraction of time is spent on what channel.
Copyright (c) 2024-2025 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
- Author:
- Wouter Schakel
-
Constructor Summary
ConstructorsConstructorDescriptionAttentionMatrix(double[] demand) Constructor which pre-calculates attention distribution assuming drivers are serial mono-taskers. -
Method Summary
Modifier and TypeMethodDescriptiondoublegetAnticipationReliance(int i) Returns the level of anticipation reliance for channel i.doublegetAttention(int i) Returns the fraction of time that is spent on channel i.doublegetDeterioration(int i) Returns the deterioration of channel i.
-
Constructor Details
-
AttentionMatrix
public AttentionMatrix(double[] demand) Constructor which pre-calculates attention distribution assuming drivers are serial mono-taskers. The probability of staying on a task is the task demand of the task, while the probability of switching is the complement. The task that will then be switched to is selected by weighting them by their task demand. This creates a transition matrix in a Markov chain. The steady-state of this Markov chain is the attention distribution.- Parameters:
demand- level of mental task demand per channel.- Throws:
IllegalArgumentException- when a demand value is below 0 or larger than or equal to 1
-
-
Method Details
-
getAttention
public double getAttention(int i) Returns the fraction of time that is spent on channel i.- Parameters:
i- index of channel.- Returns:
- fraction of time that is spent on channel i.
-
getAnticipationReliance
public double getAnticipationReliance(int i) Returns the level of anticipation reliance for channel i. This is the fraction of time that is reduced from perceiving channel i, relative to the desired fraction of time to perceive channel i.- Parameters:
i- index of channel.- Returns:
- level of anticipation reliance for channel i.
-
getDeterioration
public double getDeterioration(int i) Returns the deterioration of channel i. This is the anticipation reliance for channel i, divided by the desired level of attention for channel i. This value is an indication of perception delay for the channel.If demand for the channel is 0, this method returns 1.
- Parameters:
i- index of channel.- Returns:
- fraction of anticipation reliance over desired attention for channel i.
-