ODE Assign 2 Sol
ODE Assign 2 Sol
ODE Assign 2 Sol
Solution:
dv dX
a+bv
= ,
f c+dv
−v X
w0 − c
λw + m
=f = g(w) =⇒ w0 = c + dg(w),
d w+n
4. Show that the following equations are exact and hence find their general solution:
2 2
(T)(i) (cos x cos y − cot x) = (sin x sin y)y 0 (ii) y 0 = 2x(ye−x − y − 3x)/(x2 + 3y 2 + e−x )
Solution:
(i) Comparing the given ODE with with M dx + N dy = 0 with y 0 = dy/dx, we have
M = (cos x cos y − cot x), N = − sin x sin y. Clearly ∂M/∂y = ∂N/∂x. Hence the ode
is exact.
Since the ODE is exact, we must have
∂u ∂u
M dx + N dy = du = dx + dy
∂x ∂y
nh − mk = m(b + 1) − n(a + 1)
qh − pk = p(d + 1) − q(c + 1)
6. (T) Given that the equation (3y 2 − x) + 2y(y 2 − 3x)y 0 = 0 admits an integrating factor
which is a function of (x + y 2 ). Hence solve the differential equation.
Solution:
Assume that F (x + y 2 ) is an integrating factor. Multiplying by F (x + y 2 ) we find
M = (3y 2 − x)F (x + y 2 ) and N = 2y(y 2 − 3x)F (x + y 2 ). Using the condition of
exactness ∂M/∂y = ∂N/∂x, we get
Simplifying,
dF 1
z = −3F =⇒ F = 3 , z = x + y 2 .
dz z
Hence
3y 2 − x 4y 2 − t 2y 2 1
Z Z Z
u= M dx = dx = dt = − + + f (y),
(x + y 2 )3 t3 t2 t
by substituting t = x + y 2 . Hence
x − y2
u= + f (y).
(x + y 2 )2
Since ∂u/∂y = N , we find f 0 = 0 and hence f =constant. Hence the solution is
x − y2
=C
(x + y 2 )2
7. Consider first order ODE M (x, y)dx + N (x, y)dy = 0 with M, N are C 1 functions on R2 .
Show that
(T)(i). If ( ∂M − ∂N
R
∂y ∂x
)/N = f (x) depends on x only then, exp( f (x)dx) is an integrating
factor for the given ODE.
(ii). If ( ∂M − ∂N
R
∂y ∂x
)/M = g(y) depends on y only then, exp(− g(y)dy) is an integrating
factor for the given ODE.
R
∂
Solution: (i) Let µ = e f (x)dx
. Then ∂y
(µM ) = µ ∂M
∂y
and
∂ ∂N ∂µ ∂N ∂N ∂M ∂(µM )
(µN ) = µ +N =µ + N µf = µ( + Nf) = µ =
∂x ∂x ∂x ∂x ∂x ∂y ∂y
(ii) Similarly.
10. Solve the linear first order linear IVP y 0 + y tan x = sin 2x, y(0) = 1.
[ Recall: For y 0 + p(x)y = r(x), the left hand side becomes exact if we multiply by
d
R
µ(x) = exp( p(x)dx)). We get dx (µ(x)y) = µ(x)r(x). Integrating, general solution is
Z
−1
y(x) = µ(x) µ(x)r(x)dx + c.
]
Solution: Comparing with y 0 + p(x)y = r(x), we get p(x) = tan x, r(x) = sin 2x.
Then,
Z Z Z
p(x)dx = ln(sec x), µ(x) = sec x, µ(x)r(x)dx = sec x 2 sin x cos xdx = −2 cos x+c.
(i) Substitute u = y 3 and the ODE transform to linear form u0 + 3u/x = 3x−2 sin x.
Using integrating factor x3 , we write
d
(ux3 ) = 3x sin x =⇒ ux3 = 3(−x cos x + sin x) + C
dx
Thus, the solution is x3 y 3 + 3(x cos x − sin x) = C.
(ii) Substitute − cos y = u which leads to the linear form u0 − xu = x. Using integrating
2
factor e−x /2 , we write
d 2 2 2 2 2
(ue−x /2 ) = xe−x /2 =⇒ ue−x /2 = −e−x /2 + C =⇒ u = −1 + Cex /2
dx
2 /2
Hence, the solution is cos y = 1 − Cex .
(iii) u = 1/y 3 leads to u0 − 3u = −3x. Using integrating factor e−3x , we write
d 1 + 3x −3x 1 + 3x
(ue−3x ) = −3xe−3x =⇒ ue−3x = e + C =⇒ u = + Ce3x .
dx 3 3
Hence, the solution is 1/y 3 = Ce3x + x + 1/3.
13. (T) A radioactive substance A decays into B, which then further decays to C.
a) If the decay constants of A and B are respectively λ1 and λ2 , and the initial amounts
are respectively A0 and B0 , set up an ODE for determining B(t), the amount of B
present at time t, and solve it. (Assume λ1 6= λ2 .)
b) Assume λ1 = 1, λ2 = 2. When B(t) reaches a maximum?
Solution: dA/dt = −λ1 A and
= λ1 A − λ2 B.
14. According to Newton’s Law of Cooling, the rate at which the temperature T of a body
changes is proportional to the difference between T and the external temperature. At
time t = 0, a pot of boiling water is removed from the stove. After five minutes, the
water temperature is 80C. If the room temperature is 20C, when will the water have
cooled to 60C?
Solution: By Newton’s cooling law dT dt
= k(T − 20) where k is the constant of pro-
portionality. Solving it we get T (t) = cekt + 20. The initial condition T (0) = 100 gives
c = 80. Thus T (t) = 80ekt + 20.
Now after 5 minutes, the temperature of water is 80C. So T (5) = 80 gives k = 1/5 ln(3/4)
Now the time t to cooled down the water to 60 is given by T (t) = 60, implies kt = ln(1/2),
t = 5 ln(2)/ ln(4/3) (≈ 12) minutes.