#include <optimization_make_mbd_bounds.h>
Classes | |
class | vector_iterator |
Public Types | |
typedef T | value_type |
typedef OpenTissue::math::ValueTraits < T > | value_traits |
Public Member Functions | |
MultibodyDynamicsBoundFunctor (bool const &is_lower, ublas::vector< size_t > const &pi, ublas::vector< T > const &mu, ublas::vector< T > const &val) | |
template<typename vector_type > | |
T | operator() (vector_type const &x, size_t const &i) const |
vector_iterator | partial_begin (size_t const &i) const |
vector_iterator | partial_end (size_t const &i) const |
size_t | size () const |
Protected Attributes | |
bool | m_is_lower |
This boolean value indicates whether the functor represents lower bounds or upper bounds. | |
ublas::vector< size_t > const & | m_pi |
Dependency index vector. This vector holds information about the coupling between tangential friction forces and the corresponding normal forces. | |
ublas::vector< T > const & | m_mu |
Friction coefficient vector. The i'th entry holds the friction coefficient that should be used for the i'th ``force''. Note that the vector also holds values for normal forces. However, these values are ``don't cares'' and are ignored in this functor. | |
ublas::vector< T > const & | m_val |
If there is no dependent variable (not a friction force) then the bound value is constant and is taken from this value vector. | |
size_t | m_n |
The number of constraints (ie. the dimension of the bound function). |
Multibody Dynamics Bound Functor Wrapper. This is a convenience class making it easier to construct bound functor objects for a multibody constraint formulation.
In Multibody Dynamics the constraint forces is easily formulated as a linear mixed complementrarity problem (LMCP).
The lower and upper bounds functions are in this case easily computed from an index dependency vector, pi, and a coefficient vector, mu.
pi: This vector holds the indices of the dependent constraints. For some variables their upper and lower bounds are modelled as a linear dependency on some other variable. That is for the $j$'th variable we might have
lower_j = -mu_j x_i upper_j = mu_j x_i
This vector holds the indices of the depedent variables. That is
pi_j = i
If the j'th entry stores the maximum possible value of the underlying data-type in the vector then it means that there are no dependencies.
mu: This vectors holds the values of the linear scaling factor of the dependent constraints.
typedef OpenTissue::math::ValueTraits<T> OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::value_traits |
typedef T OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::value_type |
OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::MultibodyDynamicsBoundFunctor | ( | bool const & | is_lower, | |
ublas::vector< size_t > const & | pi, | |||
ublas::vector< T > const & | mu, | |||
ublas::vector< T > const & | val | |||
) | [inline] |
T OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::operator() | ( | vector_type const & | x, | |
size_t const & | i | |||
) | const [inline] |
vector_iterator OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::partial_begin | ( | size_t const & | i | ) | const [inline] |
vector_iterator OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::partial_end | ( | size_t const & | i | ) | const [inline] |
size_t OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::size | ( | ) | const [inline] |
bool OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::m_is_lower [protected] |
This boolean value indicates whether the functor represents lower bounds or upper bounds.
ublas::vector<T> const& OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::m_mu [protected] |
Friction coefficient vector. The i'th entry holds the friction coefficient that should be used for the i'th ``force''. Note that the vector also holds values for normal forces. However, these values are ``don't cares'' and are ignored in this functor.
size_t OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::m_n [protected] |
The number of constraints (ie. the dimension of the bound function).
ublas::vector<size_t> const& OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::m_pi [protected] |
Dependency index vector. This vector holds information about the coupling between tangential friction forces and the corresponding normal forces.
ublas::vector<T> const& OpenTissue::math::optimization::detail::MultibodyDynamicsBoundFunctor< T >::m_val [protected] |
If there is no dependent variable (not a friction force) then the bound value is constant and is taken from this value vector.