<< Chapter < Page Chapter >> Page >

Create a direction field for the differential equation y = ( x + 5 ) ( y + 2 ) ( y 2 4 y + 4 ) and identify any equilibrium solutions. Classify each of the equilibrium solutions as stable, unstable, or semi-stable.


A direction field with arrows pointing to the right at y = -4 and y = 4. The arrows point up for y > -4 and down for y < -4. Close to y = 4, the arrows are more horizontal, but the further away, the more vertical they become.
The equilibrium solutions are y = −2 and y = 2 . For this equation, y = −2 is an unstable equilibrium solution, and y = 2 is a semi-stable equilibrium solution.

Got questions? Get instant answers now!

Euler’s method

Consider the initial-value problem

y = 2 x 3 , y ( 0 ) = 3 .

Integrating both sides of the differential equation gives y = x 2 3 x + C , and solving for C yields the particular solution y = x 2 3 x + 3 . The solution for this initial-value problem appears as the parabola in [link] .

A graph over the range [-1,4] for x and y. The given upward opening parabola is drawn with vertex at (1.5, 0.75). Individual points are plotted at (0, 3), (0.5, 1.5), (1, 0.5), (1.5, 0), (2, 0), (2.5, 0.5), and (3, 1.5) with line segments connecting them.
Euler’s Method for the initial-value problem y = 2 x 3 , y ( 0 ) = 3 .

The red graph consists of line segments that approximate the solution to the initial-value problem. The graph starts at the same initial value of ( 0 , 3 ) . Then the slope of the solution at any point is determined by the right-hand side of the differential equation, and the length of the line segment is determined by increasing the x value by 0.5 each time (the step size ). This approach is the basis of Euler’s Method.

Before we state Euler’s Method as a theorem, let’s consider another initial-value problem:

y = x 2 y 2 , y ( −1 ) = 2 .

The idea behind direction fields can also be applied to this problem to study the behavior of its solution. For example, at the point ( −1 , 2 ) , the slope of the solution is given by y = ( −1 ) 2 2 2 = −3 , so the slope of the tangent line to the solution at that point is also equal to −3 . Now we define x 0 = −1 and y 0 = 2 . Since the slope of the solution at this point is equal to −3 , we can use the method of linear approximation to approximate y near ( −1 , 2 ) .

L ( x ) = y 0 + f ( x 0 ) ( x x 0 ) .

Here x 0 = −1 , y 0 = 2 , and f ( x 0 ) = −3 , so the linear approximation becomes

L ( x ) = 2 3 ( x ( −1 ) ) = 2 3 x 3 = −3 x 1.

Now we choose a step size    . The step size is a small value, typically 0.1 or less, that serves as an increment for x ; it is represented by the variable h . In our example, let h = 0.1 . Incrementing x 0 by h gives our next x value:

x 1 = x 0 + h = −1 + 0.1 = −0.9 .

We can substitute x 1 = −0.9 into the linear approximation to calculate y 1 .

y 1 = L ( x 1 ) = −3 ( −0.9 ) 1 = 1.7.

Therefore the approximate y value for the solution when x = −0.9 is y = 1.7 . We can then repeat the process, using x 1 = −0.9 and y 1 = 1.7 to calculate x 2 and y 2 . The new slope is given by y = ( −0.9 ) 2 ( 1.7 ) 2 = −2.08 . First, x 2 = x 1 + h = −0.9 + 0.1 = −0.8 . Using linear approximation gives

L ( x ) = y 1 + f ( x 1 ) ( x x 1 ) = 1.7 2.08 ( x ( −0.9 ) ) = 1.7 2.08 x 1.872 = −2.08 x 0.172.

Finally, we substitute x 2 = −0.8 into the linear approximation to calculate y 2 .

y 2 = L ( x 2 ) = −2.08 x 2 0.172 = −2.08 ( −0.8 ) 0.172 = 1.492.

Therefore the approximate value of the solution to the differential equation is y = 1.492 when x = −0.8 .

What we have just shown is the idea behind Euler’s Method    . Repeating these steps gives a list of values for the solution. These values are shown in [link] , rounded off to four decimal places.

Using euler’s method to approximate solutions to a differential equation
n 0 1 2 3 4 5
x n −1 −0.9 −0.8 −0.7 −0.6 −0.5
y n 2 1.7 1.492 1.3334 1.2046 1.0955
n 6 7 8 9 10
x n −0.4 −0.3 −0.2 −0.1 0
y n 1.0004 1.9164 1.8414 1.7746 1.7156

Euler’s method

Consider the initial-value problem

y = f ( x , y ) , y ( x 0 ) = y 0 .

To approximate a solution to this problem using Euler’s method, define

x n = x 0 + n h y n = y n 1 + h f ( x n 1 , y n 1 ) .

Here h > 0 represents the step size and n is an integer, starting with 1 . The number of steps taken is counted by the variable n .

Practice Key Terms 8

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play Download on the App Store Now




Source:  OpenStax, Calculus volume 2. OpenStax CNX. Feb 05, 2016 Download for free at http://cnx.org/content/col11965/1.2
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'Calculus volume 2' conversation and receive update notifications?

Ask