From: yudhveer on
please see my code below

function dx=newq3(t,x)
q1=x(1);q2=x(2);q3=x(3);q4=x(4);q5=x(5);q6=x(6);th=x(7);dq1=x(8);dq2=x(9);dq3=x(10);dq4=x(11);dq5=x(12);dq6=x(13);dth=x(14);p=x(15);v=x(16);
uv=10;C=8.88e-13;R=2*1.23e10;
M=1.88;J=.934;L=1.22;b=.114;d=.326;g=1.21;Ap=2.55e-4;
wb1=70.4;Kv=1.54e6;tv=.003;
al=[3.92 7.07 10.21 13.35 16.49 19.64];wb=wb1*((al/al(1)).^2);
s=sin(al);c=cos(al);sh=sinh(al);ch=cosh(al);s2=sin(2*al);sh2=sinh(2*al);
numa=.5-s2./(4*al)-(.5-sh2./(4*al)).*((s./sh).^2)+s.*(s.*ch-c.*sh)./(al.*sh);
a=sqrt(1./(M*numa));
phib=a.*(sin(al*b/L)+(s./sh).*sinh(al*b/L));phio=a.*(1+s./sh).*al/L;
be=sin(th+g)/sqrt(1+(b/d)^2-2*(b/d)*cos(th+g));
dth2=b*Ap*be*p/J;
dq12=phib(1)*b*Ap*be*p/J-wb(1)^2*q1;
dq22=phib(2)*b*Ap*be*p/J-wb(2)^2*q2;
dq32=phib(3)*b*Ap*be*p/J-wb(3)^2*q3;
dq42=phib(4)*b*Ap*be*p/J-wb(4)^2*q4;
dq52=phib(5)*b*Ap*be*p/J-wb(5)^2*q5;
dq62=phib(6)*b*Ap*be*p/J-wb(6)^2*q6;
dp=(v/R-1/R*p-Ap*be*(b*dth+phib(1)*dq1+phib(2)*dq2+phib(3)*dq3+phib(4)*dq4+phib(5)*dq5+phib(6)*dq6))/C;
dv=(Kv*uv-v)/tv;
dx=[dth2;dq12;dq22;dq32;dq42;dq52;dq62;dp;dv;dq1;dq2;dq3;dq4;dq5;dq6;dth];

this is the function file..with 9 differential equations.
when i give the command in the main window
[t,x]= ode15s(@newq3,[0.02 0.04],[0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0]);
i am getting error
Warning: Failure at t=2.213149e-002. Unable to meet integration tolerances without reducing the step size below the smallest value allowed (7.862686e-017) at time t.
> In ode15s at 686


please help how to solve this error
 | 
Pages: 1
Prev: cbir
Next: any limitation of fix points here