ocra-recipes
Doxygen documentation for the ocra-recipes repository
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ocra::ExperimentalTrajectory Class Reference

#include <ExperimentalTrajectory.h>

Inheritance diagram for ocra::ExperimentalTrajectory:
[legend]
Collaboration diagram for ocra::ExperimentalTrajectory:
[legend]

Public Member Functions

void calculateVarianceParameters ()
 
Eigen::MatrixXd getDesiredValues (double time)
 
Eigen::VectorXd getVariance (double time)
 
void getDesiredValues (double time, Eigen::MatrixXd &desiredValues, Eigen::VectorXd &variance)
 
void getDesiredValues (double time, Eigen::Displacementd &position, Eigen::Twistd &velocity, Eigen::Twistd &acceleration)
 
double getMaxVariance ()
 
Eigen::MatrixXd getWaypointData ()
 
void addNewWaypoint (Eigen::VectorXd newWaypoint, double waypointTime)
 
void removeYoungestWaypoint ()
 
void removeWaypoint (int index)
 
Eigen::MatrixXd getRbfnKernelCurves ()
 
- Public Member Functions inherited from ocra::Trajectory
 Trajectory ()
 
void setMaxVelocity (double newMaxVel)
 
void setMaxVelocity (const Eigen::VectorXd &newMaxVel)
 
double getMaxVelocity ()
 
Eigen::VectorXd getMaxVelocityVector ()
 
void setMaxAcceleration (double newMaxAcc)
 
void setMaxAcceleration (const Eigen::VectorXd &newMaxAcc)
 
double getMaxAcceleration ()
 
Eigen::VectorXd getMaxAccelerationVector ()
 
void setWaypoints (const std::vector< double > &startingDoubleVec, const std::vector< double > &endingDoubleVec, const int waypointSelector=0, bool endsWithQuaternion=false)
 
void setWaypoints (const Eigen::VectorXd &startingVector, const Eigen::VectorXd &endingVector, bool endsWithQuaternion=false)
 
void setWaypoints (Eigen::Displacementd &startingDisplacement, Eigen::Displacementd &endingDisplacement, bool endsWithQuaternion=true)
 
void setWaypoints (Eigen::Rotation3d &startingOrientation, Eigen::Rotation3d &endingOrientation, bool endsWithQuaternion=true)
 
void setWaypoints (const std::list< Eigen::VectorXd > &_waypoints, bool _endsWithQuaternion=false)
 
void setWaypoints (Eigen::MatrixXd &waypoints, bool endsWithQuaternion=false)
 
virtual ~Trajectory ()
 
void setDuration ()
 
void setDuration (const Eigen::VectorXd &_pointToPointDurationVector)
 
void setDuration (double time)
 
bool isFinished ()
 
Eigen::MatrixXd getFullTrajectory (double dt=0.01)
 
void getDesiredValues (double time, std::vector< double > &doubleVec)
 
void getDesiredValues (double time, Eigen::Displacementd &disp)
 
void getDesiredValues (double time, Eigen::Rotation3d &orient)
 
void getDesiredValues (double time, Eigen::Displacementd &pos, Eigen::Twistd &vel, Eigen::Twistd &acc)
 
virtual double getDuration ()
 
Eigen::Rotation3d quaternionSlerp (double tau, Eigen::Rotation3d &qStart, Eigen::Rotation3d &qEnd)
 
Eigen::VectorXd displacementToEigenVector (Eigen::Displacementd &disp)
 
Eigen::VectorXd quaternionToEigenVector (Eigen::Rotation3d &quat)
 
bool eigenVectorToStdVector (const Eigen::VectorXd &dispVec, std::vector< double > &doubleVec)
 
bool eigenMatrixToStdVector (const Eigen::MatrixXd &dispMat, std::vector< double > &doubleVec)
 
bool eigenVectorToDisplacement (const Eigen::VectorXd &dispVec, Eigen::Displacementd &disp)
 
bool eigenVectorToQuaternion (const Eigen::VectorXd &quatVec, Eigen::Rotation3d &quat)
 
