paramath

* B3

Image 

NUMERICAL - GRAPHICAL SOLUTIONS OF  THE
NON-LINEAR VIBRATION MODEL
with discrete data input
 

                                                                                                                                                                                               

by CO.H . TRAN
University of Natural Sciences,
HCMC  Vietnam
 

coth123@math.com & coth123@yahoo.com 
Copyright 2007 
May 06 2007   

Abstract  : The system of non-linear  differential quations  with discrete input function  is solved  by  Runge-Kutta  method  .
Subjects: Vibration Mechanics , The Differential equations  .

NOTE: This worksheet demonstrates Maple's  capabilities in the design and finding  the numerical solution of the  non-linear vibration system .                                     

All rights reserved.  Copying or transmitting of this material without the permission of the authors is not allowed .  
   

LOI GIAI SO VA DO THI CUA MAU
DAO DONG PHI TUYEN
voi so lieu roi rac
 

TRAN HONG CO
Dai hoc Khoa hoc tu nhien
tp HCM  Vietnam
 

coth123@math.com & coth123@yahoo.com   
Step 1 : System Definition. 

> restart: eq1:=(m1+m2)*Diff(y,t$2)*l*cos(phi)+(m1*l^2+J)*Diff(phi,t$2)+m1*g*l*cos(phi)=f(t);eq2:=(m1+m2)*Diff(y,t$2)+m1*l*cos(phi)*Diff(phi,t$2)-m1*l*Diff(phi,t)^2*cos(phi)+b*Diff(y,t)+c1*y+c3*y^3 =h(t);
 

`:=`(eq1, `+`(`*`(`+`(m1, m2), `*`(Diff(y, `$`(t, 2)), `*`(l, `*`(cos(phi))))), `*`(`+`(`*`(m1, `*`(`^`(l, 2))), J), `*`(Diff(phi, `$`(t, 2)))), `*`(m1, `*`(g, `*`(l, `*`(cos(phi)))))) = f(t)) (1.1)
 

