You are on page 1of 8

86505 .

wxmx 1 / 8
86505 .wxmx 2 / 8

QUESTIONS:

Q1: Find any four particular solutions of DE


y"+8y'+25y=0 and also plot the soution.Also
find the solutions of DE
with initial conditions
y(0)=a,Y'(0)=1 and plot them for a=-1,0,1.

Q2: solve the system of differential


equations y1'=2y1+5y2 and
y2'=-(1/2)y1-(3/2)y2 with
conditions y1(0)=10,y2(0)=-5

Q3: Solve x*ux+y*uy=x*exp(-u) ; u(x,x^2)=0.

Q4: Solve the DE y''-2y'-8y=3e^(-2x) using


variation of parameter.
86505 .wxmx 3 / 8

1 Q1: Find any four particular


solutions of DE
y"+8y'+25y=0 and also plot the
soution.Also
find the solutions of DE
with initial conditions
y(0)=a,Y'(0)=1 and plot them for
a=-1,0,1.
kill(all);
done
depends(y,x);
eqn:diff(y,x,2)+8·diff(y,x)+25·y=0;
s:ode2(eqn,y,x);
[ y( x ) ]
2
d d
y +8 y +25 y =0
2 dx
dx
−4 x
y =%e ( %k1 sin( 3 x ) +%k2 cos ( 3 x ) )
find particular solution for
k1=1,k2=0;k1=0,k2=1;k1=1,k2=1;and k1=-1,k2=-1;
s1:ev(s,%k1=1,%k2=0);
s2:ev(s,%k1=0,%k2=1);
s3:ev(s,%k1=1,%k2=1);
s4:ev(s,%k1=−1,%k2=−1);
−4 x
y =%e sin( 3 x )
−4 x
y =%e cos ( 3 x )
−4 x
y =%e ( sin( 3 x ) +cos ( 3 x ) )
−4 x
y =%e ( −sin( 3 x ) −cos ( 3 x ) )
Plotting these four solutions in graph
wxplot2d([rhs(s1),rhs(s2),rhs(s3),rhs(s4)],[x,−1,1],[y,−1,1]);
86505 .wxmx 4 / 8

finding the solution of above DE with initial


conditions y(0)=a and y'(0)=1 and plot it
eqn:diff(y,x,2)+8·diff(y,x)+25·y=0;
s:ode2(eqn,y,x);
I:ic2(s,x=0,y=a,diff(y,x)=1);
2
d d
y +8 y +25 y =0
2 dx
dx
−4 x
y =%e ( %k1 sin( 3 x ) +%k2 cos ( 3 x ) )
−4 x ( 4 a + 1 ) sin ( 3 x )
y =%e +a cos ( 3 x )
3
I1:ev(I,a=−1);
I2:ev(I,a=0);
I3:ev(I,a=1);
−4 x
y =%e ( −sin( 3 x ) −cos ( 3 x ) )
−4 x
%e sin ( 3 x )
y=
3
−4 x 5 sin ( 3 x )
y =%e +cos ( 3 x )
3
wxplot2d([rhs(I1),rhs(I2),rhs(I3)],[x,−1,1],[y,−1,1]);
86505 .wxmx 5 / 8

2 Q2: solve the system of


differential
equations y1'=2y1+5y2 and
y2'=-(1/2)y1-(3/2)y2 with
conditions y1(0)=10,y2(0)=-5
kill(all);
eqn1: diff(y1(t),t) = 2·y1(t) + 5·y2(t);
eqn2: diff(y2(t),t) = −(1/2)·y1(t) − 3/2·y2(t);
desolve([eqn1, eqn2], [y1(t), y2(t)]);
atvalue(y1(t), t=0, 10);
atvalue(y2(t), t=0, −5);
desolve([eqn1,eqn2], [y1(t), y2(t)]);
done
d
y1( t ) =5 y2( t ) +2 y1( t )
dt
d 3 y2 ( t ) y1 ( t )
y2( t ) =− −
dt 2 2
t
( 10 y2 ( 0 ) + 5 y1 ( 0 ) ) %e
[ y1 ( t ) = −
3
t

2
( 20 y2 ( 0 ) + 4 y1 ( 0 ) ) %e
, y2 ( t ) =
6
t

2 t
( 10 y2 ( 0 ) + 2 y1 ( 0 ) ) %e ( 2 y2 ( 0 ) + y1 ( 0 ) ) %e
− ]
6 3
10
−5
t t
− −
2 2
y1( t ) =10 %e , y2 ( t ) =−5 %e

3 Q3: Solve x*ux+y*uy=x*exp(-u) ;


u(x,x^2)=0.
86505 .wxmx 6 / 8

Soln. The charecteristic equations is


dx/x=dy/y=du/x*exp(-u
we consider dy/dx=y/x and du/dx=exp(-u)
/*Answer-*/
eq1:'diff(y,x)=y/x;
d y
y=
dx x
ode2(eq1,y,x);
y =%c x
solve(%o51,%c);
y
%c =
x
eq2:'diff(u,x)=exp(−u);
d −u
u =%e
dx
ode2(eq2,u,x);
u
%e =x +%c
solve(%o54,%c);
u
%c = %e −x
exp(u)−x=g(y/x);
u y
%e −x =1−
x
u(x,y):=log(x+g(y/x));
y
u ( x ,y ) :=log x +g
x
u(x,x^2)=0;
0=0
solve(%o58,g(x));
all
g(x):=1−x;
g ( x ) :=1 −x
'u(x,y)=u(x,y);
y
u ( x ,y ) =log − +x +1
x
86505 .wxmx 7 / 8

wxplot3d(u(x,y),[x,−10,10],[y,−10,10]);

4 Q4: Solve the DE


y''-2y'-8y=3e^(-2x) using
variation of parameter.
kill(all);

done
depends(y,x);
eq:diff(y,x,2)−2·diff(y,x) −8·y= 0;
[ y( x ) ]
2
d d
y −2 y −8 y =0
2 dx
dx
Y:ode2(eq,y,x);

4x −2 x
y =%k1 %e +%k2 %e
yc:second(Y);
4x −2 x
%k1 %e +%k2 %e
Y1:second(first(yc));
4x
%e
Y2:second(second(yc));
−2 x
%e
m:matrix([Y1,Y2],[diff(Y1,x),diff(Y2,x)]);
4x −2 x
%e %e
4x −2 x
4 %e − 2 %e
w:determinant(m);
2x
−6 %e
86505 .wxmx 8 / 8

yp:−Y1·integrate(Y2·3·%e^(−2·x)/w,x) + Y2·integrate(Y1·3·%e^(−2·x)/w
−2 x −2 x
x %e %e
− −
2 12
yg:yp+yc;
−2 x −2 x
4x x %e −2 x %e
%k1 %e − +%k2 %e −
2 12
kill(all);
done
VERIFY:
depends(y,x);
eq:diff(y,x,2)− 2·diff(y,x) − 8·y = 3·%e^(−2·x);
sol:ode2(eq,y,x);
[ y( x ) ]
2
d d −2 x
y −2 y −8 y =3 %e
2 dx
dx
−2 x
4x ( 6 x + 1 ) %e −2 x
y =%k1 %e − +%k2 %e
12

You might also like