Imagine I have a nonlinear system: $$ \frac{\text{d} x}{\text{d} t} = f(x,t)\\ y = g(x). $$ I can design a nonlinear observer to estimate the state $x$ based on the measurements $y$. However, this estimation does not need to be done online. Meaning that I have the whole measurement signal $y(t=0- T_{\text{end}})$ and would like to estimate the state in the corresponding time interval [$0, T_{\text{end}}$]. Is there an offline method for doing so?

I am asking this question, because having the whole measurement signal (previous and future steps for any given state $x(t)$) might help improving the estimation accuracy. Something like Matlab filtfilt, which removes the potential filtering phase shifts by doing filtering from both time ends.

  • $\begingroup$ You tag this as "non-linear", but the basic Kalman filter and Luenberger observer are linear systems. Is your system, indeed, nonlinear? $\endgroup$
    – TimWescott
    Jan 19, 2021 at 19:25
  • $\begingroup$ Yes, my system is nonlinear. You are right, I will edit the question. $\endgroup$ Jan 19, 2021 at 19:31

1 Answer 1


In short, yes: the key phrase that you want to search on is optimal smoothing.

You didn't ask how to do it, and the "how" is chapter-length, in a good book about Kalman filtering. So I'm not going to try to describe that.

In general hand-wavy terms, though, optimal smoothing takes into account that if you know both past and future values of a system output, then you can do a better job of estimating its state than if you just know past values.

So, some close study of optimal smoothers should get you the "how". As at least a partial benefit, you should find that the end effects that you see with filtfilt aren't as pronounced, because filtfilt uses a time-invariant filter run both directions, while an optimal smoother -- if done right -- adjusts its gains based on where in the vector it's doing its estimation.

Given that your system is nonlinear, you're going to have to do a bit of mathematical tap-dancing to make an extended (or unscented) optimal smoother, or you'll need to dig in the literature to find nonlinear optimal smoothing schemes. I'm sure they're out there, they'll just be more interesting and obscure than optimal smoothers for linear systems.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.