version 0.6.0
Loading...
Searching...
No Matches

The fast Interpolation/Reconstruction scheme type definition. The efficiency is based on: More...

Functions/Subroutines

subroutine t_int_fast_scheme_init (self)
 Initialize a 1D point interpolant.
 
subroutine t_int_fast_compute_stencil_generic_dummy (self, step, steps, derivative)
 Dummy function as it's not available for fast schemes.
 
subroutine t_int_fast_compute_stencil_generic (self, preweight, step, steps, derivative)
 Compute the stencil with a generic fast interpolation procedure.
 
double precision function t_int_fast_interpolate_dummy (self, step, steps, values, derivative)
 Dummy function as it's not available for fast schemes.
 
double precision function t_int_fast_interpolate (self, preweight, step, steps, values, derivative)
 Interpolate.
 
pure double precision function t_int_fast_scheme_apply_dummy (self, values)
 Dummy function (existing for architecture needs).
 
double precision function t_int_fast_scheme_apply_fast (self, values, preweights)
 Apply the corresponding scheme. Could be overriden by a specific function, but should be fast enough.
 
subroutine t_int_fast_scheme_precompute (self)
 Init the corresponding scheme. Should do the job for all fast schemes.
 

Detailed Description

  • the fixed position of the interpolation: at the face between index 0 and index 1' cells ;
  • the precomputation of finite differences stencils (that are used to recover interpolants and smoothness_indicator). Those are stored in the t_int_grid_preweights structure.

This definition of the interpolation scheme.

Important
There are 2 functions that has to be specified when deriving a new scheme:
  • 'compute_preweights': what is the formula for (pre)computing the stencil's weights.
  • '' Optionaly, one can also specify the 'apply_fast' function.
Note
The scheme also works (efficiently) with non uniform grids.
Todo
MCO: gfortran is making the code crash when using the inner compute_weights() method, while ifort is fine with it. For now, use a supplied procedure given to precompte(). When the problem is solved, switch back to overloaded compute_weights call, much more elegant.

Function/Subroutine Documentation

◆ t_int_fast_compute_stencil_generic()

subroutine type_int_fast_scheme::t_int_fast_compute_stencil_generic ( class(t_int_fast_scheme), intent(inout) self,
class(t_int_grid_preweights), intent(in) preweight,
double precision, intent(in) step,
double precision, dimension(:), intent(in) steps,
integer, intent(in), optional derivative )
Note
This can be overloaded by a deriving scheme with an optimized version
Parameters
[in,out]selfthe element
[in]preweightthe associated t_int_grid_preweights object
[in]stepthe step where to interpolate relatively to the reference node 0
[in]stepsthe steps between the node values (of size N-1)
[in]derivative*(optional)* the derivative number: 0 (default) for value interpolation, 1 for first derivative, etc.

dds is indexed over [points,derivative]

◆ t_int_fast_interpolate()

double precision function type_int_fast_scheme::t_int_fast_interpolate ( class(t_int_fast_scheme), intent(inout) self,
class(t_int_grid_preweights), intent(in) preweight,
double precision, intent(in) step,
double precision, dimension(:), intent(in) steps,
double precision, dimension(:), intent(in) values,
integer, intent(in), optional derivative )
Warning
the parameters 'step', 'steps' and 'derivative' are useless as we are simply fast applying the pre computed scheme.

◆ t_int_fast_scheme_apply_dummy()

pure double precision function type_int_fast_scheme::t_int_fast_scheme_apply_dummy ( class(t_int_fast_scheme), intent(in) self,
double precision, dimension(:), intent(in) values )
Parameters
[in,out]selfThe element
[in]valuesThe discrete (mean) values of the function
Precondition
The scheme has already been initialized
Todo
Throw exception

◆ t_int_fast_scheme_apply_fast()

double precision function type_int_fast_scheme::t_int_fast_scheme_apply_fast ( class(t_int_fast_scheme), intent(in) self,
double precision, dimension(:), intent(in) values,
class(t_int_grid_preweights), intent(in) preweights )
Parameters
[in]selfThe scheme
[in]valuesThe discrete values of the function
[in]preweightsThe precomputed weights (
See also
t_int_grid_preweights)
Precondition
The scheme has already been initialized

◆ t_int_fast_scheme_init()

subroutine type_int_fast_scheme::t_int_fast_scheme_init ( class(t_int_fast_scheme), intent(inout) self)

◆ t_int_fast_scheme_precompute()

subroutine type_int_fast_scheme::t_int_fast_scheme_precompute ( class(t_int_fast_scheme), intent(inout) self)
Parameters
[in]selfThe scheme.