Total variation diminishing

From HandWiki
Short description: Property of discretization schemes used to solve hyperbolic partial differential equations

In numerical methods, total variation diminishing (TVD) is a property of certain discretization schemes used to solve hyperbolic partial differential equations. The most notable application of this method is in computational fluid dynamics. The concept of TVD was introduced by Ami Harten.[1]

Model equation

In systems described by partial differential equations, such as the following hyperbolic advection equation,

[math]\displaystyle{ \frac{\partial u}{\partial t} + a\frac{\partial u}{\partial x} = 0, }[/math]

the total variation (TV) is given by

[math]\displaystyle{ TV(u(\cdot,t)) = \int \left| \frac{\partial u}{\partial x} \right| \mathrm{d}x , }[/math]

and the total variation for the discrete case is,

[math]\displaystyle{ TV(u^n) = TV(u(\cdot,t^n)) = \sum_j \left| u_{j+1}^n - u_j^n \right| . }[/math]

where [math]\displaystyle{ u_{j}^n=u(x_{j},t^n) }[/math].

A numerical method is said to be total variation diminishing (TVD) if,

[math]\displaystyle{ TV \left( u^{n+1}\right) \leq TV \left( u^{n}\right) . }[/math]

Characteristics

A numerical scheme is said to be monotonicity preserving if the following properties are maintained:

  • If [math]\displaystyle{ u^{n} }[/math] is monotonically increasing (or decreasing) in space, then so is [math]\displaystyle{ u^{n+1} }[/math].

Harten 1983 proved the following properties for a numerical scheme,

  • A monotone scheme is TVD, and
  • A TVD scheme is monotonicity preserving.

Application in CFD

In Computational Fluid Dynamics, TVD scheme is employed to capture sharper shock predictions without any misleading oscillations when variation of field variable “[math]\displaystyle{ \phi }[/math]” is discontinuous. To capture the variation fine grids ([math]\displaystyle{ \Delta x }[/math] very small) are needed and the computation becomes heavy and therefore uneconomic. The use of coarse grids with central difference scheme, upwind scheme, hybrid difference scheme, and power law scheme gives false shock predictions. TVD scheme enables sharper shock predictions on coarse grids saving computation time and as the scheme preserves monotonicity there are no spurious oscillations in the solution.

Discretisation

Consider the steady state one-dimensional convection diffusion equation,

[math]\displaystyle{ \nabla \cdot (\rho \mathbf{u} \phi)\,= \nabla \cdot (\Gamma \nabla \phi)+S_{\phi}\; }[/math],

where [math]\displaystyle{ \rho }[/math] is the density, [math]\displaystyle{ \mathbf{u} }[/math] is the velocity vector, [math]\displaystyle{ \phi }[/math] is the property being transported, [math]\displaystyle{ \Gamma }[/math] is the coefficient of diffusion and [math]\displaystyle{ S_{\phi} }[/math] is the source term responsible for generation of the property [math]\displaystyle{ \phi }[/math].

Making the flux balance of this property about a control volume we get,

[math]\displaystyle{ \int_A \mathbf {n} \cdot (\rho\mathbf{u}\phi) \, \mathrm{d}A = \int_A \mathbf{n} \cdot (\Gamma \nabla \phi) \, \mathrm{d}A+ \int_{CV} S_\phi \, \mathrm{d}V }[/math] [math]\displaystyle{ \; }[/math]

Here [math]\displaystyle{ \mathbf {n} }[/math] is the normal to the surface of control volume.

Ignoring the source term, the equation further reduces to:

[math]\displaystyle{ (\rho \mathbf {u} \phi A)_r - (\rho \mathbf {u} \phi A)_l = \left(\Gamma A \frac{\partial \phi}{\partial x}\right)_r-\left(\Gamma A \frac{\partial \phi}{\partial x}\right)_l }[/math]
A picture showing the control volume with velocities at the faces,nodes and the distance between them, where 'P' is the node at the center.

Assuming

[math]\displaystyle{ \frac{\partial \phi}{\partial x}= \frac{\delta \phi}{\delta x} }[/math] and [math]\displaystyle{ A_r = A_l, }[/math]

The equation reduces to

[math]\displaystyle{ (\rho \mathbf {u} \phi)_r - (\rho \mathbf {u} \phi)_l \,= \left( \frac{\Gamma}{\delta x} \delta \phi\right)_r - \left( \frac{\Gamma}{\delta x} \delta \phi\right)_l. }[/math]

Say,

[math]\displaystyle{ F_r=(\rho \mathbf{u})_r ;\qquad F_l=(\rho \mathbf{u})_l; }[/math]
[math]\displaystyle{ D_l = \left(\frac {\Gamma}{\delta x}\right)_l ;\qquad D_r =\left(\frac {\Gamma}{\delta x}\right)_r; }[/math]

From the figure:

[math]\displaystyle{ \delta \phi _r = \phi_R -\phi_P ;\qquad\delta x_r = x_{PR}; }[/math]
[math]\displaystyle{ \delta \phi _l = \phi_P -\phi_L ;\qquad\delta x_l = x_{LP}; }[/math]

The equation becomes:[math]\displaystyle{ F_r \phi_r - F_l \phi_l = D_r (\phi _R -\phi _P)-D_l(\phi _P - \phi _L); }[/math] The continuity equation also has to be satisfied in one of its equivalent forms for this problem:

[math]\displaystyle{ (\rho \mathbf {u})_r -(\rho \mathbf {u})_l\,=0\ \ \Longleftrightarrow\ \ F_r-F_l=0\ \ \Longleftrightarrow\ F_r=F_l=F. }[/math]

Assuming diffusivity is a homogeneous property and equal grid spacing we can say

[math]\displaystyle{ \Gamma _l=\Gamma _r; \qquad \delta x_{LP}=\delta x_{PR} = \delta x, }[/math]

we get[math]\displaystyle{ D_l=D_r=D. }[/math]The equation further reduces to[math]\displaystyle{ (\phi_r-\phi_l)\cdot F=D\cdot(\phi_R-2\phi_P+\phi_L). }[/math]The equation above can be written as[math]\displaystyle{ (\phi_r-\phi_l)\cdot P=(\phi_R-2\phi_P+\phi_L) }[/math]where [math]\displaystyle{ P }[/math] is the Péclet number

[math]\displaystyle{ P=\frac{F}{D}=\frac{\rho \mathbf{u} \delta x}{\Gamma}. }[/math]

TVD scheme

Total variation diminishing scheme[2][3] makes an assumption for the values of [math]\displaystyle{ \phi_r }[/math] and [math]\displaystyle{ \phi_l }[/math] to be substituted in the discretized equation as follows:

[math]\displaystyle{ \phi_r\cdot P=\frac{1}{2}(P+|P|)[f_r^+\phi_R+(1-f_r^+)\phi_L]+\frac{1}{2}(P-|P|)[f_r^-\phi_P+(1-f_r^-)\phi_{RR}] }[/math]
[math]\displaystyle{ \phi_l\cdot P=\frac{1}{2}(P+|P|)[f_l^+\phi_P+(1-f_l^+)\phi_{LL}]+\frac{1}{2}(P-|P|)[f_l^-\phi_L+(1-f_l^-)\phi_R] }[/math]

Where [math]\displaystyle{ P }[/math] is the Péclet number and [math]\displaystyle{ f }[/math] is the weighing function to be determined from,

[math]\displaystyle{ f=f\left(\frac{\phi_U-\phi_{UU}}{\phi_D-\phi_{UU}}\right) }[/math]

where [math]\displaystyle{ U }[/math] refers to upstream, [math]\displaystyle{ UU }[/math] refers to upstream of [math]\displaystyle{ U }[/math] and [math]\displaystyle{ D }[/math] refers to downstream.

Note that [math]\displaystyle{ f^+ }[/math] is the weighing function when the flow is in positive direction (i.e., from left to right) and [math]\displaystyle{ f^- }[/math] is the weighing function when the flow is in the negative direction from right to left. So,

[math]\displaystyle{ \begin{align} & f_r^+\text{ is a function of }\left(\dfrac{\phi_P-\phi_L}{\phi_R-\phi_L}\right), \\[10pt] & f_r^-\text{ is a function of }\left(\dfrac{\phi_R-\phi_{RR}}{\phi_P-\phi_{RR}}\right), \\[10pt] & f_l^+\text{ is a function of }\left(\dfrac{\phi_L-\phi_{LL}}{\phi_P-\phi_{LL}}\right),\text{ and} \\[10pt] & f_l^-\text{ is a function of }\left(\dfrac{\phi_P-\phi_R}{\phi_L-\phi_R}\right). \end{align} }[/math]

If the flow is in positive direction then, Péclet number [math]\displaystyle{ P }[/math] is positive and the term [math]\displaystyle{ (P-|P|)= 0 }[/math], so the function [math]\displaystyle{ f^- }[/math] won't play any role in the assumption of [math]\displaystyle{ \phi_r }[/math] and [math]\displaystyle{ \phi_l }[/math]. Likewise when the flow is in negative direction, [math]\displaystyle{ P }[/math] is negative and the term [math]\displaystyle{ (P+|P|)= 0 }[/math], so the function [math]\displaystyle{ f^+ }[/math] won't play any role in the assumption of [math]\displaystyle{ \phi_r }[/math] and [math]\displaystyle{ \phi_r }[/math].

It therefore takes into account the values of property depending on the direction of flow and using the weighted functions tries to achieve monotonicity in the solution thereby producing results with no spurious shocks.

Limitations

Monotone schemes are attractive for solving engineering and scientific problems because they do not produce non-physical solutions. Godunov's theorem proves that linear schemes which preserve monotonicity are, at most, only first order accurate. Higher order linear schemes, although more accurate for smooth solutions, are not TVD and tend to introduce spurious oscillations (wiggles) where discontinuities or shocks arise. To overcome these drawbacks, various high-resolution, non-linear techniques have been developed, often using flux/slope limiters.

See also

References

  1. Harten, Ami (1983), "High resolution schemes for hyperbolic conservation laws", J. Comput. Phys. 49 (2): 357–393, doi:10.1016/0021-9991(83)90136-5, Bibcode1983JCoPh..49..357H 
  2. Versteeg, H.K.; Malalasekera, W. (2007). An introduction to computational fluid dynamics : the finite volume method (2nd ed.). Harlow: Prentice Hall. ISBN 9780131274983. 
  3. Blazek, Jiri (2001). Computational fluid dynamics : Principles and Applications (1st ed.). London: Elsevier. ISBN 9780080430096. 

Further reading

  • Hirsch, C. (1990), Numerical Computation of Internal and External Flows, Vol 2, Wiley.
  • Laney, C. B. (1998), Computational Gas Dynamics, Cambridge University Press.
  • Toro, E. F. (1999), Riemann Solvers and Numerical Methods for Fluid Dynamics, Springer-Verlag.
  • Tannehill, J. C., Anderson, D. A., and Pletcher, R. H. (1997), Computational Fluid Mechanics and Heat Transfer, 2nd Ed., Taylor & Francis.
  • Wesseling, P. (2001), Principles of Computational Fluid Dynamics, Springer-Verlag.
  • Anil W. Date Introduction to Computational Fluid Dynamics, Cambridge University Press.