# Differential Equations Solution Guide

A Differential Equation is an equation with a function and one or more of its derivatives: Example: an equation with the function y and its derivative dy dx

In our world things change, and describing how they change often ends up as a Differential Equation.

Real world examples where Differential Equations are used include population growth, electrodynamics, heat flow, planetary movement, economical systems and much more!

## Solving

So a Differential Equation can be a very natural way of describing something.

### Example: Population Growth

Here we say that a population "N" increases (at any instant) as the growth rate times the population at that instant:

dNdt = rN

But it is not very useful as it is.

We need to solve it!

We solve it when we discover the function y (or set of functions y) that satisfies the equation, and then it can be used successfully.

### Example: continued

Our example is solved with this equation:

N(t) = N0ert

that can actually be used like this:

A population that starts at 1000 (N0) with a growth rate of 10% per month (r) will grow to

• 1000e0.1x1 = 1105 in 1 month
• 1000e0.1x6 = 1822 in 6 months
• etc

There is no magic bullet to solve all Differential Equations.

But over the millennia great minds have been building on each others work and have discovered different methods (possibly long and complicated methods!) of solving some types of Differential Equations.

So let’s take a look at some different types of Differential Equations and how to solve them

Separation of Variables equations look like this:
dydx = xy
First Order Linear are of this type:
dydx + P(x)y = Q(x)
Homogeneous equations look like:
dy dx = F (  y x )
Bernoulli are of this general form:
dydx + P(x)y = Q(x)yn, n ≠ 0 or 1
Second Order (homogeneous) are of the type:
d2ydx + P(x) dy dx + Q(x)y = 0
Undetermined Coefficients and Variation of Parameters are both methods for solving second order equations when they are non-homogeneous like:
d2ydx + p dy dx + qy = f(x)
Exact Equationis where a first-order differential equation like this:

M(x,y)dx + N(x,y)dy = 0

has some special function I(x,y) whose partial derivatives can be put in place of M and N like this:

∂I∂xdx + ∂I∂ydy = 0

## Separation of Variables Separation of Variables can be used when:

All the y terms (including dy) can be moved to one side of the equation, and

All the x terms (including dx) to the other side.

If that is the case, you will then have to integrate and simplify the solution.

## First Order Linear

A first order differential equation is linear when it can be made to look like this:

dy dx + P(x)y = Q(x)

Where P(x) and Q(x) are functions of x.

Observe that they are "First Order" when there is only dy dx , not d2y dx2 or d3y dx3 , etc.

If you have an equation like this then you can read more on Solution of First Order Linear Differential Equations

Note: non-linear differential equations are often harder to solve and therefore commonly approximated by linear differential equations to find an easier solution.

## Homogeneous Equations

There is another special case where Separation of Variables can be used called homogeneous.

A first-order differential equation is said to be homogeneous if it can be written in the form

dy dx = F (  y x )

Such an equation can be solved by using the change of variables:

v = y x

which transforms the equation into one that is separable. To discover more on this type of equations, check this complete guide on Homogeneous Differential Equations

## Bernoulli Equation

A Bernoulli equation has this form:

dydx + P(x)y = Q(x)yn
where n is any Real Number but not 0 or 1

• When n = 0 the equation can be solved as a First Order Linear Differential Equation.
• When n = 1 the equation can be solved using Separation of Variables.
• For other values of n we can solve it by substituting
u = y1−n
and turning it into a linear differential equation (and then solve that).

## Second Order Equation

In this type of equation the second derivative makes its appearance. The general second order equation is written as follows

a(x)d2y dx2 + b(x)dy dx + c(x)y = Q(x)

There are many distinctive cases among these equations.

They are classified as homogeneous (Q(x)=0), non-homogeneous, autonomous, constant coefficients, undetermined coefficients etc.

For non-homogeneous equations the general solution is equal to the sum of:

Solution to corresponding homogeneous equation

+

Particular solution of the non-homogeneous equation

## Undetermined Coefficients

This method works for a non-homogeneous equation like

d2ydx2 + P(x)dydx + Q(x)y = f(x)

where f(x) is a polynomial, exponential, sine, cosine or a linear combination of those.

To keep things simple, we only look at the case:

d2ydx2 + pdydx + qy = f(x)

where p and q are constants.

The complete solution to such an equation can be found by combining two types of solution:

1. The general solution of the homogeneous equation
2. d2ydx2 + pdydx + qy = 0

3. Particular solutions of the non-homogeneous equation
4. d2ydx2 + pdydx + qy = f(x)

Once we have found the general solution and all the particular solutions, then the final complete solution is found by adding all the solutions together.

This method also involves making a guess! Read more at Undetermined Coefficients

## Variation of Parameters

This is a more general method than Undetermined Coefficients.

Once you have the general solution to the homogeneous equation, you have two fundamental solutions y1 and y2

And when y1 and y2 are the two fundamental solutions of the homogeneous equation

d2ydx2 + pdydx + qy = 0

then the Wronskian W(y1, y2) is the determinant of the matrix

So

W(y1, y2) = y1y2' − y2y1'

And using the Wronskian we can now find the particular solution of the differential equation

d2ydx2 + pdydx + qy = f(x)

using the formula:

yp(x) = −y1(x)y2(x)f(x)W(y1,y2)dx + y2(x)y1(x)f(x)W(y1,y2)dx

Finally we complete solution by adding the general solution and the particular solution together.

## Exact Equations and Integrating Factors

An "exact" equation is where a first-order differential equation like this:

M(x,y)dx + N(x,y)dy = 0

has some special function I(x,y) whose partial derivatives can be put in place of M and N like this:

∂I∂xdx + ∂I∂ydy = 0

and our job is to find that magical function I(x,y) if it exists.

Find out how to solve these at Exact Equations and Integrating Factors

## Ordinary Differential Equations (ODEs) vs Partial Differential Equations (PDEs)

All of the methods so far are known as Ordinary Differential Equations (ODE's).

The term ordinary is used in contrast with the term partial to indicate derivatives with respect to only one independent variable.

Differential Equations with unknown multi-variable functions and their partial derivatives are a different type and require separate methods to solve them.

They are called Partial Differential Equations (PDE's), and sorry but we don't have any page on this topic yet.