Header for quadrature generation utilities.
More...
Go to the source code of this file.
|
| void | gq (const int kind, const double a, const double b, Array1D< double > &x, Array1D< double > &w) |
| | Computes abscissas and weights for several quadrature rules.
|
| |
| void | gq (const int kind, const int n, const double a, const double b, double *x, double *w) |
| | Computes abscissas and weights for several quadrature rules.
|
| |
| void | gq_gen (Array1D< double > &a, Array1D< double > &b, const double amu0, Array1D< double > &x, Array1D< double > &w) |
| | Computes abscissas and weights for a generic orthogonal polynomial recursion using the Golub-Welsch algorithm.
|
| |
| void | vandermonde_gq (Array1D< double > &x, Array1D< double > &w, Array1D< double > &q) |
| | Computes abscissas and weights for Newton-Cotes rules through the solution of a Vandermonde matrix. This function was tested as an internal function only, called by the quadrature class.
|
| |
| void | gchb (const int kind, const int n, double *x, double *w) |
| | Computes abscissas and weights for Chebyshev quadrature rules.
|
| |
Header for quadrature generation utilities.
◆ gchb()
| void gchb |
( |
const int | kind, |
|
|
const int | n, |
|
|
double * | x, |
|
|
double * | w ) |
Computes abscissas and weights for Chebyshev quadrature rules.
- Parameters
-
| kind | : defines quadrature type (1) Gauss-Chebyshev 1st kind (2) Gauss-Chebyshev 2nd kind |
| n | : quadrature order |
| x | : on return it holds quadrature abscissas. |
| w | : on return it holds quadrature weights. |
◆ gq() [1/2]
| void gq |
( |
const int | kind, |
|
|
const double | a, |
|
|
const double | b, |
|
|
Array1D< double > & | x, |
|
|
Array1D< double > & | w ) |
Computes abscissas and weights for several quadrature rules.
- Parameters
-
| kind | : defines quadrature type (1) Gauss-Legendre, (2) Gauss-Chebyshev 1st kind (3) Gauss-Chebyshev 2nd kind, (4) Gauss-Hermite, (5) Gauss-Jacobi (6) Gauss-Laguerre |
| a | : optional parameter needed by Gauss-Jacobi and Gauss-Laguerre rules |
| b | : optional parameter needed by Gauss-Jacobi rule |
| x | : on return it holds quadrature abscissas. Its initial size determines the quadrature order |
| w | : on return it holds quadrature weights. |
◆ gq() [2/2]
| void gq |
( |
const int | kind, |
|
|
const int | n, |
|
|
const double | a, |
|
|
const double | b, |
|
|
double * | x, |
|
|
double * | w ) |
Computes abscissas and weights for several quadrature rules.
- Parameters
-
| kind | : defines quadrature type (1) Gauss-Legendre, (2) Gauss-Chebyshev 1st kind (3) Gauss-Chebyshev 2nd kind, (4) Gauss-Hermite, (5) Gauss-Jacobi (6) Gauss-Laguerre |
| n | : quadrature order |
| a | : optional parameter needed by Gauss-Jacobi and Gauss-Laguerre rules |
| b | : optional parameter needed by Gauss-Jacobi rule |
| x | : on return it holds quadrature abscissas. |
| w | : on return it holds quadrature weights. |
◆ gq_gen()
Computes abscissas and weights for a generic orthogonal polynomial recursion using the Golub-Welsch algorithm.
- Parameters
-
| a | : array of parameters for the orthogonal polynomial recursion. Its initial size determines the quadrature order |
| b | : array of parameters for the orthogonal polynomial recursion |
| amu0 | : parameter for custom scaling of quadrature weights |
| x | : on return it holds quadrature abscissas |
| w | : on return it holds quadrature weights. |
◆ vandermonde_gq()
Computes abscissas and weights for Newton-Cotes rules through the solution of a Vandermonde matrix. This function was tested as an internal function only, called by the quadrature class.
- Parameters
-
| x | : holds quadrature abscissas |
| w | : on return it holds quadrature weights. |
| q | : array of parameters needed to setup the Vandermonde matrix |