Interface Estimation

    • Field Detail

      • NONE

        static final Estimation NONE
        No estimation errors.
      • UNDERESTIMATION

        static final Estimation UNDERESTIMATION
        Underestimation based on situational awareness.
      • OVERESTIMATION

        static final Estimation OVERESTIMATION
        OVerestimation based on situational awareness.
    • Method Detail

      • estimate

        NeighborTriplet estimate​(LaneBasedGTU perceivingGtu,
                                 LaneBasedGTU perceivedGtu,
                                 Length distance,
                                 boolean downstream,
                                 Time when)
                          throws org.opentrafficsim.base.parameters.ParameterException
        Estimate headway, speed and acceleration.
        Parameters:
        perceivingGtu - LaneBasedGTU; perceiving GTU
        perceivedGtu - LaneBasedGTU; perceived GTU
        distance - Length; actual headway at 'now' (i.e. not at 'when' if there is a reaction time)
        downstream - boolean; downstream (or upstream) neighbor
        when - Time; moment of perception, reaction time included
        Returns:
        NeighborTriplet; perceived headway, speed and acceleration
        Throws:
        org.opentrafficsim.base.parameters.ParameterException - on invalid parameter value or if parameter is not available
      • getDelayedHeadway

        default Length getDelayedHeadway​(LaneBasedGTU perceivingGtu,
                                         LaneBasedGTU perceivedGtu,
                                         Length distance,
                                         boolean downstream,
                                         Time when)
        Returns a delayed headway.
        Parameters:
        perceivingGtu - LaneBasedGTU; perceiving GTU
        perceivedGtu - LaneBasedGTU; perceived GTU
        distance - Length; actual headway at 'now' (i.e. not at 'when' if there is a reaction time)
        downstream - boolean; downstream (or upstream) neighbor
        when - Time; moment of perception, reaction time included
        Returns:
        Length; delayed headway
      • getEgoSpeed

        default Speed getEgoSpeed​(LaneBasedGTU perceivingGtu)
        Returns the ego speed. This is the speed used in AbstractLaneBasedGTU.getCarFollowingAcceleration(), and hence this is the reference speed for the stimulus of speed difference.
        Parameters:
        perceivingGtu - LaneBasedGTU; perceiving GTU
        Returns:
        Speed; ego speed
      • getDelayedSpeedDifference

        default Speed getDelayedSpeedDifference​(LaneBasedGTU perceivingGtu,
                                                LaneBasedGTU perceivedGtu,
                                                Time when)
        Returns a delayed speed difference (other minus ego).
        Parameters:
        perceivingGtu - LaneBasedGTU; perceiving GTU
        perceivedGtu - LaneBasedGTU; perceived GTU
        when - Time; moment of perception, reaction time included
        Returns:
        Speed; delayed speed difference (other minus ego)