WEBVTT
00:00:00.000 --> 00:00:04.000
It turns out that all positive values for the time step are okay no matter how high.
00:00:04.000 --> 00:00:07.000
This is how similar to the backward Euler method
00:00:07.000 --> 00:00:10.000
and now we're going to look into why that is the case.
00:00:10.000 --> 00:00:14.000
The trapezoidal weir turns this differential equation into the following.
00:00:14.000 --> 00:00:20.000
The next value of x equals the current value of x plus the time step
00:00:20.000 --> 00:00:27.000
times the average of two rates of change, the current rate of change (-kx₁)
00:00:27.000 --> 00:00:30.000
and the next rate of change (-kx₂).
00:00:30.000 --> 00:00:36.000
I bring the x₂ to the left-hand side and combined this x₁ with that x₁
00:00:36.000 --> 00:00:48.000
and get (1+hk/2) * x2 = (1-hk/2) * x1.
00:00:48.000 --> 00:00:57.000
Let's check that, 1x₂, it's here. (hk/2)x₂ appears on the right-hand side with a - sign.
00:00:57.000 --> 00:01:05.000
1x₁ appears here minus (hk/2)x₁ - (hk/2)x₁ appears here.
00:01:05.000 --> 00:01:16.000
Correct. And that's easy to solve for x₂. x₂ = (1-hk/2)/(1+hk/2)*x₁.
00:01:16.000 --> 00:01:21.000
If you look at what happens with the next step. We of course, get a second factor of that sort.
00:01:21.000 --> 00:01:26.000
The next next step, another factor of that sort. So what happens is that we get powers of this factor.
00:01:26.000 --> 00:01:30.000
The question is what's going to happen about powers of that factor.
00:01:30.000 --> 00:01:36.000
So we see that to get it from x₁ to x₂, we have to multiple by this factor
00:01:36.000 --> 00:01:40.000
and this is going to occur every step if we want to go from x₂ to x₃,
00:01:40.000 --> 00:01:43.000
we again multiply by that factor and so on.
00:01:43.000 --> 00:01:46.000
So in the end, we get the powers of this factor.
00:01:46.000 --> 00:01:51.000
So the question is as the nth power of this expression converts to 0,
00:01:51.000 --> 00:01:56.000
as it intends to infinity to check that, one can analyze three different cases.
00:01:56.000 --> 00:01:59.000
Let's first check what happens if the step size is moderate.
00:01:59.000 --> 00:02:09.000
For instance, if this expression hk/2 equals 0.1 and we get (1-0.1)/(1+0.1)
00:02:09.000 --> 00:02:14.000
meaning (0.9)/(1.1), this is a positive number, <1.
00:02:14.000 --> 00:02:19.000
If you take higher and higher powers of that, this number is going to become 0.
00:02:19.000 --> 00:02:24.000
The numerator becomes 0.9. The denominator becomes 1.1.
00:02:24.000 --> 00:02:31.000
The fraction is a number between 0 and 1 and if we take higher and higher powers of such a number,
00:02:31.000 --> 00:02:34.000
the results converge to 0, so this is stable.
00:02:34.000 --> 00:02:36.000
So in this case, we have stability.
00:02:36.000 --> 00:02:43.000
If hk/2 happens to be equal to 1, we get a fraction with a 0 in the numerator,
00:02:43.000 --> 00:02:48.000
that's always 0, no problem with that, so we have stability in that case.
00:02:48.000 --> 00:02:55.000
And if you use a really high value of h, for instance, such that hk/2=9,
00:02:55.000 --> 00:03:02.000
we get something like 1-9=-8 divided by 1+9=10.
00:03:02.000 --> 00:03:05.000
This is a negative number with absolute value less than 1.
00:03:05.000 --> 00:03:11.000
So, if we take higher and higher powers, the result converges to 0,
00:03:11.000 --> 00:03:16.000
we also have stability in this case but you see that this convergence comes along with an oscillation
00:03:16.000 --> 00:03:23.000
that's time changes from minus to plus to minus to plus as we form even powers and odd powers.
00:03:23.000 --> 00:03:28.000
The result has a positive sign. For odd powers, the result has a negative sign.
00:03:28.000 --> 99:59:59.999
So we see some kind of decaying oscillation here.