MOM6
|
Polynomial functions.
Date of creation: 2008.06.12 L. White
This module contains routines that handle polynomials.
Functions/Subroutines | |
real function, public | evaluation_polynomial (coeff, ncoef, x) |
Pointwise evaluation of a polynomial at x. More... | |
real function, public | first_derivative_polynomial (coeff, ncoef, x) |
Calculates the first derivative of a polynomial evaluated at a point x. More... | |
real function, public | integration_polynomial (xi0, xi1, Coeff, npoly) |
Exact integration of polynomial of degree npoly. More... | |
real function, public polynomial_functions::evaluation_polynomial | ( | real, dimension(:), intent(in) | coeff, |
integer, intent(in) | ncoef, | ||
real, intent(in) | x | ||
) |
Pointwise evaluation of a polynomial at x.
The polynomial is defined by the coefficients contained in the array of the same name, as follows: C(1) + C(2)x + C(3)x^2 + C(4)x^3 + ... where C refers to the array 'coeff'. The number of coefficients is given by ncoef and x is the coordinate where the polynomial is to be evaluated.
[in] | coeff | The coefficients of the polynomial |
[in] | ncoef | The number of polynomial coefficients |
[in] | x | The position at which to evaluate the polynomial |
Definition at line 20 of file polynomial_functions.F90.
real function, public polynomial_functions::first_derivative_polynomial | ( | real, dimension(:), intent(in) | coeff, |
integer, intent(in) | ncoef, | ||
real, intent(in) | x | ||
) |
Calculates the first derivative of a polynomial evaluated at a point x.
The polynomial is defined by the coefficients contained in the array of the same name, as follows: C(1) + C(2)x + C(3)x^2 + C(4)x^3 + ... where C refers to the array 'coeff'. The number of coefficients is given by ncoef and x is the coordinate where the polynomial's derivative is to be evaluated.
[in] | coeff | The coefficients of the polynomial |
[in] | ncoef | The number of polynomial coefficients |
[in] | x | The position at which to evaluate the derivative |
Definition at line 44 of file polynomial_functions.F90.
real function, public polynomial_functions::integration_polynomial | ( | real, intent(in) | xi0, |
real, intent(in) | xi1, | ||
real, dimension(:), intent(in) | Coeff, | ||
integer, intent(in) | npoly | ||
) |
Exact integration of polynomial of degree npoly.
The array of coefficients (Coeff) must be of size npoly+1.
[in] | xi0 | The lower bound of the integral |
[in] | xi1 | The lower bound of the integral |
[in] | coeff | The coefficients of the polynomial |
[in] | npoly | The degree of the polynomial |
Definition at line 64 of file polynomial_functions.F90.