1 #define BIORBD_API_EXPORTS
2 #include "Utils/Vector.h"
4 #include "Utils/Error.h"
5 #include "Utils/String.h"
6 #include "Utils/Vector3d.h"
9 RigidBodyDynamics::Math::VectorNd()
16 RigidBodyDynamics::Math::VectorNd(size)
23 RigidBodyDynamics::Math::VectorNd (other)
29 const RigidBodyDynamics::Math::VectorNd &other) :
30 RigidBodyDynamics::Math::VectorNd (other)
37 RigidBodyDynamics::Math::VectorNd (other)
42 #ifdef BIORBD_USE_CASADI_MATH
45 RigidBodyDynamics::Math::VectorNd(other)
51 const RBDLCasadiMath::MX_Xd_SubMatrix &other) :
52 RigidBodyDynamics::Math::VectorNd (other)
66 biorbd::utils::Scalar n = dot(*
this);
72 biorbd::utils::Scalar res(0);
73 for(
unsigned int i=0; i < size(); ++i)
74 res += std::pow(fabs((*
this)[i]), p);
78 return std::pow(res, 1.0/p);
95 double normalized(std::pow(norm(), p-1));
96 for (
unsigned int i=0; i<size(); ++i)
97 res[i] = (*
this)[i] * std::pow(fabs((*
this)[i]), p - 2);
108 this->RigidBodyDynamics::Math::VectorNd::operator=(other);
111 #ifdef BIORBD_USE_CASADI_MATH
114 const RBDLCasadiMath::MX_Xd_SubMatrix& other)
116 this->MX_Xd_dynamic::operator=(other);
120 const casadi::MX &other)
122 this->MX_Xd_dynamic::operator=(other);