First Order Di¤erential Equations
Exact Equations
Philippe B. Laval
Introduction
We are still looking at 1st order equations.
In today’s lecture we will discuss exact equationsthat is di¤erential equations of the form M(x;y)dx+N(x;y)dy =0.
In these slides, we assume that the dependent variable is y and the independent variable isx. When we sayy, we really mean "the dependent variable" and when we say x we really mean "the independent variable". The reader needs to be able to adapt this if di¤erent variables are used in an equation.
De…nitions
Recall from Calculus that if y =f (x)then the di¤erential of f is de…ned to be dy =f0(x)dx. It represents the amount by whichy will change if y =f (x) andx changes by the amountdx. There is a similar notion for functions of several variables. It is called the total di¤erential.
De…nition
Ifz =f (x;y) is a function of two variables with continuous …rst order partial derivatives then its di¤erential is
dz =df = @f @xdx+
@f
@ydy (1)
It is sometimes called the total di¤erential. It represents the amount by which z or f will change if z =f (x;y) andx changes bydx andy changes by dy.
De…nitions
With a level curve that is a curve of the formf (x;y) =C, equation 1 becomes @f
@xdx+ @f
@ydy =dC =0. This is of the form M(x;y)dx+N(x;y)dy =0.
De…nition
De…nitions
M(x;y)dx+N(x;y)dy =0 is a di¤erential equation we obtained by …nding the di¤erential of the level curve f (x;y) =C hence its solution, given implicitly, is f (x;y) =C. Suppose now that we are given a di¤erential equation of the form M(x;y)dx+N(x;y)dy =0, how can we …nd its solution? For this, we have to be able to answer the following two questions:
1 Given M(x;y)dx+N(x;y)dy =0, how do we know if
M(x;y)dx+N(x;y)dy is a total di¤erential that is if there exists a functionf such that M(x;y)dx+N(x;y)dy = @f
@xdx+ @f @ydy? 2 Even if there is such a function f, how do we …nd it?
3 Once we …ndf, the solution toM(x;y)dx +N(x;y)dy =0 will be f (x;y) =C, an implicit solution. In order to …nd C, we will need to be given initial conditions.
De…nitions
De…nition
Consider the di¤erential form M(x;y)dx+N(x;y)dy.
1 It is said to be exactin a rectangleR if there exists a function f (x;y) such that
@f
@x (x;y) =M(x;y) and @f
@y (x;y) =N(x;y) for all (x;y) in R that is the total di¤erential of f satis…es df (x;y) =M(x;y)dx +N(x;y)dy.
2 IfM(x;y)dx+N(x;y)dy is an exact di¤erential form, then the equation M(x;y)dx +N(x;y)dy =0 is said to be anexact equation.
De…nitions
Theorem
Suppose the …rst order partial derivatives of M(x;y) and N(x;y) are continuous in a rectangle R then
M(x;y)dx+N(x;y)dy =0
is an exact equation in R if and only if the compatibility condition @M
@y (x;y) = @N
@x (x;y) (2)
holds for all (x;y) in R. Example
Method 1 for Solving Exact Equations
To solveM(x;y)dx+N(x;y)dy =0, follow these steps: 1 If it is exact, then @f
@x(x;y) =M(x;y). Integrate both sides with respect to x to get
f (x;y) =
Z
M(x;y)dx+g(y) (3)
2 To …nd g(y), di¤erentiate both sides of equation 3 with respect to y, substituting N(x;y) for @f
@y (x;y). Then solve forg 0(y).
3 Integrate g0(y) with respect toy to …nd g(y) which can then be substituted in equation 3 to …nd f (x;y).
4 The solution to M(x;y)dx+N(x;y)dy =0 is given implicitly by f (x;y) =C.
Method 2 for Solving Exact Equations
To solveM(x;y)dx+N(x;y)dy =0, follow these steps: 1 If it is exact, then @f
@y (x;y) =N(x;y). Integrate both sides with respect to y to get
f (x;y) =
Z
N(x;y)dy +h(x) (4)
2 To …nd h(x), di¤erentiate both sides of equation 4 with respect to x, substituting M(x;y) for @f
@x (x;y). Then solve forh 0(x).
3 Integrate h0(x)with respect to x to …nd h(x) which can then be substituted in equation 4 to …nd f (x;y).
4 The solution to M(x;y)dx+N(x;y)dy =0 is given implicitly by f (x;y) =C.
Examples
Example (Solving an Exact DE) Solve 2xydx+ x2 1 dy =0
Example (Solving an Exact DE)
Solve e2y ycos(xy) dx+ 2xe2y xcos(xy) +2y dy=0
Example (Solving an Initial Value Problem) Solve dy
dx =
xy2 cosxsinx
Nonexact Equations Made Exact
Recall from the previous section that the left-hand side of dy
dx +P(x)y =Q(x) can be transformed into a derivative when we multiply the equation by an integrating factor.
The same basic idea sometimes works for a nonexact di¤erential equation M(x;y)dx+N(x;y)dy =0 that is it is sometimes possible to …nd an integrating factor (x;y) such that
(x;y)M(x;y)dx+ (x;y)N(x;y)dy =0 (5) is an exact equation.
Nonexact Equations Made Exact
To …nd , we use the compatibility condition given in equation 2 that is @ @y ( (x;y)M(x;y)) = @ @x( (x;y)N(x;y)) or M@ @y + @M @y =N @ @x + @N @x or N@ @x M @ @y = @M @y @N @x (6)
Nonexact Equations Made Exact
Although M andN are known and hence their partial derivatives are known, this is a partial di¤erential equation in .
Solving it is beyond the scope of this class. So, we will make some assumptions to simplify this equation.
Since we only know how to solve ODEs, we are going to assume that depends only in one variable.
So, we have two possibilities to …nd . If one does not work, try the other one. If neither works, then our technique will not work. The possibilities are:
Case 1: = (x) is a function ofx only.
Nonexact Equations Made Exact: Case 1
In this case, @@y =0 and equation 6 becomes
d dx = @M @y @N @x N (7) If the quotient @M @y @N @x
N is still a function of bothx andy, then we are at an impasse and our technique won’t work.
But if @M
@y @N
@x
N after all possible simpli…cations is a function of x only, then equation 7 is a separable linear di¤erential equation. Its solution is
(x) =eR ( @M
Nonexact Equations Made Exact: Case 2
In this case, @@x =0 and equation 6 becomes
d dy = @N @x @M @y M (8) If the quotient @N @x @M @y
M is still a function of bothx andy, then we are at an impasse and our technique won’t work.
But if @N
@x @M
@y
M after all possible simpli…cations is a function of y only, then equation 8 is a separable linear di¤erential equation. Its solution is
(y) =eR ( @N
@x @@My)
Nonexact Equations Made Exact: Finishing
If we manage to get , then equation 5 is now exact and we can …nish solving it by using the technique to solve exact equations. We illustrate this with an example.
Example