Time Domain Data or Correct Data Structure for System Identification Toolbox

Hi,
New to Matlab's system identification toolbox. I have a question regarding the data structure requirement in terms of time domain data.
.
The system requires that I have input and output data.
Please see attached screenshot...will something like this qualify as a correct time domain data for the system identification toolbox? where first column is time, second column is input and third column is output? I could also create an iddata using data = iddata(y,u,Ts). I want to be sure however that the data I will be importing to the workspace is in the correct format first.
Are there any other data format I can use? My data is in two parts, input and output (20 rows each), both of them sharing the same timestamps.
Any guidance on the appropriate representation of my data will be appreciate!
Thank you!

 채택된 답변

Star Strider
Star Strider 2022년 10월 6일
The signals appear to be regularly sampled, so that should work. The iddata function is an appropriate starting point for time domain data.
I generally use ssest to identify systems because state space models are generally more robust (at least in my experience), although all the appropriate estimation options should work. I also always use the compare function to see how well the identified system matches the data.

댓글 수: 4

Thanks for your response. So in this case do I need the time stamps as part of the data for the model estimate or I can just enter the sample time in seconds in the gui and have the input and output columns as two separate column data in the workspace?
As always, my pleasure!
The time stamps are only important with respect to determining the sampling frequency and regularity (and if you need them for other purposes). They are not important otherwise with respect to identifying the system. Only the input and output signals are important, and they both have the be the same lengths (defined at the same time stamps).
It is possible to use the input and output signals and the sampling frequency to get an estimate of the system order. To do that, calculate a one-sided fft of the transfer function (output Fourier transform divided element-wise by the input Fourier transform) and plot the imaginary part only as a function of frequency. The number of infinities (peaks) are the poles and the zero-crossings between them (including those on either side of the first and last poles) are the zeros. That can make specifying the system order a bit easier. Adjust that as necessary to get the best result as determined by the compare plot result.
Once again thank you! Last question: any idea how my input data should be if I have multiple inputs? Right now I have just one input and one output. If I have 2 inputs, should I put them in column 1&2 of the input matrix? And if I have 2 output? Any suggestions?
Thanks!
As always, my pleasure!
Yes to both. See the iddata documentation sections on u and y respectively.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

제품

릴리스

R2019b

태그

질문:

2022년 10월 6일

댓글:

2022년 10월 6일

Community Treasure Hunt

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

Start Hunting!

Translated by