ODE problem in motor
古いコメントを表示
Hello everybody
I wrote the following code but it has error. I could not debug it.
could you please help?
thanks in advance
clear
clc
Rs=0.1;
Rr=0.1;
Ls=0.5*10^-3;
Lr=0.5*10^-3;
M=0.8*10^-3;
B=0;
a=linspace(0,2*pi);
f=50;
w=314; % w=2*pi*f
theta=linspace(0,2*pi);
ir=200;
Vr=20;
Va=sin((w*a)-B);
Vb=sin((w*a)-B-(pi/2));
dIdt=@(t,I)[(Va-Rs*I(1)+M*w*ir*sin(theta))/Ls;(Vb-Rs*I(2)+M*w*ir*cos(theta))/Ls];
[t,I]=ode45(dIdt,[0 2*pi],[0 0])
1 件のコメント
James Tursa
2021 年 1 月 26 日
Please post the differential equation you are trying to solve. For starters, your use of theta is incorrect.
回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Ordinary Differential Equations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!