Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Mar 18, 2024
1 parent 167721a commit f947356
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions src/RBDyn/Jacobian.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -721,16 +721,16 @@ void Jacobian::sTranslateJacobian(const Eigen::MatrixXd & jac,
if(jac.cols() != jac_.cols() || jac.rows() != jac_.rows())
{
std::ostringstream str;
str << "jac matrix size mismatch: expected size (" << jac_.rows() << " x " << jac_.cols() << ")"
<< " gived (" << jac.rows() << " x " << jac.cols() << ")";
str << "jac matrix size mismatch: expected size (" << jac_.rows() << " x " << jac_.cols() << ")" << " gived ("
<< jac.rows() << " x " << jac.cols() << ")";
throw std::domain_error(str.str());
}

if(res.cols() != jac_.cols() || res.rows() != jac_.rows())
{
std::ostringstream str;
str << "res matrix size mismatch: expected size (" << jac_.rows() << " x " << jac_.cols() << ")"
<< " gived (" << res.rows() << " x " << res.cols() << ")";
str << "res matrix size mismatch: expected size (" << jac_.rows() << " x " << jac_.cols() << ")" << " gived ("
<< res.rows() << " x " << res.cols() << ")";
throw std::domain_error(str.str());
}

Expand All @@ -748,17 +748,16 @@ void Jacobian::sFullJacobian(const MultiBody & mb, const Eigen::MatrixXd & jac,
if(jac.cols() != jac_.cols() || jac.rows() != jac_.rows())
{
std::ostringstream str;
str << "jac matrix size mismatch: expected size (" << jac_.rows() << " x " << jac_.cols() << ")"
<< " gived (" << jac.rows() << " x " << jac.cols() << ")";
str << "jac matrix size mismatch: expected size (" << jac_.rows() << " x " << jac_.cols() << ")" << " gived ("
<< jac.rows() << " x " << jac.cols() << ")";
throw std::domain_error(str.str());
}

if(res.cols() != mb.nrDof() || res.rows() != 6)
{
std::ostringstream str;
str << "res matrix size mismatch: expected size (" << mb.nrDof() << " x "
<< "6 )"
<< " gived (" << res.rows() << " x " << res.cols() << ")";
str << "res matrix size mismatch: expected size (" << mb.nrDof() << " x " << "6 )" << " gived (" << res.rows()
<< " x " << res.cols() << ")";
throw std::domain_error(str.str());
}

Expand Down

0 comments on commit f947356

Please sign in to comment.