What exactly does compare(___,kstep) plot?

53 ビュー (過去 30 日間)
Mingming Du
Mingming Du 2025 年 2 月 6 日 7:33
移動済み: Walter Roberson 2025 年 2 月 17 日 15:48
I read this material https://ww2.mathworks.cn/help/ident/ug/definition-simulation-and-prediction.html and I still can not figure out what each data point represent when I use compare(idataexample,sys,2).
For example, as mentioned here
at t = 10, we predict 2 steps:
yp(11|10) = 0.9ym(10) + 1.5um(10),
yp(12|10) = 0.9yp(11|10) + 1.5um(11).
And so on, at t = 11, we predict 2 steps,:
yp(12|11) = 0.9ym(11) + 1.5um(11),
yp(13|11) = 0.9yp(12|11) + 1.5um(12).
So, when
compare
finally gives a plot, what does the value at t = 12 represent? Is it yp(12|10), yp(12|11), or something else?
By the way, I think there might be an error in the example(CompareEstimatedModeltoMeasuredDataExample') in the documentation ("For instance, the point at t = 15s is based on output measurements taken at or prior to t = 5s").
Thanks in advance for your help!

採用された回答

Karan Singh
Karan Singh 2025 年 2 月 11 日 4:41
First, I am not able to open the links you provided. I tried some modifications, but I still couldn't access it.
Now moving one to your query, when you run
compare(data, sys, 2)
The function evaluates 2-step-ahead predictions for every time step based on past measurements.
At each time step " t ", the prediction " yp(t+2t) " is computed using available past input-output data. When "compare" plots a prediction at " t=12 ", it is actually plotting " yp(1210) " because:
  • The horizon is 2, meaning we predict " t+2 " values.
  • The prediction at " t=12 " was made at " t=10 ", using the available measured data up to " t=10 ".
Karan
  2 件のコメント
Walter Roberson
Walter Roberson 2025 年 2 月 11 日 5:22
The URL posted originally ended in a comma; I have repaired it now.
Mingming Du
Mingming Du 約23時間 前
移動済み: Walter Roberson 約16時間 前
@Karan Singh @Walter Roberson Really appreciate for your help.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLinear Model Identification についてさらに検索

製品


リリース

R2024a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by