Merge branch 'main' of https://github.com/jverzani/CalculusWithJuliaNotes.jl
This commit is contained in:
commit
5abb03e367
@ -123,7 +123,7 @@ f(c) + diff(f(x),x)(c) * (x - c)
|
||||
(The `log1p` function implements a more accurate version of this function when numeric values are needed.)
|
||||
|
||||
|
||||
* That $1/(1-x) \approx x$ around $x=0$:
|
||||
* That $1/(1-x) \approx 1+x$ around $x=0$:
|
||||
|
||||
|
||||
```{julia}
|
||||
@ -255,7 +255,7 @@ We have $S = 4\pi r^2$ so the approximate relative change, $dy/S$ is given, usin
|
||||
|
||||
|
||||
$$
|
||||
\frac{8\pi\cdot r\cdot dr}{4\pi r^2} = 2r\cdot dr.
|
||||
\frac{8\pi\cdot r\cdot dr}{4\pi r^2} = \frac{2dr}{r}.
|
||||
$$
|
||||
|
||||
##### Example
|
||||
@ -327,7 +327,7 @@ This is off by about $3$ percent. Not so bad for some applications, devastating
|
||||
##### Example: Eratosthenes and the circumference of the earth
|
||||
|
||||
|
||||
[Eratosthenes](https://en.wikipedia.org/wiki/Eratosthenes) is said to have been the first person to estimate the radius (or by relation the circumference) of the earth. The basic idea is based on the difference of shadows cast by the sun. Suppose Eratosthenes sized the circumference as $252,000$ *stadia*. Taking $1$`stadia as``160``meters and the actual radius of the earth as``6378.137``kilometers, we can convert to see that Eratosthenes estimated the radius as``6417``.
|
||||
[Eratosthenes](https://en.wikipedia.org/wiki/Eratosthenes) is said to have been the first person to estimate the radius (or by relation the circumference) of the earth. The basic idea is based on the difference of shadows cast by the sun. Suppose Eratosthenes sized the circumference as $252,000$ *stadia*. Taking $1$ stadia as``160``meters and the actual radius of the earth as``6378.137``kilometers, we can convert to see that Eratosthenes estimated the radius as``6417``.
|
||||
|
||||
|
||||
If Eratosthenes were to have estimated the volume of a spherical earth, what would be his approximate percentage change between his estimate and the actual?
|
||||
@ -364,7 +364,7 @@ That is, the second derivative of $\theta$ is proportional to the sine of $\thet
|
||||
This would be much easier if the second derivative were proportional to the angle $\theta$ and not its sine.
|
||||
|
||||
|
||||
[Huygens](http://en.wikipedia.org/wiki/Christiaan_Huygens) used the approximation of $\sin(x) \approx x$, noted above, to say that when the angle is not too big, we have the pendulum's swing obeying $\theta''(t) = -g/l \cdot t$. Without getting too involved in why, we can verify by taking two derivatives that $\theta_0\sin(\sqrt{g/l}\cdot t)$ will be a solution to this modified equation.
|
||||
[Huygens](http://en.wikipedia.org/wiki/Christiaan_Huygens) used the approximation of $\sin(x) \approx x$, noted above, to say that when the angle is not too big, we have the pendulum's swing obeying $\theta''(t) = -g/l \cdot \theta(t)$. Without getting too involved in why, we can verify by taking two derivatives that $\theta_0\sin(\sqrt{g/l}\cdot t)$ will be a solution to this modified equation.
|
||||
|
||||
|
||||
With this solution, the motion is periodic with constant amplitude (assuming frictionless behaviour), as the sine function is. More surprisingly, the period is found from $T = 2\pi/(\sqrt{g/l}) = 2\pi \sqrt{l/g}$. It depends on $l$ - longer "rods" take more time to swing back and forth - but does not depend on the how wide the pendulum is swinging between (provided $\theta_0$ is not so big the approximation of $\sin(x) \approx x$ fails). This latter fact may be surprising, though not to Galileo who discovered it.
|
||||
@ -531,8 +531,8 @@ Is it a coincidence that a basic algebraic operation with tangent lines approxim
|
||||
|
||||
\begin{align*}
|
||||
f(x) \cdot g(x) &= [f(c) + f'(c)(x-c) + \mathcal{O}((x-c)^2)] \cdot [g(c) + g'(c)(x-c) + \mathcal{O}((x-c)^2)]\\
|
||||
&=[(f(c) + f'(c)(x-c)] \cdot [g(c) + g'(c)(x-c)] + (f(c) + f'(c)(x-c) \cdot \mathcal{O}((x-c)^2)) + g(c) + g'(c)(x-c) \cdot \mathcal{O}((x-c)^2)) + [\mathcal{O}((x-c)^2))]^2\\
|
||||
&= [(f(c) + f'(c)(x-c)] \cdot [g(c) + g'(c)(x-c)] + \mathcal{O}((x-c)^2)\\
|
||||
&=[f(c) + f'(c)(x-c)] \cdot [g(c) + g'(c)(x-c)] + (f(c) + f'(c)(x-c)) \cdot \mathcal{O}((x-c)^2) + (g(c) + g'(c)(x-c)) \cdot \mathcal{O}((x-c)^2) + [\mathcal{O}((x-c)^2)]^2\\
|
||||
&= [f(c) + f'(c)(x-c)] \cdot [g(c) + g'(c)(x-c)] + \mathcal{O}((x-c)^2)\\
|
||||
&= f(c) \cdot g(c) + [f'(c)\cdot g(c) + f(c)\cdot g'(c)] \cdot (x-c) + [f'(c)\cdot g'(c) \cdot (x-c)^2 + \mathcal{O}((x-c)^2)] \\
|
||||
&= f(c) \cdot g(c) + [f'(c)\cdot g(c) + f(c)\cdot g'(c)] \cdot (x-c) + \mathcal{O}((x-c)^2)
|
||||
\end{align*}
|
||||
@ -633,7 +633,7 @@ x = Dual(1, 1)
|
||||
@code_lowered log(x)
|
||||
```
|
||||
|
||||
We can see the derivative again reflects the chain rule, it being given by `1/x * xp` where `xp` acts like `dx` (from assignments `%5` and `%4`). Comparing the two outputs, we see only the assignment to `%4` differs, it reflecting the derivative of the function.
|
||||
We can see the derivative again reflects the chain rule, it being given by `1/x * xp` where `xp` acts like `dx` (from assignments `%5` and `%4`). Comparing the two outputs, we see only the assignment to `%5` differs, it reflecting the derivative of the function.
|
||||
|
||||
|
||||
## Questions
|
||||
@ -838,7 +838,7 @@ val = exp(-n*(n-1)/2/365)
|
||||
numericq(val)
|
||||
```
|
||||
|
||||
If $n=100$, what is the approximation for $p$ (not $\log(p)$?
|
||||
If $n=100$, what is the approximation for $p$ (not $\log(p)$)?
|
||||
|
||||
|
||||
```{julia}
|
||||
|
Loading…
Reference in New Issue
Block a user