So now, instead of calculating the small angle approximation, we want to calculate the actual differential
equation of the harmonic oscillator.
So what I'll do is I will just copy these two cells.
And we only have two very slightly modify them, so the only thing we have to do is changing here the
differential equation to and three dot sign.
Of theater.
And the starting value, 32, zero zero of zero point two is quite small, so let's consider this to
be a small starting angle.
And that's run it, and this time we almost get the same result as previously.
There's maybe a very brief difference.
So you see here, maybe the red the red line is slightly left of the blue dots, which was maybe also
here the case, but not so much.
But yeah, it's hard to say.
Maybe there's a tiny difference, but this is due to the fact that the small starting angle of 0.2
is really a very small starting angle.
So let's check the zero point two is, of course, in radiant.
So this corresponds to PI.
So we have to divide by and p dot pi and have to multiply one hundred eighty degrees.
This would correspond to 11 degrees, which is still pretty small.
So now let's consider a larger starting value.
So I would just copy all of these three cells here, and you see what we going to do next.
Large starting earlier than damping and then a driven oscillator.
And then all of these cases, we don't have to change really much about the coat.
So let me just copy this.
Of course, we could now go ahead, by the way, and the find a new function, which does not only give
us the solution, but which also does the plot here, I think for the moment.
It's really not really necessary, but you could do it.
If you want to have a more tiny notebook and have a more clean notebook, then maybe it's a good idea
to do this.
So here I will consider a starting value of 2.0, which corresponds to a much larger angle of more than
90 degree.
So here we should really see a difference.
And the rest we could really leave as it is.
So I will also delete this one here because it's really not necessary.
We'll just leave the theater zero zero and.
You see, now we get immediately a large difference between the two calculations.
And this is really not a matter of conversation or convergence.
So what we could check now is what happens if we decrease the step size to zero point zero one and then
maybe in turn we increase the simulation time to 2000.
So you see, the result is still pretty much the same.
There is just the difference now.
The reason is that the analytical solution is just not correct anymore because it was the solution for
another differential equation, which was only approximately correct if zero was small.
And now, since it isn't small anymore, the result will be different.