Skip to main content

LagrangeEvalAll

Evaluate Lagrange polynomials on triangle.

Interface 1

INTERFACE LagrangeEvalAll_Triangle
MODULE FUNCTION LagrangeEvalAll_Triangle1(order, x, xij, refTriangle, &
& coeff, firstCall, basisType) RESULT(ans)
INTEGER(I4B), INTENT(IN) :: order
!! order of Lagrange polynomials
REAL(DFP), INTENT(IN) :: x(2)
!! point of evaluation
!! x(1) is x coord
!! x(2) is y coord
REAL(DFP), INTENT(INOUT) :: xij(:, :)
!!
CHARACTER(*), INTENT(IN) :: refTriangle
!! interpolation points
REAL(DFP), OPTIONAL, INTENT(INOUT) :: coeff(SIZE(xij, 2), SIZE(xij, 2))
!! coefficient of Lagrange polynomials
LOGICAL(LGT), OPTIONAL :: firstCall
!! If firstCall is true, then coeff will be made
!! If firstCall is False, then coeff will be used
!! Default value of firstCall is True
INTEGER(I4B), OPTIONAL, INTENT(IN) :: basisType
!! Monomials *Default
!! Orthogonal, Jacobi, Legendre, Lobatto, Ultraspherical all are same
!! Heirarchical
REAL(DFP) :: ans(SIZE(xij, 2))
!! Value of n+1 Lagrange polynomials at point x
END FUNCTION LagrangeEvalAll_Triangle1
END INTERFACE LagrangeEvalAll_Triangle
xij

xij is the interpolation points for Lagrange polynomials. xij is used for constructing the coeff.

basisType

Type of basis functions used for constructing the Lagrange polynomial. Following values are allowed:

  • Monomials
  • Orthogonal, Jacobi, Legendre, Ultraspherical, are all the same.
  • Hierarchical

Interface 2

INTERFACE LagrangeEvalAll_Triangle
MODULE FUNCTION LagrangeEvalAll_Triangle2(order, x, xij, refTriangle, &
& coeff, firstCall, basisType) RESULT(ans)
INTEGER(I4B), INTENT(IN) :: order
!! Order of Lagrange polynomials
REAL(DFP), INTENT(IN) :: x(:, :)
!! Point of evaluation
!! x(1, :) is x coord
!! x(2, :) is y coord
REAL(DFP), INTENT(INOUT) :: xij(:, :)
!! Interpolation points
CHARACTER(*), INTENT(IN) :: refTriangle
!! Reference triangle
!! Biunit
!! Unit
REAL(DFP), OPTIONAL, INTENT(INOUT) :: coeff(SIZE(xij, 2), SIZE(xij, 2))
!! Coefficient of Lagrange polynomials
LOGICAL(LGT), OPTIONAL :: firstCall
!! If firstCall is true, then coeff will be made
!! If firstCall is False, then coeff will be used
!! Default value of firstCall is True
INTEGER(I4B), OPTIONAL, INTENT(IN) :: basisType
!! Monomials *Default
!! Jacobi=Dubiner
!! Heirarchical
REAL(DFP) :: ans(SIZE(x, 2), SIZE(xij, 2))
!! Value of n+1 Lagrange polynomials at point x
END FUNCTION LagrangeEvalAll_Triangle2
END INTERFACE LagrangeEvalAll_Triangle