EigenGrasp Class Reference

A single eigengrasp direction. More...

#include <eigenGrasp.h>

List of all members.

Public Member Functions

double dot (double *d)
 This is the main function that is used: dot the EG against another mSize-dimensional vector.
 EigenGrasp (const EigenGrasp *orig)
 Copy constructor.
 EigenGrasp (int size, double e=0)
 Initializes an empty eigengrasp of a given size.
void fix (double a)
 Tells this eigengrasp that it is fixed at the given value.
double getAxisValue (int i) const
 Returns the comonent of this eigengrasp along the i-th dimension.
void getEigenGrasp (double *eg) const
 Returns the mSize-dimensional vector itself.
double getEigenValue () const
 Gets the eigenvalue associated w. this eigengrasp; not used.
int getSize () const
double normalize ()
 Normalizes this eigengrasp to norm 1.
void readFromFile (FILE *fp)
int readFromStream (QTextStream *stream)
int readFromXml (const TiXmlElement *element)
void setAxisValue (int i, double val)
 Sets the component of this eigengrasp along the i-th dimension.
void setEigenGrasp (const double *eg)
 Sets the mSize-dimensional vector itself.
void setEigenValue (double e)
 Sets the eigenvalue associated w. this eigengrasp; not used.
void setOnes ()
 Sets this eigengrasp to the vector [1,...,1].
void unfix ()
 Tells this eigengrasp that it can move freely.
void writeToFile (TiXmlElement *ep)
void writeToFile (FILE *fp)
 ~EigenGrasp ()

Public Attributes

double fixedAmplitude
 If this eigengrasp is fixed, this is the value that is was fixed at.
bool mFixed
 Remembers if the amplitude along this EG is fixed (no motion along this EG is allowed).
double mMax
 Stores the max value along this eigengrasp that is inside the legal joint range.
double mMin
 Stores the min value along this eigengrasp that is inside the legal joint range.
bool mPredefinedLimits
 True if limits loaded from EigenGrasp File. If this is false Graspit! will attempt to compute limits at runtime.

Private Attributes

double mEigenValue
 The eigenvalue corresponding to this EG. Not actually used anywhere, just here if ever needed.
int mSize
 Dimension of this eigengrasp.
double * mVals
 The actual vector.

Detailed Description

A single eigengrasp direction.

An eigengrasp holds a generalized direction of motion in mSize dimensions. mSize is assumed to be the number of dofs of the robot that this is used for. It is essentially an msize-dimensional vector.

mMin and mMax store the min and max amplitudes of motion along this eigengrasp that will not take the robot outside the acceptable DOF range. They only make sense when defined relative to an ORIGIN of motion!

Definition at line 57 of file eigenGrasp.h.


Constructor & Destructor Documentation

EigenGrasp::EigenGrasp ( int  size,
double  e = 0 
)

Initializes an empty eigengrasp of a given size.

The eigengrasp is initialized to all 0s

Definition at line 42 of file eigenGrasp.cpp.

EigenGrasp::EigenGrasp ( const EigenGrasp orig  ) 

Copy constructor.

Definition at line 57 of file eigenGrasp.cpp.

EigenGrasp::~EigenGrasp (  ) 

Definition at line 69 of file eigenGrasp.cpp.


Member Function Documentation

double EigenGrasp::dot ( double *  d  ) 

This is the main function that is used: dot the EG against another mSize-dimensional vector.

Definition at line 222 of file eigenGrasp.cpp.

void EigenGrasp::fix ( double  a  )  [inline]

Tells this eigengrasp that it is fixed at the given value.

Definition at line 119 of file eigenGrasp.h.

double EigenGrasp::getAxisValue ( int  i  )  const [inline]

Returns the comonent of this eigengrasp along the i-th dimension.

Definition at line 101 of file eigenGrasp.h.

void EigenGrasp::getEigenGrasp ( double *  eg  )  const

Returns the mSize-dimensional vector itself.

Definition at line 75 of file eigenGrasp.cpp.

double EigenGrasp::getEigenValue (  )  const [inline]

Gets the eigenvalue associated w. this eigengrasp; not used.

Definition at line 93 of file eigenGrasp.h.

int EigenGrasp::getSize (  )  const [inline]

Definition at line 85 of file eigenGrasp.h.

double EigenGrasp::normalize (  ) 

Normalizes this eigengrasp to norm 1.

Definition at line 89 of file eigenGrasp.cpp.

void EigenGrasp::readFromFile ( FILE *  fp  ) 

Definition at line 141 of file eigenGrasp.cpp.

int EigenGrasp::readFromStream ( QTextStream *  stream  ) 

Definition at line 159 of file eigenGrasp.cpp.

int EigenGrasp::readFromXml ( const TiXmlElement element  ) 

Definition at line 176 of file eigenGrasp.cpp.

void EigenGrasp::setAxisValue ( int  i,
double  val 
) [inline]

Sets the component of this eigengrasp along the i-th dimension.

Definition at line 103 of file eigenGrasp.h.

void EigenGrasp::setEigenGrasp ( const double *  eg  ) 

Sets the mSize-dimensional vector itself.

Definition at line 82 of file eigenGrasp.cpp.

void EigenGrasp::setEigenValue ( double  e  )  [inline]

Sets the eigenvalue associated w. this eigengrasp; not used.

Definition at line 95 of file eigenGrasp.h.

void EigenGrasp::setOnes (  )  [inline]

Sets this eigengrasp to the vector [1,...,1].

Definition at line 98 of file eigenGrasp.h.

void EigenGrasp::unfix (  )  [inline]

Tells this eigengrasp that it can move freely.

Definition at line 121 of file eigenGrasp.h.

void EigenGrasp::writeToFile ( TiXmlElement ep  ) 

Definition at line 104 of file eigenGrasp.cpp.

void EigenGrasp::writeToFile ( FILE *  fp  ) 

Definition at line 131 of file eigenGrasp.cpp.


Member Data Documentation

If this eigengrasp is fixed, this is the value that is was fixed at.

Definition at line 77 of file eigenGrasp.h.

double EigenGrasp::mEigenValue [private]

The eigenvalue corresponding to this EG. Not actually used anywhere, just here if ever needed.

Definition at line 65 of file eigenGrasp.h.

Remembers if the amplitude along this EG is fixed (no motion along this EG is allowed).

Definition at line 75 of file eigenGrasp.h.

Stores the max value along this eigengrasp that is inside the legal joint range.

Definition at line 71 of file eigenGrasp.h.

Stores the min value along this eigengrasp that is inside the legal joint range.

Definition at line 69 of file eigenGrasp.h.

True if limits loaded from EigenGrasp File. If this is false Graspit! will attempt to compute limits at runtime.

Definition at line 73 of file eigenGrasp.h.

int EigenGrasp::mSize [private]

Dimension of this eigengrasp.

Definition at line 61 of file eigenGrasp.h.

double* EigenGrasp::mVals [private]

The actual vector.

Definition at line 63 of file eigenGrasp.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


graspit
Author(s):
autogenerated on Fri Jan 11 11:20:35 2013