To provide the best experiences, we use technologies like cookies to store and/or access device information. Consenting to these technologies will allow us to process data such as browsing behavior or unique IDs on this site. Not consenting or withdrawing consent, may adversely affect certain features and functions.
The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
The technical storage or access that is used exclusively for statistical purposes.
The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.
SOLVING DIFFERENTIAL EQUATIONS 1
Separation of Variables
Separation of Variables is a special method to solve some Differential Equations
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 dydx
When Can I Use it?
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.
Method
Three Steps:
Example: Solve this (k is a constant):
dydx = ky
Step 1 Separate the variables by moving all the y terms to one side of the equation and all the x terms to the other side:
Step 2 Integrate both sides of the equation separately:
C is the constant of integration. And we use D for the other, as it is a different constant.
Step 3 Simplify:
We have solved it:
y = cekx
This is a general type of first order differential equation which turns up in all sorts of unexpected places in real world examples.
We used y and x, but the same method works for other variable names, like this:
Example: Rabbits!
The more rabbits you have the more baby rabbits you will get. Then those rabbits grow up and have babies too! The population will grow faster and faster.
The important parts of this are:
The rate of change at any time equals the growth rate times the population:
dN dt = rN
But hey! This is the same as the equation we just solved! It just has different letters:
So we can jump to a solution:
N = cert
And here is an example, the graph of N = 0.3e2t:
Exponential Growth
There are other equations that follow this pattern such as continuous compound interest.
More Examples
OK, on to some different examples of separating the variables:
Example: Solve this:
dydx = 1y
Step 1 Separate the variables by moving all the y terms to one side of the equation and all the x terms to the other side:
Step 2 Integrate both sides of the equation separately:
We integrated both sides in the one line.
We also used a shortcut of just one constant of integration C. This is perfectly OK as we could have +D on one, +E on the other and just say that C = E−D.
Step 3 Simplify:
Note: This is not the same as y = √(2x) + C, because the C was added before we took the square root. This happens a lot with differential equations. We cannot just add the C at the end of the process. It is added when doing the integration.
We have solved it:
y = ±√(2(x + C))
A harder example:
Example: Solve this:
dydx = 2xy1+x2
Step 1 Separate the variables:
Multiply both sides by dx, divide both sides by y:
1y dy = 2x1+x2dx
Step 2 Integrate both sides of the equation separately:
∫1y dy = ∫2x1+x2dx
The left side is a simple logarithm, the right side can be integrated using substitution:
Step 3 Simplify:
It is already as simple as can be. We have solved it:
y = k(1 + x2)
An even harder example: the famous Verhulst Equation
Example: Rabbits Again!
Remember our growth Differential Equation:
dNdt = rN
Well, that growth can’t go on forever as they will soon run out of available food.
A guy called Verhulst included k (the maximum population the food can support) to get:
dNdt = rN(1−N/k)
The Verhulst Equation
Can this be solved?
Yes, with the help of one trick …
Step 1 Separate the variables:
Step 2 Integrate:
∫1N(1−N/k)dN = ∫ r dt
Hmmm… the left side looks hard to integrate. In fact it can be done with a little trick from Partial Fractions … we rearrange it like this:
Now it is a lot easier to solve. We can integrate each term separately, like this:
(Why did that become minus ln(k−N)? Because we are integrating with respect to N.)
Step 3 Simplify:
We are getting close! Just a little more algebra to get N on its own:
And we have our solution:
N = k1 + Ae−rt
Here is an example, the graph of 401 + 5e−2t
It starts rising exponentially,
then flattens out as it reaches k=40
Solution of First Order Linear Differential Equations
You might like to read about Differential Equations and Separation of Variables first!
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 dydx
Here we will look at solving a special class of Differential Equations called First Order Linear Differential Equations
First Order
They are “First Order” when there is only dydx , not d2ydx2 or d3ydx3 etc
Linear
A first order differential equation is linear when it can be made to look like this:
dydx + P(x)y = Q(x)
Where P(x) and Q(x) are functions of x.
To solve it there is a special method:
And we also use the derivative of y=uv (see Derivative Rules (Product Rule) ):
dydx = udvdx + vdudx
Steps
Here is a step-by-step method for solving them:
dydx = udvdx + vdudx
into
dydx + P(x)y = Q(x)
Let’s try an example to see:
Example 1: Solve this:
dydx − yx = 1
First, is this linear? Yes, as it is in the form
dydx + P(x)y = Q(x)
where P(x) = −1x and Q(x) = 1
So let’s follow the steps:
Step 1: Substitute y = uv, and dydx = u dvdx + v dudx
Step 2: Factor the parts involving v
Step 3: Put the v term equal to zero
Step 4: Solve using separation of variables to find u
Step 5: Substitute u back into the equation at Step 2
Step 6: Solve this to find v
Step 7: Substitute into y = uv to find the solution to the original equation.
And it produces this nice family of curves:
y = x ln(cx) for various values of c
What is the meaning of those curves? They are the solution to the equation dydx − yx = 1
In other words:
Anywhere on any of those curves
the slope minus yx equals 1
Let’s check a few points on the c=0.6 curve:
Estmating off the graph (to 1 decimal place):
Why not test a few points yourself? You can plot the curve here.
Perhaps another example to help you? Maybe a little harder?
Example 2: Solve this:
dydx − 3yx = x
First, is this linear? Yes, as it is in the form
dydx + P(x)y = Q(x)
where P(x) = − 3x and Q(x) = x
So let’s follow the steps:
Step 1: Substitute y = uv, and dydx = u dvdx + v dudx
Step 2: Factor the parts involving v
Step 3: Put the v term equal to zero
Step 4: Solve using separation of variables to find u
Step 5: Substitute u back into the equation at Step 2
Step 6: Solve this to find v
Step 7: Substitute into y = uv to find the solution to the original equation.
And it produces this nice family of curves:
y = c x3 − x2 for various values of c
And one more example, this time even harder:
Example 3: Solve this:
dydx + 2xy= −2x3
First, is this linear? Yes, as it is in the form
dydx + P(x)y = Q(x)
where P(x) = 2x and Q(x) = −2x3
So let’s follow the steps:
Step 1: Substitute y = uv, and dydx = u dvdx + v dudx
Step 2: Factor the parts involving v
Step 3: Put the v term equal to zero
Step 4: Solve using separation of variables to find u
Step 5: Substitute u back into the equation at Step 2
Step 6: Solve this to find v
Let’s see … we can integrate by parts… which says:
∫ RS dx = R ∫ S dx − ∫ R’ ( ∫ S dx) dx
(Side Note: we use R and S here, using u and v could be confusing as they already mean something else.)
Choosing R and S is very important, this is the best choice we found:
So let’s go:
Put in R = −x2 and S = 2x ex2
And also R’ = −2x and ∫ S dx = ex2
Step 7: Substitute into y = uv to find the solution to the original equation.
And we get this nice family of curves:
y = 1 − x2 + c e−x2 for various values of c
Assignment
ASSIGNMENT : SOLVING DES1 ASSIGNMENT MARKS : 30 DURATION : 1 week, 3 days