Verified Commit cbb14de6 authored by Justin Carpentier's avatar Justin Carpentier
Browse files

all: fix variable init

parent 4602c412
Pipeline #13918 passed with stage
in 151 minutes and 5 seconds
......@@ -26,8 +26,8 @@ int main(int argc, char ** argv)
// Sample a random joint configuration as well as random joint velocity and torque
Eigen::VectorXd q = randomConfiguration(model);
Eigen::VectorXd v = Eigen::VectorXd(model.nv);
Eigen::VectorXd tau = Eigen::VectorXd(model.nv);
Eigen::VectorXd v = Eigen::VectorXd::Zero(model.nv);
Eigen::VectorXd tau = Eigen::VectorXd::Zero(model.nv);
// Allocate result container
Eigen::MatrixXd djoint_acc_dq = Eigen::MatrixXd::Zero(model.nv,model.nv);
......
......@@ -26,8 +26,8 @@ int main(int argc, char ** argv)
// Sample a random joint configuration as well as random joint velocity and acceleration
Eigen::VectorXd q = randomConfiguration(model);
Eigen::VectorXd v = Eigen::VectorXd(model.nv);
Eigen::VectorXd a = Eigen::VectorXd(model.nv);
Eigen::VectorXd v = Eigen::VectorXd::Zero(model.nv);
Eigen::VectorXd a = Eigen::VectorXd::Zero(model.nv);
// Allocate result container
Eigen::MatrixXd djoint_torque_dq = Eigen::MatrixXd::Zero(model.nv,model.nv);
......
......@@ -25,8 +25,8 @@ int main(int argc, char ** argv)
// Sample a random joint configuration as well as random joint velocity and acceleration
Eigen::VectorXd q = randomConfiguration(model);
Eigen::VectorXd v = Eigen::VectorXd(model.nv);
Eigen::VectorXd a = Eigen::VectorXd(model.nv);
Eigen::VectorXd v = Eigen::VectorXd::Zero(model.nv);
Eigen::VectorXd a = Eigen::VectorXd::Zero(model.nv);
// Computes the kinematics derivatives for all the joints of the robot
computeForwardKinematicsDerivatives(model, data, q, v, a);
......
......@@ -155,7 +155,7 @@ BOOST_AUTO_TEST_CASE ( test_timings )
{
std::vector<Eigen::VectorXd> randvec(NBT);
for(size_t i=0;i<NBT;++i ) randvec[i] = Eigen::VectorXd::Random(model.nv);
Eigen::VectorXd zero = Eigen::VectorXd(model.nv);
Eigen::VectorXd zero = Eigen::VectorXd::Zero(model.nv);
Eigen::VectorXd res (model.nv);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment