diff --git a/book/content/bvps/eigenvalue.ipynb b/book/content/bvps/eigenvalue.ipynb index 61bd397..a8b9958 100644 --- a/book/content/bvps/eigenvalue.ipynb +++ b/book/content/bvps/eigenvalue.ipynb @@ -302,12 +302,13 @@ "## Example: mass-spring system\n", "\n", "Let's analyze the motion of masses connected by springs in a system:\n", - "
\n", - "
\n", - " \"mass-spring\n", - "
Figure: System with two masses connected by springs
\n", - "
\n", - "
\n", + "\n", + ":::{figure-md} fig-mass-spring\n", + "\"mass-spring\n", + "\n", + "System with two masses connected by springs\n", + ":::\n", + "\n", "First, we need to write the equations of motion, based on doing a free-body diagram on each mass:\n", "\\begin{align}\n", "m_1 \\frac{d^2 x_1}{dt^2} &= -k x_1 + k(x_2 - x_1) \\\\\n", diff --git a/book/content/bvps/finite-difference.ipynb b/book/content/bvps/finite-difference.ipynb index e8fc766..4c8a105 100644 --- a/book/content/bvps/finite-difference.ipynb +++ b/book/content/bvps/finite-difference.ipynb @@ -539,12 +539,11 @@ "\n", "Let's now consider a more complicated example: heat transfer through an extended surface (a fin).\n", "\n", - "
\n", - "
\n", - " \"Heat\n", - "
Figure: Geometry of a heat transfer fin
\n", - "
\n", - "
\n", + ":::{figure-md} fig-fin\n", + "\"Heat\n", + "\n", + "Geometry of a heat transfer fin\n", + ":::\n", "\n", "In this situation, we have the temperature of the body $T_b$, the temperature of the ambient fluid $T_{\\infty}$; the length $L$, width $w$, and thickness $t$ of the fin; the thermal conductivity of the fin material $k$; and convection heat transfer coefficient $h$.\n", "\n", @@ -556,12 +555,11 @@ "\n", "Our goal is to solve for the temperature distribution $T(x)$. To do this, we need to set up a governing differential equation. Let's do a control volume analysis of heat transfer through the fin:\n", "\n", - "
\n", - "
\n", - " \"Control\n", - "
Figure: Control volume for heat transfer through the fin
\n", - "
\n", - "
\n", + ":::{figure-md} fig-control-volume\n", + "\"Control\n", + "\n", + "Control volume for heat transfer through the fin\n", + ":::\n", "\n", "Given a particular volumetric slice of the fin, we can define the heat transfer rates of conduction through the fin and convection from the fin to the air:\n", "\\begin{align}\n", @@ -652,7 +650,7 @@ ], "mimetype": "text/x-octave", "name": "matlab", - "version": "0.16.7" + "version": "0.16.11" } }, "nbformat": 4, diff --git a/book/content/bvps/shooting-method.ipynb b/book/content/bvps/shooting-method.ipynb index 1ba9df2..8fc85e9 100644 --- a/book/content/bvps/shooting-method.ipynb +++ b/book/content/bvps/shooting-method.ipynb @@ -146,12 +146,11 @@ "\n", "We can use the shooting method to solve a famous fluids problem: the [Blasius boundary layer](https://en.wikipedia.org/wiki/Blasius_boundary_layer).\n", "\n", - "
\n", - "
\n", - " \"Laminar\n", - "
Figure: Laminar boundary layer, taken from https://commons.wikimedia.org/wiki/File:Laminar_boundary_layer_scheme.svg
\n", - "
\n", - "
\n", + ":::{figure-md} fig-boundary-layer\n", + "\"Laminar\n", + "\n", + "Laminar boundary layer, taken from \n", + ":::\n", "\n", "To get to a solveable ODE, we start with the conservation of momentum equation (i.e., Navier–Stokes equation) in the $x$-direction:\n", "\\begin{equation}\n", @@ -452,7 +451,7 @@ ], "mimetype": "text/x-octave", "name": "matlab", - "version": "0.16.7" + "version": "0.16.11" } }, "nbformat": 4, diff --git a/book/content/numerical-methods/stability.ipynb b/book/content/numerical-methods/stability.ipynb index bcc5ffc..8b8d8c2 100644 --- a/book/content/numerical-methods/stability.ipynb +++ b/book/content/numerical-methods/stability.ipynb @@ -396,9 +396,9 @@ ], "mimetype": "text/x-octave", "name": "matlab", - "version": "0.16.7" + "version": "0.16.11" } }, "nbformat": 4, - "nbformat_minor": 2 + "nbformat_minor": 4 } diff --git a/book/content/quizzes/quiz3-BVPs.md b/book/content/quizzes/quiz3-BVPs.md index f1504a9..aeb7646 100644 --- a/book/content/quizzes/quiz3-BVPs.md +++ b/book/content/quizzes/quiz3-BVPs.md @@ -9,12 +9,11 @@ r \frac{d^2 T}{dr^2} + \frac{dT}{dr} - rm^2 (T - T_{\infty}) = 0 \;, where $r$ is the radial distance from the centerline (the independent variable) and $m^2$ is a constant that depends on the heat transfer coefficient, thermal conductivity, and thickness of the annulus. Assuming we choose a spatial step size $\Delta r$, -
-
- Annular fin -
Figure: Annular fin
-
-
+:::{figure-md} markdown-fig +Annular fin + +Annular fin +::: a.) Write the finite-difference representation of the ODE (that applies at a location $r_i$), using central differences. @@ -138,7 +137,3 @@ z_2 (1.0) &= z_2 (0.5) + \left( 4z_1(0.5) \right) 0.5 = 6.0 so for solution 3: $y(1) = 3$ which is the target. So our answer is $y'(0) = 3$. - -```python - -``` diff --git a/docs/_images/annular-fin.png b/docs/_images/annular-fin.png new file mode 100644 index 0000000..3322282 Binary files /dev/null and b/docs/_images/annular-fin.png differ diff --git a/docs/_images/boundary-layer.png b/docs/_images/boundary-layer.png new file mode 100644 index 0000000..a407837 Binary files /dev/null and b/docs/_images/boundary-layer.png differ diff --git a/docs/_images/fin-control-volume.png b/docs/_images/fin-control-volume.png new file mode 100644 index 0000000..d2ce014 Binary files /dev/null and b/docs/_images/fin-control-volume.png differ diff --git a/docs/_images/fin.png b/docs/_images/fin.png new file mode 100644 index 0000000..8f5942e Binary files /dev/null and b/docs/_images/fin.png differ diff --git a/docs/_images/mass-spring-system.jpg b/docs/_images/mass-spring-system.jpg new file mode 100644 index 0000000..eb20d1d Binary files /dev/null and b/docs/_images/mass-spring-system.jpg differ diff --git a/docs/_sources/content/bvps/eigenvalue.ipynb b/docs/_sources/content/bvps/eigenvalue.ipynb index 61bd397..a8b9958 100644 --- a/docs/_sources/content/bvps/eigenvalue.ipynb +++ b/docs/_sources/content/bvps/eigenvalue.ipynb @@ -302,12 +302,13 @@ "## Example: mass-spring system\n", "\n", "Let's analyze the motion of masses connected by springs in a system:\n", - "
\n", - "
\n", - " \"mass-spring\n", - "
Figure: System with two masses connected by springs
\n", - "
\n", - "
\n", + "\n", + ":::{figure-md} fig-mass-spring\n", + "\"mass-spring\n", + "\n", + "System with two masses connected by springs\n", + ":::\n", + "\n", "First, we need to write the equations of motion, based on doing a free-body diagram on each mass:\n", "\\begin{align}\n", "m_1 \\frac{d^2 x_1}{dt^2} &= -k x_1 + k(x_2 - x_1) \\\\\n", diff --git a/docs/_sources/content/bvps/finite-difference.ipynb b/docs/_sources/content/bvps/finite-difference.ipynb index e8fc766..4c8a105 100644 --- a/docs/_sources/content/bvps/finite-difference.ipynb +++ b/docs/_sources/content/bvps/finite-difference.ipynb @@ -539,12 +539,11 @@ "\n", "Let's now consider a more complicated example: heat transfer through an extended surface (a fin).\n", "\n", - "
\n", - "
\n", - " \"Heat\n", - "
Figure: Geometry of a heat transfer fin
\n", - "
\n", - "
\n", + ":::{figure-md} fig-fin\n", + "\"Heat\n", + "\n", + "Geometry of a heat transfer fin\n", + ":::\n", "\n", "In this situation, we have the temperature of the body $T_b$, the temperature of the ambient fluid $T_{\\infty}$; the length $L$, width $w$, and thickness $t$ of the fin; the thermal conductivity of the fin material $k$; and convection heat transfer coefficient $h$.\n", "\n", @@ -556,12 +555,11 @@ "\n", "Our goal is to solve for the temperature distribution $T(x)$. To do this, we need to set up a governing differential equation. Let's do a control volume analysis of heat transfer through the fin:\n", "\n", - "
\n", - "
\n", - " \"Control\n", - "
Figure: Control volume for heat transfer through the fin
\n", - "
\n", - "
\n", + ":::{figure-md} fig-control-volume\n", + "\"Control\n", + "\n", + "Control volume for heat transfer through the fin\n", + ":::\n", "\n", "Given a particular volumetric slice of the fin, we can define the heat transfer rates of conduction through the fin and convection from the fin to the air:\n", "\\begin{align}\n", @@ -652,7 +650,7 @@ ], "mimetype": "text/x-octave", "name": "matlab", - "version": "0.16.7" + "version": "0.16.11" } }, "nbformat": 4, diff --git a/docs/_sources/content/bvps/shooting-method.ipynb b/docs/_sources/content/bvps/shooting-method.ipynb index 1ba9df2..8fc85e9 100644 --- a/docs/_sources/content/bvps/shooting-method.ipynb +++ b/docs/_sources/content/bvps/shooting-method.ipynb @@ -146,12 +146,11 @@ "\n", "We can use the shooting method to solve a famous fluids problem: the [Blasius boundary layer](https://en.wikipedia.org/wiki/Blasius_boundary_layer).\n", "\n", - "
\n", - "
\n", - " \"Laminar\n", - "
Figure: Laminar boundary layer, taken from https://commons.wikimedia.org/wiki/File:Laminar_boundary_layer_scheme.svg
\n", - "
\n", - "
\n", + ":::{figure-md} fig-boundary-layer\n", + "\"Laminar\n", + "\n", + "Laminar boundary layer, taken from \n", + ":::\n", "\n", "To get to a solveable ODE, we start with the conservation of momentum equation (i.e., Navier–Stokes equation) in the $x$-direction:\n", "\\begin{equation}\n", @@ -452,7 +451,7 @@ ], "mimetype": "text/x-octave", "name": "matlab", - "version": "0.16.7" + "version": "0.16.11" } }, "nbformat": 4, diff --git a/docs/_sources/content/numerical-methods/stability.ipynb b/docs/_sources/content/numerical-methods/stability.ipynb index bcc5ffc..8b8d8c2 100644 --- a/docs/_sources/content/numerical-methods/stability.ipynb +++ b/docs/_sources/content/numerical-methods/stability.ipynb @@ -396,9 +396,9 @@ ], "mimetype": "text/x-octave", "name": "matlab", - "version": "0.16.7" + "version": "0.16.11" } }, "nbformat": 4, - "nbformat_minor": 2 + "nbformat_minor": 4 } diff --git a/docs/_sources/content/quizzes/quiz3-BVPs.md b/docs/_sources/content/quizzes/quiz3-BVPs.md index f1504a9..aeb7646 100644 --- a/docs/_sources/content/quizzes/quiz3-BVPs.md +++ b/docs/_sources/content/quizzes/quiz3-BVPs.md @@ -9,12 +9,11 @@ r \frac{d^2 T}{dr^2} + \frac{dT}{dr} - rm^2 (T - T_{\infty}) = 0 \;, where $r$ is the radial distance from the centerline (the independent variable) and $m^2$ is a constant that depends on the heat transfer coefficient, thermal conductivity, and thickness of the annulus. Assuming we choose a spatial step size $\Delta r$, -
-
- Annular fin -
Figure: Annular fin
-
-
+:::{figure-md} markdown-fig +Annular fin + +Annular fin +::: a.) Write the finite-difference representation of the ODE (that applies at a location $r_i$), using central differences. @@ -138,7 +137,3 @@ z_2 (1.0) &= z_2 (0.5) + \left( 4z_1(0.5) \right) 0.5 = 6.0 so for solution 3: $y(1) = 3$ which is the target. So our answer is $y'(0) = 3$. - -```python - -``` diff --git a/docs/content/bvps/eigenvalue.html b/docs/content/bvps/eigenvalue.html index 9742bba..0f05040 100644 --- a/docs/content/bvps/eigenvalue.html +++ b/docs/content/bvps/eigenvalue.html @@ -404,45 +404,45 @@

4.3. Eigenvalue problems

4.3.1. Example: beam buckling

Let’s consider deflection in a simply supported (static) vertical beam: \(y(x)\), with boundary conditions \(y(0) = 0\) and \(y(L) = 0\). To get the governing equation, start with considering the sum of moments around the upper pin:

