From 56e15ab1f42ce29ff0da429d85af4e07dabbb2ed Mon Sep 17 00:00:00 2001 From: James Goppert Date: Sun, 13 Jan 2013 18:38:09 -0500 Subject: Working on comments. --- apps/mathlib/math/Dcm.cpp | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) (limited to 'apps/mathlib/math/Dcm.cpp') diff --git a/apps/mathlib/math/Dcm.cpp b/apps/mathlib/math/Dcm.cpp index 467c6f34e..25f4913a6 100644 --- a/apps/mathlib/math/Dcm.cpp +++ b/apps/mathlib/math/Dcm.cpp @@ -138,25 +138,25 @@ int __EXPORT dcmTest() Matrix::identity(3))); // quaternion ctor ASSERT(matrixEqual( - Dcm(Quaternion(0.983347, 0.034271, 0.106021, 0.143572)), - Dcm( 0.9362934, -0.2750958, 0.2183507, - 0.2896295, 0.9564251, -0.0369570, - -0.1986693, 0.0978434, 0.9751703))); + Dcm(Quaternion(0.983347f, 0.034271f, 0.106021f, 0.143572f)), + Dcm( 0.9362934f, -0.2750958f, 0.2183507f, + 0.2896295f, 0.9564251f, -0.0369570f, + -0.1986693f, 0.0978434f, 0.9751703f))); // euler angle ctor ASSERT(matrixEqual( - Dcm(EulerAngles(0.1, 0.2, 0.3)), - Dcm( 0.9362934, -0.2750958, 0.2183507, - 0.2896295, 0.9564251, -0.0369570, - -0.1986693, 0.0978434, 0.9751703))); + Dcm(EulerAngles(0.1f, 0.2f, 0.3f)), + Dcm( 0.9362934f, -0.2750958f, 0.2183507f, + 0.2896295f, 0.9564251f, -0.0369570f, + -0.1986693f, 0.0978434f, 0.9751703f))); // rotations Vector3 vB(1, 2, 3); - ASSERT(vectorEqual(Vector3(-2, 1, 3), - Dcm(EulerAngles(0, 0, M_PI_2_F))*vB)); - ASSERT(vectorEqual(Vector3(3, 2, -1), - Dcm(EulerAngles(0, M_PI_2_F, 0))*vB)); - ASSERT(vectorEqual(Vector3(1, -3, 2), - Dcm(EulerAngles(M_PI_2_F, 0, 0))*vB)); - ASSERT(vectorEqual(Vector3(3, 2, -1), + ASSERT(vectorEqual(Vector3(-2.0f, 1.0f, 3.0f), + Dcm(EulerAngles(0.0f, 0.0f, M_PI_2_F))*vB)); + ASSERT(vectorEqual(Vector3(3.0f, 2.0f, -1.0f), + Dcm(EulerAngles(0.0f, M_PI_2_F, 0.0f))*vB)); + ASSERT(vectorEqual(Vector3(1.0f, -3.0f, 2.0f), + Dcm(EulerAngles(M_PI_2_F, 0.0f, 0.0f))*vB)); + ASSERT(vectorEqual(Vector3(3.0f, 2.0f, -1.0f), Dcm(EulerAngles( M_PI_2_F, M_PI_2_F, M_PI_2_F))*vB)); printf("PASS\n"); -- cgit v1.2.3