Skip to content

Commit ccfafd0

Browse files
committed
debug: call the good method in update_cov!
1 parent 532223f commit ccfafd0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/estimator/mhe/execute.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -436,7 +436,7 @@ function correct_cov!(estim::MovingHorizonEstimator)
436436
try
437437
correct_estimate!(estim.covestim, y0marr, d0arr)
438438
estim.P̂arr_old .= estim.covestim.
439-
invert_cov!(estim, estim.covestim.)
439+
invert_cov!(estim, estim.P̂arr_old)
440440
catch err
441441
if err isa PosDefException
442442
@warn("Arrival covariance is not positive definite: keeping the old one")
@@ -454,9 +454,9 @@ function update_cov!(estim::MovingHorizonEstimator)
454454
estim.covestim.x̂0 .= estim.x̂0arr_old
455455
estim.covestim.P̂ .= estim.P̂arr_old
456456
try
457-
correct_estimate!(estim.covestim, y0marr, d0arr)
457+
update_estimate!(estim.covestim, y0marr, d0arr, u0arr)
458458
estim.P̂arr_old .= estim.covestim.
459-
invert_cov!(estim, estim.covestim.)
459+
invert_cov!(estim, estim.P̂arr_old)
460460
catch err
461461
if err isa PosDefException
462462
@warn("Arrival covariance is not positive definite: keeping the old one")

0 commit comments

Comments
 (0)