-
-(4.46)\[\begin{align} +
+(4.46)\[\begin{align} \sum M &= M_z + P y = 0 \\ M_z &= -P y \end{align}\]

We also know that \(M_z = E I y''\), so we can obtain

-
-(4.47)\[\begin{align} +
+(4.47)\[\begin{align} M_z = E I \frac{d^2 y}{dx^2} &= -P y \\ y'' + \frac{P}{EI} y &= 0 \end{align}\]

This equation governs the stability of a beam, considering small deflections. To simplify things, let’s define \(\lambda^2 = \frac{P}{EI}\), which gives us the ODE

-
-(4.48)\[\begin{equation} +
+(4.48)\[\begin{equation} y'' + \lambda^2 y = 0 \end{equation}\]

We can get the general solution to this:

-
-(4.49)\[\begin{equation} +
+(4.49)\[\begin{equation} y(x) = A \cos (\lambda x) + B \sin (\lambda x) \end{equation}\]

To find the coefficients, let’s apply the boundary conditions, starting with \(x=0\):

-
-(4.50)\[\begin{align} +
+(4.50)\[\begin{align} y(x=0) &= 0 = A \cos 0 + B \sin 0 \\ \rightarrow A &= 0 \\ y(x=L) &= 0 = B \sin (\lambda L) \end{align}\]

Now what? \(B \neq 0\), because otherwise we would have the trivial solution \(y(x) = 0\). Instead, to satisfy the boundary condition, we need

-
-(4.51)\[\begin{align} +
+(4.51)\[\begin{align} B \neq 0 \rightarrow \sin (\lambda L) &= 0 \\ \text{so} \quad \lambda L &= n \pi \quad n = 1, 2, 3, \ldots, \infty \\ \lambda &= \frac{n \pi}{L} \quad n = 1, 2, 3, \ldots, \infty \end{align}\]

\(\lambda\) give the the eigenvalues for this problem; as you can see, there are an infinite number, that correspond to eigenfunctions:

-
-(4.52)\[\begin{equation} +
+(4.52)\[\begin{equation} y_n = B \sin \left( \frac{n \pi x}{L} \right) \quad n = 1, 2, 3, \ldots, \infty \end{equation}\]

The eigenvalues and associated eigenfunctions physically represent different modes of deflection. @@ -471,15 +471,15 @@

4.3.1. Example: beam buckling -(4.53)\[\begin{gather} +
+(4.53)\[\begin{gather} \lambda^2 = \frac{P}{EI} \rightarrow \lambda = \sqrt{\frac{P}{EI}} = \frac{n \pi}{L} \\ P = \frac{EI}{L} n^2 \pi^2 \end{gather}\]

This means that when the combination of load force and beam properties match certain values, the beam will deflect—and buckle—in one of the modes corresponding to the associated eigenfunction.

In particular, the first mode (\(n=1\)) is interesting, because this is the first one that will be encountered if a load starts at zero and increases. This is the Euler critical load of buckling, \(P_{cr}\):

-
-(4.54)\[\begin{gather} +
+(4.54)\[\begin{gather} \lambda_1 = \frac{\pi}{L} \rightarrow \lambda_1^2 = \frac{P}{EI} = \frac{\pi^2}{L^2} \\ P_{cr} = \frac{\pi^2 E I}{L^2} \end{gather}\]
@@ -488,14 +488,14 @@

4.3.1. Example: beam buckling4.3.2. Example: beam buckling with different boundary conditions

Let’s consider a slightly different case, where at \(x=0\) the beam is supported such that \(y'(0) = 0\). How does the beam buckle in this case?

The governing equation and general solution are the same:

-
-(4.55)\[\begin{align} +
+(4.55)\[\begin{align} y'' + \lambda^2 y &= 0 \\ y(x) &= A \cos (\lambda x) + B \sin (\lambda x) \end{align}\]

but our boundary conditions are now different:

-
-(4.56)\[\begin{align} +
+(4.56)\[\begin{align} y'(0) = 0 = -\lambda A \sin(0) + \lambda B\cos(0) \\ \rightarrow B &= 0 \\ y &= A \cos (\lambda x) \\ @@ -505,8 +505,8 @@

4.3.2. Example: beam buckling with diffe \lambda &= \frac{(2n-1) \pi}{2 L} \quad n = 1,2,3,\ldots, \infty \end{align}\]

Then, the critical buckling load, again corresponding to \(n=1\), is

-
-(4.57)\[\begin{equation} +
+(4.57)\[\begin{equation} P_{cr} = \frac{\pi^2 EI}{4 L^2} \end{equation}\]
@@ -514,74 +514,74 @@

4.3.2. Example: beam buckling with diffe

4.3.3. Getting eigenvalues numerically

We can only get the eigenvalues analytically if we can obtain an analytical solution of the ODE, but we might want to get eigenvalues for more complex problems too. In that case, we can use an approach based on finite differences to find the eigenvalues.

Consider the same problem as above, for deflection of a simply supported beam:

-
-(4.58)\[\begin{equation} +
+(4.58)\[\begin{equation} y'' + \lambda^2 y = 0 \end{equation}\]

with boundary conditions \(y(0) = 0\) and \(y(L) = 0\). Let’s represent this using finite differences, for a case where \(L=3\) and \(\Delta x = 1\), so we have four points in our solution grid.

The finite difference representation of the ODE is:

-
-(4.59)\[\begin{align} +
+(4.59)\[\begin{align} \frac{y_{i-1} - 2y_i + y_{i+1}}{\Delta x^2} + \lambda^2 y_i &= 0 \\ y_{i-1} + \left( \lambda^2 \Delta x^2 - 2 \right) y_i + y_{i+1} &= 0 \end{align}\]

However, in this case, we are not solving for the values of deflection (\(y_i\)), but instead the eigenvalues \(\lambda\).

Then, we can write the system of equations using the above recursion formula and our two boundary conditions:

-
-(4.60)\[\begin{align} +
+(4.60)\[\begin{align} y_1 &= 0 \\ y_1 + y_2 \left( \lambda^2 \Delta x^2 - 2 \right) + y_3 &= 0 \\ y_2 + y_3 \left( \lambda^2 \Delta x^2 - 2 \right) + y_4 &= 0 \\ y_4 &= 0 \end{align}\]

which we can simplify down to two equations by incorporating the boundary conditions into the equations for the two middle points, and also letting \(k = \lambda^2 \Delta x^2\):

-
-(4.61)\[\begin{align} +
+(4.61)\[\begin{align} y_2 (k-2) + y_3 &= 0 \\ y_2 + y_3 (k-2) &= 0 \end{align}\]

Let’s modify this once more by multiplying both equations by \(-1\):

-
-(4.62)\[\begin{align} +
+(4.62)\[\begin{align} y_2 (2-k) - y_3 &= 0 \\ -y_2 + y_3 (2-k) &= 0 \end{align}\]

Now we can represent this system of equations as a matrix equation \(A \mathbf{y} = \mathbf{b} = \mathbf{0}\):

-
-(4.63)\[\begin{equation} +
+(4.63)\[\begin{equation} \begin{bmatrix} 2-k & -1 \\ -1 & 2-k \end{bmatrix} \begin{bmatrix} y_2 \\ y_3 \end{bmatrix} = \begin{bmatrix} 0 \\ 0 \end{bmatrix} \end{equation}\]

\(\mathbf{y} = \mathbf{0}\) is a trivial solution to this, so instead \(\det(A) = 0\) satisfies this equation. For our \(2\times 2\) matrix, that looks like:

-
-(4.64)\[\begin{align} +
+(4.64)\[\begin{align} \det(A) = \begin{vmatrix} 2-k & -1 \\ -1 & 2-k \end{vmatrix} = (2-k)^2 - 1 &= 0 \\ k^2 - 4k + 3 &= 0 \\ (k-3)(k-1) &= 0 \end{align}\]

so the roots of this equation are \(k_1 = 1\) and \(k_2 = 3\). Recall that \(k\) is directly related to the eigenvalue: \(k = \lambda^2 \Delta x^2\), and \(\Delta x = 1\) for this case, so we can calculate the two associated eigenvalues:

-
-(4.65)\[\begin{align} +
+(4.65)\[\begin{align} k_1 &= \lambda_1^2 \Delta x^2 = 1 \rightarrow \lambda_1 = 1 \\ k_2 &= \lambda_2^2 \Delta x^2 = 3 \rightarrow \lambda_2 = \sqrt{3} = 1.732 \end{align}\]

Our work has given us approximations for the first two eigenvalues. We can compare these against the exact values, given in general by \(\lambda = n \pi / L\) (which we determined above):

-
-(4.66)\[\begin{align} +
+(4.66)\[\begin{align} n=1: \quad \lambda_1 &= \frac{\pi}{L} = \frac{\pi}{3} = 1.0472 \\ n=2: \quad \lambda_2 &= \frac{2\pi}{L} = \frac{2\pi}{3} = 2.0944 \end{align}\]

So, our approximations are close, but with some obvious error. This is because we used a fairly crude step size of \(\Delta x = 1\), dividing the domain into just three segments. By using a finer resolution, we can get more-accurate eigenvalues and also more of them (remember, there are actually an infinite number!).

To do that, we will need to use Matlab, which offers the eig() function for calculating eigenvalues—essentially it is finding the roots to the polynomial given by \(\det(A) = 0\). We need to modify this slightly, though, to use the function:

-
-(4.67)\[\begin{align} +
+(4.67)\[\begin{align} \det(A) &= 0 \\ \det \left( A^* - k I \right) = 0 \end{align}\]

where the new matrix is

-
-(4.68)\[\begin{equation} +
+(4.68)\[\begin{equation} A^* = \begin{bmatrix} 2 & -1 \\ -1 & 2 \end{bmatrix} \end{equation}\]

Then, eig(A*) will provide the values of \(k\), which we can use to find the \(\lambda\)s:

@@ -658,58 +658,58 @@

4.3.3. Getting eigenvalues numerically

4.3.4. Example: mass-spring system

Let’s analyze the motion of masses connected by springs in a system:

-
-
- mass-spring system -
Figure: System with two masses connected by springs
-
-
-First, we need to write the equations of motion, based on doing a free-body diagram on each mass: -\begin{align} -m_1 \frac{d^2 x_1}{dt^2} &= -k x_1 + k(x_2 - x_1) \\ -m_2 \frac{d^2 x_2}{dt^2} &= -k (x_2 - x_1) - k x_2 -\end{align} -We can condense these equations a bit: -\begin{align} -x_1^{\prime\prime} - \frac{k}{m_1} \left( -2 x_1 + x_2 \right) &= 0 \\ -x_2^{\prime\prime} - \frac{k}{m_2} \left( x_1 - 2 x_2 \right) &= 0 -\end{align} +
+mass-spring system +

Fig. 4.4 System with two masses connected by springs

+
+

First, we need to write the equations of motion, based on doing a free-body diagram on each mass:

+
+(4.69)\[\begin{align} +m_1 \frac{d^2 x_1}{dt^2} &= -k x_1 + k(x_2 - x_1) \\ +m_2 \frac{d^2 x_2}{dt^2} &= -k (x_2 - x_1) - k x_2 +\end{align}\]
+

We can condense these equations a bit:

+
+(4.70)\[\begin{align} +x_1^{\prime\prime} - \frac{k}{m_1} \left( -2 x_1 + x_2 \right) &= 0 \\ +x_2^{\prime\prime} - \frac{k}{m_2} \left( x_1 - 2 x_2 \right) &= 0 +\end{align}\]

To proceed, we can assume that the masses will move in a sinusoidal fashion, with a shared frequency but separate amplitude:

-
-(4.69)\[\begin{align} +
+(4.71)\[\begin{align} x_i &= A_i \sin (\omega t) \\ x_i^{\prime\prime} &= -A_i \omega^2 \sin (\omega t) \end{align}\]

We can plug these into the ODEs:

-
-(4.70)\[\begin{align} +
+(4.72)\[\begin{align} \sin (\omega t) \left[ \left( \frac{2k}{m_1} - \omega^2 \right) A_1 - \frac{k}{m_1} A_2 \right] &= 0 \\ \sin (\omega t) \left[ -\frac{k}{m_2} A_1 + \left( \frac{2k}{m_2} - \omega^2 \right) A_2 \right] &= 0 \end{align}\]

or

-
-(4.71)\[\begin{align} +
+(4.73)\[\begin{align} \left( \frac{2k}{m_1} - \omega^2 \right) A_1 - \frac{k}{m_1} A_2 &= 0 \\ -\frac{k}{m_2} A_1 + \left( \frac{2k}{m_2} - \omega^2 \right) A_2 &= 0 \end{align}\]

Let’s put some numbers in, and try to solve for the eigenvalues: \(\omega^2\). Let \(m_1 = m_2 = 40 \) kg and \(k = 200\) N/m.

Now, the equations become

-
-(4.72)\[\begin{align} +
+(4.74)\[\begin{align} \left( 10 - \omega^2 \right) A_1 - 5 A_2 &= 0 \\ -5 A_1 + \left( 10 - \omega^2 \right) A_2 &= 0 \end{align}\]

or \(A \mathbf{y} = \mathbf{0}\), which we can represent as

-
-(4.73)\[\begin{equation} +
+(4.75)\[\begin{equation} \begin{bmatrix} 10-\omega^2 & -5 \\ -5 & 10-\omega^2 \end{bmatrix} \begin{bmatrix} A_1 \\ A_2 \end{bmatrix} = \begin{bmatrix} 0 \\ 0 \end{bmatrix} \end{equation}\]

Here, \(\omega^2\) are the eigenvalues, and we can find them with \(\det(A) = 0\):

-
-(4.74)\[\begin{align} +
+(4.76)\[\begin{align} \det(B) &= 0 \\ \det (B^* - \omega^2 I) &= 0 \end{align}\]
@@ -734,8 +734,8 @@

4.3.4. Example: mass-spring system

We find there are two modes of oscillation, each associated with a different natural frequency. Unfortunately, we cannot calculate independent and unique values for the amplitudes, but if we insert the values of \(\omega\) into the above equations, we can find relations connecting the amplitudes:

-
-(4.75)\[\begin{align} +
+(4.77)\[\begin{align} \omega_1: \quad A_1 &= A_2 \\ \omega_2: \quad A_1 &= -A_2 \end{align}\]
diff --git a/docs/content/bvps/finite-difference.html b/docs/content/bvps/finite-difference.html index ff3300f..1f2c42f 100644 --- a/docs/content/bvps/finite-difference.html +++ b/docs/content/bvps/finite-difference.html @@ -435,24 +435,24 @@

4.2. Finite difference method4.2.1. Finite differences

Another method of solving boundary-value problems (and also partial differential equations, as we’ll see later) involves finite differences, which are numerical approximations to exact derivatives.

Recall that the exact derivative of a function \(f(x)\) at some point \(x\) is defined as:

-
-(4.13)\[\begin{equation} +
+(4.13)\[\begin{equation} f^{\prime}(x) = \frac{df}{dx}(x) = \lim_{\Delta x \rightarrow 0} \frac{f(x+\Delta x) - f(x)}{\Delta x} \end{equation}\]

So, we can approximate this derivative using a finite difference (rather than an infinitesimal difference as in the exact derivative):

-
-(4.14)\[\begin{equation} +
+(4.14)\[\begin{equation} f^{\prime}(x) \approx \frac{f(x+\Delta x) - f(x)}{\Delta x} \end{equation}\]

which involves some error. This is a forward difference for approximating the first derivative. We can also approximate the first derivative using a backward difference:

-
-(4.15)\[\begin{equation} +
+(4.15)\[\begin{equation} f^{\prime}(x) \approx \frac{f(x) - f(x - \Delta x)}{\Delta x} \end{equation}\]

To understand the error involved in these differences, we can use Taylor’s theorem to obtain Taylor series expansions:

-
-(4.16)\[\begin{align} +
+(4.16)\[\begin{align} f(x + \Delta x) &= f(x) + \Delta x \, f^{\prime}(x) + \Delta x^2 \frac{1}{2!} f^{\prime\prime}(x) + \cdots \\ \rightarrow \frac{f(x + \Delta x) - f(x)}{\Delta x} &= f^{\prime}(x) + \mathcal{O}\left( \Delta x \right) \\ f(x - \Delta x) &= f(x) - \Delta x \, f^{\prime}(x) + \Delta x^2 \frac{1}{2!} f^{\prime\prime}(x) + \cdots \\ @@ -463,21 +463,21 @@

4.2.1. Finite differences

4.2.2. Second-order finite differences

We can obtain higher-order approximations for the first derivative, and an approximations for the second derivative, by combining these Taylor series expansions:

-
-(4.17)\[\begin{align} +
+(4.17)\[\begin{align} f(x + \Delta x) &= f(x) + \Delta x \, f^{\prime}(x) + \Delta x^2 \frac{1}{2!} f^{\prime\prime}(x) + \mathcal{O}\left( \Delta x^3 \right) \\ f(x - \Delta x) &= f(x) - \Delta x \, f^{\prime}(x) + \Delta x^2 \frac{1}{2!} f^{\prime\prime}(x) + \mathcal{O}\left( \Delta x^3 \right) \end{align}\]

Subtracting the Taylor series for \(f(x+\Delta x)\) by that for \(f(x-\Delta x)\) gives:

-
-(4.18)\[\begin{align} +
+(4.18)\[\begin{align} f(x + \Delta x) - f(x - \Delta x) &= 2 \Delta x \, f^{\prime}(x) + \mathcal{O}\left( \Delta x^3 \right) \\ f^{\prime}(x) &= \frac{f(x + \Delta x) - f(x - \Delta x)}{2 \Delta x} + \mathcal{O}\left( \Delta x^2 \right) \end{align}\]

which is a second-order accurate approximation for the first derivative.

Adding the Taylor series for \(f(x+\Delta x)\) to that for \(f(x-\Delta x)\) gives:

-
-(4.19)\[\begin{align} +
+(4.19)\[\begin{align} f(x + \Delta x) + f(x - \Delta x) &= 2 f(x) + \Delta x^2 f^{\prime\prime}(x) + \mathcal{O}\left( \Delta x^3 \right) \\ f^{\prime\prime}(x) &= \frac{f(x + \Delta x) - 2 f(x) + f(x - \Delta x)}{\Delta x^2} + \mathcal{O}\left( \Delta x^2 \right) \end{align}\]
@@ -487,8 +487,8 @@

4.2.2. Second-order finite differences4.2.3. Solving ODEs with finite differences

We can use finite differences to solve ODEs by substituting them for exact derivatives, and then applying the equation at discrete locations in the domain. This gives us a system of simultaneous equations to solve.

For example, let’s consider the ODE

-
-(4.20)\[\begin{equation} +
+(4.20)\[\begin{equation} y^{\prime\prime} + x y^{\prime} - x y = 2 x \;, \end{equation}\]

with the boundary conditions \(y(0) = 1\) and \(y(2) = 8\).

@@ -498,22 +498,22 @@

4.2.3. Solving ODEs with finite differen

To do this, we’ll follow a few steps:

1.) Replace exact derivatives in the original ODE with finite differences, and apply the equation at a particular location \((x_i, y_i)\).

For our example, this gives:

-
-(4.21)\[\begin{equation} +
+(4.21)\[\begin{equation} \frac{y_{i+1} - 2y_i + y_{i-1}}{\Delta x^2} + x_i \left( \frac{y_{i+1} - y_{i-1}}{2 \Delta x}\right) - x_i y_i = 2 x_i \end{equation}\]

which applies at location \((x_i, y_i)\).

2.) Next, rearrange the equation into a recursion formula:

-
-(4.22)\[\begin{equation} +
+(4.22)\[\begin{equation} y_{i-1} \left(1 - x_i \frac{\Delta x}{2}\right) + y_i \left( -2 -\Delta x^2 x_i \right) + y_{i+1} \left(1 + x_i \frac{\Delta x}{2}\right) = 2 x_i \Delta x^2 \end{equation}\]

We can use this equation to get an equation for each of the interior points in the domain.

For the first and last points—the boundary points—we already have equations, given by the boundary conditions.

3.) Set up system of linear equations

Applying the recursion formula to the interior points, and the boundary conditions for the boundary points, we can get a system of simultaneous linear equations:

-
-(4.23)\[\begin{align} +
+(4.23)\[\begin{align} y_1 &= 1 \\ y_1 (0.875) + y_2 (-2.125) + y_3 (1.125) &= 0.25 \\ y_2 (0.75) + y_3 (-2.25) + y_4 (1.25) &= 0.5 \\ @@ -521,8 +521,8 @@

4.2.3. Solving ODEs with finite differen y_5 &= 8 \end{align}\]

This is a system of five equations and five unknowns, which we can solve! But, solving using substitution would be painful, so let’s represent this system of equations using a matrix and vectors:

-
-(4.24)\[\begin{equation} +
+(4.24)\[\begin{equation} \begin{bmatrix} 1 & 0 & 0 & 0 & 0 \\ 0.875 & -2.125 & 1.125 & 0 & 0 \\ @@ -637,8 +637,8 @@

4.2.4. Boundary conditions\(y(0) = a\), then this equation is straightforward:

-
-(4.25)\[\begin{equation} +
+(4.25)\[\begin{equation} y_1 = a \end{equation}\]

where \(y_1\) is the first point in the grid of points, corresponding to \(x_1 = 0\). (We saw this in the example above.) In Matlab, we can implement this equation with

@@ -647,8 +647,8 @@

4.2.4. Boundary conditions\(y^{\prime}(0) = 0\), then we need to use a finite difference to represent the derivative. When the boundary condition is at the starting location, \(x=0\), the easiest way to do this is with a forward difference:

-
-(4.26)\[\begin{align} +
+(4.26)\[\begin{align} y^{\prime}(0) \approx \frac{y_2 - y_1}{\Delta x} &= 0 \\ -y_1 + y_2 &= 0 \end{align}\]
@@ -659,8 +659,8 @@

4.2.4. Boundary conditions\(x=L\), then we can use a backward difference to represent the derivative:

-
-(4.27)\[\begin{align} +
+(4.27)\[\begin{align} y^{\prime}(L) \approx \frac{y_n - y_{n_1}}{\Delta x} &= 0 \\ -y_{n-1} + y_n &= 0 \end{align}\]
@@ -671,8 +671,8 @@

4.2.4. Boundary conditions
\[\begin{align} +
+(4.28)\[\begin{align} a y(0) + b y^{\prime}(0) \approx a y_1 + b \frac{y_2 - y_1}{\Delta x} &= c \\ (a \Delta x - b) y_1 + b y_2 &= c \Delta x \end{align}\]
@@ -686,21 +686,21 @@

4.2.4. Boundary conditions4.2.4.1. Using central differences for derivative BCs

When a boundary condition involves a derivative, we can use a central difference to approximate the first derivative; this is more accurate than a forward or backward difference.

Consider the formula for a central difference at \(x=0\), applied for the boundary condition \(y^{\prime}(0) = 0\):

-
-(4.29)\[\begin{align} +
+(4.29)\[\begin{align} y^{\prime}(0) \approx \frac{y_2 - y_0}{2 \Delta x} &= 0 \\ y_0 &= y_2 \end{align}\]

where \(y_0\) is an imaginary, or ghost, node outside the domain. We can’t actually keep this point in our implementation, because it isn’t a real point.

We still need an equation for the point at the boundary, \(y_1\). To get this, we’ll apply the regular recursion formula, normally used at interior points:

-
-(4.30)\[\begin{align} +
+(4.30)\[\begin{align} a y_{i-1} + b y_i + c y_{i+1} = f(x_i) \\ a y_0 + b y_1 + c y_2 = f(x_1) \;, \end{align}\]

where \(a\), \(b\), \(c\), and \(f(x)\) depend on the problem. Normally we wouldn’t use this at the boundary node, \(y_1\), because it references a point outside the domain to the left—but we have an equation for that! From above, based on the boundary condition, we have \(y_0 = y_2\). If we incorporate that into the recursion formula, we can eliminate the ghost node \(y_0\):

-
-(4.31)\[\begin{align} +
+(4.31)\[\begin{align} a y_2 + b y_1 + c y_2 &= f(x_1) \\ b y_1 + (a + c) y_2 &= f(x_1) \, \end{align}\]
@@ -717,19 +717,19 @@

4.2.4.1. Using central differences for d

4.2.5. Example: nonlinear BVP

So far we’ve seen how to handle a linear boundary value problem, but what if we have a nonlinear BVP? This is going to be trickier, because our work so far relies on using linear algebra to solve the system of (linear) equations.

For example, consider the 2nd-order ODE

-
-(4.32)\[\begin{equation} +
+(4.32)\[\begin{equation} y^{\prime\prime} = 3y + x^2 + 100 y^2 \end{equation}\]

with the boundary conditions \(y(0) = y(1) = 0\). This is nonlinear, due to the \(y^3\) term on the right-hand side.

To solve this, let’s first convert it into a discrete form, by replacing the second derivative with a finite difference and any \(x\)/\(y\) present with \(x_i\) and \(y_i\). We’ll also move any constants (i.e., terms that don’t contain \(y_i\)) and the nonlinear term to the right-hand side:

-
-(4.33)\[\begin{equation} +
+(4.33)\[\begin{equation} \frac{y_{i-1} - 2y_i + y_{i+1}}{\Delta x^2} - 3y_i = x_i^2 + 100 y_i^2 \end{equation}\]

where the boundary conditions are now \(y_1 = 0\) and \(y_n = 0\), with \(n\) as the number of grid points. We can rearrange and simplify into our recursion formula:

-
-(4.34)\[\begin{equation} +
+(4.34)\[\begin{equation} y_{i-1} + y_i \left( -2 - 3 \Delta x^2 \right) + y_{i+1} = x_i^2 \Delta x^2 + 100 \Delta x^2 y_i^2 \end{equation}\]

The question is: how do we solve this now? The nonlinear term involving \(y_i^3\) on the right-hand side complicates things, but we know how to set up and solve this without the nonlinear term. We can use an approach known as successive iteration:

@@ -859,37 +859,33 @@

4.2.5. Example: nonlinear BVP

4.2.6. Example: heat transfer through a fin

Let’s now consider a more complicated example: heat transfer through an extended surface (a fin).

-
-
- Heat transfer fin -
Figure: Geometry of a heat transfer fin
-
-
+
+Heat transfer fin +

Fig. 4.2 Geometry of a heat transfer fin

+

In this situation, we have the temperature of the body \(T_b\), the temperature of the ambient fluid \(T_{\infty}\); the length \(L\), width \(w\), and thickness \(t\) of the fin; the thermal conductivity of the fin material \(k\); and convection heat transfer coefficient \(h\).

The boundary conditions can be defined in different ways, but generally we can say that the temperature of the fin at the wall is the same as the body temperature, and that the fin is insulated at the tip. This gives us

-
-(4.35)\[\begin{align} +
+(4.35)\[\begin{align} T(x=0) &= T_b \\ q(x=L) = 0 \rightarrow \frac{dT}{dx} (x=0) &= 0 \end{align}\]

Our goal is to solve for the temperature distribution \(T(x)\). To do this, we need to set up a governing differential equation. Let’s do a control volume analysis of heat transfer through the fin:

-
-
- Control volume for heat transfer fin -
Figure: Control volume for heat transfer through the fin
-
-
+
+Control volume for heat transfer fin +

Fig. 4.3 Control volume for heat transfer through the fin

+

Given a particular volumetric slice of the fin, we can define the heat transfer rates of conduction through the fin and convection from the fin to the air:

-
-(4.36)\[\begin{align} +
+(4.36)\[\begin{align} q_{\text{conv}} &= h P \left( T - T_{\infty} \right) dx \\ q_{\text{cond}, x} &= -k A_c \left(\frac{dT}{dx}\right)_{x} \\ q_{\text{cond}, x+\Delta x} &= -k A_c \left(\frac{dT}{dx}\right)_{x+\Delta x} \;, \end{align}\]

where \(P\) is the perimeter (so that \(P \, dx\) is the heat transfer area to the fluid) and \(A_c\) is the cross-sectional area.

Performing a balance through the control volume:

-
-(4.37)\[\begin{align} +
+(4.37)\[\begin{align} q_{\text{cond}, x+\Delta x} &= q_{\text{cond}, x} - q_{\text{conv}} \\ -k A_c \left(\frac{dT}{dx}\right)_{x+\Delta x} &= -k A_c \left(\frac{dT}{dx}\right)_{x} - h P \left( T - T_{\infty} \right) dx \\ -k A_c \frac{\left.\frac{dT}{dx}\right|_{x+\Delta x} - \left.\frac{dT}{dx}\right|_{x}}{dx} &= -h P ( T - T_{\infty} ) \\ @@ -898,43 +894,43 @@

4.2.6. Example: heat transfer through a \frac{d^2 T}{dx^2} &= m^2 (T - T_{\infty}) \end{align}\]

then we have as a governing equation

-
-(4.38)\[\begin{equation} +
+(4.38)\[\begin{equation} \frac{d^2 T}{dx^2} - m^2 (T - T_{\infty}) = 0 \;, \end{equation}\]

where \(m^2 = (h P)/(k A_c)\).

We can obtain an exact solution for this ODE. For convenience, let’s define a new variable, \(\theta\), which is a normalized temperature:

-
-(4.39)\[\begin{equation} +
+(4.39)\[\begin{equation} \theta \equiv T - T_{\infty} \end{equation}\]

where \(\theta^{\prime} = T^{\prime}\) and \(\theta^{\prime\prime} = T^{\prime\prime}\). This gives us a new governing equation:

-
-(4.40)\[\begin{equation} +
+(4.40)\[\begin{equation} \theta^{\prime\prime} - m^2 \theta = 0 \;. \end{equation}\]

This is a 2nd-order homogeneous ODE, which looks a lot like \(y^{\prime\prime} + a y = 0\). The exact solution is then

-
-(4.41)\[\begin{align} +
+(4.41)\[\begin{align} \theta(x) &= c_1 e^{-m x} + c_2 e^{m x} \\ T(x) &= T_{\infty} + c_1 e^{-m x} + c_2 e^{m x} \end{align}\]

We’ll use this to look at the accuracy of a numerical solution, but we will not be able to find an exact solution for more complicated versions of this problem.

We can also solve this numerically using the finite difference method. Let’s replace the derivative with a finite difference:

-
-(4.42)\[\begin{align} +
+(4.42)\[\begin{align} \frac{d^2 T}{dx^2} - m^2 (T - T_{\infty}) &= 0 \\ \frac{T_{i-1} - 2T_i + T_{i+1}}{\Delta x^2} - m^2 \left( T_i - T_{\infty} \right) &= 0 \end{align}\]

which we can rearrange into a recursion formula:

-
-(4.43)\[\begin{equation} +
+(4.43)\[\begin{equation} T_{i-1} + T_i \left( -2 - \Delta x^2 m^2 \right) + T_{i+1} = -m^2 \Delta x^2 \, T_{\infty} \end{equation}\]

This gives us an equation for all the interior nodes; we can use the above boundary conditions to get equations for the boundary nodes. For the boundary condition at \(x=L\), \(T^{\prime}(x=L) = 0\), let’s use a backward difference:

-
-(4.44)\[\begin{align} +
+(4.44)\[\begin{align} T_1 &= T_b \\ \frac{T_n - T_{n-1}}{\Delta x} = 0 \rightarrow - T_{n-1} + T_n &= 0 \end{align}\]
@@ -942,8 +938,8 @@

4.2.6. Example: heat transfer through a

4.2.6.1. Heat transfer with radiation

Let’s now consider a more-complicated case, where we also have radiation heat transfer occuring along the length of the fin. Now, our governing ODE is

-
-(4.45)\[\begin{equation} +
+(4.45)\[\begin{equation} \frac{d^2 T}{dx^2} - \frac{h P}{k A_c} \left(T - T_{\infty}\right) - \frac{\sigma \epsilon P}{h A_c} \left(T^4 - T_{\infty}^4 \right) = 0 \end{equation}\]

This is a bit trickier to solve because of the nonlinear term involving \(T^4\). But, we can handle it via the iterative solution method discussed above.

diff --git a/docs/content/bvps/shooting-method.html b/docs/content/bvps/shooting-method.html index 2c0cda8..9a9cf54 100644 --- a/docs/content/bvps/shooting-method.html +++ b/docs/content/bvps/shooting-method.html @@ -392,8 +392,8 @@

Mechanical Engineering Methods notes

4.1. Shooting Method

Boundary-value problems are also ordinary differential equations—the difference is that our two constraints are at boundaries of the domain, rather than both being at the starting point.

For example, consider the ODE

-
-(4.1)\[\begin{equation} +
+(4.1)\[\begin{equation} y^{\prime\prime} + xy^{\prime} - xy = 2x \end{equation}\]

with the boundary conditions \(y(0)=1\) and \(y(2)=8\).

@@ -406,8 +406,8 @@

4.1. Shooting Method\(y(L)\) does not match the given boundary condition, adjust your guess for \(y'(0)\) and repeat.

Now, this algorithm will not work particularly well if all your guesses are random/uninformed. Fortunately, we can use linear interpolation to inform a third guess based on two initial attempts:

-
-(4.2)\[\begin{align} +
+(4.2)\[\begin{align} \text{guess 3} &= \text{guess 2} + m \left( \text{target} - \text{solution 2} \right) \\ m &= \frac{\text{guess 1} - \text{guess 2}}{\text{solution 1} - \text{solution 2}} \end{align}\]
@@ -415,14 +415,14 @@

4.1. Shooting Method

4.1.1. Example: linear ODE

Let’s try solving the given ODE using the shooting method:

-
-(4.3)\[\begin{equation} +
+(4.3)\[\begin{equation} y^{\prime\prime} + xy^{\prime} - xy = 2x \end{equation}\]

with the boundary conditions \(y(0)=1\) and \(y(2)=8\).

First, we need to convert this 2nd-order ODE into a system of two 1st-order ODEs, where we can define \(u = y'\):

-
-(4.4)\[\begin{align} +
+(4.4)\[\begin{align} y' &= u \\ u' &= 2x + xy - xu \end{align}\]
@@ -492,31 +492,29 @@

4.1.1. Example: linear ODE

4.1.2. Example: nonlinear ODE

We can use the shooting method to solve a famous fluids problem: the Blasius boundary layer.

-
-
- Laminar boundary layer, from https://commons.wikimedia.org/wiki/File:Laminar_boundary_layer_scheme.svg -
Figure: Laminar boundary layer, taken from https://commons.wikimedia.org/wiki/File:Laminar_boundary_layer_scheme.svg
-
-
+
+Laminar boundary layer, from https://commons.wikimedia.org/wiki/File:Laminar_boundary_layer_scheme.svg +

Fig. 4.1 Laminar boundary layer, taken from https://commons.wikimedia.org/wiki/File:Laminar_boundary_layer_scheme.svg

+

To get to a solveable ODE, we start with the conservation of momentum equation (i.e., Navier–Stokes equation) in the \(x\)-direction:

-
-(4.5)\[\begin{equation} +
+(4.5)\[\begin{equation} u \frac{\partial u}{\partial x} + v \frac{\partial u}{\partial y} = \nu \frac{\partial^2 u}{\partial y^2} \end{equation}\]

and the conservation of mass equation:

-
-(4.6)\[\begin{equation} +
+(4.6)\[\begin{equation} \frac{\partial u}{\partial x} + \frac{\partial v}{\partial y} = 0 \;, \end{equation}\]

where \(u\) is the velocity component in the \(x\)-direction, \(v\) is the velocity component in the \(y\)-direction, and \(\nu\) is the fluid’s kinematic viscosity. The boundary conditions are that \(u = v = 0\) at \(y=0\), and that \(u = U_{\infty}\) as \(y \rightarrow \infty\), where \(U_{\infty}\) is the free-stream velocity.

Blasius solved this problem by converting the PDE into an ODE, by recognizing that the boundary layer thickness is given by \(\delta(x) \sim \sqrt{\frac{x \nu}{U_{\infty}}}\), and then nondimensionalizing the position coordinates using a similarity variable

-
-(4.7)\[\begin{equation} +
+(4.7)\[\begin{equation} \eta = y \sqrt{\frac{U_{\infty}}{2 \nu x}} \end{equation}\]

By introducing the stream function, \(\psi (x,y)\), we can ensure the continuity equation is satisfied:

-
-(4.8)\[\begin{equation} +
+(4.8)\[\begin{equation} u = \frac{\partial \psi}{\partial y} \;, \quad v = -\frac{\partial \psi}{\partial x} \end{equation}\]

Let’s check this, using SymPy:

@@ -546,13 +544,13 @@

4.1.2. Example: nonlinear ODE\(f(\eta)\):

-
-(4.9)\[\begin{equation} +
+(4.9)\[\begin{equation} f(\eta) = \frac{\psi}{U_{\infty}} \sqrt{\frac{U_{\infty}}{2 \nu x}} \end{equation}\]

which relates directly to the velocity components:

-
-(4.10)\[\begin{align} +
+(4.10)\[\begin{align} u &= \frac{\partial \psi}{\partial y} = \frac{\partial \psi}{\partial f} \frac{\partial f}{\partial \eta} \frac{\partial \eta}{\partial y} \\ &= U_{\infty} \sqrt{\frac{2 \nu x}{U_{\infty}}} \cdot f^{\prime}(\eta) \cdot \sqrt{\frac{U_{\infty}}{2 \nu x}} \\ u &= U_{\infty} f^{\prime} (\eta) \\ @@ -560,14 +558,14 @@

4.1.2. Example: nonlinear ODE\(x\)-momentum equation, which leads to an ODE for the dimensionless stream function \(f(\eta)\):

-
-(4.11)\[\begin{equation} +
+(4.11)\[\begin{equation} f^{\prime\prime\prime} + f f^{\prime\prime} = 0 \;, \end{equation}\]

with the boundary conditions \(f = f^{\prime} = 0\) at \(\eta = 0\), and \(f^{\prime} = 1\) as \(\eta \rightarrow \infty\).

This is a 3rd-order ODE, which we can solve by converting it into three 1st-order ODEs:

-
-(4.12)\[\begin{align} +
+(4.12)\[\begin{align} y_1 &= f \quad y_1^{\prime} = y_2 \\ y_2 &= f^{\prime} \quad y_2^{\prime} = y_3 \\ y_3 &= f^{\prime\prime} \quad y_3^{\prime} = -y_1 y_3 diff --git a/docs/content/numerical-methods/stability.html b/docs/content/numerical-methods/stability.html index 1bf9bbc..627f426 100644 --- a/docs/content/numerical-methods/stability.html +++ b/docs/content/numerical-methods/stability.html @@ -413,8 +413,8 @@

2.4. Stability and Stiffness -(2.19)\[\begin{equation} +
+(2.19)\[\begin{equation} \frac{dy}{dt} = -3 y \end{equation}\]

with the initial condition \(y(0) = 1\). As we will see, this ODE can cause explicit numerical schemes to become unstable, and thus it is a stiff ODE. (Note that we can easily obtain the exact solution for this problem, which is \(y(t) = e^{-3 t}\).)

@@ -472,8 +472,8 @@

2.4. Stability and Stiffness\(\Delta t = 0.1\) and \(\Delta t = 0.25\), we see that the solution is well-behaved. But, when we increase \(\Delta t\) to 0.5, we see some instability that goes away with time. Then, when we increase \(\Delta t\) to 0.75, the solution eventually blows up, leading to error much larger than what we should expect based on the method’s order of accuracy (first) and the step size value.

Compare this behavior to that for the ODE

-
-(2.20)\[\begin{equation} +
+(2.20)\[\begin{equation} \frac{dy}{dt} = e^{-t} \end{equation}\]

which is non-stiff:

@@ -541,13 +541,13 @@

2.4. Stability and Stiffness

2.4.1. Backward Euler method

The Backward Euler method is very similar to the Forward Euler method, except in one way: it uses the slope at the next time step:

-
-(2.21)\[\begin{equation} +
+(2.21)\[\begin{equation} \left(\frac{dy}{dx}\right)_{i+1} \approx \frac{y_{i+1} - y_i}{\Delta x} \end{equation}\]

Then, the resulting recursion formula is

-
-(2.22)\[\begin{equation} +
+(2.22)\[\begin{equation} y_{i+1} = y_i + \Delta x \left(\frac{dy}{dx}\right)_{i+1}, \text{ or} \\ y_{i+1} = y_i + \Delta x \, f(x_{i+1}, y_{i+1}) \end{equation}\]
@@ -556,13 +556,13 @@

2.4.1. Backward Euler method

2.4.1.1. Backward Euler example

For example, consider the problem

-
-(2.23)\[\begin{equation} +
+(2.23)\[\begin{equation} \frac{dy}{dx} = f(x,y) = 8 e^{-x} (1+x) - 2y \end{equation}\]

To actually solve this problem with the Backward Euler method, we need to incorporate the derivative function \(f(x,y)\) into the recursion formula and solve for \(y_{i+1}\):

-
-(2.24)\[\begin{align} +
+(2.24)\[\begin{align} y_{i+1} &= y_i + \Delta x \, f(x_{i+1}, y_{i+1}) \\ y_{i+1} &= y_i + \Delta x \left[ 8 e^{-x_{i+1}} (1 + x_{i+1}) - 2 y_{i+1} \right] \\ y_{i+1} &= y_i + 8 e^{-x_{i+1}} (1 + x_{i+1}) \Delta x - 2 \Delta x \, y_{i+1} \\ @@ -598,8 +598,8 @@

2.4.1.1. Backward Euler example

This matches nearly what we saw with the Forward Euler method before—Backward Euler is also a first-order method, so the global error should be proportional to \(\Delta x\).

Let’s now return to the stiff ODE \(y^{\prime} = -3 y\), and see how the Backward Euler method does. First, we need to obtain our useable recursion formula:

-
-(2.25)\[\begin{align} +
+(2.25)\[\begin{align} y_{i+1} &= y_i + \Delta t \, f(t_{i+1}, y_{i+1}) \\ y_{i+1} &= y_i + \Delta t \, \left( -3 y_{i+1} \right) \\ y_{i+1} + 3 y_{i+1} \Delta t &= y_i \\ @@ -663,8 +663,8 @@

2.4.2. Stability analysis

2.4.2.1. Stability analysis of Forward Euler

We can perform a stability analysis of the stiff problem to identify when the Forward Euler method becomes unstable. Let’s apply the method to the ODE at hand:

-
-(2.26)\[\begin{align} +
+(2.26)\[\begin{align} \frac{dy}{dt} &= -3 y \\ y_{i+1} &= y_i + \Delta t f(t_i, y_i) \\ y_{i+1} &= y_i + \Delta t (-3 y_i) \\ @@ -673,8 +673,8 @@

2.4.2.1. Stability analysis of Forward E \end{align}\]

where \(\sigma\) is the amplification factor. This defines whether the solution grows or decays each step—for a stable physical system, we expect the solution to get smaller or remain contant with each step.

Therefore, for the method to remain stable, we must have \(\sigma | \leq 1\). We can use this stability criterion to find conditions on \(\Delta t\) for stability:

-
-(2.27)\[\begin{gather} +
+(2.27)\[\begin{gather} | \sigma | = | 1 - 3 \Delta t | \leq 1 \\ -1 \leq 1 - 3 \Delta t \leq 1 \\ -1 \leq 1 - 3 \Delta t \quad \text{or} \quad 1 - 3 \Delta t \leq 1 \\ @@ -689,8 +689,8 @@

2.4.2.1. Stability analysis of Forward E

2.4.2.2. Stability analysis of Backward Euler

We can also perform a stability analysis on the Backward Euler method to show that its stability does not depend on the step size:

-
-(2.28)\[\begin{align} +
+(2.28)\[\begin{align} \frac{dy}{dt} &= -3 y \\ y_{i+1} &= y_i + \Delta t f(t_{i+1}, y_{i+1}) \\ y_{i+1} &= y_i + \Delta t (-3 y_{i+1}) \\ @@ -698,8 +698,8 @@

2.4.2.2. Stability analysis of Backward \sigma &= \frac{y_{i+1}}{y_i} = \frac{1}{1 + 3 \Delta t} \end{align}\]

For stability, we need \(| \sigma | \leq 1\):

-
-(2.29)\[\begin{align} +
+(2.29)\[\begin{align} | \sigma | &= \left| \frac{1}{1 + 3 \Delta t} \right| \leq 1 \\ \rightarrow \Delta t &> 0 \end{align}\]
diff --git a/docs/content/quizzes/quiz3-BVPs.html b/docs/content/quizzes/quiz3-BVPs.html index 420d8a3..8775d51 100644 --- a/docs/content/quizzes/quiz3-BVPs.html +++ b/docs/content/quizzes/quiz3-BVPs.html @@ -402,48 +402,46 @@

Sample Quiz 3 problems: BVPs

Problem 1: Finite difference method

The temperature distribution \(T(r)\) in an annular fin of inner radius \(r_1\) and outer radius \(r_2\) is described by the equation

-
-(24)\[\begin{equation} +
+(24)\[\begin{equation} r \frac{d^2 T}{dr^2} + \frac{dT}{dr} - rm^2 (T - T_{\infty}) = 0 \;, \end{equation}\]

where \(r\) is the radial distance from the centerline (the independent variable) and \(m^2\) is a constant that depends on the heat transfer coefficient, thermal conductivity, and thickness of the annulus. Assuming we choose a spatial step size \(\Delta r\),

-
-
- Annular fin -
Figure: Annular fin
-
-
+
+Annular fin +

Fig. 1 Annular fin

+

a.) Write the finite-difference representation of the ODE (that applies at a location \(r_i\)), using central differences.

b.) Based on the last part, write the recursion formula.

c.) The boundary condition at the outer radius \(r = r_2\) is described by convection heat transfer:

-
-(25)\[\begin{equation} +
+(25)\[\begin{equation} -k \left. \frac{dT}{dr} \right|_{r=r_2} = h \left[ T(r=r_2) - T_{\infty} \right] \;. \end{equation}\]

Write the boundary condition at \(r = r_2\) in recursion form (i.e., the equation you would implement into your system of equations to solve for temperature).

Solution

a.) Replace the derivatives in the given ODE with finite differences, and replace any locations with the \(i\) location:

-
-(26)\[\begin{equation} +
+(26)\[\begin{equation} r_i \frac{T_{i-1} - 2T_i + T_{i+1}}{\Delta r^2} + \frac{T_{i+1} - T_{i-1}}{2\Delta r} - r_i m^2 (T_i - T_{\infty}) = 0 \end{equation}\]

or

-
-(27)\[\begin{equation} +
+(27)\[\begin{equation} r_i (T_{i-1} - 2T_i + T_{i+1}) + \frac{\Delta r}{2} (T_{i+1} - T_{i-1}) - r_i m^2 \Delta r^2 (T_i - T_{\infty}) = 0 \end{equation}\]

b.) Rearrange and combine terms:

-
-(28)\[\begin{align} +
+(28)\[\begin{align} r_i (T_{i-1} - 2T_i + T_{i+1}) + \frac{\Delta r}{2} (T_{i+1} - T_{i-1}) - r_i m^2 \Delta r^2 (T_i - T_{\infty}) &= 0 \\ r_i (T_{i-1} - 2T_i + T_{i+1}) + \frac{\Delta r}{2} (T_{i+1} - T_{i-1}) - r_i m^2 \Delta r^2 T_i &= -r_i m^2 \Delta r^2 T_{\infty} \\ \left(r_i - \frac{\Delta r}{2}\right) T_{i-1} + \left( -2 r_i - r_i m^2 \Delta r^2 \right) T_i + \left( r_i + \frac{\Delta r}{2} \right) T_{i+1} &= -r_i m^2 \Delta r^2 T_{\infty} \end{align}\]

c.) We can use a backward difference to approximate the \(dT/dr\) term. \(T_n\) represents the temperature at node \(n\) where \(r_n = r_2\):

-
-(29)\[\begin{align} +
+(29)\[\begin{align} -k \frac{T_n - T_{n-1}}{\Delta r} &= h (T_n - T_{\infty}) \\ -k (T_n - T_{n-1}) &= h \Delta r (T_n - T_{\infty}) \\ k T_{n-1} - (k + h\Delta r) T_n &= -h \Delta r T_{\infty} @@ -458,8 +456,8 @@

Problem 2: eigenvalue

Solution

a.)

-
-(30)\[\begin{gather} +
+(30)\[\begin{gather} y(x) = A \sin (3 \lambda x) + B \cos (3 \lambda x) \\ \text{Apply BCs: } y(x=0) = 0 = A \sin(0) + B \cos(0) = B \\ \therefore B = 0 \\ @@ -469,13 +467,13 @@

Solution

The eigenfunction is then the solution function associated with an eigenvalue:

-
-(31)\[\begin{equation} +
+(31)\[\begin{equation} y_n = A_n \sin \left( \frac{n \pi x}{2} \right) \quad n = 1, 2, 3, \ldots, \infty \end{equation}\]

b.) The principal eigenvalue is just that associated with \(n = 1\):

-
-(32)\[\begin{equation} +
+(32)\[\begin{equation} \lambda_p = \lambda_1 = \frac{\pi}{6} \end{equation}\]
@@ -483,23 +481,23 @@

Solution

Problem 3: shooting method

Use the shooting method to solve the boundary value problem

-
-(33)\[\begin{equation} +
+(33)\[\begin{equation} y^{\prime\prime} - 4y = 0 \end{equation}\]

where \(y(0) = 0\) and \(y(1) = 3\). Find the initial value of \(y'\) (meaning, \(y'(0)\)) that satisfies the given boundary conditions. Use the forward Euler method with a step size of \(\Delta x = 0.5\).

Solution

First decompose into two 1st-order ODEs:

-
-(34)\[\begin{align} +
+(34)\[\begin{align} z_1' &= y' = z_2 \\ z_2' &= y'' = 4 z_1 \end{align}\]

with BCs \(z_1 (x=0) = z_{1,1} = 0\) and \(z_1(x=1) = z_{1,3} = 3\), we do not know \(y'(0) = z_2(x=0) = z_{2,1} = ?\)

Try some guess #1: \(y' (0) = 0 = z_2 (0)\), with the forward Euler method:

-
-(35)\[\begin{align} +
+(35)\[\begin{align} z_{1,2} = z_1 (0.5) &= z_1 (0) + z_2(0) 0.5 = 0 \\ z_{2,2} = z_2 (0.5) &= z_2 (0) + \left( 4z_1(0) \right) 0.5 = 0 \\ z_{1,3} = z_1 (1.0) &= z_1 (0.5) + z_2(0.5) 0.5 = 0 \leftarrow \text{solution 1} \\ @@ -507,8 +505,8 @@

Solution

so for solution 1: \(y(1) = 0 \neq 3\).

For guess #2: \(y' (0) = 2 = z_2 (0)\), with the forward Euler method:

-
-(36)\[\begin{align} +
+(36)\[\begin{align} z_1 (0.5) &= z_1 (0) + z_2(0) 0.5 = 1.0 \\ z_2 (0.5) &= z_2 (0) + \left( 4z_1(0) \right) 0.5 = 2.0 \\ z_1 (1.0) &= z_1 (0.5) + z_2(0.5) 0.5 = 2.0 \leftarrow \text{solution 2} \\ @@ -516,14 +514,14 @@

Solution

so for solution 1: \(y(1) = 2 \neq 3\).

For guess #3, we can interpolate:

-
-(37)\[\begin{align} +
+(37)\[\begin{align} m &= \frac{\text{guess 1} - \text{guess 2}}{\text{solution 1} - \text{solution 2}} = \frac{0 - 2}{0 - 2} = 1 \\ \text{guess 3} &= \text{guess 2} + m (\text{target} - \text{solution 2}) = 2 + 1(3-2) = 3 \end{align}\]

then, use this guess:

-
-(38)\[\begin{align} +
+(38)\[\begin{align} z_1 (0.5) &= z_1 (0) + z_2(0) 0.5 = 1.5 \\ z_2 (0.5) &= z_2 (0) + \left( 4z_1(0) \right) 0.5 = 3.0 \\ z_1 (1.0) &= z_1 (0.5) + z_2(0.5) 0.5 = 3.0 \leftarrow \text{solution 3} \\ @@ -531,9 +529,6 @@

Solution

so for solution 3: \(y(1) = 3\) which is the target.

So our answer is \(y'(0) = 3\).

-

-
-

diff --git a/docs/objects.inv b/docs/objects.inv index 30617d0..e525b78 100644 Binary files a/docs/objects.inv and b/docs/objects.inv differ diff --git a/docs/searchindex.js b/docs/searchindex.js index 0bc172d..f5aad67 100644 --- a/docs/searchindex.js +++ b/docs/searchindex.js @@ -1 +1 @@ -Search.setIndex({docnames:["content/LICENSE","content/bvps/boundary-value-problems","content/bvps/eigenvalue","content/bvps/finite-difference","content/bvps/shooting-method","content/contributing","content/first-order","content/installing-jupyter","content/intro","content/numerical-methods/error","content/numerical-methods/initial-value-methods","content/numerical-methods/integrals","content/numerical-methods/numerical-methods","content/numerical-methods/stability","content/pdes/elliptic","content/pdes/parabolic","content/pdes/partial-differential-equations","content/quizzes/quiz2-IVPs","content/quizzes/quiz3-BVPs","content/second-order/analytical","content/second-order/fourier-series","content/second-order/initial-value-problems","content/second-order/numerical-methods","content/second-order/power-series","content/second-order/second-order"],envversion:{"sphinx.domains.c":2,"sphinx.domains.changeset":1,"sphinx.domains.citation":1,"sphinx.domains.cpp":3,"sphinx.domains.index":1,"sphinx.domains.javascript":2,"sphinx.domains.math":2,"sphinx.domains.python":2,"sphinx.domains.rst":2,"sphinx.domains.std":2,"sphinx.ext.intersphinx":1,sphinx:56},filenames:["content/LICENSE.md","content/bvps/boundary-value-problems.md","content/bvps/eigenvalue.ipynb","content/bvps/finite-difference.ipynb","content/bvps/shooting-method.ipynb","content/contributing.md","content/first-order.md","content/installing-jupyter.ipynb","content/intro.md","content/numerical-methods/error.md","content/numerical-methods/initial-value-methods.ipynb","content/numerical-methods/integrals.ipynb","content/numerical-methods/numerical-methods.md","content/numerical-methods/stability.ipynb","content/pdes/elliptic.ipynb","content/pdes/parabolic.ipynb","content/pdes/partial-differential-equations.md","content/quizzes/quiz2-IVPs.md","content/quizzes/quiz3-BVPs.md","content/second-order/analytical.ipynb","content/second-order/fourier-series.ipynb","content/second-order/initial-value-problems.ipynb","content/second-order/numerical-methods.ipynb","content/second-order/power-series.md","content/second-order/second-order.md"],objects:{},objnames:{},objtypes:{},terms:{"000":[2,14],"000007":11,"0004":10,"0007":10,"000821":11,"001":3,"0016":10,"005":14,"0125":14,"019":4,"0225":17,"025":14,"047":2,"0472":2,"050":10,"055":10,"068":22,"082126":11,"091":2,"0944":2,"099":22,"100":[2,3,11,14,20],"1000":[4,14,20],"1000x":11,"1056":4,"1061":14,"10762":14,"125":3,"13421":14,"156":14,"160":14,"16t":17,"16y":17,"16y_h":17,"16z_1":17,"1790":20,"1dt":20,"1e3":4,"1e4":4,"1st":[2,4,13,17,18,19,22],"200":[2,4,15],"20067":14,"2025":14,"228":22,"242":22,"250":20,"256":15,"291":14,"2dt":20,"2dx":19,"2nd":[1,2,3,4,16,17,23,24],"2t_i":[3,18],"2u_":14,"2y_i":[2,3],"3048":14,"3566":4,"373":8,"37378":14,"375":3,"3803":14,"3rd":[4,22],"3x3":[4,14],"3y_i":3,"400":14,"46922":4,"46957":4,"48301":4,"4a_n":23,"4th":[10,13,17],"4u_":14,"4xy":23,"4z_1":18,"500":20,"54587":4,"564":14,"5717":14,"5z_2":22,"625":3,"6553":4,"69037":14,"6a_n":23,"6z_1":22,"7181":14,"732":2,"746211":11,"7468":[6,11],"746818":11,"746824":11,"7x3":4,"875":3,"8y_h":17,"8z_2":17,"99951":4,"break":[4,5],"case":[2,3,4,10,11,13,14,15,19,20,21,22,23],"final":[3,19,20],"float":9,"function":[2,3,4,6,9,10,11,13,14,17,18,19,21,22],"import":[2,3,4,14,19,21],"int":[6,11,19,20,21],"long":[13,14,22],"new":[2,3,4,5,7,14,19,21],"return":[13,14],"static":[2,5],"transient":[14,15,20],"true":[3,4,21,23],"try":[2,4,5,13,14,18,19,21,23],"while":[3,4,5,6,11,14,17,20,22],Adding:3,BCs:18,But:[2,3,4,13,14,20],For:[2,3,4,5,6,9,10,13,14,15,17,18,19,20,21,22,23],ODE:[2,3,6,10,13,17,18,21,22,23],ODEs:[1,2,4,18,20,23,24],One:[19,20,22],That:[10,11,19,20],The:[2,3,4,10,13,14,15,16,17,18,19,20,21,22,23],Then:[2,3,6,10,13,17,19,20,21,22,23],There:[10,14,17,23],These:[2,5,9,14],Use:[5,17,18,23],Using:[4,14,17,20],With:[2,15],Yes:23,_____:4,_______:4,_________:4,_build:5,_includ:5,_sass:5,a_0:[17,20,23],a_1:[2,19,20,23],a_2:[2,19,20,23],a_3:23,a_4:23,a_5:23,a_6:23,a_7:23,a_c:3,a_i:2,a_m:[20,23],a_n:[17,18,20,23],abl:[2,3,4,14,20],about:[2,5,7,11,13,14,15,19,20,22,23],abov:[2,3,5,6,10,11,14,15,19,20,21,22],abs:[2,3,4,10,11,14,22],absolut:13,acceler:19,accept:5,account:5,accumul:[10,17],accur:[2,3,10,11,14,17,22],accuraci:[3,11,13,17],across:9,action:10,activ:7,actual:[2,3,10,13,14,19,20],add:5,added:[5,14],adding:20,addit:5,adher:5,adjust:[4,10],advantag:23,aejm:19,affect:11,after:[6,9,14,20,21],again:[2,19,20,23],against:[2,10,22],air:3,algebra:[3,19],algorithm:[4,14],align:[2,3,4,6,10,11,13,14,15,17,18,19,20,21,22,23],all:[2,3,4,5,6,9,10,13,14,15,18,20,21,22,23],allow:[5,10,11,13,23],almost:13,along:[3,12,14],alpha:[14,15,20,21],alreadi:[3,4,5,7,21,22],also:[2,3,4,5,9,10,11,13,14,15,16,17,19,20,21,22],although:13,alwai:[13,23],ambient:3,among:5,amount:14,amplif:[13,17],amplitud:2,anaconda:7,analysi:3,analyt:[2,10,11,20,21,23,24],analyz:2,ani:[3,5,9,13,14,17,18,19,22],anim:15,annular:18,annulu:18,anonym:10,anoth:[3,5,10,13,19,23],ans:4,answer:[5,10,18,22],anyon:5,aperiod:21,app:7,appear:14,append:15,appli:[2,3,9,10,11,13,14,15,17,18,19,23],applic:7,appreci:5,approach:[2,3,4,6,11,14,16,17,19,20,21,23],appropri:[2,14],approx:[3,10,11,13,14],approxim:[2,3,9,10,11,14,15,17,18],arbitrari:14,arbitrarili:[15,23],arctan:6,area:[2,3,11],aren:[5,14],around:[2,5,10,14,20],arrai:[4,14,22],ask:[5,21],asset:5,assign:5,associ:[2,14,18,21],assum:[2,4,7,9,18,21],assumpt:9,astar:2,attempt:4,autom:[4,14],automat:10,avail:[5,14],averag:[10,14],avoid:13,awai:[3,13],awesom:5,axi:[4,11,15,19,20,21],axmx:21,b_1:[14,20,22],b_2:[14,20,22],b_i:14,b_n:[14,17,20],back:[9,23],backward:[3,14,18],bad:3,balanc:3,baptist:20,bar:19,base:[2,3,4,5,10,13,14,15,17,18,19],bash:7,basi:19,beam:19,becaus:[2,3,4,10,13,14,20,21,23],becom:[2,13,14,15],been:[5,13,14,20],befor:[5,7,13,14,19],begin:[2,3,4,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],behav:[2,10,13,22],behavior:[13,14],being:[4,9,14,15,23],below:[5,15],bernoulli:6,beta:[20,21],better:[10,11,20],between:[9,10,11,13,14,17,19],beyond:14,big:[5,20],bit:[2,3,10,14,21],black:11,blasiu:4,blasius_rh:4,blog:5,blow:[13,15,22],bmatrix:[2,3,14,17,22],bodi:[2,3],bold:[5,22],book:[2,4,8,14],book_templ:5,both:[2,4,5,13,14,15,20,22,23],bottom:14,bound:23,boundari:[4,15,18,19,23,24],box:[2,9],branch:5,bring:23,brk:5,broken:9,bstar:2,bug:5,build:5,built:10,bvp:[1,2,4,24],c_1:[3,17,19,20,21,23],c_2:[3,17,19,20,21,23],c_p:15,calcul:[2,13,14,18,20],call:[3,7,10],can:[2,3,4,5,6,9,10,11,13,14,15,16,18,19,20,21,22,23],cancel:[],candid:21,cannot:[2,4,9,11,13,14,17,19,21,23],cantilev:19,care:14,carri:5,categor:[16,19],categori:[16,19,21],cauchi:19,caus:[13,20],cdot:[3,4,14,17,23],center:14,centerlin:18,central:[14,15,18],certain:[2,23],chain:19,chang:[3,6,14,23],chao:13,chapter:[1,12,16,24],characteris:21,characterist:[2,16,19,21],chat:5,chatterje:19,check:[3,4,5,14,23],choic:[13,14,15],choos:[3,4,10,15,17,18],chose:15,chosen:15,classic:[14,15],clc:[2,3,4,14],clear:[2,3,4,10,13,14,15,22],clearli:[14,17],cli:5,close:[2,5,6,10,11,14,15,20],code:[5,9,10,17],coeffic:23,coeffici:[2,3,14,17,18,19,22,23],collabor:5,color:11,colorbar:14,column:[14,22],combin:[2,3,5,14,15,18,20,21,23],come:[3,7,9,11,21],comfort:15,command:7,comment:5,common:[4,21],compact:10,compactli:3,compar:[2,9,10,13,22],comparison:10,complet:[5,20],complex:[2,10,13],complic:[2,3,10,21],compon:[4,20],comput:[9,13,14],computation:10,concept:[4,9,12],cond:3,conda:7,condens:2,condit:[1,4,10,13,15,17,18,19,21,22,23],condition:[13,17],conduct:[3,5,14,18],configur:5,confirm:[2,5,14,20,22],connect:[2,5],conserv:4,consid:[2,3,4,5,6,10,13,14,19,20,23],constant:[3,6,15,16,18,19,23],constrain:[1,15],constraint:[4,19,23],construct:[3,14,20],contain:[3,5],contant:13,content:[2,4,5,14],continu:[3,4,5,7,9,14,23],contour:14,contourf:14,control:[3,5,10],conv:3,convect:[3,18],conveni:[3,14],convent:5,converg:[3,4,14],convert:[2,3,4,5,14,22],coordin:4,copi:5,core:5,corner:[14,20],correct:[4,10,14],corrector:[10,22],correspond:[2,3,23],cos:[2,6,17,18,20,21,22,23],cosh:[19,21],cosin:[20,21,23],cost:[13,14],could:[3,4,5,20,21,22],coupl:22,cours:3,cover:[5,13],cramer:17,creat:[2,3,4,5,7,10,11,14,22],criterion:[13,15],critic:[2,21],cross:3,crude:2,css:5,cubic:14,current:5,curv:11,cut:10,damp:[21,22],data:9,date:5,ddot:14,deal:3,decai:[13,15,20,21],decompos:18,defin:[2,3,4,5,9,10,11,13,14,17,19,22,23],definit:[10,11],deflect:[2,19],degre:11,del:14,delaytim:15,deliber:15,delta:[2,3,4,9,10,11,13,14,15,17,18,22],demonstr:22,depend:[3,5,6,13,16,18,19,21,22],deriv:[2,4,6,10,13,15,16,18,19,22,23],describ:[5,12,14,18,19],design:5,desir:14,det:[2,22],detail:[5,19],determin:[2,5,14,22],develop:5,devic:9,diagram:2,did:[4,14],diff:4,differ:[4,5,7,14,15,16,17,19,21,22],differenti:[3,4,9,12,15],difficult:5,diffus:[14,15],digit:9,dimens:[14,16],dimension:[14,15],dimensionless:4,dimensionlesss:4,direct:[4,14,15],directli:[2,4,6,13,14,17],dirichlet:[3,14],discontinu:[14,20,21,23],discrep:20,discret:[3,9,14],discuss:[3,4,5,6,10,14,19,22,23],disp:[7,14],displac:[2,17,19,20,22],distanc:[15,18,19],distinct:5,distribut:[3,5,18],divid:[2,3],doc:[5,22],document:5,doe:[2,3,4,11,13,14,19,21,22],doesn:14,doing:[2,4,5,7],domain:[2,3,4,10,13,14,15,17],don:[2,3,5,14],dot:[10,23],down:2,downsid:10,downward:19,dqw4w9wgxcq:5,draft:5,drag:19,due:[3,9,14,19,20],dummi:[14,23],dxdt:2,dydx:4,dynam:[13,14],dz_1:22,dz_2:22,dzdt:22,each:[2,3,5,9,10,11,13,14,17,19,20,22,23],earli:5,easi:[5,7],easier:[3,4,5],easiest:3,easili:[13,20],edit:5,effect:5,eig:2,eigenfunct:[2,18],eight:14,either:[2,14],electrostat:14,element:[9,14],elimin:[3,17],ellipt:16,els:[2,3,5,14,15],elseif:[2,3,14,15],empti:5,encount:[2,3,14],encourag:5,end:[2,3,4,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],engin:[7,8,13],enh:5,enhanc:5,enough:4,ensur:4,enter:3,enthusiast:5,entir:[5,9,23],entri:5,environ:7,epsilon:[3,14],equal:[2,15,22],equat:[2,3,4,6,9,10,11,12,13,14,15,17,18,19,20,22,23],equiv:3,equival:[3,17,21,22],erf:[6,11],err:2,error:[2,3,5,6,7,10,11,12,13,17,22],especi:5,essenti:[2,14],eta:4,etc:5,euclid:19,euler:[2,4,15,18,19],evalu:4,even:[9,13,14,17,23],eventu:[13,14],ever:20,everi:[5,6],everyon:5,exact:[2,3,6,9,10,11,13,20,22],exactli:9,exampl:[6,7,9,10,15],except:[13,20,22],excit:5,exhibit:[13,16],exist:[4,5],exp:[10,11,13,19,22],expand:20,expans:[3,10,23],expect:[2,5,13,14,17,22],expens:10,experi:5,experienc:19,explain:5,explan:5,explic:10,explicit:[10,13],explicitli:13,explor:[5,15],exponenti:[14,15,21],express:[18,20,22,23],extend:3,extern:7,fact:9,factor:[6,11,13,17],fail:[14,23],fairli:[2,10],fall:[10,21],famili:10,familiar:4,famou:4,far:[3,9,10,14,22,23],fashion:[2,22],faster:[3,14,22],fastest:5,favorit:19,feel:5,few:[3,5,14,19,20],fewer:14,fig:15,figur:[2,3,4,14,15,18],file:[2,4,5,10,14,22],filenam:15,fin:18,find:[2,3,4,5,6,10,11,13,14,17,18,19,20,21,23],fine:10,finer:2,finit:[2,9,14,15,23],first:[2,3,4,5,6,10,11,12,13,14,15,17,18,19,20,21,22,23],fit:[5,11],five:[3,9,14,15],fix:[3,5,14,19],fluid:[3,4,14],focu:[13,14,19,22],focus:[1,5,16,21,24],folder:5,follow:[3,5,14,15,20,21],forc:[2,15,17,19,20,21,22],fork:5,form:[3,6,10,11,14,17,18,19,20,21,23],formal:14,format:[5,10],formula:[2,3,9,10,11,13,14,15,17,18,21,22,23],fortun:4,forward:[3,4,5,14,15,17,18],found:[5,14,20,21],four:[2,3,10,11,14],fourier:15,fprintf:[2,3,4,10,11,14,22],frac:[2,3,4,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],frame2im:15,free:[2,4,5],frequenc:[2,17,20,21],frequent:14,frictionless:9,from:[3,4,5,6,9,11,13,14,15,17,18,21],front:5,full:[3,10,19,21,23],fulli:19,function_nam:10,fundament:[17,20],further:[3,14],gase:9,gather:[2,13,18,22],gave:14,gca:[2,20],gcf:15,gener:[2,3,5,10,13,14,15,16,17,19,20,21,22,23],geometri:3,georg:9,geq:[13,15],get:[3,4,5,7,10,13,14,17,19,20,21,22],getfram:15,ghost:[3,14],gibb:20,gif:15,git:5,give:[2,3,5,10,14,15,17,18,19,20,21,22],given:[2,3,4,6,10,11,14,15,17,18,19,20,21,22],glanc:5,global:[9,10,13,17],goal:[3,5],goe:[4,13],going:[3,5,14],gone:22,good:[3,5,14,20,22],govern:[2,3,15,19],grab:21,gradient:14,gradual:20,graviti:19,great:5,greater:15,grid:[2,3,14],group:5,grow:[5,13],guess1:4,guess2:4,guess3:4,guess:[3,4,14,18],guid:[5,7],guidelin:5,had:[4,14],half:[14,15],hand:[3,13,14,19,20,21,22,23],handl:[3,14],hang:19,happen:[2,13,15],harmon:[17,20],has:[2,5,9,13,14,19,23],have:[2,3,4,5,6,7,9,10,13,14,15,20,21,22],head:5,header:5,heat:[15,18],heat_equ:14,heat_equation_gaussseidel:14,heat_equation_jacobi:14,help:[5,14],henc:20,here:[2,5,14,17,19],heun:13,higher:[3,10,11,17,20],his:19,hold:[2,3,10,11,13,14,22],homogen:[3,17,20,21,23],homogenen:20,honor:19,hopefulli:5,horizont:19,how:[2,3,5,9,10,11,13,14,19,20,21,22,23],howev:[2,14,19],html:5,http:[4,5,19],human:9,hyperbol:[16,21],idea:14,ideal:9,identifi:[2,13,14,20,23],imaginari:[3,14,21],imind:15,immedi:5,implement:[5,13,18,22],implicit:[13,17],improv:5,imwrit:15,includ:[5,14,21,23,24],incorpor:[2,3,10,13,14],increas:[2,10,11,13,14,20],increment:[10,17],independ:[2,18,21],index:[10,14,20,23],indic:[14,22],individu:5,inf:15,infinit:[2,4,9,10,20,23],infinitesim:3,inform:[2,4,5,10,14,15],infti:[2,3,4,17,18,20,23],inhomogen:17,init:7,init_print:4,initi:[2,3,4,10,13,14,15,17,18,19,22,23,24],inlin:10,inner:18,input:[9,14,17],insert:[2,4,20,21,22,23],insid:23,instabl:13,instead:[2,4,9,10,11,14,22],instruct:5,insul:3,int_0:[17,20],int_1:20,int_:[17,19],int_a:[10,11],integ:20,integr:[2,4,10,12,13,15,20,21,23],interact:[8,15],interest:[2,13],interestingli:14,interior:[3,14],intermedi:10,intern:11,interpol:[4,11,18],intertia:19,interv:9,introduc:[4,9,10],inv:[3,22],involv:[2,3,5,13,15,16,19,21,22,23],ipynb:5,isn:[3,22],isol:22,issu:15,ital:5,iter:[3,4],its:[3,5,10,13,14],itself:19,ittak:14,ivp:24,javascript:5,jean:20,jmatlab:7,job:11,joe:19,joseph:20,jupyt:[8,15],jupyter_book:5,just:[2,3,4,10,18,19,20,21,23],k_0:21,k_1:[2,10,20,21],k_2:[2,10,20,21],k_3:10,k_4:10,k_n:21,keep:[3,5],kernel:7,kick:4,kij:14,kijm1:14,kijp1:14,kim1j:14,kind:[3,9],kinemat:4,kip1j:14,know:[2,3,5,13,18,19,21,23],known:[3,6,10,11,13,14,15,17,19,20],kutta:[4,13,17],kyle:[14,22],label:14,lambda:[2,17,18,21],lambda_1:[2,18,20,21],lambda_2:[2,20,21],lambda_p:18,laminar:4,laminar_boundary_layer_schem:4,laplac:[14,21],larg:[4,15],larger:[13,14,15,22],largest:13,last:[3,18,20],later:[3,9,14,20],layer:4,ldot:[2,14,15,17,18,20,21,23],lead:[4,6,11,13,15,21],least:5,left:[2,3,4,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],leftarrow:18,legend:[3,10,11,13,14,22],length:[2,3,10,11,13,14,15,19,20,22],leq:[3,4,10,13,15,17,22],less:[10,13,14],let:[2,3,4,5,6,10,11,13,14,15,19,20,21,22,23],level:14,like:[2,3,4,6,10,11,13,14,15,17,19,20,21,22],lim_:3,limit:[13,15],line:11,linear:[3,10,14,16,17,19,22],linearli:21,linestyl:11,link:5,linspac:[2,10,11,13,19,20,22],list:5,littl:5,load:2,local:[9,10,17],locat:[3,10,14,15,18,22],log:[14,19],loglog:14,longer:3,look:[2,3,5,6,10,11,14,15,19,20,21],loop:[3,4,5,10,13],loopcount:15,loss:9,lot:3,m_1:[2,21],m_2:[2,21],m_z:2,machin:9,made:[3,19],magnitud:[3,10,11],mai:[2,3,6,7,9,10,11,13,14,15,21],main:[3,5,9,10,22],maintain:5,make:[3,4,7,9,10,11,14,15],manag:7,mani:[2,9],manual:[2,4],march:10,markdown:5,markerfacecolor:10,mass:[4,9,17,19],mass_spr:22,master:5,match:[2,3,4,13,14,20,21],materi:3,mathbf:[2,3,14,22],mathcal:[3,10,14,22],mathemat:9,matlab:[2,10,14,15,17,22],matlab_kernel:7,matlab_r2019b:7,matric:14,matrix:[2,3,14],max:[3,10,14,22],max_i:9,maximum:[4,9,10,20,22],me373:[2,4,14,22],mean:[2,10,13,14,15,18,19,20,21,22,23],meant:5,measur:9,mechan:8,member:5,merg:[5,23],method:[1,8,9,11,15,16,17,19,20,23,24],middl:[2,14,19,20],midpoint:[13,17],might:[2,10,13,20,21,23],miss:4,mix:3,mod:20,mode:2,model:9,modifi:[2,10,17],modul:5,modulu:19,moment:[2,19],momentum:4,more:[2,3,4,5,9,10,11,13,14,19,21,22,23],most:[5,14],mostli:13,motion:2,move:[2,3,5,14],movi:15,much:[3,5,13],multipl:[5,14,16,19],multipli:[2,6,20,23],must:[13,15],mybook:5,n_1:3,n_max:20,nabla:14,name:10,natur:2,navier:[4,14],navig:5,nearli:13,necessari:[4,14],need:[2,3,4,5,7,10,13,14,15,17,19,20,21,22,23],neighbor:14,neither:17,neq:[2,6,14,18,20],neumann:3,newer:14,next:[3,5,10,11,13,14,17,21],nice:5,niemeyek:[2,4],nine:14,nodal:15,node:[3,14,18],non:13,nondimension:[4,10],none:23,nonlinear:[10,13],normal:[3,4,14,21],northwest:[10,14],notabl:14,notat:3,note:[4,13,14,19,20,21],notebook:[7,15],notic:[10,13,19,20,23],now:[2,3,4,5,6,7,10,11,13,14,19,20,21,22,23],num:[4,14],num_it:14,num_iter_g:14,num_iter_jac:14,num_point:14,number:[2,3,4,9,10,11,14,15,20,22],numer:[3,4,9,13,14,16,17,24],nums_g:14,nums_jac:14,object:14,obtain:[2,3,10,13,15,19,21,22],obviou:[2,6,9,11],obvious:4,occur:3,odd:[17,23],ode45:[2,4,10],off:[2,4,9,10,11],offer:[2,10],often:5,old:[3,14],omega:[2,17,20,21,22],omega_1:2,omega_2:2,omega_squar:2,onc:[2,6,14,19,21],one:[2,4,5,10,13,14,15,16,19,20,21,22],ones:[5,14],onli:[2,4,10,14,19,21,23],open:[5,7],oper:14,opposit:2,option:[3,5,10,17],order:[1,2,4,11,12,13,14,16,18,23],ordinari:[4,12,15,23],oregon:8,org:4,origin:[3,4,6,10,20],orthogon:20,oscil:2,other:[3,5,10,11,13,14,15,17,19,20,22,23],otherwis:[2,4],our:[2,3,4,5,9,10,11,13,14,15,18,19,20,21,22,23],out:[5,15,19],outer:18,outlin:5,output:14,outsid:[3,14],over:[4,6,9,10,11,13,15,17,20,22],overal:[5,10,14,17,19,20,21],overdamp:21,overlap:5,overshoot:20,own:[5,14],packag:7,page:5,pain:3,parabol:16,parabolic_anim:15,parabolic_implicit_anim:15,parabolic_unstable_anim:15,paramet:13,parenthes:15,part:[11,17,18,21,23],partial:[3,4,14,15],particular:[2,3,10,13,19],particularli:4,past:[13,15],path:7,pattern:[2,23],pde:[4,16],pdf:19,per:10,perform:[3,11,13,14,17],perimet:3,period:[2,14,17,21],phenomena:20,physic:[2,13,14],pick:4,piec:5,piecewis:20,pin:2,pip:7,place:[5,14],plan:5,pleas:[5,19],plot:[2,3,4,10,11,13,14,15,19,20,22],plug:[2,19,21,22,23],point:[2,3,4,5,9,10,11,14,15,19,21,23],poisson:14,polynomi:[2,11],popul:3,popular:10,posit:[4,19],possibl:[5,21],potenti:[4,9],power:10,practic:22,prahl:19,predict:10,predictor:[10,22],prefix:5,present:3,pressur:14,prevent:[4,13],previous:19,prime:[2,3,4,6,10,13,17,18,19,20,21,22,23],princip:18,print:4,probabl:4,problem:[3,4,5,6,10,11,13,23,24],proce:2,procedur:[19,21],process:[3,5,9,19],product:[14,23],professor:19,profil:5,program:9,progress:5,project:[2,4,14,22],prompt:7,properti:2,proport:13,proportion:19,propos:5,provid:[2,3,10,22],psi:4,pure:[2,9],purpos:[15,17],put:[2,5,19,21,23],python:[4,7],quad:[2,4,6,10,13,14,17,18,19,20,21,22,23],quadrat:[11,14],quantiti:[9,13,22],question:[3,5],quickli:14,r2019_b:7,r_1:18,r_2:18,r_i:18,r_n:18,rad:2,radial:18,radiu:18,rand:3,random:[3,4,9],rang:[6,11,13],rare:9,rate:[3,21],rather:[3,4,13,14,15],read:19,readi:5,real:[3,9,21],realist:14,realiti:[9,14],realli:[5,14,22],rearrang:[3,6,14,15,18,23],reason:14,recal:[2,3,10,19,20,21,22],recogn:[4,6,11,20,23],recommend:7,recreat:5,recurs:[2,3,10,13,14,15,17,18,22,23],red:11,redefin:23,reduc:[3,10,11,13,14,17],reduct:21,ref:5,refactor:5,refer:[3,5,11,14,19],referenc:5,regard:13,region:14,regular:[3,10],rel:13,relat:[2,4,5,10,12,13,14,20,23],relationship:14,reli:[3,7],remain:[13,14,20,22],rememb:[2,10,21],remind:5,render:5,repeat:[3,4,14,15,17,21],replac:[3,14,18,22,23],repmat:20,repres:[2,3,9,10,14,15,18,20],represent:[2,9,17,18,20],requir:[4,10,13,14,16],resembl:20,reshap:14,residu:14,resolut:[2,14],reson:13,respect:9,respons:17,rest:20,result:[2,10,11,13,14,15,17,20],revers:2,review:5,rewrit:15,rgb2ind:15,rho:15,right:[2,3,4,5,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],rightarrow:[2,3,4,13,14,17,19,20,21,22,23],ring:20,rise:10,rk4:10,robin:3,robust:13,root:[2,21],rope:19,round:9,rule:[5,9,10,13,17,23],run:[5,7,10],rung:[4,13,17],safe:5,safeti:13,sai:[3,10,14,19],same:[2,3,4,5,10,11,14,20,21,22],satisfi:[2,4,18,23],saw:[3,13,22],sawtooth:20,scheme:[11,13,22],scss:5,sec:14,second:[2,4,7,10,14,21,22],section:[3,5,21],see:[2,3,4,5,6,10,11,13,14,15,19,20,22,23],seen:3,segment:[2,3,11,14],select:5,self:5,sens:14,separ:[2,3,15,22],seri:[3,9,10,19],set:[2,3,4,5,14,15,21],setup:[3,7],sever:5,shape:19,share:[2,20],sharp:20,shell:7,shift:23,shooting_rh:4,shortli:4,should:[4,5,7,10,13,14,17,20,21,23],show:[2,4,13,14,15,17,19],shown:[10,14,17,20],side:[3,13,14,19,20,21],sigma:[3,13,17],sign:5,signific:9,significantli:11,sim:[4,10],similar:[4,5,13,14,15,22,23],similarli:14,simpl:[6,10,13,14,19],simpler:[4,11,17],simpli:2,simplif:[9,19],simplifi:[2,3,9,14,20,21,23],simpson:[9,10],simultan:3,sin:[2,17,18,20,21,22,23],sinc:[14,20,22],sine:[20,23],singl:[5,14,22,23],sinh:19,sinusoid:[2,20,21],sit:5,site:5,situat:[3,5],size:[2,3,9,10,11,13,14,15,17,18,22],skip:[19,20],slice:3,slightli:[2,3,5,10,15,16],slope:[10,13,14,19],slow:14,small:[2,14,15],smaller:[10,11,13,14,15],solid:14,solut:[2,3,4,9,11,13,15,16,20,21,22],solution1:4,solution2:4,solution3:4,solutionn:21,solv:[1,2,4,6,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24],solveabl:4,some:[2,3,5,9,10,13,14,15,17,18,19,20,21],somebodi:5,someth:[4,10],somewher:14,soon:10,sophist:11,sort:3,sourc:9,southeast:22,space:[5,14,15],spatial:[15,18],specif:[5,19,20],specifi:[3,10,14,17],split:5,spring:[9,17],sprintf:[13,20],sqrt:[2,4,6,11,19,21],squar:20,squarewav:20,stabil:[2,12,15],stabl:[13,15,17,22],stage:[10,22],stai:13,stand:3,standard:[5,6,23],start:[2,3,4,5,10,14,19,20,22,23],state:[8,14,17,20],steadi:[14,20],stemmrolemodel:5,stencil:[14,15],step:[2,3,4,5,9,10,11,13,14,15,17,18,19,22],step_siz:14,still:[3,11],stitch:5,stoke:[4,14],stop:14,store:[4,22],straight:11,straightforward:3,strategi:13,stream:4,streamfunct:4,string:[14,19],stuck:15,sty:5,style:14,stylist:5,submit:5,subplot:[2,13,20],substack:20,substitut:[3,17,22],subtl:5,subtract:3,success:3,suffici:4,sum:[2,9,11,20,23],sum_:[14,17,20,23],superposit:2,support:[2,5],sure:5,surfac:3,surround:14,svg:4,sym:4,symbol:[4,5],sympi:4,sync:2,syntax:10,system:[3,4,13,14,17,18,21,22],systemat:9,t_1:[3,15],t_b:3,t_i:[3,13,15,17,18],t_n:[3,15,18],tab:5,tabl:[4,9,21],tag:5,take:[3,4,5,10,14,20,21,23],taken:4,talk:[13,19,22],tan:6,tanh:19,target:[4,5,14,18],task:5,taught:8,taylor:[3,10,23],teach:19,team:5,techniqu:[21,23],tell:[2,5,7,14],temperatur:[3,14,15,18],tempt:5,tend:14,term:[3,9,10,13,15,18,20,21,23],termin:7,test:5,text:[2,3,4,5,6,10,11,13,14,15,17,18,19,20,21,22,23],textbook:9,than:[3,4,10,11,13,14,15,22],thei:[2,5,13,14,22],them:[2,3,5,10,14,19],themselv:20,theorem:3,therefor:[10,13,18,19],thermal:[3,14,15,18],theta:3,thi:[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24],thick:[3,4,18],thing:[2,3,14,22],think:[5,19],third:[3,4,11],those:[5,13,14,19,20,21],though:[2,14,19],three:[2,3,4,11,16,20,21,22],threshold:13,thu:[3,10,13,17,20,21,22,23],thumb:13,tic:14,tild:9,time:[2,5,13,14,15,17,19,20,22],times_g:14,times_jac:14,tip:3,titl:[2,13,20],toc:[5,14],togeth:[5,19,21,23],toler:[3,14],too:[2,10,15,22],top:[5,14],total:14,toward:4,tradeoff:13,transfer:[15,18],transform:[6,14,21,22],transpos:14,trapezoid:[9,10],treat:3,trentu:19,tri:[4,15],trial:4,trickier:3,trigonometr:20,trivial:[2,19],truli:4,truncat:[9,10,17],tst:5,two:[2,3,4,5,9,10,14,17,18,21,22,23],type:[2,3,16],typic:20,typo:9,u_1:21,u_2:21,u_bottom:14,u_i:17,u_left:14,u_old:14,u_right:14,u_squar:14,u_top:14,unbound:[13,23],uncertainti:9,uncondition:[13,15,17,22],under:[7,11],underdamp:21,undershoot:20,understand:3,underwai:5,undetermin:[17,20,22],unexpect:14,unfeas:14,unforc:[19,21],unfortun:[2,6],uniform:14,uninform:4,uniqu:[2,5],unit:5,univers:8,unknown:[3,4,10,14,19,21,22,23],unphys:[13,15],unreason:14,unstabl:[13,15,17],unsteadi:15,until:14,updat:[5,14],upper:[2,14],upward:19,usabl:[14,22],use:[2,3,4,5,7,9,10,11,13,14,15,17,18,20,21,22,23],useabl:13,used:[2,3,4,5,11,12,14,15,17,20,21,23],useful:[5,9,20,23],user:[2,4,5,14,22],uses:[5,10,13,14],using:[2,3,4,5,6,7,9,10,11,14,15,17,18,19,20,21,22,23],usual:20,v4n1:19,valid:23,valu:[2,3,4,9,11,13,14,15,16,17,18,19,20,22,23,24],vari:[14,15],variabl:[3,4,14,16,17,18,19,22,23],vdot:14,vector:[3,9,14,22],veloc:[2,4,19],veri:[7,10,13,15],versa:13,version:[3,5,7],vertic:2,via:[3,6,19,21,22],vice:13,viscos:4,visibl:[2,10],visual:14,vmatrix:[2,21,22],volum:3,volumetr:3,wai:[2,3,5,10,13,14,17,19,20,23],wait:13,wall:3,want:[2,5,7,10,13,14,17,21],waveform:17,webpag:5,websit:8,welcom:5,well:[4,10,13,15,21,22],what:[2,3,4,5,11,13,14,15,17,18,19,20,21,22,23],when:[2,3,5,6,10,11,13,14,17,21],whenev:7,where:[2,3,4,5,6,10,11,13,14,15,16,17,18,19,20,21,22,23],whether:[3,13,17,20,23],which:[2,3,4,5,6,7,9,10,11,13,14,15,16,18,19,21,23],whichev:3,whole:[5,17],why:[5,17],width:3,wiki:4,wikimedia:4,within:[5,23],without:3,won:5,word:[5,10,11,13,14,15,22],work:[2,3,4,5,9,10,13,14,15,19,20,21,22],workflow:5,would:[2,3,4,10,14,17,18,19,21,23],wouldn:3,write:[2,5,14,15,16,17,18],writemod:15,written:13,wrong:[4,9],wronksian:21,x_1:[2,3,10,14,21,22],x_2:[2,3,14,22],x_3:3,x_4:3,x_5:3,x_a:19,x_b:19,x_end:10,x_exact:[10,13],x_i:[2,3,10,11,14,15,22],x_j:14,x_n:[3,10,14],x_start:10,xaxisloc:20,xlabel:[2,4,14,15,20,22],xline:11,y_0:[3,21],y_1:[2,3,4,10,19,21,22],y_2:[2,3,4,19,21,22],y_3:[2,3,4],y_4:[2,3],y_5:3,y_a:19,y_b:19,y_exact:[10,13,22],y_h:[17,20,21],y_half:10,y_i:[2,3,9,10,13,17,22],y_j:14,y_n:[2,3,18],y_old:3,y_p:10,yaxisloc:20,ydir:2,yep:14,yes:23,yet:5,ylabel:[2,4,14,15,20,22],ylim:[4,20],yline:11,you:[2,4,6,7,10,11,13,15,17,18,19,21,23],young:5,your:[4,5,7,17,18],yourself:5,youtu:5,z1p:22,z2p:22,z_1:[17,18,22],z_2:[17,18,22],zero:[2,3,4,9,13,14,15,19,20,21,22,23],zsh:7},titles:["<no title>","4. Boundary Value Problems","4.3. Eigenvalue problems","4.2. Finite difference method","4.1. Shooting Method","Contributing to Jupyter Book","1. Solutions to 1st-order ODEs","Installing Jupyter for Matlab","Introduction","2.2. Error","2.3. Numerical Solutions of 1st-order ODEs","2.1. Numerical integrals","2. Numerical Methods","2.4. Stability and Stiffness","5.1. Elliptic PDEs","5.2. Parabolic PDEs","5. Partial Differential Equations","Sample Quiz 2 problems: IVPs","Sample Quiz 3 problems: BVPs","3.1. Analytical Solutions to 2nd-order ODEs","3.4. Fourier Series","3.2. Initial-Value Problems","3.3. Numerical methods for 2nd-order ODEs","3.5. Power Series Solutions","3. Second-order Ordinary Differential Equations"],titleterms:{"1st":[6,10],"2nd":[19,20,21,22],"function":20,"try":7,BCs:3,ODE:[4,19,20],ODEs:[3,6,10,19,21,22],The:5,Using:3,absolut:9,analysi:[13,17],analyt:[17,19],applic:20,backward:[13,17,22],beam:2,board:5,book:5,both:19,boundari:[1,2,3,14],buckl:2,bvp:[3,18],catenari:19,cauchi:21,central:3,chang:5,coeffic:21,coeffici:[20,21],command:5,condit:[2,3,14],constant:21,continu:21,contribut:5,contributor:5,convers:5,cramer:22,damp:20,deriv:[3,14],differ:[2,3,18],differenti:[16,24],direct:[6,19],eigenvalu:[2,18],ellipt:14,equat:[16,21,24],error:9,euler:[10,13,17,21,22],even:20,exampl:[2,3,4,5,13,14,19,20,21,22,23],explicit:15,fall:19,fin:3,finit:[3,18],forward:[10,13,22],fourier:[17,20],fourth:10,gauss:14,gener:6,get:2,github:5,have:19,heat:[3,14],heun:[10,22],higher:22,homogen:19,implement:3,implicit:15,independ:19,inhomogen:[20,21],initi:21,instal:7,integr:[6,11,19],introduct:8,issu:5,iter:14,ivp:17,jacobi:14,join:5,jupyt:[5,7],kutta:[10,22],label:5,larg:14,line:5,linear:[4,6],linearli:19,linux:7,maco:7,major:14,make:5,map:14,mass:[2,20,22],matlab:[3,7],method:[3,4,10,12,13,14,18,21,22],midpoint:10,mileston:5,neumann:14,nonlinear:[3,4,6],numer:[2,10,11,12,22],object:19,odd:20,ode45:22,order:[3,6,10,17,19,20,21,22,24],ordinari:24,out:7,packag:5,parabol:15,paramet:21,part:19,partial:16,pde:[14,15],period:20,plate:14,power:23,problem:[1,2,14,17,18,19,21,22],project:5,properti:[20,23],pull:5,python:5,quiz:[17,18],radiat:3,recogn:5,rectangular:20,reduct:19,redux:14,rel:9,repositori:5,request:5,row:14,rule:[11,22],rung:[10,22],sampl:[17,18],satisfi:19,scheme:15,second:[3,17,24],seidel:14,separ:6,seri:[17,20,23],shoot:[4,18],simpson:11,solut:[6,10,14,17,18,19,23],solv:3,spring:[2,20,22],squar:14,ssg:5,stabil:[13,17],stiff:13,structur:5,substitut:19,system:[2,20],templat:5,thank:5,through:[3,5],tool:5,transfer:[3,14],trapezoid:11,two:19,undamp:20,understand:5,undetermin:21,valu:[1,21],variabl:6,variat:21,veri:14,wave:20,websit:5,window:7,you:5}}) \ No newline at end of file +Search.setIndex({docnames:["content/LICENSE","content/bvps/boundary-value-problems","content/bvps/eigenvalue","content/bvps/finite-difference","content/bvps/shooting-method","content/contributing","content/first-order","content/installing-jupyter","content/intro","content/numerical-methods/error","content/numerical-methods/initial-value-methods","content/numerical-methods/integrals","content/numerical-methods/numerical-methods","content/numerical-methods/stability","content/pdes/elliptic","content/pdes/parabolic","content/pdes/partial-differential-equations","content/quizzes/quiz2-IVPs","content/quizzes/quiz3-BVPs","content/second-order/analytical","content/second-order/fourier-series","content/second-order/initial-value-problems","content/second-order/numerical-methods","content/second-order/power-series","content/second-order/second-order"],envversion:{"sphinx.domains.c":2,"sphinx.domains.changeset":1,"sphinx.domains.citation":1,"sphinx.domains.cpp":3,"sphinx.domains.index":1,"sphinx.domains.javascript":2,"sphinx.domains.math":2,"sphinx.domains.python":2,"sphinx.domains.rst":2,"sphinx.domains.std":2,"sphinx.ext.intersphinx":1,sphinx:56},filenames:["content/LICENSE.md","content/bvps/boundary-value-problems.md","content/bvps/eigenvalue.ipynb","content/bvps/finite-difference.ipynb","content/bvps/shooting-method.ipynb","content/contributing.md","content/first-order.md","content/installing-jupyter.ipynb","content/intro.md","content/numerical-methods/error.md","content/numerical-methods/initial-value-methods.ipynb","content/numerical-methods/integrals.ipynb","content/numerical-methods/numerical-methods.md","content/numerical-methods/stability.ipynb","content/pdes/elliptic.ipynb","content/pdes/parabolic.ipynb","content/pdes/partial-differential-equations.md","content/quizzes/quiz2-IVPs.md","content/quizzes/quiz3-BVPs.md","content/second-order/analytical.ipynb","content/second-order/fourier-series.ipynb","content/second-order/initial-value-problems.ipynb","content/second-order/numerical-methods.ipynb","content/second-order/power-series.md","content/second-order/second-order.md"],objects:{},objnames:{},objtypes:{},terms:{"000":[2,14],"000007":11,"0004":10,"0007":10,"000821":11,"001":3,"0016":10,"005":14,"0125":14,"019":4,"0225":17,"025":14,"047":2,"0472":2,"050":10,"055":10,"068":22,"082126":11,"091":2,"0944":2,"099":22,"100":[2,3,11,14,20],"1000":[4,14,20],"1000x":11,"1056":4,"1061":14,"10762":14,"125":3,"13421":14,"156":14,"160":14,"16t":17,"16y":17,"16y_h":17,"16z_1":17,"1790":20,"1dt":20,"1e3":4,"1e4":4,"1st":[2,4,13,17,18,19,22],"200":[2,4,15],"20067":14,"2025":14,"228":22,"242":22,"250":20,"256":15,"291":14,"2dt":20,"2dx":19,"2nd":[1,2,3,4,16,17,23,24],"2t_i":[3,18],"2u_":14,"2y_i":[2,3],"3048":14,"3566":4,"373":8,"37378":14,"375":3,"3803":14,"3rd":[4,22],"3x3":[4,14],"3y_i":3,"400":14,"46922":4,"46957":4,"48301":4,"4a_n":23,"4th":[10,13,17],"4u_":14,"4xy":23,"4z_1":18,"500":20,"54587":4,"564":14,"5717":14,"5z_2":22,"625":3,"6553":4,"69037":14,"6a_n":23,"6z_1":22,"7181":14,"732":2,"746211":11,"7468":[6,11],"746818":11,"746824":11,"7x3":4,"875":3,"8y_h":17,"8z_2":17,"99951":4,"break":[4,5],"case":[2,3,4,10,11,13,14,15,19,20,21,22,23],"final":[3,19,20],"float":9,"function":[2,3,4,6,9,10,11,13,14,17,18,19,21,22],"import":[2,3,4,14,19,21],"int":[6,11,19,20,21],"long":[13,14,22],"new":[2,3,4,5,7,14,19,21],"return":[13,14],"static":[2,5],"transient":[14,15,20],"true":[3,4,21,23],"try":[2,4,5,13,14,18,19,21,23],"while":[3,4,5,6,11,14,17,20,22],Adding:3,BCs:18,But:[2,3,4,13,14,20],For:[2,3,4,5,6,9,10,13,14,15,17,18,19,20,21,22,23],ODE:[2,3,6,10,13,17,18,21,22,23],ODEs:[1,2,4,18,20,23,24],One:[19,20,22],That:[10,11,19,20],The:[2,3,4,10,13,14,15,16,17,18,19,20,21,22,23],Then:[2,3,6,10,13,17,19,20,21,22,23],There:[10,14,17,23],These:[2,5,9,14],Use:[5,17,18,23],Using:[4,14,17,20],With:[2,15],Yes:23,_____:4,_______:4,_________:4,_build:5,_includ:5,_sass:5,a_0:[17,20,23],a_1:[2,19,20,23],a_2:[2,19,20,23],a_3:23,a_4:23,a_5:23,a_6:23,a_7:23,a_c:3,a_i:2,a_m:[20,23],a_n:[17,18,20,23],abl:[2,3,4,14,20],about:[2,5,7,11,13,14,15,19,20,22,23],abov:[2,3,5,6,10,11,14,15,19,20,21,22],abs:[2,3,4,10,11,14,22],absolut:13,acceler:19,accept:5,account:5,accumul:[10,17],accur:[2,3,10,11,14,17,22],accuraci:[3,11,13,17],across:9,action:10,activ:7,actual:[2,3,10,13,14,19,20],add:5,added:[5,14],adding:20,addit:5,adher:5,adjust:[4,10],advantag:23,aejm:19,affect:11,after:[6,9,14,20,21],again:[2,19,20,23],against:[2,10,22],air:3,algebra:[3,19],algorithm:[4,14],align:[2,3,4,6,10,11,13,14,15,17,18,19,20,21,22,23],all:[2,3,4,5,6,9,10,13,14,15,18,20,21,22,23],allow:[5,10,11,13,23],almost:13,along:[3,12,14],alpha:[14,15,20,21],alreadi:[3,4,5,7,21,22],also:[2,3,4,5,9,10,11,13,14,15,16,17,19,20,21,22],although:13,alwai:[13,23],ambient:3,among:5,amount:14,amplif:[13,17],amplitud:2,anaconda:7,analysi:3,analyt:[2,10,11,20,21,23,24],analyz:2,ani:[3,5,9,13,14,17,18,19,22],anim:15,annular:18,annulu:18,anonym:10,anoth:[3,5,10,13,19,23],ans:4,answer:[5,10,18,22],anyon:5,aperiod:21,app:7,appear:14,append:15,appli:[2,3,9,10,11,13,14,15,17,18,19,23],applic:7,appreci:5,approach:[2,3,4,6,11,14,16,17,19,20,21,23],appropri:[2,14],approx:[3,10,11,13,14],approxim:[2,3,9,10,11,14,15,17,18],arbitrari:14,arbitrarili:[15,23],arctan:6,area:[2,3,11],aren:[5,14],around:[2,5,10,14,20],arrai:[4,14,22],ask:[5,21],asset:5,assign:5,associ:[2,14,18,21],assum:[2,4,7,9,18,21],assumpt:9,astar:2,attempt:4,autom:[4,14],automat:10,avail:[5,14],averag:[10,14],avoid:13,awai:[3,13],awesom:5,axi:[4,11,15,19,20,21],axmx:21,b_1:[14,20,22],b_2:[14,20,22],b_i:14,b_n:[14,17,20],back:[9,23],backward:[3,14,18],bad:3,balanc:3,baptist:20,bar:19,base:[2,3,4,5,10,13,14,15,17,18,19],bash:7,basi:19,beam:19,becaus:[2,3,4,10,13,14,20,21,23],becom:[2,13,14,15],been:[5,13,14,20],befor:[5,7,13,14,19],begin:[2,3,4,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],behav:[2,10,13,22],behavior:[13,14],being:[4,9,14,15,23],below:[5,15],bernoulli:6,beta:[20,21],better:[10,11,20],between:[9,10,11,13,14,17,19],beyond:14,big:[5,20],bit:[2,3,10,14,21],black:11,blasiu:4,blasius_rh:4,blog:5,blow:[13,15,22],bmatrix:[2,3,14,17,22],bodi:[2,3],bold:[5,22],book:[2,4,8,14],book_templ:5,both:[2,4,5,13,14,15,20,22,23],bottom:14,bound:23,boundari:[4,15,18,19,23,24],box:[2,9],branch:5,bring:23,brk:5,broken:9,bstar:2,bug:5,build:5,built:10,bvp:[1,2,4,24],c_1:[3,17,19,20,21,23],c_2:[3,17,19,20,21,23],c_p:15,calcul:[2,13,14,18,20],call:[3,7,10],can:[2,3,4,5,6,9,10,11,13,14,15,16,18,19,20,21,22,23],cancel:[],candid:21,cannot:[2,4,9,11,13,14,17,19,21,23],cantilev:19,care:14,carri:5,categor:[16,19],categori:[16,19,21],cauchi:19,caus:[13,20],cdot:[3,4,14,17,23],center:14,centerlin:18,central:[14,15,18],certain:[2,23],chain:19,chang:[3,6,14,23],chao:13,chapter:[1,12,16,24],characteris:21,characterist:[2,16,19,21],chat:5,chatterje:19,check:[3,4,5,14,23],choic:[13,14,15],choos:[3,4,10,15,17,18],chose:15,chosen:15,classic:[14,15],clc:[2,3,4,14],clear:[2,3,4,10,13,14,15,22],clearli:[14,17],cli:5,close:[2,5,6,10,11,14,15,20],code:[5,9,10,17],coeffic:23,coeffici:[2,3,14,17,18,19,22,23],collabor:5,color:11,colorbar:14,column:[14,22],combin:[2,3,5,14,15,18,20,21,23],come:[3,7,9,11,21],comfort:15,command:7,comment:5,common:[4,21],compact:10,compactli:3,compar:[2,9,10,13,22],comparison:10,complet:[5,20],complex:[2,10,13],complic:[2,3,10,21],compon:[4,20],comput:[9,13,14],computation:10,concept:[4,9,12],cond:3,conda:7,condens:2,condit:[1,4,10,13,15,17,18,19,21,22,23],condition:[13,17],conduct:[3,5,14,18],configur:5,confirm:[2,5,14,20,22],connect:[2,5],conserv:4,consid:[2,3,4,5,6,10,13,14,19,20,23],constant:[3,6,15,16,18,19,23],constrain:[1,15],constraint:[4,19,23],construct:[3,14,20],contain:[3,5],contant:13,content:[2,4,5,14],continu:[3,4,5,7,9,14,23],contour:14,contourf:14,control:[3,5,10],conv:3,convect:[3,18],conveni:[3,14],convent:5,converg:[3,4,14],convert:[2,3,4,5,14,22],coordin:4,copi:5,core:5,corner:[14,20],correct:[4,10,14],corrector:[10,22],correspond:[2,3,23],cos:[2,6,17,18,20,21,22,23],cosh:[19,21],cosin:[20,21,23],cost:[13,14],could:[3,4,5,20,21,22],coupl:22,cours:3,cover:[5,13],cramer:17,creat:[2,3,4,5,7,10,11,14,22],criterion:[13,15],critic:[2,21],cross:3,crude:2,css:5,cubic:14,current:5,curv:11,cut:10,damp:[21,22],data:9,date:5,ddot:14,deal:3,decai:[13,15,20,21],decompos:18,defin:[2,3,4,5,9,10,11,13,14,17,19,22,23],definit:[10,11],deflect:[2,19],degre:11,del:14,delaytim:15,deliber:15,delta:[2,3,4,9,10,11,13,14,15,17,18,22],demonstr:22,depend:[3,5,6,13,16,18,19,21,22],deriv:[2,4,6,10,13,15,16,18,19,22,23],describ:[5,12,14,18,19],design:5,desir:14,det:[2,22],detail:[5,19],determin:[2,5,14,22],develop:5,devic:9,diagram:2,did:[4,14],diff:4,differ:[4,5,7,14,15,16,17,19,21,22],differenti:[3,4,9,12,15],difficult:5,diffus:[14,15],digit:9,dimens:[14,16],dimension:[14,15],dimensionless:4,dimensionlesss:4,direct:[4,14,15],directli:[2,4,6,13,14,17],dirichlet:[3,14],discontinu:[14,20,21,23],discrep:20,discret:[3,9,14],discuss:[3,4,5,6,10,14,19,22,23],disp:[7,14],displac:[2,17,19,20,22],distanc:[15,18,19],distinct:5,distribut:[3,5,18],divid:[2,3],doc:[5,22],document:5,doe:[2,3,4,11,13,14,19,21,22],doesn:14,doing:[2,4,5,7],domain:[2,3,4,10,13,14,15,17],don:[2,3,5,14],dot:[10,23],down:2,downsid:10,downward:19,dqw4w9wgxcq:5,draft:5,drag:19,due:[3,9,14,19,20],dummi:[14,23],dxdt:2,dydx:4,dynam:[13,14],dz_1:22,dz_2:22,dzdt:22,each:[2,3,5,9,10,11,13,14,17,19,20,22,23],earli:5,easi:[5,7],easier:[3,4,5],easiest:3,easili:[13,20],edit:5,effect:5,eig:2,eigenfunct:[2,18],eight:14,either:[2,14],electrostat:14,element:[9,14],elimin:[3,17],ellipt:16,els:[2,3,5,14,15],elseif:[2,3,14,15],empti:5,encount:[2,3,14],encourag:5,end:[2,3,4,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],engin:[7,8,13],enh:5,enhanc:5,enough:4,ensur:4,enter:3,enthusiast:5,entir:[5,9,23],entri:5,environ:7,epsilon:[3,14],equal:[2,15,22],equat:[2,3,4,6,9,10,11,12,13,14,15,17,18,19,20,22,23],equiv:3,equival:[3,17,21,22],erf:[6,11],err:2,error:[2,3,5,6,7,10,11,12,13,17,22],especi:5,essenti:[2,14],eta:4,etc:5,euclid:19,euler:[2,4,15,18,19],evalu:4,even:[9,13,14,17,23],eventu:[13,14],ever:20,everi:[5,6],everyon:5,exact:[2,3,6,9,10,11,13,20,22],exactli:9,exampl:[6,7,9,10,15],except:[13,20,22],excit:5,exhibit:[13,16],exist:[4,5],exp:[10,11,13,19,22],expand:20,expans:[3,10,23],expect:[2,5,13,14,17,22],expens:10,experi:5,experienc:19,explain:5,explan:5,explic:10,explicit:[10,13],explicitli:13,explor:[5,15],exponenti:[14,15,21],express:[18,20,22,23],extend:3,extern:7,fact:9,factor:[6,11,13,17],fail:[14,23],fairli:[2,10],fall:[10,21],famili:10,familiar:4,famou:4,far:[3,9,10,14,22,23],fashion:[2,22],faster:[3,14,22],fastest:5,favorit:19,feel:5,few:[3,5,14,19,20],fewer:14,fig:15,figur:[4,14,15],file:[2,4,5,10,14,22],filenam:15,fin:18,find:[2,3,4,5,6,10,11,13,14,17,18,19,20,21,23],fine:10,finer:2,finit:[2,9,14,15,23],first:[2,3,4,5,6,10,11,12,13,14,15,17,18,19,20,21,22,23],fit:[5,11],five:[3,9,14,15],fix:[3,5,14,19],fluid:[3,4,14],focu:[13,14,19,22],focus:[1,5,16,21,24],folder:5,follow:[3,5,14,15,20,21],forc:[2,15,17,19,20,21,22],fork:5,form:[3,6,10,11,14,17,18,19,20,21,23],formal:14,format:[5,10],formula:[2,3,9,10,11,13,14,15,17,18,21,22,23],fortun:4,forward:[3,4,5,14,15,17,18],found:[5,14,20,21],four:[2,3,10,11,14],fourier:15,fprintf:[2,3,4,10,11,14,22],frac:[2,3,4,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],frame2im:15,free:[2,4,5],frequenc:[2,17,20,21],frequent:14,frictionless:9,from:[3,4,5,6,9,11,13,14,15,17,18,21],front:5,full:[3,10,19,21,23],fulli:19,function_nam:10,fundament:[17,20],further:[3,14],gase:9,gather:[2,13,18,22],gave:14,gca:[2,20],gcf:15,gener:[2,3,5,10,13,14,15,16,17,19,20,21,22,23],geometri:3,georg:9,geq:[13,15],get:[3,4,5,7,10,13,14,17,19,20,21,22],getfram:15,ghost:[3,14],gibb:20,gif:15,git:5,give:[2,3,5,10,14,15,17,18,19,20,21,22],given:[2,3,4,6,10,11,14,15,17,18,19,20,21,22],glanc:5,global:[9,10,13,17],goal:[3,5],goe:[4,13],going:[3,5,14],gone:22,good:[3,5,14,20,22],govern:[2,3,15,19],grab:21,gradient:14,gradual:20,graviti:19,great:5,greater:15,grid:[2,3,14],group:5,grow:[5,13],guess1:4,guess2:4,guess3:4,guess:[3,4,14,18],guid:[5,7],guidelin:5,had:[4,14],half:[14,15],hand:[3,13,14,19,20,21,22,23],handl:[3,14],hang:19,happen:[2,13,15],harmon:[17,20],has:[2,5,9,13,14,19,23],have:[2,3,4,5,6,7,9,10,13,14,15,20,21,22],head:5,header:5,heat:[15,18],heat_equ:14,heat_equation_gaussseidel:14,heat_equation_jacobi:14,help:[5,14],henc:20,here:[2,5,14,17,19],heun:13,higher:[3,10,11,17,20],his:19,hold:[2,3,10,11,13,14,22],homogen:[3,17,20,21,23],homogenen:20,honor:19,hopefulli:5,horizont:19,how:[2,3,5,9,10,11,13,14,19,20,21,22,23],howev:[2,14,19],html:5,http:[4,5,19],human:9,hyperbol:[16,21],idea:14,ideal:9,identifi:[2,13,14,20,23],imaginari:[3,14,21],imind:15,immedi:5,implement:[5,13,18,22],implicit:[13,17],improv:5,imwrit:15,includ:[5,14,21,23,24],incorpor:[2,3,10,13,14],increas:[2,10,11,13,14,20],increment:[10,17],independ:[2,18,21],index:[10,14,20,23],indic:[14,22],individu:5,inf:15,infinit:[2,4,9,10,20,23],infinitesim:3,inform:[2,4,5,10,14,15],infti:[2,3,4,17,18,20,23],inhomogen:17,init:7,init_print:4,initi:[2,3,4,10,13,14,15,17,18,19,22,23,24],inlin:10,inner:18,input:[9,14,17],insert:[2,4,20,21,22,23],insid:23,instabl:13,instead:[2,4,9,10,11,14,22],instruct:5,insul:3,int_0:[17,20],int_1:20,int_:[17,19],int_a:[10,11],integ:20,integr:[2,4,10,12,13,15,20,21,23],interact:[8,15],interest:[2,13],interestingli:14,interior:[3,14],intermedi:10,intern:11,interpol:[4,11,18],intertia:19,interv:9,introduc:[4,9,10],inv:[3,22],involv:[2,3,5,13,15,16,19,21,22,23],ipynb:5,isn:[3,22],isol:22,issu:15,ital:5,iter:[3,4],its:[3,5,10,13,14],itself:19,ittak:14,ivp:24,javascript:5,jean:20,jmatlab:7,job:11,joe:19,joseph:20,jupyt:[8,15],jupyter_book:5,just:[2,3,4,10,18,19,20,21,23],k_0:21,k_1:[2,10,20,21],k_2:[2,10,20,21],k_3:10,k_4:10,k_n:21,keep:[3,5],kernel:7,kick:4,kij:14,kijm1:14,kijp1:14,kim1j:14,kind:[3,9],kinemat:4,kip1j:14,know:[2,3,5,13,18,19,21,23],known:[3,6,10,11,13,14,15,17,19,20],kutta:[4,13,17],kyle:[14,22],label:14,lambda:[2,17,18,21],lambda_1:[2,18,20,21],lambda_2:[2,20,21],lambda_p:18,laminar:4,laminar_boundary_layer_schem:4,laplac:[14,21],larg:[4,15],larger:[13,14,15,22],largest:13,last:[3,18,20],later:[3,9,14,20],layer:4,ldot:[2,14,15,17,18,20,21,23],lead:[4,6,11,13,15,21],least:5,left:[2,3,4,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],leftarrow:18,legend:[3,10,11,13,14,22],length:[2,3,10,11,13,14,15,19,20,22],leq:[3,4,10,13,15,17,22],less:[10,13,14],let:[2,3,4,5,6,10,11,13,14,15,19,20,21,22,23],level:14,like:[2,3,4,6,10,11,13,14,15,17,19,20,21,22],lim_:3,limit:[13,15],line:11,linear:[3,10,14,16,17,19,22],linearli:21,linestyl:11,link:5,linspac:[2,10,11,13,19,20,22],list:5,littl:5,load:2,local:[9,10,17],locat:[3,10,14,15,18,22],log:[14,19],loglog:14,longer:3,look:[2,3,5,6,10,11,14,15,19,20,21],loop:[3,4,5,10,13],loopcount:15,loss:9,lot:3,m_1:[2,21],m_2:[2,21],m_z:2,machin:9,made:[3,19],magnitud:[3,10,11],mai:[2,3,6,7,9,10,11,13,14,15,21],main:[3,5,9,10,22],maintain:5,make:[3,4,7,9,10,11,14,15],manag:7,mani:[2,9],manual:[2,4],march:10,markdown:5,markerfacecolor:10,mass:[4,9,17,19],mass_spr:22,master:5,match:[2,3,4,13,14,20,21],materi:3,mathbf:[2,3,14,22],mathcal:[3,10,14,22],mathemat:9,matlab:[2,10,14,15,17,22],matlab_kernel:7,matlab_r2019b:7,matric:14,matrix:[2,3,14],max:[3,10,14,22],max_i:9,maximum:[4,9,10,20,22],me373:[2,4,14,22],mean:[2,10,13,14,15,18,19,20,21,22,23],meant:5,measur:9,mechan:8,member:5,merg:[5,23],method:[1,8,9,11,15,16,17,19,20,23,24],middl:[2,14,19,20],midpoint:[13,17],might:[2,10,13,20,21,23],miss:4,mix:3,mod:20,mode:2,model:9,modifi:[2,10,17],modul:5,modulu:19,moment:[2,19],momentum:4,more:[2,3,4,5,9,10,11,13,14,19,21,22,23],most:[5,14],mostli:13,motion:2,move:[2,3,5,14],movi:15,much:[3,5,13],multipl:[5,14,16,19],multipli:[2,6,20,23],must:[13,15],mybook:5,n_1:3,n_max:20,nabla:14,name:10,natur:2,navier:[4,14],navig:5,nearli:13,necessari:[4,14],need:[2,3,4,5,7,10,13,14,15,17,19,20,21,22,23],neighbor:14,neither:17,neq:[2,6,14,18,20],neumann:3,newer:14,next:[3,5,10,11,13,14,17,21],nice:5,niemeyek:[2,4],nine:14,nodal:15,node:[3,14,18],non:13,nondimension:[4,10],none:23,nonlinear:[10,13],normal:[3,4,14,21],northwest:[10,14],notabl:14,notat:3,note:[4,13,14,19,20,21],notebook:[7,15],notic:[10,13,19,20,23],now:[2,3,4,5,6,7,10,11,13,14,19,20,21,22,23],num:[4,14],num_it:14,num_iter_g:14,num_iter_jac:14,num_point:14,number:[2,3,4,9,10,11,14,15,20,22],numer:[3,4,9,13,14,16,17,24],nums_g:14,nums_jac:14,object:14,obtain:[2,3,10,13,15,19,21,22],obviou:[2,6,9,11],obvious:4,occur:3,odd:[17,23],ode45:[2,4,10],off:[2,4,9,10,11],offer:[2,10],often:5,old:[3,14],omega:[2,17,20,21,22],omega_1:2,omega_2:2,omega_squar:2,onc:[2,6,14,19,21],one:[2,4,5,10,13,14,15,16,19,20,21,22],ones:[5,14],onli:[2,4,10,14,19,21,23],open:[5,7],oper:14,opposit:2,option:[3,5,10,17],order:[1,2,4,11,12,13,14,16,18,23],ordinari:[4,12,15,23],oregon:8,org:4,origin:[3,4,6,10,20],orthogon:20,oscil:2,other:[3,5,10,11,13,14,15,17,19,20,22,23],otherwis:[2,4],our:[2,3,4,5,9,10,11,13,14,15,18,19,20,21,22,23],out:[5,15,19],outer:18,outlin:5,output:14,outsid:[3,14],over:[4,6,9,10,11,13,15,17,20,22],overal:[5,10,14,17,19,20,21],overdamp:21,overlap:5,overshoot:20,own:[5,14],packag:7,page:5,pain:3,parabol:16,parabolic_anim:15,parabolic_implicit_anim:15,parabolic_unstable_anim:15,paramet:13,parenthes:15,part:[11,17,18,21,23],partial:[3,4,14,15],particular:[2,3,10,13,19],particularli:4,past:[13,15],path:7,pattern:[2,23],pde:[4,16],pdf:19,per:10,perform:[3,11,13,14,17],perimet:3,period:[2,14,17,21],phenomena:20,physic:[2,13,14],pick:4,piec:5,piecewis:20,pin:2,pip:7,place:[5,14],plan:5,pleas:[5,19],plot:[2,3,4,10,11,13,14,15,19,20,22],plug:[2,19,21,22,23],point:[2,3,4,5,9,10,11,14,15,19,21,23],poisson:14,polynomi:[2,11],popul:3,popular:10,posit:[4,19],possibl:[5,21],potenti:[4,9],power:10,practic:22,prahl:19,predict:10,predictor:[10,22],prefix:5,present:3,pressur:14,prevent:[4,13],previous:19,prime:[2,3,4,6,10,13,17,18,19,20,21,22,23],princip:18,print:4,probabl:4,problem:[3,4,5,6,10,11,13,23,24],proce:2,procedur:[19,21],process:[3,5,9,19],product:[14,23],professor:19,profil:5,program:9,progress:5,project:[2,4,14,22],prompt:7,properti:2,proport:13,proportion:19,propos:5,provid:[2,3,10,22],psi:4,pure:[2,9],purpos:[15,17],put:[2,5,19,21,23],python:[4,7],quad:[2,4,6,10,13,14,17,18,19,20,21,22,23],quadrat:[11,14],quantiti:[9,13,22],question:[3,5],quickli:14,r2019_b:7,r_1:18,r_2:18,r_i:18,r_n:18,rad:2,radial:18,radiu:18,rand:3,random:[3,4,9],rang:[6,11,13],rare:9,rate:[3,21],rather:[3,4,13,14,15],read:19,readi:5,real:[3,9,21],realist:14,realiti:[9,14],realli:[5,14,22],rearrang:[3,6,14,15,18,23],reason:14,recal:[2,3,10,19,20,21,22],recogn:[4,6,11,20,23],recommend:7,recreat:5,recurs:[2,3,10,13,14,15,17,18,22,23],red:11,redefin:23,reduc:[3,10,11,13,14,17],reduct:21,ref:5,refactor:5,refer:[3,5,11,14,19],referenc:5,regard:13,region:14,regular:[3,10],rel:13,relat:[2,4,5,10,12,13,14,20,23],relationship:14,reli:[3,7],remain:[13,14,20,22],rememb:[2,10,21],remind:5,render:5,repeat:[3,4,14,15,17,21],replac:[3,14,18,22,23],repmat:20,repres:[2,3,9,10,14,15,18,20],represent:[2,9,17,18,20],requir:[4,10,13,14,16],resembl:20,reshap:14,residu:14,resolut:[2,14],reson:13,respect:9,respons:17,rest:20,result:[2,10,11,13,14,15,17,20],revers:2,review:5,rewrit:15,rgb2ind:15,rho:15,right:[2,3,4,5,6,9,10,11,13,14,15,16,17,18,19,20,21,22,23],rightarrow:[2,3,4,13,14,17,19,20,21,22,23],ring:20,rise:10,rk4:10,robin:3,robust:13,root:[2,21],rope:19,round:9,rule:[5,9,10,13,17,23],run:[5,7,10],rung:[4,13,17],safe:5,safeti:13,sai:[3,10,14,19],same:[2,3,4,5,10,11,14,20,21,22],satisfi:[2,4,18,23],saw:[3,13,22],sawtooth:20,scheme:[11,13,22],scss:5,sec:14,second:[2,4,7,10,14,21,22],section:[3,5,21],see:[2,3,4,5,6,10,11,13,14,15,19,20,22,23],seen:3,segment:[2,3,11,14],select:5,self:5,sens:14,separ:[2,3,15,22],seri:[3,9,10,19],set:[2,3,4,5,14,15,21],setup:[3,7],sever:5,shape:19,share:[2,20],sharp:20,shell:7,shift:23,shooting_rh:4,shortli:4,should:[4,5,7,10,13,14,17,20,21,23],show:[2,4,13,14,15,17,19],shown:[10,14,17,20],side:[3,13,14,19,20,21],sigma:[3,13,17],sign:5,signific:9,significantli:11,sim:[4,10],similar:[4,5,13,14,15,22,23],similarli:14,simpl:[6,10,13,14,19],simpler:[4,11,17],simpli:2,simplif:[9,19],simplifi:[2,3,9,14,20,21,23],simpson:[9,10],simultan:3,sin:[2,17,18,20,21,22,23],sinc:[14,20,22],sine:[20,23],singl:[5,14,22,23],sinh:19,sinusoid:[2,20,21],sit:5,site:5,situat:[3,5],size:[2,3,9,10,11,13,14,15,17,18,22],skip:[19,20],slice:3,slightli:[2,3,5,10,15,16],slope:[10,13,14,19],slow:14,small:[2,14,15],smaller:[10,11,13,14,15],solid:14,solut:[2,3,4,9,11,13,15,16,20,21,22],solution1:4,solution2:4,solution3:4,solutionn:21,solv:[1,2,4,6,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24],solveabl:4,some:[2,3,5,9,10,13,14,15,17,18,19,20,21],somebodi:5,someth:[4,10],somewher:14,soon:10,sophist:11,sort:3,sourc:9,southeast:22,space:[5,14,15],spatial:[15,18],specif:[5,19,20],specifi:[3,10,14,17],split:5,spring:[9,17],sprintf:[13,20],sqrt:[2,4,6,11,19,21],squar:20,squarewav:20,stabil:[2,12,15],stabl:[13,15,17,22],stage:[10,22],stai:13,stand:3,standard:[5,6,23],start:[2,3,4,5,10,14,19,20,22,23],state:[8,14,17,20],steadi:[14,20],stemmrolemodel:5,stencil:[14,15],step:[2,3,4,5,9,10,11,13,14,15,17,18,19,22],step_siz:14,still:[3,11],stitch:5,stoke:[4,14],stop:14,store:[4,22],straight:11,straightforward:3,strategi:13,stream:4,streamfunct:4,string:[14,19],stuck:15,sty:5,style:14,stylist:5,submit:5,subplot:[2,13,20],substack:20,substitut:[3,17,22],subtl:5,subtract:3,success:3,suffici:4,sum:[2,9,11,20,23],sum_:[14,17,20,23],superposit:2,support:[2,5],sure:5,surfac:3,surround:14,svg:4,sym:4,symbol:[4,5],sympi:4,sync:2,syntax:10,system:[3,4,13,14,17,18,21,22],systemat:9,t_1:[3,15],t_b:3,t_i:[3,13,15,17,18],t_n:[3,15,18],tab:5,tabl:[4,9,21],tag:5,take:[3,4,5,10,14,20,21,23],taken:4,talk:[13,19,22],tan:6,tanh:19,target:[4,5,14,18],task:5,taught:8,taylor:[3,10,23],teach:19,team:5,techniqu:[21,23],tell:[2,5,7,14],temperatur:[3,14,15,18],tempt:5,tend:14,term:[3,9,10,13,15,18,20,21,23],termin:7,test:5,text:[2,3,4,5,6,10,11,13,14,15,17,18,19,20,21,22,23],textbook:9,than:[3,4,10,11,13,14,15,22],thei:[2,5,13,14,22],them:[2,3,5,10,14,19],themselv:20,theorem:3,therefor:[10,13,18,19],thermal:[3,14,15,18],theta:3,thi:[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24],thick:[3,4,18],thing:[2,3,14,22],think:[5,19],third:[3,4,11],those:[5,13,14,19,20,21],though:[2,14,19],three:[2,3,4,11,16,20,21,22],threshold:13,thu:[3,10,13,17,20,21,22,23],thumb:13,tic:14,tild:9,time:[2,5,13,14,15,17,19,20,22],times_g:14,times_jac:14,tip:3,titl:[2,13,20],toc:[5,14],togeth:[5,19,21,23],toler:[3,14],too:[2,10,15,22],top:[5,14],total:14,toward:4,tradeoff:13,transfer:[15,18],transform:[6,14,21,22],transpos:14,trapezoid:[9,10],treat:3,trentu:19,tri:[4,15],trial:4,trickier:3,trigonometr:20,trivial:[2,19],truli:4,truncat:[9,10,17],tst:5,two:[2,3,4,5,9,10,14,17,18,21,22,23],type:[2,3,16],typic:20,typo:9,u_1:21,u_2:21,u_bottom:14,u_i:17,u_left:14,u_old:14,u_right:14,u_squar:14,u_top:14,unbound:[13,23],uncertainti:9,uncondition:[13,15,17,22],under:[7,11],underdamp:21,undershoot:20,understand:3,underwai:5,undetermin:[17,20,22],unexpect:14,unfeas:14,unforc:[19,21],unfortun:[2,6],uniform:14,uninform:4,uniqu:[2,5],unit:5,univers:8,unknown:[3,4,10,14,19,21,22,23],unphys:[13,15],unreason:14,unstabl:[13,15,17],unsteadi:15,until:14,updat:[5,14],upper:[2,14],upward:19,usabl:[14,22],use:[2,3,4,5,7,9,10,11,13,14,15,17,18,20,21,22,23],useabl:13,used:[2,3,4,5,11,12,14,15,17,20,21,23],useful:[5,9,20,23],user:[2,4,5,14,22],uses:[5,10,13,14],using:[2,3,4,5,6,7,9,10,11,14,15,17,18,19,20,21,22,23],usual:20,v4n1:19,valid:23,valu:[2,3,4,9,11,13,14,15,16,17,18,19,20,22,23,24],vari:[14,15],variabl:[3,4,14,16,17,18,19,22,23],vdot:14,vector:[3,9,14,22],veloc:[2,4,19],veri:[7,10,13,15],versa:13,version:[3,5,7],vertic:2,via:[3,6,19,21,22],vice:13,viscos:4,visibl:[2,10],visual:14,vmatrix:[2,21,22],volum:3,volumetr:3,wai:[2,3,5,10,13,14,17,19,20,23],wait:13,wall:3,want:[2,5,7,10,13,14,17,21],waveform:17,webpag:5,websit:8,welcom:5,well:[4,10,13,15,21,22],what:[2,3,4,5,11,13,14,15,17,18,19,20,21,22,23],when:[2,3,5,6,10,11,13,14,17,21],whenev:7,where:[2,3,4,5,6,10,11,13,14,15,16,17,18,19,20,21,22,23],whether:[3,13,17,20,23],which:[2,3,4,5,6,7,9,10,11,13,14,15,16,18,19,21,23],whichev:3,whole:[5,17],why:[5,17],width:3,wiki:4,wikimedia:4,within:[5,23],without:3,won:5,word:[5,10,11,13,14,15,22],work:[2,3,4,5,9,10,13,14,15,19,20,21,22],workflow:5,would:[2,3,4,10,14,17,18,19,21,23],wouldn:3,write:[2,5,14,15,16,17,18],writemod:15,written:13,wrong:[4,9],wronksian:21,x_1:[2,3,10,14,21,22],x_2:[2,3,14,22],x_3:3,x_4:3,x_5:3,x_a:19,x_b:19,x_end:10,x_exact:[10,13],x_i:[2,3,10,11,14,15,22],x_j:14,x_n:[3,10,14],x_start:10,xaxisloc:20,xlabel:[2,4,14,15,20,22],xline:11,y_0:[3,21],y_1:[2,3,4,10,19,21,22],y_2:[2,3,4,19,21,22],y_3:[2,3,4],y_4:[2,3],y_5:3,y_a:19,y_b:19,y_exact:[10,13,22],y_h:[17,20,21],y_half:10,y_i:[2,3,9,10,13,17,22],y_j:14,y_n:[2,3,18],y_old:3,y_p:10,yaxisloc:20,ydir:2,yep:14,yes:23,yet:5,ylabel:[2,4,14,15,20,22],ylim:[4,20],yline:11,you:[2,4,6,7,10,11,13,15,17,18,19,21,23],young:5,your:[4,5,7,17,18],yourself:5,youtu:5,z1p:22,z2p:22,z_1:[17,18,22],z_2:[17,18,22],zero:[2,3,4,9,13,14,15,19,20,21,22,23],zsh:7},titles:["<no title>","4. Boundary Value Problems","4.3. Eigenvalue problems","4.2. Finite difference method","4.1. Shooting Method","Contributing to Jupyter Book","1. Solutions to 1st-order ODEs","Installing Jupyter for Matlab","Introduction","2.2. Error","2.3. Numerical Solutions of 1st-order ODEs","2.1. Numerical integrals","2. Numerical Methods","2.4. Stability and Stiffness","5.1. Elliptic PDEs","5.2. Parabolic PDEs","5. Partial Differential Equations","Sample Quiz 2 problems: IVPs","Sample Quiz 3 problems: BVPs","3.1. Analytical Solutions to 2nd-order ODEs","3.4. Fourier Series","3.2. Initial-Value Problems","3.3. Numerical methods for 2nd-order ODEs","3.5. Power Series Solutions","3. Second-order Ordinary Differential Equations"],titleterms:{"1st":[6,10],"2nd":[19,20,21,22],"function":20,"try":7,BCs:3,ODE:[4,19,20],ODEs:[3,6,10,19,21,22],The:5,Using:3,absolut:9,analysi:[13,17],analyt:[17,19],applic:20,backward:[13,17,22],beam:2,board:5,book:5,both:19,boundari:[1,2,3,14],buckl:2,bvp:[3,18],catenari:19,cauchi:21,central:3,chang:5,coeffic:21,coeffici:[20,21],command:5,condit:[2,3,14],constant:21,continu:21,contribut:5,contributor:5,convers:5,cramer:22,damp:20,deriv:[3,14],differ:[2,3,18],differenti:[16,24],direct:[6,19],eigenvalu:[2,18],ellipt:14,equat:[16,21,24],error:9,euler:[10,13,17,21,22],even:20,exampl:[2,3,4,5,13,14,19,20,21,22,23],explicit:15,fall:19,fin:3,finit:[3,18],forward:[10,13,22],fourier:[17,20],fourth:10,gauss:14,gener:6,get:2,github:5,have:19,heat:[3,14],heun:[10,22],higher:22,homogen:19,implement:3,implicit:15,independ:19,inhomogen:[20,21],initi:21,instal:7,integr:[6,11,19],introduct:8,issu:5,iter:14,ivp:17,jacobi:14,join:5,jupyt:[5,7],kutta:[10,22],label:5,larg:14,line:5,linear:[4,6],linearli:19,linux:7,maco:7,major:14,make:5,map:14,mass:[2,20,22],matlab:[3,7],method:[3,4,10,12,13,14,18,21,22],midpoint:10,mileston:5,neumann:14,nonlinear:[3,4,6],numer:[2,10,11,12,22],object:19,odd:20,ode45:22,order:[3,6,10,17,19,20,21,22,24],ordinari:24,out:7,packag:5,parabol:15,paramet:21,part:19,partial:16,pde:[14,15],period:20,plate:14,power:23,problem:[1,2,14,17,18,19,21,22],project:5,properti:[20,23],pull:5,python:5,quiz:[17,18],radiat:3,recogn:5,rectangular:20,reduct:19,redux:14,rel:9,repositori:5,request:5,row:14,rule:[11,22],rung:[10,22],sampl:[17,18],satisfi:19,scheme:15,second:[3,17,24],seidel:14,separ:6,seri:[17,20,23],shoot:[4,18],simpson:11,solut:[6,10,14,17,18,19,23],solv:3,spring:[2,20,22],squar:14,ssg:5,stabil:[13,17],stiff:13,structur:5,substitut:19,system:[2,20],templat:5,thank:5,through:[3,5],tool:5,transfer:[3,14],trapezoid:11,two:19,undamp:20,understand:5,undetermin:21,valu:[1,21],variabl:6,variat:21,veri:14,wave:20,websit:5,window:7,you:5}}) \ No newline at end of file