i wanted to know how to do initial value problem with step function using matlab
古いコメントを表示
for example: D^3x-Dx= 1 for t<2 =0 for t >=2 having x(o)=x'(0)=x''(0)=0
I know the basic of laplace in matlab like using syms t s x and using dsolve method to solve but dont know how to write this togther with step function to get final answer..
回答 (1 件)
Azzi Abdelmalek
2012 年 12 月 28 日
編集済み: Azzi Abdelmalek
2012 年 12 月 28 日
Look at this example d2y/dt+2dy/dt+3y=4*dx/dt+6x
N=[4 6],
D=[1 2 3];
model=tf(N,D) % your transfer function
t=0:0.1:100; % your time vector
[y,t]=step(model,t)
plot(t,y)
You can also use lsim command for any input
カテゴリ
ヘルプ センター および File Exchange で Common Operations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!