如何用matlab求函數的導數與高階導數?
需要先轉換為符號量,求導之后再轉換為傳遞函數.
參考代碼:
Gs=poly2sym(G.num{1},'s')/poly2sym(G.den{1},'s');
D5Gs=diff(Gs,5);
[num,den]=numden(D5Gs);
tf(sym2poly(num),sym2poly(den))
如何用matlab求函數的導數與高階導數?
需要先轉換為符號量,求導之后再轉換為傳遞函數.
參考代碼:
Gs=poly2sym(G.num{1},'s')/poly2sym(G.den{1},'s');
D5Gs=diff(Gs,5);
[num,den]=numden(D5Gs);
tf(sym2poly(num),sym2poly(den))