`:=`(eq2, `+`(`*`(`+`(m1, m2), `*`(Diff(y, `$`(t, 2)))), `*`(m1, `*`(l, `*`(cos(phi), `*`(Diff(phi, `$`(t, 2)))))), `-`(`*`(m1, `*`(l, `*`(`^`(Diff(phi, t), 2), `*`(cos(phi)))))), `*`(b, `*`(Diff(y, t... (1.1)
 

> with(plots): readlib(spline): with(inttrans):
 

Warning, the name changecoords has been redefined
 
 

Step 2 : Fitting  the experimental  data  by  Spline  function. 

> eq1:=(m1+m2)*Diff(y,t$2)*l*cos(phi)+(m1*l^2+J)*Diff(phi,t$2)+m1*g*l*cos(phi)=f(t);eq2:=(m1+m2)*Diff(y,t$2)+m1*l*cos(phi)*Diff(phi,t$2)-m1*l*Diff(phi,t)^2*cos(phi)+b*Diff(y,t)+c1*y+c3*y^3 =h(t);
 

`:=`(eq1, `+`(`*`(`+`(m1, m2), `*`(Diff(y, `$`(t, 2)), `*`(l, `*`(cos(phi))))), `*`(`+`(`*`(m1, `*`(`^`(l, 2))), J), `*`(Diff(phi, `$`(t, 2)))), `*`(m1, `*`(g, `*`(l, `*`(cos(phi)))))) = f(t)) (2.1)
 

`:=`(eq2, `+`(`*`(`+`(m1, m2), `*`(Diff(y, `$`(t, 2)))), `*`(m1, `*`(l, `*`(cos(phi), `*`(Diff(phi, `$`(t, 2)))))), `-`(`*`(m1, `*`(l, `*`(`^`(Diff(phi, t), 2), `*`(cos(phi)))))), `*`(b, `*`(Diff(y, t... (2.1)
 

> datax1:=[0,0.5,1,1.5,2,2.5,3,3.5,4];
datay1:=[0.2,0.5,0.7,0.4,0.65,1.2,2.4,0.9,1.1];
pldataf:= zip((x,y)->[x,y], datax1, datay1):
dataplot1 := pointplot(pldataf, symbol=diamond);
 

`:=`(datax1, [0, .5, 1, 1.5, 2, 2.5, 3, 3.5, 4]) (2.2)
 

`:=`(datay1, [.2, .5, .7, .4, .65, 1.2, 2.4, .9, 1.1]) (2.2)
 

`:=`(dataplot1, INTERFACE_PLOT(POINTS([0., .2], [.5, .5], [1., .7], [1.5, .4], [2., .65], [2.5, 1.2], [3., 2.4], [3.5, .9], [4., 1.1]), SYMBOL(DIAMOND))) (2.2)
 

> Ft:=spline(datax1, datay1, w, cubic);
 

Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi( (2.3)
 

> dothif:=plot(Ft, w=0..5, color=red):
display(dataplot1,dothif, axes=frame);
 

Plot_2d  
 

> fnum:=subs(w=t,Ft);eq1:=subs(f(t)=fnum,eq1);
 

Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi( (2.4)
 

Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi(
Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi(
(2.4)
 

> datax2:=[0,0.5,1,1.5,2,2.5,3,3.5,4];
datay2:=[0.3,0.5,0.58,0.4,0.85,1.2,1.4,0.9,1.55];
Ht := zip((x,y)->[x,y], datax2, datay2):
dataplot2 := pointplot(Ht, symbol=cross);
 

`:=`(datax2, [0, .5, 1, 1.5, 2, 2.5, 3, 3.5, 4]) (2.5)
 

`:=`(datay2, [.3, .5, .58, .4, .85, 1.2, 1.4, .9, 1.55]) (2.5)
 

`:=`(dataplot2, INTERFACE_PLOT(POINTS([0., .3], [.5, .5], [1., .58], [1.5, .4], [2., .85], [2.5, 1.2], [3., 1.4], [3.5, .9], [4., 1.55]), SYMBOL(CROSS))) (2.5)
 

> Ht:=spline(datax2, datay2, w, cubic);
 

Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi( (2.6)
 

> dothih:=plot(Ht, w=0..5, color=blue):
display(dataplot2,dothih, axes=frame);
 

Plot_2d  
 

> h1:=subs(w=t,Ht);eq2:=subs(h(t)=h1,eq2);
 

Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi( (2.7)
 

Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi(
Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi(
(2.7)
 

Step 3 : The non-linear  vibration system with discrete data input . 

> T:=5;m1:=1; m2:=1; b:=5; c1:= 1;c3:=1 ; l:= 0.05 ; J:= 0.5 ; g:=9.8;n:=2;
 

> with(DEtools):with(plots):
alias(y=y(t), phi=phi(t), y0=y(0),p0=phi(0), yp0=D(y)(0),pp0=D(phi)(0));

eq1 := .10*Diff(y,`$`(t,2))*cos(phi)+.5025*Diff(phi,`$`(t,2))+.490*cos(phi) = PIECEWISE([.2000000000+.559628129599999968*t+.161487481600000010*t^3, t < .5],[.1596281296+.680743740799999997*t+.242231222385861644*(t-.5)^2-1.60743740800000001*(t-.5)^3, t < 1],[.9826030927-.282603092700000002*t-2.16892488954344652*(t-1)^2+3.06826215099999988*(t-1)^3, t < 1.5],[.6254970546-.150331369699999995*t+2.43346833578792321*(t-1.5)^2-2.26561119299999980*(t-1.5)^3, t < 2],[-.5178571430+.583928571299999977*t-.964948453608247214*(t-2)^2+3.99418262299999994*(t-2)^3, t < 2.5],[-5.336542708+2.61461708300000017*t+5.02632547864506574*(t-2.5)^2-10.9111192900000002*(t-2.5)^3, t < 3],[4.027190721-.542396906999999984*t-11.3403534609720165*(t-3)^2+12.8502945499999992*(t-3)^3, t < 3.5],[8.757603092-2.24502945500000006*t+7.93508836524300420*(t-3.5)^2-5.29005890999999994*(t-3.5)^3, otherwise]);

eq2 := 2*Diff(y,`$`(t,2))+.5e-1*cos(phi)*Diff(phi,`$`(t,2))-.5e-1*Diff(phi,t)^2*cos(phi)+5*Diff(y,t)+y+y^3 = PIECEWISE([.3000000000+.401389911599999982*t-.555964654000000014e-2*t^3, t < .5],[.3013899116+.397220176799999990*t-.833946980854194387e-2*(t-.5)^2-.932201767300000039*(t-.5)^3, t < 1],[.8902706185-.310270618499999984*t-1.40664212076583217*(t-1)^2+2.61436671600000015*(t-1)^3, t < 1.5],[.342065540e-1+.243862297300000003*t+2.51490795287187030*(t-1.5)^2-2.40526509599999994*(t-1.5)^3, t < 2],[-1.059642857+.954821428699999974*t-1.09298969072164964*(t-2)^2+1.16669366700000010*(t-2)^3, t < 2.5],[-.642129970+.736851987999999958*t+.657050810014727760*(t-2.5)^2-2.66150957300000002*(t-2.5)^3, t < 3],[3.206688144-.602229381300000033*t-3.33521354933726099*(t-3)^2+5.07934462299999990*(t-3)^3, t < 3.5],[1.347770617-.127934461999999998*t+4.28380338733431554*(t-3.5)^2-2.85586892500000022*(t-3.5)^3, otherwise]);

G:=dsolve({eq1,eq2,y0=0,p0=0,yp0=0,pp0=0.1},[y,phi],'numeric'):
print(" Loi giai so bang phuong phap RUNGE - KUTTA ");

for i from 0 to T do print(G(i)); od;

yy:=t-> rhs(G(t)[2]):
pp:=t-> rhs(G(t)[4]):
yyp:=t->rhs(G(t)[3]):ppp:=t->rhs(G(t)[5]):plot(yy,0..n*T,color=red,thickness=3,title=`tung do y(t)`);

plot(pp,0..n*T,color=blue,thickness=3,title=`goc phi phi(t)`);
plot(yyp,0..n*T,color=green,title=`daohamtungdo y'(t)`);

plot(ppp,0..n*T,color=black,title=`daohamgocphi phi'(t)`);
 

`:=`(T, 5)  
 

`:=`(m1, 1)  
 

`:=`(m2, 1)  
 

`:=`(b, 5)  
 

`:=`(c1, 1)  
 

`:=`(c3, 1)  
 

`:=`(l, 0.5e-1)  
 

`:=`(J, .5)  
 

`:=`(g, 9.8)  
 

`:=`(n, 2)  
 

y, phi, y0, p0, yp0, pp0  
 

Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi(
Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi(
 
 

Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi(
Typesetting:-mrow(Typesetting:-mrow(Typesetting:-mi(
 
 

 Loi giai so bang phuong phap RUNGE - KUTTA  
 

[t = 0., y = 0., diff(y, t) = 0., phi = 0., diff(phi, t) = .10000000000000]  
 

[t = 1., y = 0.562387514180973936e-1, diff(y, t) = 0.919325793332233798e-1, phi = -0.355290448685309080e-2, diff(phi, t) = 0.868067480650852458e-1]  
 

[t = 2., y = .140320184545176530, diff(y, t) = 0.960867096874300497e-1, phi = .129759952972422458, diff(phi, t) = .147394103759956706]  
 

[t = 3., y = .287906241037682474, diff(y, t) = .192109787101329366, phi = .827233008575420260, diff(phi, t) = 1.98294084634170864]  
 

[t = 4., y = .417793708807629116, diff(y, t) = 0.557060351021547648e-1, phi = 4.39925455245758722, diff(phi, t) = 4.86262636426738658]  
 

[t = 5., y = .653989756950584145, diff(y, t) = 0.322542423343675153e-1, phi = 10.1859611662254004, diff(phi, t) = 5.95737412594295090]  
 

Plot_2d  
 

Plot_2d  
 

Plot_2d  
 

Plot_2d  
 

Mohinh procedure 
 

> mohinh:=proc(M,lan)
 

> mohinh(0.75,3);
 

Plot_2d  
 

 

Legal Notice: The copyright for this application is owned by the author(s). Neither Maplesoft nor the author are responsible for any errors contained within and are not liable for any damages resulting from the use of this material. This application is intended for non-commercial, non-profit use only. Contact the author for permission if you wish to use this application in for-profit activities.
 

ImageB3.COHONGTRAN-NUGRADIS 
 
Today, there have been 48 visitors (51 hits) on this page!
This website was created for free with Own-Free-Website.com. Would you also like to have your own website?
Sign up for free