Autopysta
Loading...
Searching...
No Matches
no_lch Class Reference

A lane-changing model that forbids any lane changes. More...

#include <no_lch.h>

Inheritance diagram for no_lch:
lcm

Public Member Functions

 no_lch ()
 Default constructor for the no_lch model.
 
bool lch_left (point *leader, point *follower, point *new_leader, point *new_follower, model *cfm, params *lcmpars) override
 Determine if the vehicle should change lanes to the left.
 
bool lch_right (point *leader, point *follower, point *new_leader, point *new_follower, model *cfm, params *lcmpars) override
 Determine if the vehicle should change lanes to the right.
 
- Public Member Functions inherited from lcm

Additional Inherited Members

- Protected Member Functions inherited from lcm
- Protected Attributes inherited from lcm
model_cf
 Car-following model used in conjunction with lane-changing decisions.
 
params_lcpars
 Lane-changing model parameters.
 

Detailed Description

A lane-changing model that forbids any lane changes.

This class represents a model where no lane-changing maneuvers are allowed. It acts as a fallback or placeholder model when lane-changing is not considered in a traffic simulation.

Constructor & Destructor Documentation

◆ no_lch()

no_lch::no_lch ( )

Default constructor for the no_lch model.

Initializes the lane-changing model with no parameters and prohibits all lane changes.

Member Function Documentation

◆ lch_left()

bool no_lch::lch_left ( point * leader,
point * follower,
point * new_leader,
point * new_follower,
model * cfm,
params * lcmpars )
overridevirtual

Determine if the vehicle should change lanes to the left.

Always returns false since lane changes are disallowed.

Parameters
leaderThe current leader's position and speed (optional).
followerThe subject vehicle's position and speed.
new_leaderThe position and speed of the new leader after lane change (optional).
new_followerThe position and speed of the new follower after lane change (optional).
cfmA car-following model.
lcmparsLane-changing model parameters.
Returns
Always returns false.

Implements lcm.

◆ lch_right()

bool no_lch::lch_right ( point * leader,
point * follower,
point * new_leader,
point * new_follower,
model * cfm,
params * lcmpars )
overridevirtual

Determine if the vehicle should change lanes to the right.

Always returns false since lane changes are disallowed.

Parameters
leaderThe current leader's position and speed (optional).
followerThe subject vehicle's position and speed.
new_leaderThe position and speed of the new leader after lane change (optional).
new_followerThe position and speed of the new follower after lane change (optional).
cfmA car-following model.
lcmparsLane-changing model parameters.
Returns
Always returns false.

Implements lcm.


The documentation for this class was generated from the following file: