Recon1d_PPM_H4_2019 module reference
Piecewise Parabolic Method 1D reconstruction with h4 interpolation for edges
This implementation of PPM follows White and Adcroft 2008 [91], with cells resorting to PCM for extrema including first and last cells in column. This scheme differs from Colella and Woodward, 1984 [18], in the method of first estimating the fourth-order accurate edge values. This uses numerical expressions refactored at the beginning of 2019. The first and last cells are always limited to PCM.
Data Types
PPM reconstruction following White and Adcroft, 2008 |
Functions/Subroutines
Initialize a 1D PPM_H4_2019 reconstruction for n cells |
|
Calculate a 1D PPM_H4_2019 reconstructions based on h(:) and u(:) |
|
Determine a one-sided 4th order polynomial fit of u to the data points for the purposes of specifying edge values, as described in the appendix of White and Adcroft JCP 2008. |
|
Value of PPM_H4_2019 reconstruction at a point in cell k [A] |
|
Derivative of PPM_H4_2019 reconstruction at a point in cell k [A] |
|
Average between xa and xb for cell k of a 1D PPM reconstruction [A] |
|
Deallocate the PPM_H4_2019 reconstruction |
|
Checks the PPM_H4_2019 reconstruction for consistency |
|
Runs PPM_H4_2019 reconstruction unit tests and returns True for any fails, False otherwise |
Detailed Description
Type Documentation
- type, extends(Recon1d) :: PPM_H4_2019
PPM reconstruction following White and Adcroft, 2008
The source for the methods ultimately used by this class are:
init() *locally defined
reconstruct() *locally defined
average() *locally defined
f() *locally defined
dfdx() *locally defined
check_reconstruction() *locally defined
unit_tests() *locally defined
destroy() *locally defined
remap_to_sub_grid() -> recon1d_type.remap_to_sub_grid()
init_parent() -> init()
reconstruct_parent() -> reconstruct()
- Parameters
ul
Left edge value [A]
ur
Right edge value [A]
Functions/Subroutine Documentation
- subroutine init(this, n, h_neglect, check)
Initialize a 1D PPM_H4_2019 reconstruction for n cells
- Parameters
this [out]
This reconstruction
n [in]
Number of cells in this column
h_neglect [in]
A negligibly small width used in cell reconstructions [H]
check [in]
If true, enable some consistency checking
- subroutine reconstruct(this, h, u)
Calculate a 1D PPM_H4_2019 reconstructions based on h(:) and u(:)
- Parameters
this [inout]
This reconstruction
h [in]
Grid spacing (thickness) [typically H]
u [in]
Cell mean values [A]
hMinFrac
A minimum fraction for min(h)/sum(h) [nondim]
- subroutine end_value_h4(dz, u, Csys)
Determine a one-sided 4th order polynomial fit of u to the data points for the purposes of specifying edge values, as described in the appendix of White and Adcroft JCP 2008.
- Parameters
dz [in]
The thicknesses of 4 layers, starting at the edge [H]. The values of dz must be positive.
u [in]
The average properties of 4 layers, starting at the edge [A]
Csys [out]
The four coefficients of a 4th order polynomial fit of u as a function of z [A H-(n-1)]
- real function f(this, k, x)
Value of PPM_H4_2019 reconstruction at a point in cell k [A]
- Parameters
this [in]
This reconstruction
k [in]
Cell number
x [in]
Non-dimensional position within element [nondim]
- real function dfdx(this, k, x)
Derivative of PPM_H4_2019 reconstruction at a point in cell k [A]
- Parameters
this [in]
This reconstruction
k [in]
Cell number
x [in]
Non-dimensional position within element [nondim]
- real function average(this, k, xa, xb)
Average between xa and xb for cell k of a 1D PPM reconstruction [A]
- Parameters
this [in]
This reconstruction
k [in]
Cell number
xa [in]
Start of averaging interval on element (0 to 1)
xb [in]
End of averaging interval on element (0 to 1)
- subroutine destroy(this)
Deallocate the PPM_H4_2019 reconstruction
- Parameters
this [inout]
This reconstruction
- logical function check_reconstruction(this, h, u)
Checks the PPM_H4_2019 reconstruction for consistency
- Parameters
this [in]
This reconstruction
h [in]
Grid spacing (thickness) [typically H]
u [in]
Cell mean values [A]
- logical function unit_tests(this, verbose, stdout, stderr)
Runs PPM_H4_2019 reconstruction unit tests and returns True for any fails, False otherwise
- Parameters
this [inout]
This reconstruction
verbose [in]
True, if verbose
stdout [in]
I/O channel for stdout
stderr [in]
I/O channel for stderr