From ed4f2deccfeab5621fa9910bd97df0e37d4f7374 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joan=20Sol=C3=A0?= <jsola@iri.upc.edu> Date: Wed, 7 Mar 2018 22:53:24 +0100 Subject: [PATCH] Rename Jacobian --- src/test/gtest_IMU.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/test/gtest_IMU.cpp b/src/test/gtest_IMU.cpp index a656fdcd1..80969eaac 100644 --- a/src/test/gtest_IMU.cpp +++ b/src/test/gtest_IMU.cpp @@ -124,7 +124,7 @@ class Process_Constraint_IMU : public testing::Test * Delta: the preintegrated delta * J_D_b_ptr: a pointer to the Jacobian of Delta wrt bias. Defaults to nullptr. */ - static void integrateOneStep(const VectorXs& motion, const VectorXs& bias_real, const VectorXs& bias_preint, Scalar dt, Quaternions& q_real, VectorXs& Delta, Matrix<Scalar, 9, 6>* J_D_d_ptr = nullptr) + static void integrateOneStep(const VectorXs& motion, const VectorXs& bias_real, const VectorXs& bias_preint, Scalar dt, Quaternions& q_real, VectorXs& Delta, Matrix<Scalar, 9, 6>* J_D_b_ptr = nullptr) { VectorXs delta(10), data(6); VectorXs Delta_plus(10); @@ -134,7 +134,7 @@ class Process_Constraint_IMU : public testing::Test data = imu::motion2data(motion, q_real, bias_real); q_real = q_real*exp_q(motion.tail(3)*dt); Vector6s body = data - bias_preint; - if (J_D_d_ptr == nullptr) + if (J_D_b_ptr == nullptr) { delta = imu::body2delta(body, dt); Delta_plus = imu::compose(Delta, delta, dt); @@ -143,10 +143,10 @@ class Process_Constraint_IMU : public testing::Test { imu::body2delta(body, dt, delta, J_d_d); imu::compose(Delta, delta, dt, Delta_plus, J_D_D, J_D_d); - J_D_b = *J_D_d_ptr; + J_D_b = *J_D_b_ptr; J_d_b = - J_d_d; J_D_b = J_D_D*J_D_b + J_D_d*J_d_b; - *J_D_d_ptr = J_D_b; + *J_D_b_ptr = J_D_b; } Delta = Delta_plus; } -- GitLab