Drake
ArcRoadCurve Class Reference

RoadCurve specification for a reference curve that describes a piece of an arc. More...

#include <drake/automotive/maliput/multilane/arc_road_curve.h>

Inheritance diagram for ArcRoadCurve:
[legend]
Collaboration diagram for ArcRoadCurve:
[legend]

Public Member Functions

 ArcRoadCurve (const Vector2< double > &center, double radius, double theta0, double d_theta, const CubicPolynomial &elevation, const CubicPolynomial &superelevation)
 Constructor. More...
 
 ~ArcRoadCurve () override=default
 
double p_from_s (double s, double r) const override
 
double s_from_p (double p, double r) const override
 
Vector2< doublexy_of_p (double p) const override
 Computes the reference curve. More...
 
Vector2< doublexy_dot_of_p (double p) const override
 Computes the first derivative of the reference curve. More...
 
double heading_of_p (double p) const override
 Computes the heading of the reference curve. More...
 
double heading_dot_of_p (double p) const override
 Computes the first derivative heading of the reference curve. More...
 
double p_scale () const override
 Computes the path length integral of the reference curve for the interval [0;1] of p. More...
 
Vector3< doubleToCurveFrame (const Vector3< double > &geo_coordinate, double r_min, double r_max, const api::HBounds &height_bounds) const override
 Converts a geo_coordinate in the world frame to the composed curve frame, i.e., the superposition of the reference curve, elevation and superelevation polynomials. More...
 
bool IsValid (double r_min, double r_max, const api::HBounds &height_bounds) const override
 Checks that there are no self-intersections (singularities) in the volume created by applying the constant r_min, r_max and height_bounds to the RoadCurve. More...
 
Does not allow copy, move, or assignment
 ArcRoadCurve (const ArcRoadCurve &)=delete
 
ArcRoadCurveoperator= (const ArcRoadCurve &)=delete
 
 ArcRoadCurve (ArcRoadCurve &&)=delete
 
ArcRoadCurveoperator= (ArcRoadCurve &&)=delete
 
- Public Member Functions inherited from RoadCurve
virtual ~RoadCurve ()=default
 
const CubicPolynomialelevation () const
 
const CubicPolynomialsuperelevation () const
 
Vector3< doubleW_of_prh (double p, double r, double h) const
 Returns W, the world function evaluated at p, r, h. More...
 
Vector3< doubleW_prime_of_prh (double p, double r, double h, const Rot3 &Rabg, double g_prime) const
 Returns W' = ∂W/∂p, the partial differential of W with respect to p, evaluated at p, r, h. More...
 
Rot3 Rabg_of_p (double p) const
 Returns the rotation R_αβγ, evaluated at p along the reference curve. More...
 
Rot3 Orientation (double p, double r, double h) const
 Returns the rotation R_αβγ, evaluated at p, r and h. More...
 
Vector3< doubles_hat_of_prh (double p, double r, double h, const Rot3 &Rabg, double g_prime) const
 Returns the s-axis unit-vector, expressed in the world frame, of the (s,r,h) Lane-frame (with respect to the world frame). More...
 
Vector3< doubler_hat_of_Rabg (const Rot3 &Rabg) const
 Returns the r-axis unit-vector, expressed in the world frame, of the (s,r,h) Lane-frame (with respect to the world frame). More...
 
 RoadCurve (const RoadCurve &)=delete
 
RoadCurveoperator= (const RoadCurve &)=delete
 
 RoadCurve (RoadCurve &&)=delete
 
RoadCurveoperator= (RoadCurve &&)=delete
 

Additional Inherited Members

- Protected Member Functions inherited from RoadCurve
 RoadCurve (const CubicPolynomial &elevation, const CubicPolynomial &superelevation)
 Constructs a road curve given elevation and superelevation curves. More...
 

Detailed Description

RoadCurve specification for a reference curve that describes a piece of an arc.

Constructor & Destructor Documentation

ArcRoadCurve ( const ArcRoadCurve )
delete
ArcRoadCurve ( ArcRoadCurve &&  )
delete
ArcRoadCurve ( const Vector2< double > &  center,
double  radius,
double  theta0,
double  d_theta,
const CubicPolynomial elevation,
const CubicPolynomial superelevation 
)
inlineexplicit

Constructor.

The reference curve is created from the circle center, the radius, initial angular position theta0 and the angle span d_theta. elevation and superelevation polynomials will be used to feed RoadGeometry parent class.

