MFEM v4.7.0
Finite element discretization library
|
Go to the source code of this file.
Functions | |
void | RationalApproximation_AAA (const Vector &val, const Vector &pt, Array< real_t > &z, Array< real_t > &f, Vector &w, real_t tol, int max_order) |
void | ComputePolesAndZeros (const Vector &z, const Vector &f, const Vector &w, Array< real_t > &poles, Array< real_t > &zeros, real_t &scale) |
void | PartialFractionExpansion (real_t scale, Array< real_t > &poles, Array< real_t > &zeros, Array< real_t > &coeffs) |
void | ComputePartialFractionApproximation (real_t &alpha, Array< real_t > &coeffs, Array< real_t > &poles, real_t lmax=1000., real_t tol=1e-10, int npoints=1000, int max_order=100) |
void ComputePartialFractionApproximation | ( | real_t & | alpha, |
Array< real_t > & | coeffs, | ||
Array< real_t > & | poles, | ||
real_t | lmax = 1000., | ||
real_t | tol = 1e-10, | ||
int | npoints = 1000, | ||
int | max_order = 100 ) |
ComputePartialFractionApproximation: compute a rational approximation (RA) in partial fraction form, e.g., f(z) ≈ Σ_i c_i / (z - p_i), from sampled values of the function f(z) = z^{-a}, 0 < a < 1.
[in] | alpha | Exponent a in f(z) = z^-a |
[in] | lmax,npoints | f(z) is uniformly sampled npoints times in the interval [ 0, lmax ] |
[in] | tol | Relative tolerance |
[in] | max_order | Maximum number of terms (order) of the RA |
[out] | coeffs | Coefficients c_i |
[out] | poles | Poles p_i |
NOTES: When MFEM is not built with LAPACK support, only alpha = 0.33, 0.5, and 0.99 are possible. In this case, if alpha != 0.33 and alpha != 0.99, then alpha = 0.5 is used by default.
See pg. A1501 of Nakatsukasa et al. [1].
void ComputePolesAndZeros | ( | const Vector & | z, |
const Vector & | f, | ||
const Vector & | w, | ||
Array< real_t > & | poles, | ||
Array< real_t > & | zeros, | ||
real_t & | scale ) |
ComputePolesAndZeros: compute the poles [out] and zeros [out] of the rational function f(z) = C p(z)/q(z) from its ration barycentric form.
[in] | z | Support points in rational barycentric form |
[in] | f | Data values at support points z |
[in] | w | Weights in rational barycentric form |
[out] | poles | Array of poles (roots of p(z)) |
[out] | zeros | Array of zeros (roots of q(z)) |
[out] | scale | Scaling constant in f(z) = C p(z)/q(z) |
See pg. A1501 of Nakatsukasa et al. [1].
void PartialFractionExpansion | ( | real_t | scale, |
Array< real_t > & | poles, | ||
Array< real_t > & | zeros, | ||
Array< real_t > & | coeffs ) |
PartialFractionExpansion: compute the partial fraction expansion of the rational function f(z) = Σ_i c_i / (z - p_i) from its poles [in] and zeros [in].
[in] | poles | Array of poles (same as p_i above) |
[in] | zeros | Array of zeros |
[in] | scale | Scaling constant |
[out] | coeffs | Coefficients c_i |
void RationalApproximation_AAA | ( | const Vector & | val, |
const Vector & | pt, | ||
Array< real_t > & | z, | ||
Array< real_t > & | f, | ||
Vector & | w, | ||
real_t | tol, | ||
int | max_order ) |
RationalApproximation_AAA: compute the rational approximation (RA) of data val [in] at the set of points pt [in].
[in] | val | Vector of data values |
[in] | pt | Vector of sample points |
[in] | tol | Relative tolerance |
[in] | max_order | Maximum number of terms (order) of the RA |
[out] | z | Support points of the RA in rational barycentric form |
[out] | f | Data values at support points z |
[out] | w | Weights of the RA in rational barycentric form |
See pg. A1501 of Nakatsukasa et al. [1].