How do I call "frd" for discrete time?
1 回表示 (過去 30 日間)
古いコメントを表示
I have M, and blk from
[M,NDelta,blk] = lftdata(ClosedLoop);
Making a frequency vector and defining my discrete time step as:
freq=logspace(-1,2,100);
dt = 0.05;
I now want to call frd as:
M_g = frd(M,freq,dt);
but get the error: "The frequency units must be specified as one of the strings 'rad/TimeUnit', 'cycles/TimeUnit', 'rad/s', 'Hz', 'kHz', 'MHz', 'GHz', or 'rpm'."
I have no idea how to specify these units though... Help?!?
0 件のコメント
回答 (1 件)
Sebastian Castro
2014 年 11 月 20 日
編集済み: Sebastian Castro
2014 年 11 月 20 日
Hi Mark,
The following commands worked for me:
M_disc = c2d(M,0.05);
M_g = frd(M_disc,freq,'rad/s');
After displaying M_g, at the very end I get the following:
Sample time: 0.05 seconds
Discrete-time frequency response.
Best,
Sebastian
参考
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!