- 3.0.2 rigid body dynamics module.
|
NLOC for fixed base systems without an explicit contact model. More...
#include <FixBaseNLOC.h>
Public Member Functions | |
FixBaseNLOC ()=default | |
default constructor More... | |
FixBaseNLOC (std::shared_ptr< ct::optcon::CostFunctionQuadratic< STATE_DIM, CONTROL_DIM, SCALAR >> costFun, const typename NLOptConSolver::Settings_t &nlocSettings, std::shared_ptr< FBSystem > system=std::shared_ptr< FBSystem >(new FBSystem), bool verbose=false, std::shared_ptr< LinearizedSystem > linearizedSystem=nullptr) | |
constructor which directly takes a cost function More... | |
FixBaseNLOC (std::shared_ptr< ct::optcon::CostFunctionQuadratic< STATE_DIM, CONTROL_DIM, SCALAR >> costFun, std::shared_ptr< ct::optcon::LinearConstraintContainer< STATE_DIM, CONTROL_DIM, SCALAR >> inputBoxConstraints, std::shared_ptr< ct::optcon::LinearConstraintContainer< STATE_DIM, CONTROL_DIM, SCALAR >> stateBoxConstraints, std::shared_ptr< ct::optcon::LinearConstraintContainer< STATE_DIM, CONTROL_DIM, SCALAR >> generalConstraints, const typename NLOptConSolver::Settings_t &nlocSettings, std::shared_ptr< FBSystem > system=std::shared_ptr< FBSystem >(new FBSystem), bool verbose=false, std::shared_ptr< LinearizedSystem > linearizedSystem=nullptr) | |
constructor which directly takes a cost function and constraints, mind the order of the constraints More... | |
void | initialize (const RobotState_t &x0, const core::Time &tf, StateVectorArray x_ref=StateVectorArray(), FeedbackArray u0_fb=FeedbackArray(), ControlVectorArray u0_ff=ControlVectorArray()) |
void | initializeSteadyPose (const RobotState_t &x0, const core::Time &tf, const int N, ControlVector &u_ref, FeedbackMatrix K=FeedbackMatrix::Zero()) |
initialize fixed-base robot with a steady pose using inverse dynamics torques as feedforward More... | |
void | initializeDirectInterpolation (const RobotState_t &x0, const RobotState_t &xf, const core::Time &tf, const int N, FeedbackMatrix K=FeedbackMatrix::Zero()) |
initialize fixed-base robot with a directly interpolated state trajectory and corresponding ID torques More... | |
void | initializeDirectInterpolation (const RobotState_t &x0, const RobotState_t &xf, const core::Time &tf, const int N, ct::core::ControlVectorArray< NJOINTS, SCALAR > &u_array, ct::core::StateVectorArray< STATE_DIM, SCALAR > &x_array, FeedbackMatrix K=FeedbackMatrix::Zero()) |
initialize fixed-base robot with a directly interpolated state trajectory and corresponding ID torques More... | |
bool | runIteration () |
bool | solve () |
const StateFeedbackController & | getSolution () |
const core::TimeArray & | getTimeArray () |
const FeedbackArray & | getFeedbackArray () |
const ControlVectorArray & | getControlVectorArray () |
const StateVectorArray & | getStateVectorArray () |
const NLOptConSolver::Settings_t & | getSettings () const |
void | changeCostFunction (std::shared_ptr< CostFunction > costFunction) |
std::shared_ptr< NLOptConSolver > | getSolver () |
Static Public Attributes | |
static EIGEN_MAKE_ALIGNED_OPERATOR_NEW const bool | eeForcesAreControlInputs = false |
static const size_t | CONTROL_DIM = FBSystem::CONTROL_DIM |
static const size_t | NJOINTS = FBSystem::NJOINTS |
static const size_t | STATE_DIM = FBSystem::STATE_DIM |
static const size_t | ACTUATOR_STATE_DIM = FBSystem::ACTUATOR_STATE_DIM |
NLOC for fixed base systems without an explicit contact model.
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::FBSystem = FIX_BASE_FD_SYSTEM |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::SCALAR = typename FBSystem::SCALAR |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::LinearizedSystem = ct::core::LinearSystem<STATE_DIM, CONTROL_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::NLOptConSolver = ct::optcon::NLOptConSolver<STATE_DIM, CONTROL_DIM, STATE_DIM / 2, STATE_DIM / 2, SCALAR> |
@ todo: introduce templates for P_DIM and V_DIM
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::RobotState_t = FixBaseRobotState<NJOINTS, ACTUATOR_STATE_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::StateVector = typename core::StateVector<STATE_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::ControlVector = typename core::ControlVector<CONTROL_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::FeedbackMatrix = typename core::FeedbackMatrix<STATE_DIM, CONTROL_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::StateVectorArray = typename core::StateVectorArray<STATE_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::ControlVectorArray = typename core::ControlVectorArray<CONTROL_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::FeedbackArray = typename core::FeedbackArray<STATE_DIM, CONTROL_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::StateFeedbackController = typename core::StateFeedbackController<STATE_DIM, CONTROL_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::CostFunction = ct::optcon::CostFunctionQuadratic<STATE_DIM, CONTROL_DIM, SCALAR> |
using ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::JointAcceleration_t = JointAcceleration<NJOINTS, SCALAR> |
|
default |
default constructor
ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::FixBaseNLOC | ( | std::shared_ptr< ct::optcon::CostFunctionQuadratic< STATE_DIM, CONTROL_DIM, SCALAR >> | costFun, |
const typename NLOptConSolver::Settings_t & | nlocSettings, | ||
std::shared_ptr< FBSystem > | system = std::shared_ptr<FBSystem>(new FBSystem) , |
||
bool | verbose = false , |
||
std::shared_ptr< LinearizedSystem > | linearizedSystem = nullptr |
||
) |
constructor which directly takes a cost function
ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::FixBaseNLOC | ( | std::shared_ptr< ct::optcon::CostFunctionQuadratic< STATE_DIM, CONTROL_DIM, SCALAR >> | costFun, |
std::shared_ptr< ct::optcon::LinearConstraintContainer< STATE_DIM, CONTROL_DIM, SCALAR >> | inputBoxConstraints, | ||
std::shared_ptr< ct::optcon::LinearConstraintContainer< STATE_DIM, CONTROL_DIM, SCALAR >> | stateBoxConstraints, | ||
std::shared_ptr< ct::optcon::LinearConstraintContainer< STATE_DIM, CONTROL_DIM, SCALAR >> | generalConstraints, | ||
const typename NLOptConSolver::Settings_t & | nlocSettings, | ||
std::shared_ptr< FBSystem > | system = std::shared_ptr<FBSystem>(new FBSystem) , |
||
bool | verbose = false , |
||
std::shared_ptr< LinearizedSystem > | linearizedSystem = nullptr |
||
) |
constructor which directly takes a cost function and constraints, mind the order of the constraints
void ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::initialize | ( | const RobotState_t & | x0, |
const core::Time & | tf, | ||
StateVectorArray | x_ref = StateVectorArray() , |
||
FeedbackArray | u0_fb = FeedbackArray() , |
||
ControlVectorArray | u0_ff = ControlVectorArray() |
||
) |
References dt, and ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getSettings().
void ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::initializeSteadyPose | ( | const RobotState_t & | x0, |
const core::Time & | tf, | ||
const int | N, | ||
ControlVector & | u_ref, | ||
FeedbackMatrix | K = FeedbackMatrix::Zero() |
||
) |
initialize fixed-base robot with a steady pose using inverse dynamics torques as feedforward
References ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::ACTUATOR_STATE_DIM, dt, ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getSettings(), ct::rbd::FixBaseRobotState< NJOINTS, ACT_STATE_DIM, SCALAR >::joints(), and ct::rbd::FixBaseRobotState< NJOINTS, ACT_STATE_DIM, SCALAR >::toStateVector().
void ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::initializeDirectInterpolation | ( | const RobotState_t & | x0, |
const RobotState_t & | xf, | ||
const core::Time & | tf, | ||
const int | N, | ||
FeedbackMatrix | K = FeedbackMatrix::Zero() |
||
) |
initialize fixed-base robot with a directly interpolated state trajectory and corresponding ID torques
void ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::initializeDirectInterpolation | ( | const RobotState_t & | x0, |
const RobotState_t & | xf, | ||
const core::Time & | tf, | ||
const int | N, | ||
ct::core::ControlVectorArray< NJOINTS, SCALAR > & | u_array, | ||
ct::core::StateVectorArray< STATE_DIM, SCALAR > & | x_array, | ||
FeedbackMatrix | K = FeedbackMatrix::Zero() |
||
) |
initialize fixed-base robot with a directly interpolated state trajectory and corresponding ID torques
References ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::ACTUATOR_STATE_DIM, ct::rbd::FixBaseRobotState< NJOINTS, ACT_STATE_DIM, SCALAR >::actuatorState(), dt, ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getSettings(), i, ct::rbd::FixBaseRobotState< NJOINTS, ACT_STATE_DIM, SCALAR >::joints(), ct::rbd::JointState< NJOINTS, SCALAR >::toImplementation(), and ct::rbd::FixBaseRobotState< NJOINTS, ACT_STATE_DIM, SCALAR >::toStateVector().
bool ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::runIteration | ( | ) |
bool ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::solve | ( | ) |
const FixBaseNLOC< FIX_BASE_FD_SYSTEM >::StateFeedbackController & ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getSolution | ( | ) |
const core::TimeArray & ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getTimeArray | ( | ) |
const FixBaseNLOC< FIX_BASE_FD_SYSTEM >::FeedbackArray & ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getFeedbackArray | ( | ) |
const FixBaseNLOC< FIX_BASE_FD_SYSTEM >::ControlVectorArray & ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getControlVectorArray | ( | ) |
const FixBaseNLOC< FIX_BASE_FD_SYSTEM >::StateVectorArray & ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getStateVectorArray | ( | ) |
const FixBaseNLOC< FIX_BASE_FD_SYSTEM >::NLOptConSolver::Settings_t & ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getSettings | ( | ) | const |
void ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::changeCostFunction | ( | std::shared_ptr< CostFunction > | costFunction | ) |
std::shared_ptr< typename FixBaseNLOC< FIX_BASE_FD_SYSTEM >::NLOptConSolver > ct::rbd::FixBaseNLOC< FIX_BASE_FD_SYSTEM >::getSolver | ( | ) |
|
static |
|
static |
|
static |
|
static |
|
static |