Mister Exam

Linear inhomogeneous differential equations of the 1st order Step-By-Step

For example, you have entered (calculator here):
7y(x)+ddxy(x)=sin(x)7 y{\left(x \right)} + \frac{d}{d x} y{\left(x \right)} = \sin{\left(x \right)}

Detail solution

Given the equation:
7y(x)+ddxy(x)=sin(x)7 y{\left(x \right)} + \frac{d}{d x} y{\left(x \right)} = \sin{\left(x \right)}
This differential equation has the form:
y' + P(x)y = Q(x)

where
P(x)=7P{\left(x \right)} = 7
and
Q(x)=sin(x)Q{\left(x \right)} = \sin{\left(x \right)}
and it is called linear homogeneous
differential first-order equation:
First of all, we should solve the correspondent linear homogeneous equation
y' + P(x)y = 0

with multiple variables
The equation is solved using following steps:
From y' + P(x)y = 0 you get

dyy=P(x)dx\frac{dy}{y} = - P{\left(x \right)} dx, if y is not equal to 0
1ydy=P(x)dx\int \frac{1}{y}\, dy = - \int P{\left(x \right)}\, dx
log(y)=P(x)dx\log{\left(\left|{y}\right| \right)} = - \int P{\left(x \right)}\, dx
Or,
y=eP(x)dx\left|{y}\right| = e^{- \int P{\left(x \right)}\, dx}
Therefore,
y1=eP(x)dxy_{1} = e^{- \int P{\left(x \right)}\, dx}
y2=eP(x)dxy_{2} = - e^{- \int P{\left(x \right)}\, dx}
The expression indicates that it is necessary to find the integral:
P(x)dx\int P{\left(x \right)}\, dx
Because
P(x)=7P{\left(x \right)} = 7, then
P(x)dx\int P{\left(x \right)}\, dx =
= 7dx=7x+Const\int 7\, dx = 7 x + Const
Detailed solution of the integral
So, solution of the homogeneous linear equation:
y1=eC17xy_{1} = e^{C_{1} - 7 x}
y2=eC27xy_{2} = - e^{C_{2} - 7 x}
that leads to the correspondent solution
for any constant C, not equal to zero:
y=Ce7xy = C e^{- 7 x}
We get a solution for the correspondent homogeneous equation
Now we should solve the inhomogeneous equation
y' + P(x)y = Q(x)

Use variation of parameters method
Now, consider C a function of x

y=C(x)e7xy = C{\left(x \right)} e^{- 7 x}
And apply it in the original equation.
Using the rules
- for product differentiation;
- of composite functions derivative,
we find that
ddxC(x)=Q(x)eP(x)dx\frac{d}{d x} C{\left(x \right)} = Q{\left(x \right)} e^{\int P{\left(x \right)}\, dx}
Let use Q(x) and P(x) for this equation.
We get the first-order differential equation for C(x):
ddxC(x)=e7xsin(x)\frac{d}{d x} C{\left(x \right)} = e^{7 x} \sin{\left(x \right)}
So, C(x) =
e7xsin(x)dx=(7e7xsin(x)50e7xcos(x)50)+Const\int e^{7 x} \sin{\left(x \right)}\, dx = \left(\frac{7 e^{7 x} \sin{\left(x \right)}}{50} - \frac{e^{7 x} \cos{\left(x \right)}}{50}\right) + Const
Detailed solution of the integral
use C(x) at
y=C(x)e7xy = C{\left(x \right)} e^{- 7 x}
and we get a definitive solution for y(x):
e7x(7e7xsin(x)50e7xcos(x)50+Const)e^{- 7 x} \left(\frac{7 e^{7 x} \sin{\left(x \right)}}{50} - \frac{e^{7 x} \cos{\left(x \right)}}{50} + Const\right)