#### Transcript Sec. 1.2: Finding Limits Graphically and Numerically

```AP Calculus BC
Tuesday, 19 November 2013
• OBJECTIVE TSW solve differential equations using
slope fields, Euler’s Method, and separation of
variables.
• ASSIGNMENTS
– Sec. 4.5 is due on Friday (TEST day).
Solving Differential Equations
Slope Fields
Solving DE: Slope Fields
Slope Fields allow you to approximate the
solutions to differential equations graphically.
Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in a solution curve for the initial condition.
y

Example 1
Initial condition
y 1  1

dy
 x 1
dx

x









Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in a solution curve for the initial condition.
y

Example 1
Initial condition

dy
 x 1
dx
y 1  1


x













Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in a solution curve for the initial condition.
y

Example 1
Initial condition

dy
 x 1
dx
y 1  1


x













Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in solution curves for the initial conditions.
y

Example 2
Initial condition
a) y  1  1

dy
 2y
dx

x









b) y  2   2
Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in solution curves for the initial conditions.
y

Example 2
Initial condition

dy
 2y
dx
a) y  1  1


x













b) y  2   2
Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in solution curves for the initial conditions.
y

Example 2
Initial condition

dy
 2y
dx
a) y  1  1


x













b) y  2   2
Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in solution curves for the initial conditions.
y

Example 2
Initial condition

dy
 2y
dx
a) y  1  1


x













b) y  2   2
Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in solution curves for the initial conditions.
y

Example 3
Initial condition
a) y  0   1

dy
 x y
dx
b) y  1  1

x









Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in solution curves for the initial conditions.
y

Example 3
Initial condition

dy
 x y
dx
a) y  0   1

b) y  1  1

x













Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in solution curves for the initial conditions.
y

Example 3
Initial condition

dy
 x y
dx
a) y  0   1

b) y  1  1

x













Solving DE: Slope Fields
Draw a slope field in the grid for the given differential equation. Then,
draw in solution curves for the initial conditions.
y

Example 3
Initial condition

dy
 x y
dx
a) y  0   1

b) y  1  1

x













Solving DE: Slope Fields
• Assignment
 WS Solving Differential Equations – Slope
Fields
 Due Friday, 22 November 2013.
 WS Slope Fields
 Due Friday, 22 November 2013.
Solving DE: Euler’s Method
Illustration of Euler’s
Method; the curve is
being “linearized” to
approximate a
desired solution,
given an initial value.
A better
approximation is
attained with a
smaller step size h.
Solving DE: Euler’s Method
Euler’s Method
To approximate the solution of the initial-value
problem
y ′ = f (x, y), y (x0) = y0,
proceed as follows:
Step 1: Choose a nonzero number h to serve as
an increment or step size along the x-axis,
NOTE: h will
and let
be given.
x1 = x0 + h, x2 = x1 + h, x3 = x2 + h, . . .
Solving DE: Euler’s Method
Euler’s Method
Step 2: Compute successively
y1 = y0 + f (x0, y0)h
y2 = y1 + f (x1, y1)h
y3 = y2 + f (x2, y2)h
...
The numbers y1, y2, y3, . . . in these equations are
the approximation of y(x1), y(x2), y(x3), . . .
Solving DE: Euler’s Method
Ex:
Use Euler's method with a step size of 0.5
to solve the initial-value problem
y' = y – x, y (0) = 2
over the interval 0 ≤ x ≤ 1.
 x0, y 0    0, 2 
y1  y 0  f  x0 , y 0  h  y1  2  f  0, 2  0.5 
y 0  2 
y1  2   2  0  0.5   3
 x1, y1    0.5, 3 
Solving DE: Euler’s Method
Ex:
Use Euler's method with a step size of 0.5
to solve the initial-value problem
y' = y – x, y (0) = 2
over the interval 0 ≤ x ≤ 1.
 x1, y1    0.5, 3 
y 2  y1  f  x1, y1  h  y 2  3  f  0.5, 3  0.5 
y 2  3   3  0.5  0.5   4.25
y 1  4.25
 x2, y 2   1, 4.25 
Solving DE: Euler’s Method
Ex:
Use Euler's method with a step size of 0.25
to solve the initial-value problem
y' = y – x, y (0) = 2
over the interval 0 ≤ x ≤ 1.
 x0, y 0    0, 2 
y1  y 0  f  x0 , y 0  h  y1  2  f  0, 2  0.25 
y 0  2 
y1  2   2  0  0.25   2.5
 x1, y1   0.25, 2.5 
Solving DE: Euler’s Method
Ex:
Use Euler's method with a step size of 0.5
to solve the initial-value problem
y' = y – x, y (0) = 2
over the interval 0 ≤ x ≤ 1.
 x1, y1    0.25, 2.5 
 x2, y 2    0.5, 3.0625 
y 2  y1  f  x1, y1  h
y 3  y 2  f  x2 , y 2  h
y 2  2.5  f  0.25, 2.5  0.25 
y 3  3.0625  f  0.5, 3.0625  0.25 
y 2  2.5   2.5  0.25  0.25 
y 3  3.0625   3.0625  0.5  0.25 
y 2  3.0625
y 3  3.703125
 x2, y 2    0.5, 3.0625 
 x3 , y 3    0.75, 3.703125 
Solving DE: Euler’s Method
Ex:
Use Euler's method with a step size of 0.5
to solve the initial-value problem
y' = y – x, y (0) = 2
over the interval 0 ≤ x ≤ 1.
 x3 , y 3    0.75, 3.703125 
y 4  y 3  f  x3 , y 3  h
y 4  3.703125  f  0.75, 3.703125  0.25 
y 4  3.703125   3.703125  0.75  0.25 
y 4  4.44140625
 x4 , y 4   1, 4.44140625 
When using Euler’s
Method, use all decimals !
y 1  4.44140625
Solving DE: Euler’s Method

WS Euler’s Method

Due on Friday, 22 November 2013.
AP Calculus BC
Wednesday, 20 November 2013
• OBJECTIVE TSW (1) solve differential equations
using the technique of separation of variables, and (2)
review for the test covering indefinite integration.
• ASSIGNMENTS DUE FRIDAY
–
–
–
–
–
(11/22/13)
Sec. 4.5
WS Slope Fields
WS Solving Differential Equations – Slope Fields
WS Euler's Method
WS Separation of Variables
Solving Differential Equations
Separation of Variables
Solving Differential Equations:
Separation of Variables

We have seen differential equations that are
explicitly in terms of x:
dy
Ex :
 4x  1
dx
Ex : y   3 x 2
dy
x
Ex :

dx
16  x 2
Solving Differential Equations:
Separation of Variables

We solved these by multiplying both sides
by dx and integrating. For example,
dy
 4x  1
dx
dy   4 x  1 dx
 dy    4x  1 dx
y  2x 2  x  C
Solving Differential Equations:
Separation of Variables
Sometimes, though, the differential
equations are not as straightforward.
dy
Ex : Solve the DE:
 4 xy 2.
dx
Get terms with "y" on
1
one side, all other terms
dy  4 xdx
2
on the other side.
y
1
NOTE: The solution is NOT
dy


4
xdx


2
1
y
y  2  C.
2x
1
  2x 2  C
y
1
This is called the general solution
y 2
because it has "C".
2x  C

Solving Differential Equations:
Separation of Variables

Let's add an initial condition: y(0) = 1
1
1
y 2
1
2
2x  C
2 0  C
1
1
C
1 C
y
1
2x 2  1
This is called the
particular solution.
Solving Differential Equations:
Separation of Variables

Solve
dy
 4y  cos y   3 x 2  0, y  0   0
dx
dy
 4y  cos y   3 x 2
dx
 4y  cos y  dy  3x 2dx
2
4
y

cos
y
dy

3
x


 dx
2y 2  sin y  x 3  C
The equation cannot be
simplified for y.
Solving Differential Equations:
Separation of Variables

For the particular solution, y(0) = 0, so
2y 2  sin y  x 3  C
2  0   sin  0    0   C
2
3
0 C
2y 2  sin y  x 3
Solving Differential Equations:
Separation of Variables

WS Separation of Variables

Due on Friday, 22 November 2013 (TEST day).
```