15 #ifndef TRAFFIC_SIMULATOR__BEHAVIOR__LONGITUDINAL_SPEED_PLANNING_HPP_
16 #define TRAFFIC_SIMULATOR__BEHAVIOR__LONGITUDINAL_SPEED_PLANNING_HPP_
18 #include <traffic_simulator_msgs/msg/action_status.hpp>
19 #include <traffic_simulator_msgs/msg/dynamic_constraints.hpp>
24 namespace longitudinal_speed_planning
31 double target_speed,
const traffic_simulator_msgs::msg::DynamicConstraints &,
32 const geometry_msgs::msg::Twist & current_twist,
33 const geometry_msgs::msg::Accel & current_accel)
const
34 -> std::tuple<geometry_msgs::msg::Twist, geometry_msgs::msg::Accel, double>;
36 double target_speed,
const traffic_simulator_msgs::msg::DynamicConstraints &,
37 const geometry_msgs::msg::Twist & current_twist,
38 const geometry_msgs::msg::Accel & current_accel)
const -> double;
40 double target_speed,
const geometry_msgs::msg::Twist & current_twist,
41 const geometry_msgs::msg::Accel & current_accel,
double acceleration_duration,
42 const traffic_simulator_msgs::msg::DynamicConstraints & constraints)
43 -> traffic_simulator_msgs::msg::DynamicConstraints;
45 double target_speed,
const traffic_simulator_msgs::msg::DynamicConstraints &,
46 const geometry_msgs::msg::Twist & current_twist,
47 const geometry_msgs::msg::Accel & current_accel,
double current_linear_jerk)
const -> double;
48 auto isAccelerating(
double target_speed,
const geometry_msgs::msg::Twist & current_twist)
const
50 auto isDecelerating(
double target_speed,
const geometry_msgs::msg::Twist & current_twist)
const
53 double target_speed,
const geometry_msgs::msg::Twist & current_twist,
54 double tolerance = 0.01)
const noexcept -> bool;
59 auto isReachedToTargetSpeedWithConstantJerk(
60 double target_speed,
const traffic_simulator_msgs::msg::DynamicConstraints &,
61 const geometry_msgs::msg::Twist & current_twist,
62 const geometry_msgs::msg::Accel & current_accel,
double duration,
double tolerance = 0.01) const
64 auto getVelocityWithConstantJerk(
65 double target_speed, const geometry_msgs::msg::Twist & current_twist,
66 const geometry_msgs::msg::Accel & current_accel,
67 const traffic_simulator_msgs::msg::DynamicConstraints &,
double duration) const ->
double;
68 auto getVelocityWithConstantJerk(
69 const geometry_msgs::msg::Twist & current_twist,
70 const geometry_msgs::msg::Accel & current_accel,
double linear_jerk,
double duration) const
72 auto getQuadraticAccelerationDuration(
73 double target_speed, const traffic_simulator_msgs::msg::DynamicConstraints &,
74 const geometry_msgs::msg::Twist & current_twist,
75 const geometry_msgs::msg::Accel & current_accel) const ->
double;
76 auto getLinearAccelerationDuration(
77 double target_speed, const traffic_simulator_msgs::msg::DynamicConstraints &,
78 const geometry_msgs::msg::Twist & current_twist,
79 const geometry_msgs::msg::Accel & current_accel) const ->
double;
80 auto getQuadraticAccelerationDurationWithConstantJerk(
81 double target_speed, const traffic_simulator_msgs::msg::DynamicConstraints &,
82 const geometry_msgs::msg::Twist & current_twist,
83 const geometry_msgs::msg::Accel & current_accel) const ->
double;
85 double target_speed, const traffic_simulator_msgs::msg::DynamicConstraints &,
86 const geometry_msgs::msg::Twist & current_twist,
87 const geometry_msgs::msg::Accel & current_accel) const ->
double;
89 double linear_jerk, const geometry_msgs::msg::Accel &,
90 const traffic_simulator_msgs::msg::DynamicConstraints &) const -> geometry_msgs::msg::Accel;
92 const geometry_msgs::msg::Accel &, const geometry_msgs::msg::Twist &,
93 const traffic_simulator_msgs::msg::DynamicConstraints &) const -> geometry_msgs::msg::Twist;
95 const geometry_msgs::msg::Twist & before, const geometry_msgs::msg::Twist & after) const
96 -> geometry_msgs::msg::Accel;
98 const geometry_msgs::msg::Accel & before, const geometry_msgs::msg::Accel & after) const
Definition: longitudinal_speed_planning.hpp:27
const std::string entity
Definition: longitudinal_speed_planning.hpp:56
LongitudinalSpeedPlanner(const double step_time, const std::string &entity)
Definition: longitudinal_speed_planning.cpp:26
auto getDynamicStates(double target_speed, const traffic_simulator_msgs::msg::DynamicConstraints &, const geometry_msgs::msg::Twist ¤t_twist, const geometry_msgs::msg::Accel ¤t_accel) const -> std::tuple< geometry_msgs::msg::Twist, geometry_msgs::msg::Accel, double >
Definition: longitudinal_speed_planning.cpp:92
auto isTargetSpeedReached(double target_speed, const geometry_msgs::msg::Twist ¤t_twist, double tolerance=0.01) const noexcept -> bool
Definition: longitudinal_speed_planning.cpp:136
auto getRunningDistance(double target_speed, const traffic_simulator_msgs::msg::DynamicConstraints &, const geometry_msgs::msg::Twist ¤t_twist, const geometry_msgs::msg::Accel ¤t_accel, double current_linear_jerk) const -> double
Definition: longitudinal_speed_planning.cpp:109
auto isDecelerating(double target_speed, const geometry_msgs::msg::Twist ¤t_twist) const -> bool
Definition: longitudinal_speed_planning.cpp:262
auto planConstraintsFromJerkAndTimeConstraint(double target_speed, const geometry_msgs::msg::Twist ¤t_twist, const geometry_msgs::msg::Accel ¤t_accel, double acceleration_duration, const traffic_simulator_msgs::msg::DynamicConstraints &constraints) -> traffic_simulator_msgs::msg::DynamicConstraints
Definition: longitudinal_speed_planning.cpp:41
auto getAccelerationDuration(double target_speed, const traffic_simulator_msgs::msg::DynamicConstraints &, const geometry_msgs::msg::Twist ¤t_twist, const geometry_msgs::msg::Accel ¤t_accel) const -> double
Definition: longitudinal_speed_planning.cpp:32
auto isAccelerating(double target_speed, const geometry_msgs::msg::Twist ¤t_twist) const -> bool
Definition: longitudinal_speed_planning.cpp:256
const double step_time
Definition: longitudinal_speed_planning.hpp:55
std::string string
Definition: junit5.hpp:26