next up previous contents
Next: A Practical Example: One-Dimensional Up: Components of MHD Numerical Previous: Time step

Computation scheme

Now, it seems that we can start to perform numerical simulations. This is true, but we will not obtain acceptable results without knowing something about computation schemes.

Computation schemes are the ways that we use to push the evolution of the system. Different schemes are developed to overcome certain numerical difficulties that we meet in numerical simulation. Here we choose a typical one dimensional fluid dynamics equation as an example.


\begin{displaymath}\frac{\partial u}{\partial t}+\frac{\partial f}{\partial x}=0
\end{displaymath} (61)

where u is the system variable, f is the flux.

The naive way to differentiate this equation is


\begin{displaymath}\frac{u^{n+1}_i-u^n_i}{\Delta t}+\frac{f^n_{i+1}-f^n_{i-1}}{2\Delta x}=0
\end{displaymath} (62)

where uni is the u value of space position i, time n. From this we can get the evolution of the variable u


\begin{displaymath}u^{n+1}_i=u^n_i-\frac{\Delta t}{2\Delta x}(f^n_{i+1}-f^n_{i-1})
\end{displaymath} (63)

Though this naive way is the most natural way to compute the time evolution of simulation system, later we will see that it is far from satisfactory in a practical simulation. Following are some other schemes developed to overcome the numerical difficulty of the naive scheme.


First order scheme: Rusanov scheme

$u^{n+1}_i=u^n_i-sign(u^n_i)(\Delta t/2\Delta x)$

(fni+1-fni-1)

$+\frac{1}{4}((\alpha^n_{i+1}+\alpha^n_i)(u^n_{i+1}-u^n_{i})$

\begin{displaymath}-(\alpha^n_i+\alpha^n_{i-1})(u^n_{i}-u^n_{i-1}))
\end{displaymath} (64)

$\alpha^n_i=\omega(\Delta t/\Delta x)(u+c)^n_i$


Second order scheme: Lax-Wendroff scheme


\begin{displaymath}u^{n+\frac{1}{2}}_{i+\frac{1}{2}}=
\frac{1}{2}(u^n_{i+1}+u^n_i)-(\Delta t/\Delta x)
(f^n_{i+1}-f^n_i)
\end{displaymath} (65)


\begin{displaymath}u^{n+1}_i=u^n_i-(\Delta t/\Delta x)(f^{n+\frac{1}{2}}_{i+
\frac{1}{2}}-f^{n+\frac{1}{2}}_{i-\frac{1}{2}})
\end{displaymath} (66)



Other schemes, such as upwind, MacCormack, hybrid, etc. are also common schemes in numerical simulation.


next up previous contents
Next: A Practical Example: One-Dimensional Up: Components of MHD Numerical Previous: Time step