Video Transcript
Solve the differential equation 𝑥
d𝑦 by d𝑥 equals 𝑦 plus 𝑥 squared sin 𝑥 subject to the condition 𝑦 of 𝜋 equals
zero. Is it (a) 𝑦 equals 𝑥 cos 𝑥 plus
𝑥? (b) 𝑦 equals 𝑥 cos 𝑥 minus
𝑥. (c) 𝑦 equals negative 𝑥 cos 𝑥
plus 𝑥. (d) 𝑦 equals 𝑥 cos 𝑥. Or (e) 𝑦 equals negative 𝑥 cos 𝑥
minus 𝑥.
A first-order linear differential
equation in its most general form looks like this: d𝑦 by d𝑥 plus some function 𝑓
of 𝑥 times 𝑦 equals some function 𝑔 of 𝑥. In most cases for 𝑓 of 𝑥 and 𝑔
of 𝑥, it will not be possible to separate the variables of this differential
equation. So we need to use an integrating
factor, which is given by 𝐼 of 𝑥 equals 𝑒 to the integral 𝑓 of 𝑥 d𝑥. And we ignore the constant of
integration. We then multiply both sides of the
differential equation by this integrating factor. What this achieves is that we now
have an exact differential equation, which is to say that we have a derivative of
only one term on the left-hand side.
More specifically, we have d by d𝑥
of the integrating factor times 𝑦. This then allows us to separate the
variables and integrate with respect to 𝑥 on both sides. This gives us a standard formula
for the solution to a general first-order differential equation, which may usually
be quoted without proof, 𝐼𝑦 equals integral 𝐼𝑔 of 𝑥 d𝑥.
So let’s apply this to the given
differential equation. We first need to rearrange the
equation to get it in the standard form. That is, d𝑦 d𝑥 plus some function
of 𝑥 times 𝑦 equals another function of 𝑥. Rearranging into this form, we get
d𝑦 by d𝑥 minus 𝑦 over 𝑥 equals 𝑥 sin 𝑥. So in this case, our 𝑓 of 𝑥 is
negative one over 𝑥 and our 𝑔 of 𝑥 is just 𝑥 sin 𝑥. So our integrating factor is given
by 𝑒 to the integral 𝑓 of 𝑥 d𝑥, which in this case is 𝑒 to the integral
negative one over 𝑥 d𝑥. This integrates to 𝑒 to the
negative natural log of 𝑥. And we ignore the constant of
integration.
Using standard indices laws, this
is equal to 𝑒 to the natural log of 𝑥 to the negative one. 𝑒 to the natural log of 𝑥 is
simply 𝑒 raised to the power of 𝑒 that makes 𝑥. So this is simply 𝑥. So our integrating factor 𝐼 of 𝑥
is one over 𝑥. Now plugging into the standard
formula 𝐼𝑦 equals integral 𝐼𝑔 of 𝑥 d𝑥. We have one over 𝑥 𝑦 equals the
integral of one over 𝑥 times 𝑥 sin 𝑥 d𝑥. The right-hand side simplifies to
the integral of sin 𝑥 d𝑥, which integrates to negative cos 𝑥. And this time, we do not ignore the
constant of integration. Multiplying both sides by 𝑥, we
get 𝑦 equals negative 𝑥 cos 𝑥 plus 𝐶𝑥.
This is the general solution to the
differential equation. But we’re not finished yet since
this is subject to a condition 𝑦 of 𝜋 equals zero. Plugging in these values of 𝑥 and
𝑦, we get zero equals negative 𝜋 cos 𝜋 plus 𝐶𝜋. Rearranging and simplifying, we get
𝐶 is equal to negative one. Substituting in this value of 𝐶
into the general solution, we get the particular solution 𝑦 equals negative 𝑥 cos
𝑥 minus 𝑥. Comparing this with our possible
answers, we can see that this matches with (e). 𝑦 equals negative 𝑥 cos 𝑥 minus
𝑥.