polynomials_js Derived Type

type, public, extends(polynomials) :: polynomials_js

type~~polynomials_js~~InheritsGraph type~polynomials_js polynomials_js type~polynomials polynomials type~polynomials->type~polynomials_js type~base_object base_object type~base_object->type~polynomials
Help


Jiang-Shu (Lagrange) polynomials object.


Source Code


Components

TypeVisibility AttributesNameInitial
real(kind=R_P), public, allocatable:: poly(:,:)

Polynomial reconstructions [1:2,0:S-1].

real(kind=R_P), private, allocatable:: coef(:,:,:)

Polynomial coefficients [1:2,0:S-1,0:S-1].


Type-Bound Procedures

procedure, public, pass(self) :: compute

Compute weights.

  • private pure subroutine compute(self, S, stencil, f1, f2, ff)

    Compute polynomials.

    Arguments

    Type IntentOptional AttributesName
    class(polynomials_js), intent(inout) :: self

    WENO polynomial.

    integer(kind=I_P), intent(in) :: S

    Number of stencils actually used.

    real(kind=R_P), intent(in) :: stencil(1:,1-S:)

    Stencil used for the interpolation, [1:2, 1-S:-1+S].

    integer(kind=I_P), intent(in) :: f1

    Faces to be computed.

    integer(kind=I_P), intent(in) :: f2

    Faces to be computed.

    integer(kind=I_P), intent(in) :: ff

    Faces to be computed.

procedure, public, nopass :: description

Return weights string-description.

  • private pure function description() result(string)

    Return polynomials string-description.

    Arguments

    None

    Return Value character(len=:), allocatable

    String-description.

procedure, public, pass(self) :: create

Create weights.

  • private pure subroutine create(self, constructor)

    Create coefficients.

    Arguments

    Type IntentOptional AttributesName
    class(polynomials_js), intent(inout) :: self

    Polynomials.

    class(base_object_constructor), intent(in) :: constructor

    Polynomials constructor.

procedure, public, pass(self) :: destroy

Destroy weights.

  • private elemental subroutine destroy(self)

    Destroy polynomials.

    Arguments

    Type IntentOptional AttributesName
    class(polynomials_js), intent(inout) :: self

    WENO polynomials.

Source Code

type, extends(polynomials) :: polynomials_js
  !< Jiang-Shu (Lagrange) polynomials object.
  !<
  !< @note The provided polynomials implement the Lagrange polynomials defined in *Efficient Implementation
  !< of Weighted ENO Schemes*, Guang-Shan Jiang, Chi-Wang Shu, JCP, 1996, vol. 126, pp. 202--228, doi:10.1006/jcph.1996.0130 and
  !< *Very-high-order weno schemes*, G. A. Gerolymos, D. Senechal, I. Vallet, JCP, 2009, vol. 228, pp. 8481-8524,
  !< doi:10.1016/j.jcp.2009.07.039
  private
  real(R_P), allocatable :: coef(:,:,:) !< Polynomial coefficients [1:2,0:S-1,0:S-1].
  contains
    ! deferred public methods
    procedure, pass(self) :: compute     !< Compute weights.
    procedure, nopass     :: description !< Return weights string-description.
    ! overridden public methods
    procedure, pass(self) :: create  !< Create weights.
    procedure, pass(self) :: destroy !< Destroy weights.
endtype polynomials_js