exo3 maple

restart:val:= m[K]=1000, m[G]=4000, r=10, g=9.81, K[M]=100, T[M]=1:
> eq1 := m[K]*diff(x[K](t),`$`(t,2)) = F[K](t)+S*sin(theta(t))
> eq2:=m[G]*diff(x[G](t),t$2)=-S*sin(theta(t)):
> eq3:=m[G]*diff(z[G](t),t$2)=m[G]*g-S*cos(theta(t)):
> eq4:=x[G](t)=x[K](t)+r*sin(theta(t)):
> eq5:=z[G](t)=r*cos(theta(t)):
> s1:=diff(eq4,t,t);
> s2:=diff(eq5,t,t);
> s3:=subs(s1,eq2);
s4:=subs(s2,eq3);
> s5:=S=solve(s4,S);
> tmp:=subs(s5,s3);
> tmp2:=expand(tmp/m[G]*cos(theta(t)));
> deq1:=simplify(lhs(tmp2)-rhs(tmp2))=0;
> tmp4:=algsubs(rhs(eq2)=lhs(eq2),eq1);
> deq2:=expand(subs(s1,tmp4));
> lindeq1:=subs(sin(theta(t))=theta(t),cos(theta(t))=1,diff(theta(t),t)^2=0,deq1);
> lindeq2:=subs(sin(theta(t))=theta(t),cos(theta(t))=1,diff(theta(t),t)^2=0,deq2);
> deq3 := T[M]*diff(F[K](t),t)+F[K](t) = K[M]*u
> sys:={lindeq1, lindeq2, deq3};
> sysval := subs(val,u = 10,sys); init := {x[K](0) = 2, D(x[K])(0) = 0, theta(0) = 0, D(theta)(0) = 0, F[K](0) = 0}
> sol:=dsolve(sysval union init,[x[K](t),theta(t),F[K](t)],type=numeric);
> plot(['op(2,sol(t)[2])'], t=0..30, axes=boxed,
> title=" Position as a function of Time", > labels=["Time [s]", "x [K]"]);
> plot(['op(2,sol(t)[3])'], t=0..30, axes=boxed, > title=" Speed as a function of Time", > labels=["Time [s]", "Speed [K]"]);
> plot(['op(2,sol(t)[4])'], t=0..30, axes=boxed, > title=" Angle as a function of Time", > labels=["Time [s]", "Theta "]);
> with(DEtools):with(linalg):
> syst:=convertsys(sys,init,[x[K](t), theta(t), F[K](t)],t,X,X_p);
> A:=genmatrix(map(rhs=0,syst[1]), [ X[1],X[2],X[3],X[4],X[5]], 'inhom');
> b:=map(x->-1*x/u,inhom);
> Q:=concat(b, multiply(A,b), multiply(A^2,b), > multiply(A^3,b), multiply(A^4,b));
> det(Q);
> pole:=eigenvalues(A);
> pole:=subs(val,[pole]);
> readlib(polar):
> plot(map([Re,Im],pole),-2..0,-2.5..2.5,style=point,symbol=circle);
> G:=s->K/(1+2*d*T*s+T^2*s^2):
> h:=t->K-K/sqrt(1-d^2)*exp(-d*t/T)*sin(sqrt(1-d^2)*t/T):
> he:=t->K-K/sqrt(1-d^2)*exp(-d*t/T):
> abs(he-K)=K/sqrt(1-d^2)*exp(-d*t/T):
> r1:=K*2/100=K/sqrt(1-d^2)*exp(-d*t/T):
> r2:=solve(subs(d=0.7,t=25,r1),{T});
> G_:=subs(d=0.7,t=25,r2,G(s));
> p:=(s+1)^3*simplify(denom(G_)/lcoeff(denom(G_)));
> plot(map([Re, Im],[fsolve(p=0,s,complex)]),-2 .. 0,-1 .. 1,style = point,symbol = circle);
> Q_:=inverse(Q);
> Q_5:=row(Q_,5);
> R:=scalarmul(Q_5,coeff(p,s,0)):
> for i from 1 to 5 do
> R:=matadd(R,multiply(Q_5,A^i),1,coeff(p,s,i)):
> od: i:='i':
> R:=subs(val,evalm(R));
> TMP:=array(1..5,1..5,[[0,0,0,0,0],[0,0,0,0,0],[0,0,0,0,0],[0,0,0,0,0],[b[5]*R[i]$i=1..5]]);
> s[1]:=1/multiply(multiply([1,0,0,0,0],inverse(matadd(TMP,A,1,-1))),b);
> X := vector([x[1](t), x[2](t), x[3](t), x[4](t), x[5](t)])
> Xp:=vector([diff(x[1](t),t),diff(x[2](t),t),diff(x[3](t),t),diff(x[4](t),t),diff(x[5](t),t)]):
> R:=convert(evalm(R),vector);
> r2:=scalarmul(b,innerprod(R,X));
> SYS:=geneqns(A,X,matadd(matadd(Xp,scalarmul(b,s[1]*w),1,-1),r2,1,1));
> SYS:=simplify(subs(val, w=10, SYS));
> INIT:={x[1](0)=2,x[2](0)=0,x[3](0)=0,x[4](0)=0,x[5](0)=0}:
> sol:=dsolve(SYS union INIT,
> [x[1](t),x[2](t),x[3](t),x[4](t),x[5](t)],type=numeric);
> plot(['op(2,sol(t)[2])'], t=0..30, axes=boxed,
> title=" Position as a function of Time",
> labels=["Time [s]", "Position [K]"]);
> plot(['op(2,sol(t)[3])'], t=0..30, axes=boxed,
> title=" Speed as a function of Time",
> labels=["Time [s]", "Speed [K]"]);
> plot(['op(2,sol(t)[4])'], t=0..30, axes=BOXED,
> title=" Angle as a function of Time",
> labels=["Time [s]", "Theta"]);
Commentaires (1)

1. arthritis (site web) 28/10/2012

I came across akour.e-monsite.com and i love it !
psoriatic arthritis

http://arthritissymptomstreatment.blogspot.com/2012/10/what-is-arthritis_28.html

Ajouter un commentaire

Vous utilisez un logiciel de type AdBlock, qui bloque le service de captchas publicitaires utilisé sur ce site. Pour pouvoir envoyer votre message, désactivez Adblock.

MOBILISONS NOUS POUR LE DEVELOPPEMENT DE SARGHINE EN AIDANT L'ASSOCIATION AMSIRAR.

Créer un site gratuit avec e-monsite - Signaler un contenu illicite sur ce site

×