![]() |
Peano
|
The Gauss-Legendre Basis is by construction the only basis which yields diagonal mass matrices. More...
Public Member Functions | |
__init__ (self, polynomial_order) | |
quadrature_points (self) | |
It seems to be a little bit weird that I have to use the polynomial order plus one here, but you have to read the docu to understand that we are evaluating the polynomial of a certain order to get the roots. | |
quadrature_weights (self) | |
It seems to be a little bit weird that I have to use the polynomial order plus one here, but you have to read the docu to understand that we are evaluating the polynomial of a certain order to get the roots. | |
![]() | |
__str__ (self) | |
init_dictionary_with_default_parameters (self, dictionary, use_multidimensional_arrays) | |
To be implemented by subclass. | |
value1d (self, x, number) | |
Return the numberth shape function's value at x. | |
derivative1d (self, x, number) | |
Return the numberth shape function's derivative at x. | |
![]() | |
order (self) | |
dofs_per_axis (self) | |
Additional Inherited Members | |
![]() | |
dofs_per_axis | |
![]() | |
str | QuadraturePoints1dDocumentation |
str | QuadratureWeights1dDocumentation |
str | MassMatrix1dDocumentation |
str | StiffnessOperator1dDocumentation |
str | BasisFunctionValuesLeft1dDocumentation |
str | DerivativeOperator1dDocumentation |
str | InterpolationMatrix1dDocumentation |
str | RestrictionMatrix1dDocumentation |
![]() | |
_polynomial_order | |
![]() | |
_polynomial_order | |
_render_digits | |
The Gauss-Legendre Basis is by construction the only basis which yields diagonal mass matrices.
I rely solely on SciPy here to construct these functions, as I'm interested in numerical values only, and as the normal SciPy accuracy is sufficient.
There might be more elegant implementations using SymPy which exploit the special structure behind Gauss-Legendre. But I prefer here to stick to one Python package only.
Definition at line 609 of file LagrangeBasisWithDiagonalMassMatrix.py.
exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.GaussLegendreBasis.__init__ | ( | self, | |
polynomial_order ) |
Reimplemented from exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix.
Definition at line 623 of file LagrangeBasisWithDiagonalMassMatrix.py.
References exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.GaussLegendreBasis.__init__().
Referenced by exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.GaussLegendreBasis.__init__().
exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.GaussLegendreBasis.quadrature_points | ( | self | ) |
It seems to be a little bit weird that I have to use the polynomial order plus one here, but you have to read the docu to understand that we are evaluating the polynomial of a certain order to get the roots.
So the argument has to be equal to the number of quadrature points that I wannt have.
I originally used the roots_legendre and then did recalibrate the result manually. Today, SciPy directly offers a shifted Legendre function which I can use directly. So I don't need an expression like
return [ x/2.0+0.5 for x in roots_on_minus_one_one_interval ]
anymore. The nicest definition of the shifted Legendre shape functions can, as so often, be found on Wikipedia:
https://en.wikipedia.org/wiki/Legendre_polynomials#Shifted_Legendre_polynomials
Reimplemented from exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix.
Definition at line 628 of file LagrangeBasisWithDiagonalMassMatrix.py.
References exahype2.solvers.LagrangeBasis.LagrangeBasis._polynomial_order, and exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix._polynomial_order.
Referenced by exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix.__compute_derivative_operator(), exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix.__compute_restriction_matrix(), exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix.derivative1d(), exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix.init_dictionary_with_default_parameters(), and exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix.value1d().
exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.GaussLegendreBasis.quadrature_weights | ( | self | ) |
It seems to be a little bit weird that I have to use the polynomial order plus one here, but you have to read the docu to understand that we are evaluating the polynomial of a certain order to get the roots.
So the argument has to be equal to the number of quadrature points that I wannt have.
I originally used the roots_legendre and then did recalibrate the result manually. Today, SciPy directly offers a shifted Legendre function which I can use directly. So I don't need an expression like
return [ x/2.0+0.5 for x in roots_on_minus_one_one_interval ]
anymore. The nicest definition of the shifted Legendre shape functions can, as so often, be found on Wikipedia:
https://en.wikipedia.org/wiki/Legendre_polynomials#Shifted_Legendre_polynomials
Reimplemented from exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix.
Definition at line 656 of file LagrangeBasisWithDiagonalMassMatrix.py.
References exahype2.solvers.LagrangeBasis.LagrangeBasis._polynomial_order, and exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix._polynomial_order.
Referenced by exahype2.solvers.LagrangeBasisWithDiagonalMassMatrix.LagrangeBasisWithDiagonalMassMatrix.init_dictionary_with_default_parameters().