Conversation
I'd like to include some actual fitting of a first-principles model to drive home the point well enough to include
There was a problem hiding this comment.
Pull Request Overview
This PR adds a new case study to the documentation demonstrating the impact of a single-sample delay on model estimation using a double-mass system example. Key changes include the introduction of a detailed step-by-step example, the generation of simulation data, and the comparison between ARX and subspace identification methods.
|
|
||
| If we specify that we have a delay (1 sample delay implies causality, 2 samples delay implies causality + one sample pure delay), we indeed get what we would expect: | ||
| ```@example DELAY | ||
| model_arx_2 = arx(d, 3, 3, inputdelay=2) |
There was a problem hiding this comment.
The usage of 'inputdelay=2' for a single-sample delay may be confusing; please add clarification in the text to explain the relationship between the specified delay value and the system delay representation.
| model_arx = arx(d, 3, 3) | ||
| bodeplot!(bp, model_arx, lab="ARX model") | ||
| ``` | ||
| As we can see, the fit is terrible! The least-squares estimation that underpins the [`arx`](@ref) estimator tries to find a model that relates the last three outputs and inputs to the current output, but this is not possible due to the extra delay, in this case the result is catastrophic due to the "shortsightedness" of the [`arx`](@ref) function, it only looks at the immediate past and future, i.e., high-frequency properties. |
There was a problem hiding this comment.
[nitpick] Consider revising the informal term 'catastrophic' to a more neutral expression to maintain an objective tone in the documentation.
I'd like to include some actual fitting of a first-principles model to drive home the point well enough to include