Integration rules for the reference interval and triangle.
More...
#include <utility>
#include <xtensor/containers/xarray.hpp>
#include <xtensor/core/xtensor_forward.hpp>
Go to the source code of this file.
|
| std::pair< xt::xarray< double >, xt::xarray< double > > | oiseau::utils::integration::triangle_cubature (int order) |
| | Return a cubature rule for the triangle with vertices (-1, -1), (1, -1), and (-1, 1).
|
| std::pair< xt::xarray< double >, xt::xarray< double > > | oiseau::utils::integration::quadrature (int order) |
| | Return a Gauss-Legendre quadrature rule on [-1, 1].
|
| std::pair< xt::xarray< double >, xt::xarray< double > > | oiseau::utils::integration::jacobi_gq (unsigned n, double alpha, double beta) |
| | Return Gauss-Jacobi nodes and weights on [-1, 1].
|
| xt::xarray< double > | oiseau::utils::integration::jacobi_gl (unsigned n, double alpha, double beta) |
| | Return Gauss-Lobatto-Jacobi nodes on [-1, 1].
|
Integration rules for the reference interval and triangle.
◆ jacobi_gl()
| xt::xarray< double > oiseau::utils::integration::jacobi_gl |
( |
unsigned | n, |
|
|
double | alpha, |
|
|
double | beta ) |
Return Gauss-Lobatto-Jacobi nodes on [-1, 1].
- Parameters
-
| n | Polynomial order, at least 1. |
| alpha | Exponent of (1 - x) in the Jacobi weight, greater than -1. |
| beta | Exponent of (1 + x) in the Jacobi weight, greater than -1. |
- Returns
- A one-dimensional array of
n plus one node, including both endpoints.
◆ jacobi_gq()
| std::pair< xt::xarray< double >, xt::xarray< double > > oiseau::utils::integration::jacobi_gq |
( |
unsigned | n, |
|
|
double | alpha, |
|
|
double | beta ) |
Return Gauss-Jacobi nodes and weights on [-1, 1].
- Parameters
-
| n | Polynomial order. The rule contains n plus one node. |
| alpha | Exponent of (1 - x) in the Jacobi weight, greater than -1. |
| beta | Exponent of (1 + x) in the Jacobi weight, greater than -1. |
- Returns
- One-dimensional arrays of nodes and their corresponding weights. For
n equal to zero, the single weight is 2.
◆ quadrature()
| std::pair< xt::xarray< double >, xt::xarray< double > > oiseau::utils::integration::quadrature |
( |
int | order | ) |
|
Return a Gauss-Legendre quadrature rule on [-1, 1].
- Parameters
-
| order | Requested polynomial degree of exactness, greater than zero. |
- Returns
- One-dimensional arrays of nodes and their corresponding weights.
- Exceptions
-
| std::out_of_range | If order is zero or negative. |
◆ triangle_cubature()
| std::pair< xt::xarray< double >, xt::xarray< double > > oiseau::utils::integration::triangle_cubature |
( |
int | order | ) |
|
Return a cubature rule for the triangle with vertices (-1, -1), (1, -1), and (-1, 1).
Orders 1 through 28 use tabulated rules. Higher orders use a mapped Gauss-Jacobi rule.
- Parameters
-
| order | Requested total polynomial degree of exactness, greater than zero. |
- Returns
- An N-by-2 array of (r, s) nodes and a length-N array of weights.
- Exceptions
-
| std::out_of_range | If order is zero or negative. |