WARPXM v1.10.0
|
Classes | |
class | Basis |
class | LineBasisTest |
class | QuadratureRule |
Functions | |
def | make_vandermonde (modes, nodes, sym) |
def | lgl_points_1d_on_01 (N) |
def | lgl_quad_rule_1d_01 (N) |
def | gauss_legendre_quad_rule_1d (N) |
def | coefs_of_polynomial (poly, degree) |
We're going to compute the coefficients of the polynomial, which is just an opaque lambda function to us, in the monomial basis, so that we can pass them to mp.polyroots. | |
def | mp_to_np (matrix) |
def | np_to_mp (array) |
def | lgl_simplex_nodes (dims, degree) |
Variables | |
exit | |
dps | |
TriangleBasis | b = TriangleBasis(3) |
TriangleBasis | ells = b.lagrange_interpolating_polynomials() |
def simplex_basis.coefs_of_polynomial | ( | poly, | |
degree | |||
) |
We're going to compute the coefficients of the polynomial, which is just an opaque lambda function to us, in the monomial basis, so that we can pass them to mp.polyroots.
To do so, we use the relation
p'.(x) = V * c, (**)
where
To find c, we just have to solve the equation (**).
It doesn't matter what vector of point we choose for x as long as it results in a well-conditioned matrix V. We choose the Chebyshev nodes.
def simplex_basis.gauss_legendre_quad_rule_1d | ( | N | ) |
def simplex_basis.lgl_points_1d_on_01 | ( | N | ) |
def simplex_basis.lgl_quad_rule_1d_01 | ( | N | ) |
def simplex_basis.lgl_simplex_nodes | ( | dims, | |
degree | |||
) |
def simplex_basis.make_vandermonde | ( | modes, | |
nodes, | |||
sym | |||
) |
sym | the symbol indicating which family of polynomials to use: p – the "primary" polynomials of this set of modes dpdr – their derivatives with respect to r dpds – their derivatives with respect to s |
def simplex_basis.mp_to_np | ( | matrix | ) |
def simplex_basis.np_to_mp | ( | array | ) |
TriangleBasis simplex_basis.b = TriangleBasis(3) |
simplex_basis.dps |
TriangleBasis simplex_basis.ells = b.lagrange_interpolating_polynomials() |
simplex_basis.exit |