Skip to content

debug: use the most recent d in MovingHorizonEstimator with SingleShooting - #502

Merged
franckgaga merged 9 commits into
mainfrom
mhe_ss_debug
Nov 4, 2026
Merged

franckgaga merged 9 commits into
mainfrom
mhe_ss_debug

Conversation

@franckgaga

@franckgaga franckgaga commented Nov 4, 2026 •

Copy link
Copy Markdown
Member

The current formulation (direct=false) of the MovingHorizonEstimator never needs the measured disturbances of the next time step $\mathbf{d}(k+1)$. All the required $\mathbf{d}$ values for computing the predictions are explicitly available in the mhe.D0 window.

Before this PR, the SingleShooting case was ignoring the most recent measurement and was using the approximation $\mathbf{d}(k) \approx \mathbf{d}(k-1)$. Now the latest $\mathbf{d}$ is used, as it should be.

Also, the coverage of the SingleShooting case with NonLinModel is slightly improved.

@codecov-commenter

codecov-commenter commented Nov 4, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.25%. Comparing base (9ac8953) to head (9ccd5fc).
⚠️ Report is 13 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #502   +/-   ##
=======================================
  Coverage   97.25%   97.25%           
=======================================
  Files          28       28           
  Lines        7093     7095    +2     
=======================================
+ Hits         6898     6900    +2     
  Misses        195      195           
Flag Coverage Δ
unittests 97.25% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@franckgaga
franckgaga merged commit 34a1f13 into main Nov 4, 2026
29 of 34 checks passed
@franckgaga
franckgaga deleted the mhe_ss_debug branch November 4, 2026 21:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants