Skip to content

Commit 7d492a6

Browse files
committed
Fix Mac tolerances
1 parent 3614134 commit 7d492a6

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

multibody/optimization/test/toppra_test.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ TEST_F(IiwaToppraTest, JointTorqueLimit) {
210210
auto s_path = result.value();
211211

212212
// This tolerance was tuned to work with the given gridpoints.
213-
const double tol = 1e-14;
213+
const double tol = 1e-13;
214214
Eigen::MatrixXd M(7, 7);
215215
Eigen::VectorXd Cv(7);
216216
Eigen::VectorXd G(7);

multibody/plant/test/multibody_plant_forward_dynamics_test.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,8 @@ class KukaIiwaModelForwardDynamicsTests : public test::KukaIiwaModelTests {
116116
plant_->CalcMassMatrixViaInverseDynamics(*context_, &M);
117117
const double kappa = 1.0 / M.llt().rcond();
118118

119-
// Compare expected results against actual vdot.
120-
const double kRelativeTolerance = kappa * kEpsilon;
119+
// Compare expected results against actual vdot (with a little slop).
120+
const double kRelativeTolerance = 2 * kappa * kEpsilon;
121121
EXPECT_TRUE(CompareMatrices(vdot, vdot_expected, kRelativeTolerance,
122122
MatrixCompareType::relative));
123123
}

0 commit comments

Comments
 (0)