Skip to content

Commit 46068fb

Browse files
committed
update readme.md for benchmarks
1 parent a19cc6b commit 46068fb

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

benchmarks/readme.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -32,42 +32,42 @@ We consider three ODE problems for direct time-domain integration with `solve_iv
3232

3333
1. **Bremer Eq. 237**
3434
Taken from Bremer (2018), Eq. (237).
35-
``` math
35+
```math
3636
y''(x) + \lambda^2\bigl[1 - x^2 \cos(3x)\bigr]\,y(x) \;=\; 0,
37-
```
37+
```
3838
for $x \in [-1,\,1]$. The initial conditions are chosen as
39-
```math
39+
```math
4040
y(-1) = 0,
4141
\quad
4242
y'(-1) = \lambda,
43-
```
43+
```
4444
so that the problem depends strongly on $\lambda$. As $\lambda$ grows, the equation becomes increasingly oscillatory (high-frequency), which can be challenging for general-purpose ODE solvers.
4545

4646
2. **Airy Equation**
4747
The classical Airy equation can be written as
48-
```math
48+
```math
4949
y''(x) - x \, y(x) \;=\; 0,
50-
```
50+
```
5151
for $x \in [0,\,100]$. The Airy functions $\mathrm{Ai}$ and $\mathrm{Bi}$ form the fundamental solutions; however, here we pose initial conditions in terms of these functions at $x = 0$ and integrate out to $x = 100$. Numerically, one can write this as
52-
```math
52+
```math
5353
y'(x) = \begin{bmatrix} y_1'(x) \\ y_2'(x) \end{bmatrix}
5454
= \begin{bmatrix}
5555
y_2(x) \\
5656
-\,x\,y_1(x)
5757
\end{bmatrix}.
58-
```
58+
```
5959

6060
3. **Stiff Problem**
6161
We label this “Stiff” because it includes large and rapidly changing coefficients. The equation is
62-
```math
62+
```math
6363
y''(t) \;+\; (t + 21)\,y'(t) \;+\; 21\,t\,y(t) \;=\; 0,
64-
```
64+
```
6565
integrated on $[0,\,200]$ with initial conditions
66-
```math
66+
```math
6767
y(0) = 0,
6868
\quad
6969
y'(0) = 1.
70-
```
70+
```
7171
The combination of the $t\,y'(t)$ and $t\,y(t)$ terms can produce stiffness as $t$ grows large.
7272

7373
In each case, we compare several solvers:
@@ -133,9 +133,9 @@ In the Schrödinger equation benchmark, we consider a one-dimensional potential
133133
with some mass parameter $m$ (here $m=0.5$), seeking the bound-state energies for large quantum numbers. We do so by implementing a **shooting method**:
134134

135135
1. We define the ODE
136-
```math
136+
```math
137137
\psi''(x) \;=\; -\,2m\;\bigl[E - V(x)\bigr]\;\psi(x),
138-
```
138+
```
139139
which is a form of the time-independent Schrödinger equation.
140140
2. For each guess $E$ of the energy, we integrate from a left boundary to the midpoint and from a right boundary to the midpoint.
141141
3. We then minimize the mismatch in derivatives at the midpoint to find an accurate bound-state energy.

0 commit comments

Comments
 (0)