ocra-recipes
Doxygen documentation for the ocra-recipes repository
|
#include <ocra/util/MathTypes.h>
#include "ocra/optim/Variable.h"
#include "ocra/optim/Constraint.h"
#include "ocra/optim/uncompress.h"
#include <Eigen/Eigen>
#include <iostream>
#include <iomanip>
#include "SolverUtilities.hxx"
Go to the source code of this file.
Classes | |
struct | ocra::OptimizationResult |
Namespaces | |
ocra | |
Optimization-based Robot Controller namespace. a library of classes to write and solve optimization problems dedicated to the control of multi-body systems. | |
ocra::utils | |
ocra::utils::details | |
Macros | |
#define | DECLARE_UNCOMPRESSED_FUNCTION(functionName) |
Functions | |
template<class Derived , class VectorBase > | |
void | ocra::utils::printLinearEquation (const MatrixBase< Derived > &A, const VectorBase &b, int space=9, int precision=3) |
void | ocra::utils::printSolution (const VectorXd &result, const Variable &var, int space=9, int precision=3) |
template<class Derived , class VectorBase1 , class VectorBase2 > | |
void | ocra::utils::convert (const LinearConstraint &cstr, const std::vector< int > &mapping, eConstraintOutput type, MatrixBase< Derived > &A, VectorBase1 &b, VectorBase2 &l, double infinity=0.) |
template<class VectorBase1 , class VectorBase2 > | |
void | ocra::utils::intersectBounds (const DiagonalLinearConstraint &bounds, const std::vector< int > &mapping, VectorBase1 &bl, VectorBase2 &bu) |
void | ocra::testUtilities () |
Variables | |
const details::eConvertCase | ocra::utils::conversion_cases [7][7] |
#define DECLARE_UNCOMPRESSED_FUNCTION | ( | functionName | ) |
The following functions are aliases on usages of the methods of uncompress<Functor> (Uncompress.h), defined for userfriendliness:
void functionName(const Variable& base, const Variable& rel, const MatrixBase<Derived1>& in, MatrixBase<Derived2>& out, std::vector<int>& mapping, double scale=1.)
Given two matrices in and out, and a vector of indices mapping, these functions will perform an operation between:
true
, the indices k and mapping[k] are swaped: for example, for functions postfixed by ByRow, the operation will happen between in.col(mapping[i]) and out.col(i) The operation between these two elements e1 and e2 is e2 = e1 for uncompress functions, e2 += e1 for addCompressed functions, e2 = min(e1,e2) for minCompressed functions, e2 = max(e1,e2) for maxCompressed functions.Each function has two overloads:
Definition at line 138 of file SolverUtilities.h.