Robotics Library  0.7.0
Public Member Functions | Static Public Member Functions | Protected Attributes | List of all members
rl::math::Circular< Vector2 > Class Reference

Circular segment function that maps from a time x to a point in 2D on a circular trajectory. More...

#include <CircularVector2.h>

Inheritance diagram for rl::math::Circular< Vector2 >:
Inheritance graph
[legend]

Public Member Functions

 Circular ()
 
virtual ~Circular ()
 
Circular< Vector2 > * clone () const
 
Real getAngle () const
 
Vector2 getAxisX () const
 
Vector2 getAxisY () const
 
Vector2 getCenter () const
 
Vector2 operator() (const Real &x, const ::std::size_t &derivative=0) const
 Evaluates the circular segment function for a given x. More...
 
- Public Member Functions inherited from rl::math::Function< Vector2 >
 Function ()
 
virtual ~Function ()
 
virtual Functionclone () const=0
 
Real duration () const
 
Reallower ()
 
const Reallower () const
 
Realupper ()
 
const Realupper () const
 

Static Public Member Functions

static Circular< Vector2ThreePoints (const Vector2 &y0, const Vector2 &yi, const Vector2 &y1, const Real &x1=1)
 Generates a circular segment function in 2D through three given points. More...
 
static Circular< Vector2ThreePointsAngle (const Vector2 &y0, const Vector2 &yi, const Vector2 &y1, const Real &angle, const Real &x1=1)
 Generates a circular segment through three given points in 2D with a given segment angle. More...
 

Protected Attributes

Real angle
 Angle of circular motion. More...
 
Vector2 axisX
 First axis of the circular motion. More...
 
Vector2 axisY
 Second axis of the circular motion. More...
 
Vector2 center
 Center of the circle. More...
 
- Protected Attributes inherited from rl::math::Function< Vector2 >
Real x0
 
Real x1
 

Detailed Description

Circular segment function that maps from a time x to a point in 2D on a circular trajectory.

Constructor & Destructor Documentation

◆ Circular()

◆ ~Circular()

virtual rl::math::Circular< Vector2 >::~Circular ( )
inlinevirtual

Member Function Documentation

◆ clone()

Circular<Vector2>* rl::math::Circular< Vector2 >::clone ( ) const
inline

◆ getAngle()

Real rl::math::Circular< Vector2 >::getAngle ( ) const
inline

◆ getAxisX()

Vector2 rl::math::Circular< Vector2 >::getAxisX ( ) const
inline

◆ getAxisY()

Vector2 rl::math::Circular< Vector2 >::getAxisY ( ) const
inline

◆ getCenter()

Vector2 rl::math::Circular< Vector2 >::getCenter ( ) const
inline

◆ operator()()

Vector2 rl::math::Circular< Vector2 >::operator() ( const Real x,
const ::std::size_t &  derivative = 0 
) const
inlinevirtual

Evaluates the circular segment function for a given x.

Note that only the first two derivatives are implemented, all higher orders will return NaN.

Implements rl::math::Function< Vector2 >.

◆ ThreePoints()

static Circular<Vector2> rl::math::Circular< Vector2 >::ThreePoints ( const Vector2 y0,
const Vector2 yi,
const Vector2 y1,
const Real x1 = 1 
)
inlinestatic

Generates a circular segment function in 2D through three given points.

The given points most not be (numerically close to) colinear.

◆ ThreePointsAngle()

static Circular<Vector2> rl::math::Circular< Vector2 >::ThreePointsAngle ( const Vector2 y0,
const Vector2 yi,
const Vector2 y1,
const Real angle,
const Real x1 = 1 
)
inlinestatic

Generates a circular segment through three given points in 2D with a given segment angle.

The given points must not be (numerically close to) colinear. Contrary to ThreePoints, where the circular segment ends in y1, the circular segments ends after a given angle. With this, a full circle can be constructed, given an angle of 2*pi. The given segment angle may be any real number, which allows multiple rotations.

Member Data Documentation

◆ angle

Real rl::math::Circular< Vector2 >::angle
protected

Angle of circular motion.

Any real value is allowed.

◆ axisX

Vector2 rl::math::Circular< Vector2 >::axisX
protected

First axis of the circular motion.

Note that at time 0, the function value is (center + axisX).

◆ axisY

Vector2 rl::math::Circular< Vector2 >::axisY
protected

Second axis of the circular motion.

After a motion of 90 degrees, the function value is (center + axisY).

◆ center

Vector2 rl::math::Circular< Vector2 >::center
protected

Center of the circle.


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