RobWorkProject  24.12.4-
Public Member Functions | Static Public Member Functions | Friends | List of all members
ModRusselBeamBase Class Referenceabstract

Base class for implementing Modified Russel beam problems. More...

#include <ModRusselBeamBase.hpp>

Inherited by ModRusselBeamIpopt.

Public Member Functions

 ModRusselBeamBase (std::shared_ptr< rwlibs::softbody::BeamGeometry > geomPtr, std::shared_ptr< rwlibs::softbody::BeamObstaclePlane > obstaclePtr, int M)
 Constructor. More...
 
virtual void solve (Eigen::VectorXd &xinituser, Eigen::VectorXd &U, Eigen::VectorXd &V)=0
 
void integrateAngleU (Eigen::VectorXd &U, const Eigen::VectorXd &avec)
 given a vector of angles, calculates the x-part of the corresponding curve More...
 
void integrateAngleV (Eigen::VectorXd &V, const Eigen::VectorXd &avec)
 given a vector of angles, calculates the y-part of the corresponding curve More...
 
std::vector< int > getIntegralIndices (void) const
 returns the indices on the beam at which to place integral constraints More...
 
void setIntegralIndices (const std::vector< int > &indices)
 sets the integral indices for the beam More...
 
std::shared_ptr< BeamGeometrygetGeometry (void) const
 returns the BeamGeometry used by the beam More...
 
std::shared_ptr< BeamObstaclePlanegetObstacle (void) const
 returns the BeamObstaclePlane used by the beam More...
 
int getM (void) const
 returns number of cross sections in beam More...
 
double getAccuracy (void) const
 returns accuracy goal of underlying numerical methods More...
 
void setAccuracy (double acc)
 sets accuracy goal of underlying numerical methods More...
 
rw::math::Transform3D< double > get_planeTbeam (void) const
 returns the plane to beam transform More...
 
double get_thetaTCP (void) const
 returns the angle of the beam base frame wrt. the associated obstacle plane More...
 
double get_yTCP (void) const
 returns the height of the beam baseframe over the associated obstacle plane More...
 
double get_uxTCPy (void) const
 return the x-component of the y-axis of the beam baseframe, for the current plane to beam transform More...
 
double get_uyTCPy (void) const
 return the y-component of the y-axis of the beam baseframe, for the current plane to beam transform More...
 
double get_h (void) const
 return the discretization step for the beam cross sections More...
 

Static Public Member Functions

static std::vector< int > computeIntegralIndicies (const int nIntegralConstraints, const int N)
 precomputes the indices on the beam at which to place integral constraints More...
 
static double get_uxTCPy (const rw::math::Transform3D<> planeTbeam)
 return the x-component of the y-axis of the beam baseframe More...
 
static double get_uyTCPy (const rw::math::Transform3D<> planeTbeam)
 return the y-component of the y-axis of the beam baseframe More...
 

Friends

std::ostream & operator<< (std::ostream &out, const ModRusselBeamBase &obj)
 outputs a ModRusselBeamBase to stream More...
 

Detailed Description

Base class for implementing Modified Russel beam problems.

Constructor & Destructor Documentation

◆ ModRusselBeamBase()

ModRusselBeamBase ( std::shared_ptr< rwlibs::softbody::BeamGeometry geomPtr,
std::shared_ptr< rwlibs::softbody::BeamObstaclePlane obstaclePtr,
int  M 
)

Constructor.

Parameters
geomPtrpointer to the beam geometry
obstaclePtrpointer to the obstacle
Mnumber of slices in the beam

Member Function Documentation

◆ computeIntegralIndicies()

static std::vector<int> computeIntegralIndicies ( const int  nIntegralConstraints,
const int  N 
)
static

precomputes the indices on the beam at which to place integral constraints

This function will precompute indices on the beam at which integral constraints are present to check for penetration with the plane. For nIntegralConstraints equal to 1, only the tip at x=L will be tested. For 2 integral constraints, indices equivalent to x=L and x=L/2 will be tested and so forth.

The number of integral constraints is set by the method set_nIntegralConstraints

Bug:
Does not support more than M/2 integral constraints

◆ get_h()

double get_h ( void  ) const

return the discretization step for the beam cross sections

Returns
discretization step

◆ get_planeTbeam()

rw::math::Transform3D<double> get_planeTbeam ( void  ) const

returns the plane to beam transform

Returns
plane to beam transform

◆ get_thetaTCP()

double get_thetaTCP ( void  ) const

returns the angle of the beam base frame wrt. the associated obstacle plane

Returns
angle of beam base in radians

◆ get_uxTCPy() [1/2]

static double get_uxTCPy ( const rw::math::Transform3D<>  planeTbeam)
static

return the x-component of the y-axis of the beam baseframe

Parameters
planeTbeamthe plane to beam transform to use
Returns
x-component of the y-axis of the beam baseframe

◆ get_uxTCPy() [2/2]

double get_uxTCPy ( void  ) const

return the x-component of the y-axis of the beam baseframe, for the current plane to beam transform

Returns
x-component of the y-axis of the beam baseframe

◆ get_uyTCPy() [1/2]

static double get_uyTCPy ( const rw::math::Transform3D<>  planeTbeam)
static

return the y-component of the y-axis of the beam baseframe

Parameters
planeTbeamthe plane to beam transform to use
Returns
x-component of the y-axis of the beam baseframe

◆ get_uyTCPy() [2/2]

double get_uyTCPy ( void  ) const

return the y-component of the y-axis of the beam baseframe, for the current plane to beam transform

Returns
x-component of the y-axis of the beam baseframe

◆ get_yTCP()

double get_yTCP ( void  ) const

returns the height of the beam baseframe over the associated obstacle plane

Returns
height above the obstacle in millimeters

◆ getAccuracy()

double getAccuracy ( void  ) const

returns accuracy goal of underlying numerical methods

Returns
accuracy goal

◆ getGeometry()

std::shared_ptr<BeamGeometry> getGeometry ( void  ) const

returns the BeamGeometry used by the beam

Returns
the BeamGeometry used by the beam

◆ getIntegralIndices()

std::vector<int> getIntegralIndices ( void  ) const

returns the indices on the beam at which to place integral constraints

Returns
indices on the beam

◆ getM()

int getM ( void  ) const

returns number of cross sections in beam

Returns
number of cross sections in beam

◆ getObstacle()

std::shared_ptr<BeamObstaclePlane> getObstacle ( void  ) const

returns the BeamObstaclePlane used by the beam

Returns
the BeamObstaclePlane used by the beam

◆ integrateAngleU()

void integrateAngleU ( Eigen::VectorXd &  U,
const Eigen::VectorXd &  avec 
)

given a vector of angles, calculates the x-part of the corresponding curve

Parameters
Ureference to the vector to store the x-component in
avecreference to the vector of angles

◆ integrateAngleV()

void integrateAngleV ( Eigen::VectorXd &  V,
const Eigen::VectorXd &  avec 
)

given a vector of angles, calculates the y-part of the corresponding curve

Parameters
Vreference to the vector to store the x-component in
avecreference to the vector of angles

◆ setAccuracy()

void setAccuracy ( double  acc)

sets accuracy goal of underlying numerical methods

Parameters
accaccuracy goal

◆ setIntegralIndices()

void setIntegralIndices ( const std::vector< int > &  indices)

sets the integral indices for the beam

Parameters
indicesvector of indices

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  out,
const ModRusselBeamBase obj 
)
friend

outputs a ModRusselBeamBase to stream

Parameters
outthe stream
objthe beam
Returns
a stream

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