2 #include <gtest/gtest.h> 73 double kineticEnergy = m * mv2;
75 EXPECT_EQ(kineticEnergy, m.dot(mv2) / 2.);
78 int main(
int argc,
char** argv)
80 ::testing::InitGoogleTest(&argc, argv);
81 return RUN_ALL_TESTS();
void setAngularPart(const Vector3d &v)
SpatialMatrix crossf(const SpatialVector &v)
Get the spatial force cross matrix.
void setLinearPart(const Vector3d &v)
static Matrix3d toTildeForm(const Point3d &p)
Momentum is mass/inertia multiplied by velocity.
This class stores a bodies mass, center of mass, and inertia information. The inertia elements are st...
TEST_F(MomentumTests, testComparisonSpatialVectorCross)
EIGEN_STRONG_INLINE Vector3d getAngularPart() const
Math types such as vectors and matrices and utility functions.
static bool checkSpatialVectorsEpsilonClose(const RobotDynamics::Math::SpatialVector &v1, const RobotDynamics::Math::SpatialVector &v2, const double epsilon)
SpatialMatrix toMatrix() const
EIGEN_STRONG_INLINE Vector3d getLinearPart() const
SpatialMatrix crossm(const SpatialVector &v)
Get the spatial motion cross matrix.
int main(int argc, char **argv)