Interface PerceivedObject.Kinematics

All Known Implementing Classes:
PerceivedObject.Kinematics.Record
Enclosing interface:
PerceivedObject

public static interface PerceivedObject.Kinematics
Information on the kinematics of the perceived object.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
    Description of overlap information.
    static final record 
    Record storing kinematics information.
  • Method Summary

    Modifier and Type
    Method
    Description
    dynamicAhead(org.djunits.value.vdouble.scalar.Length distance, org.djunits.value.vdouble.scalar.Speed objectSpeed, org.djunits.value.vdouble.scalar.Acceleration objectAcceleration, boolean facingSameDirection, org.djunits.value.vdouble.scalar.Length objectLength, org.djunits.value.vdouble.scalar.Length referenceLength)
    Return kinematics for a dynamic object ahead.
    dynamicBehind(org.djunits.value.vdouble.scalar.Length distance, org.djunits.value.vdouble.scalar.Speed objectSpeed, org.djunits.value.vdouble.scalar.Acceleration objectAcceleration, boolean facingSameDirection, org.djunits.value.vdouble.scalar.Length objectLength, org.djunits.value.vdouble.scalar.Length referenceLength)
    Return kinematics for a dynamic object behind.
    org.djunits.value.vdouble.scalar.Acceleration
    Returns acceleration.
    org.djunits.value.vdouble.scalar.Length
    Retrieve the strongly typed distance to the other object.
    Returns information on the overlap for parallel objects.
    org.djunits.value.vdouble.scalar.Speed
    Returns speed.
    boolean
    Returns whether the object is facing the same direction.
    staticAhead(org.djunits.value.vdouble.scalar.Length distance)
    Return kinematics for a static object at given distance ahead.
    staticBehind(org.djunits.value.vdouble.scalar.Length distance)
    Return kinematics for a static object at given distance behind.
  • Method Details

    • getDistance

      org.djunits.value.vdouble.scalar.Length getDistance()
      Retrieve the strongly typed distance to the other object.
      Returns:
      the distance to the object
    • getSpeed

      org.djunits.value.vdouble.scalar.Speed getSpeed()
      Returns speed.
      Returns:
      the (perceived) speed of the other object
    • getAcceleration

      org.djunits.value.vdouble.scalar.Acceleration getAcceleration()
      Returns acceleration.
      Returns:
      the (perceived) acceleration of the other object
    • isFacingSameDirection

      boolean isFacingSameDirection()
      Returns whether the object is facing the same direction.
      Returns:
      whether the object is facing the same direction
    • getOverlap

      Returns information on the overlap for parallel objects. For objects fully ahead or behind that fact is provided, with null overlap values.
      Returns:
      information on the overlap for parallel objects
    • staticAhead

      static PerceivedObject.Kinematics staticAhead(org.djunits.value.vdouble.scalar.Length distance)
      Return kinematics for a static object at given distance ahead. Overlap is considered non-existent. The object is considered to face the same direction, which might not mean much for a static object.
      Parameters:
      distance - distance to object
      Returns:
      kinematics for a static object at given distance
    • staticBehind

      static PerceivedObject.Kinematics staticBehind(org.djunits.value.vdouble.scalar.Length distance)
      Return kinematics for a static object at given distance behind. Overlap is considered non-existent. The object is considered to face the same direction, which might not mean much for a static object.
      Parameters:
      distance - distance to object
      Returns:
      kinematics for a static object at given distance
    • dynamicAhead

      static PerceivedObject.Kinematics dynamicAhead(org.djunits.value.vdouble.scalar.Length distance, org.djunits.value.vdouble.scalar.Speed objectSpeed, org.djunits.value.vdouble.scalar.Acceleration objectAcceleration, boolean facingSameDirection, org.djunits.value.vdouble.scalar.Length objectLength, org.djunits.value.vdouble.scalar.Length referenceLength)
      Return kinematics for a dynamic object ahead. The distance may be negative up to an absolute value equal to the object length plus the ego length.
      Parameters:
      distance - distance from ego front to object rear (or front when not facing the same direction)
      objectSpeed - speed of perceived object
      objectAcceleration - acceleration of perceived object
      facingSameDirection - whether the object is facing the same direction
      objectLength - object length
      referenceLength - length of reference object, usually the perceiving GTU
      Returns:
      kinematic for a dynamic object
      Throws:
      IllegalArgumentException - when the distance beyond the extent of object length plus reference length
    • dynamicBehind

      static PerceivedObject.Kinematics dynamicBehind(org.djunits.value.vdouble.scalar.Length distance, org.djunits.value.vdouble.scalar.Speed objectSpeed, org.djunits.value.vdouble.scalar.Acceleration objectAcceleration, boolean facingSameDirection, org.djunits.value.vdouble.scalar.Length objectLength, org.djunits.value.vdouble.scalar.Length referenceLength)
      Return kinematics for a dynamic object behind. The distance may be negative up to an absolute value equal to the object length plus the ego length.
      Parameters:
      distance - distance from ego front to object rear (or front when not facing the same direction)
      objectSpeed - speed of perceived object
      objectAcceleration - acceleration of perceived object
      facingSameDirection - whether the object is facing the same direction
      objectLength - object length
      referenceLength - length of reference object, usually the perceiving GTU
      Returns:
      kinematic for a dynamic object
      Throws:
      IllegalArgumentException - when the distance beyond the extent of object length plus reference length