Parameters
centerCenter of the reference arc.
radiusRadius of the reference arc (must be positive).
theta0Angle of the start point of the reference arc with respect to center (0 == parallel to x-axis).
d_thetaCentral angle of the arc, i.e., angular displacement from start to end. d_theta > 0 is counter-clockwise.
elevationCubicPolynomial object that represents the elevation polynomial. See RoadCurve class constructor for more details.
superelevationCubicPolynomial object that represents the superelevation polynomial. See RoadCurve class constructor for more details.
Exceptions
std::runtime_errorWhen radius is not positive.

Here is the call graph for this function:

~ArcRoadCurve ( )
overridedefault

Here is the caller graph for this function:

Member Function Documentation

double heading_dot_of_p ( double  p) const
inlineoverridevirtual

Computes the first derivative heading of the reference curve.

Parameters
pThe reference curve parameter.
Returns
The derivative of the heading with respect to p, i.e., d_heading/dp evaluated at p.

Implements RoadCurve.

Here is the call graph for this function:

Here is the caller graph for this function:

double heading_of_p ( double  p) const
inlineoverridevirtual

Computes the heading of the reference curve.

Parameters
pThe reference curve parameter.
Returns
The heading of the curve at p, i.e., the angle of the tangent vector (with respect to x-axis) in the increasing-p direction.

Implements RoadCurve.

Here is the call graph for this function:

Here is the caller graph for this function:

bool IsValid ( double  r_min,
double  r_max,
const api::HBounds height_bounds 
) const
overridevirtual

Checks that there are no self-intersections (singularities) in the volume created by applying the constant r_min, r_max and height_bounds to the RoadCurve.

Parameters
r_minMinimum lateral distance from the composed curve to evaluate the validity of the geometry.
r_maxMaximum lateral distance from the composed curve to evaluate the validity of the geometry.
height_boundsAn api::HBounds object that represents the elevation bounds of the surface mapping.
Returns
True when there are no self-intersections.

Implements RoadCurve.

Here is the call graph for this function:

Here is the caller graph for this function:

ArcRoadCurve& operator= ( ArcRoadCurve &&  )
delete
ArcRoadCurve& operator= ( const ArcRoadCurve )
delete
double p_from_s ( double  s,
double  r 
) const
overridevirtual
Exceptions
std::runtime_errorWhen r makes the effective radius to be negative or zero.

Implements RoadCurve.

Here is the call graph for this function:

Here is the caller graph for this function:

double p_scale ( ) const
inlineoverridevirtual

Computes the path length integral of the reference curve for the interval [0;1] of p.

Returns
The path length integral of the reference curve.

Implements RoadCurve.

Here is the call graph for this function:

Here is the caller graph for this function:

double s_from_p ( double  p,
double  r 
) const
overridevirtual
Exceptions
std::runtime_errorWhen r makes the effective radius to be negative or zero.

Implements RoadCurve.

Here is the call graph for this function:

Here is the caller graph for this function:

Vector3< double > ToCurveFrame ( const Vector3< double > &  geo_coordinate,
double  r_min,
double  r_max,
const api::HBounds height_bounds 
) const
overridevirtual

Converts a geo_coordinate in the world frame to the composed curve frame, i.e., the superposition of the reference curve, elevation and superelevation polynomials.

The resulting coordinates [p, r, h] are saturated in the following domain ranges.

  • p: [0, 1]
  • r: [r_min, r_max]
  • h: [height_bounds]
    Parameters
    geo_coordinateA 3D vector in the world frame to be converted to the composed curve frame.
    r_minMinimum lateral distance from the composed curve to saturate, if it is necessary, the result in the given direction.
    r_maxMaximum lateral distance from the composed curve to evaluate, if it is necessary, the result in the given direction
    height_boundsAn api::HBounds object that represents the elevation bounds of the surface mapping.
    Returns
    A 3D vector [p, r, h], that represent the domain coordinates of the world function, that gives as world function output geo_cooridnate.

Implements RoadCurve.

Here is the call graph for this function:

Here is the caller graph for this function:

Vector2<double> xy_dot_of_p ( double  p) const
inlineoverridevirtual

Computes the first derivative of the reference curve.

Parameters
pThe reference curve parameter.
Returns
The derivative of the curve with respect to p, at p, i.e., F'(p0) = (dx/dp, dy/dp) at p0.

Implements RoadCurve.

Here is the call graph for this function:

Here is the caller graph for this function:

Vector2<double> xy_of_p ( double  p) const
inlineoverridevirtual

Computes the reference curve.

Parameters
pThe reference curve parameter.
Returns
The reference curve itself, F(p).

Implements RoadCurve.

Here is the call graph for this function:

Here is the caller graph for this function:


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