1
00:00:01,525 --> 00:00:03,332
Here's an overview of Euler's method
2
00:00:03,332 --> 00:00:06,212
for solving differential equations of this form.
3
00:00:06,212 --> 00:00:10,091
The derivative of some unknown function X is just a function of X,
4
00:00:10,091 --> 00:00:14,825
and we assume that we know the starting value of this function X,
5
00:00:14,825 --> 00:00:19,441
- so this could be temperature, this could be position, could be anything.
6
00:00:19,441 --> 00:00:22,025
So, we start - we need to choose a step size,
7
00:00:22,025 --> 00:00:25,897
- that's a choice that we get to make, and we'll start at time t equal 0,
8
00:00:25,897 --> 00:00:28,687
where we know the X value.
9
00:00:28,687 --> 00:00:30,773
So, then using the current value of X,
10
00:00:30,773 --> 00:00:33,987
the equation - the differential equation - this function,
11
00:00:33,987 --> 00:00:35,577
tells us the rate of change.
12
00:00:35,577 --> 00:00:38,971
So, we know how fast X is changing.
13
00:00:38,971 --> 00:00:41,296
We then use this rate of change
14
00:00:41,296 --> 00:00:44,441
to determine the next value for X,
15
00:00:44,441 --> 00:00:47,938
This is the current value for X,
16
00:00:47,938 --> 00:00:51,983
this is how much X changes, in the time interval delta t.
17
00:00:51,983 --> 00:00:53,654
This is a little bit of make-believe
18
00:00:53,654 --> 00:00:56,372
- we're pretending that the rate of change is constant
19
00:00:56,372 --> 00:00:59,357
for this time interval delta t, and we can use that
20
00:00:59,357 --> 00:01:03,585
to figure out the next value of X,
21
00:01:03,585 --> 00:01:07,505
then, we increased t by delta t
22
00:01:07,505 --> 00:01:11,895
and we go back to this step, and we figure out the derivative again.
23
00:01:11,895 --> 00:01:15,377
The derivative tells us how to go forward a little bit in time
24
00:01:15,377 --> 00:01:20,030
to figure out the next X, then we update time, figure out the derivative again,
25
00:01:20,030 --> 00:01:23,211
move forward to figure out X.
26
00:01:23,211 --> 00:01:26,215
So 2 and 3 - these are the key steps here,
27
00:01:26,215 --> 00:01:28,574
- wer'e constantly shuffling back and forth,
28
00:01:28,574 --> 00:01:33,193
the function - the differential equation - tells us the derivative,
29
00:01:33,193 --> 00:01:37,180
- here we use the derivative to figure out the value of X,
30
00:01:37,180 --> 00:01:41,028
and then we go back, X gives us the derivative from the differential equation,
31
00:01:41,028 --> 00:01:43,941
- we use a derivative to figure out X, and so on.
32
00:01:43,941 --> 00:01:47,574
So, one repeats through these processes
33
00:01:47,574 --> 00:01:51,493
until you have enough of a solution.
34
00:01:51,493 --> 00:01:56,520
So, in practice, one would choose smaller and smaller delta t
35
00:01:56,520 --> 00:01:58,817
until the solution curve stops changing.
36
00:01:58,817 --> 00:02:03,448
So, if you chose a delta t of 2, and then 1, and then .01, and .001,
37
00:02:03,448 --> 00:02:07,010
doing this on a computer, or a spreadsheet,
38
00:02:07,010 --> 00:02:12,776
and eventually one would see that your table of values, if you plotted them,
39
00:02:12,776 --> 00:02:16,564
your X's would stop changing, and that would be an indication
40
00:02:16,564 --> 00:02:21,359
that you're delta t was small enough.
41
00:02:21,405 --> 00:02:24,109
So, this is Euler's method in a nutshell.
42
00:02:24,109 --> 00:02:26,608
It gets at the heart of what the differential equation means,
43
00:02:26,608 --> 00:02:32,143
- the rate of change is given by the quantity X,
44
00:02:32,143 --> 00:02:34,580
we use that rate of change to figure out X,
45
00:02:34,580 --> 00:02:38,031
so, again we're thinking of this as a dynamical system,
46
00:02:38,031 --> 00:02:40,906
- it's a rule that specifies how X changes,
47
00:02:40,906 --> 00:02:43,605
the rule is written in terms of the derivative,
48
00:02:43,605 --> 00:02:45,981
- the rate of change of X, rather than X directly,
49
00:02:45,981 --> 00:02:48,739
but, not a problem, Euler's method, or things like it,
50
00:02:48,739 --> 00:02:55,140
let us convert from rates of change in to the function itself.