Bombentrichter
> restart;Exakte analytische Lösung:> GL:=M_G+J*diff(phi(t),t,t)=0; > M_G:=m*g*l*phi(t);> J:=m*l^2;> RB:={phi(0)=phi_0,D(phi)(0)=0}; > LSG:=dsolve({GL} union RB,phi(t)); > eval(LSG,{g=l,phi_0=0.5}); > restart;Numerische Lösung:> G1:=D_phi´/D_t=omega´;> G2:=D_omega´/D_t+g/l*phi´=0; > D_t:=0.025:> imax:=1000:> t_max:=imax*D_t:> phi:=array(0..imax):omega:=array(0..imax):> D_phi´:=phi[k+1]-phi[k]:> D_omega´:=omega[k+1]-omega[k]:> phi´:=phi[k]:> omega´:=omega[k]: > GG1:=isolate(G1,phi[k+1]);> GG2:=isolate(G2,omega[k+1]);> g:=l:> phi[0]:=0.5:> omega[0]:=0:> LG1:=(eval(GG1,k=k-1));> LG2:=eval(GG2,k=k-1);> for i from 1 by 1 to 1000 do k:=i;assign(LG1);> assign(LG2) end do:> plot({phi[t/D_t],cos(t)*0.5},t=0..t_max);
class Pendel Real phi(start=0.5); Real omega ; Real alpha;equation der(phi)=omega; der(omega)=alpha; alpha+phi=0;end Pendel;
simulate(Pendel,stopTime=10)
DESOLVE(DIFF(PHI(t),t,2)+g/l*PHI(t)=0,PHI(t));Is g l positive, negative, or zero?positive;(D2) PHI(t) = ! 2 SQRT(g l) t d ! l SIN(-----------) (-- (PHI(t))! ) l dt ! !t = 0 SQRT(g l) t --------------------------------------- + PHI(0) l COS(-----------) SQRT(g l) l ------------------------------------------------------------------- l(C3)
> restart;> with(LinearAlgebra):> P_KOS2:=;> Rz:=1*Matrix([[cos(phi),-sin(phi),0],[sin(phi),cos(phi),0],[0,0,1]]):> P_KOS1:=Rz.P_KOS2:> P_WKOS:=a0++P_KOS1:> r_S:=1:a0:=<0,r_S,0>:> phi:=alpha+omega*t:> v_F:=1:omega:=5:> P_WKOS;> t:=tau/100:> s:=seq([P_WKOS[1],P_WKOS[2]],tau=0..40):> kreis:=[seq([r_S*cos(phi/10),r_S+r_S*sin(phi/10)],phi=-20..10)]:> s1:=[eval(s,alpha=0)]:s2:=[eval(s,alpha=0.7)]:> plot({s1,s2,kreis},color=[red,blue,black]);