bool eigenVectorToTwist (const Eigen::VectorXd &twistVec, Eigen::Twistd &twist)
 
virtual void recalculateTrajectory ()
 

Protected Member Functions

virtual void initializeTrajectory ()
 

Protected Attributes

double t0
 
double t0_variance
 
bool varianceStartTrigger
 
- Protected Attributes inherited from ocra::Trajectory
double maximumVelocity
 
Eigen::VectorXd maximumVelocityVector
 
double maximumAcceleration
 
Eigen::VectorXd maximumAccelerationVector
 
std::list< Eigen::VectorXd > waypointList
 
Eigen::MatrixXd waypoints
 
int nDoF
 
int nWaypoints
 
bool endsWithQuaternion
 
bool startTrigger
 
int currentWaypointIndex
 
int nonRotationDof
 
Eigen::VectorXd pointToPointDurationVector
 
double pointToPointDuration
 
double totalTrajectoryDuration
 
bool usingDurationVector
 
bool trajectoryFinished
 

Detailed Description

Definition at line 11 of file ExperimentalTrajectory.h.

Member Function Documentation

void ocra::ExperimentalTrajectory::addNewWaypoint ( Eigen::VectorXd  newWaypoint,
double  waypointTime 
)

Definition at line 327 of file ExperimentalTrajectory.cpp.

void ocra::ExperimentalTrajectory::calculateVarianceParameters ( )

Definition at line 12 of file ExperimentalTrajectory.cpp.

Eigen::MatrixXd ocra::ExperimentalTrajectory::getDesiredValues ( double  time)
virtual

For details on the analytical point to point min-jerk formulation see: http://www.jneurosci.org/content/5/7/1688.full.pdf http://shadmehrlab.org/book/minimum_jerk/minimumjerk.htm

Reimplemented from ocra::Trajectory.

Definition at line 175 of file ExperimentalTrajectory.cpp.

void ocra::ExperimentalTrajectory::getDesiredValues ( double  time,
Eigen::MatrixXd &  desiredValues,
Eigen::VectorXd &  variance 
)
virtual

Reimplemented from ocra::Trajectory.

Definition at line 253 of file ExperimentalTrajectory.cpp.

void ocra::ExperimentalTrajectory::getDesiredValues ( double  time,
Eigen::Displacementd &  position,
Eigen::Twistd &  velocity,
Eigen::Twistd &  acceleration 
)

Definition at line 260 of file ExperimentalTrajectory.cpp.

double ocra::ExperimentalTrajectory::getMaxVariance ( )

Definition at line 309 of file ExperimentalTrajectory.cpp.

Eigen::MatrixXd ocra::ExperimentalTrajectory::getRbfnKernelCurves ( )

Definition at line 421 of file ExperimentalTrajectory.cpp.

Eigen::VectorXd ocra::ExperimentalTrajectory::getVariance ( double  time)

Definition at line 229 of file ExperimentalTrajectory.cpp.

Eigen::MatrixXd ocra::ExperimentalTrajectory::getWaypointData ( )

Definition at line 39 of file ExperimentalTrajectory.cpp.

void ocra::ExperimentalTrajectory::initializeTrajectory ( )
protectedvirtual

Reimplemented from ocra::Trajectory.

Definition at line 267 of file ExperimentalTrajectory.cpp.

void ocra::ExperimentalTrajectory::removeWaypoint ( int  index)

Definition at line 388 of file ExperimentalTrajectory.cpp.

void ocra::ExperimentalTrajectory::removeYoungestWaypoint ( )

Definition at line 383 of file ExperimentalTrajectory.cpp.

Member Data Documentation

double ocra::ExperimentalTrajectory::t0
protected

Definition at line 38 of file ExperimentalTrajectory.h.

double ocra::ExperimentalTrajectory::t0_variance
protected

Definition at line 38 of file ExperimentalTrajectory.h.

bool ocra::ExperimentalTrajectory::varianceStartTrigger
protected

Definition at line 39 of file ExperimentalTrajectory.h.


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