Skip to content

Commit

Permalink
Merge branch 'devel' into cmake
Browse files Browse the repository at this point in the history
  • Loading branch information
cmastalli committed May 15, 2024
2 parents 1593e62 + fb9df51 commit 4f40055
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## [Unreleased]

* Updated CMake packaging in https://github.com/loco-3d/crocoddyl/pull/1249
* Fixed ruff reported error in https://github.com/loco-3d/crocoddyl/pull/1248
* Fixed yapf reported errors in https://github.com/loco-3d/crocoddyl/pull/1238
* Tested Python stubs in Conda CI in https://github.com/loco-3d/crocoddyl/pull/1228
* Fixed Rviz display in https://github.com/loco-3d/crocoddyl/pull/1227
Expand Down
6 changes: 3 additions & 3 deletions examples/notebooks/solutions/cartpole_dyn.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ def cartpole_dynamics(model, data, x, u):
f = u[0].item()

# Shortname for system parameters
m1, m2, l, g = model.m1, model.m2, model.l, model.g
m1, m2, le, g = model.m1, model.m2, model.l, model.g
s, c = np.sin(th), np.cos(th)

# Defining the equation of motions
m = m1 + m2
mu = m1 + m2 * s**2
xddot = (f + m2 * c * s * g - m2 * l * s * thdot) / mu
thddot = (c * f / l + m * g * s / l - m2 * c * s * thdot**2) / mu
xddot = (f + m2 * c * s * g - m2 * le * s * thdot) / mu
thddot = (c * f / le + m * g * s / le - m2 * c * s * thdot**2) / mu

return [xddot, thddot]

0 comments on commit 4f40055

Please sign in to comment.