WARPXM v1.10.0
Loading...
Searching...
No Matches
triangle_basis Namespace Reference

Classes

class  TriangleBasis
 
class  TrianglePPQuadratureTest
 

Functions

def rs_to_a (r, s)
 
def rs_to_b (r, s)
 
def triangle_orthogonal_polynomials (max_degree)
 An orthogonal polynomial family on the [0, 1], [0, 1] triangle, up to total degree max_degree
 
def triangle_monomials (max_degree)
 The monomials in 2 dimensions, with their degrees ordered like [(0, 0), (1, 0), (0, 1), (2, 0), (1, 1), (0, 2), ...].
 
def triangle_collocation_nodes (order)
 
def triangle_exact_quadrature_rule (order)
 
def triangle_projected_quadrature_rule (u_rule, v_rule, corner=1)
 Uses a modification of the procedure described in [1] Xiangxiong Zhang, Yinhua Xia, Chi-Wang Shu.
 
def tensor_product_quad_rule_2d (u_rule, v_rule)
 
def triangle_tensor_product_positivity_preserving_quad_rule (order)
 
def triangle_positivity_preserving_quad_rule (order)
 Computes a quadrature rule on the triangle which is exact for polynomials up to degree order-1, and which has all-positive weights.
 
def triangle_positivity_preserving_extra_quad_nodes (order, collocation_nodes)
 Determine the extra positivity-preserving quadrature nodes, in addition to the face LGL nodes, at which to enforce positivity in the positivity-enforcing limiter.
 
def triangle_optimal_gq_rule (order)
 

Function Documentation

◆ rs_to_a()

def triangle_basis.rs_to_a (   r,
  s 
)

◆ rs_to_b()

def triangle_basis.rs_to_b (   r,
  s 
)

◆ tensor_product_quad_rule_2d()

def triangle_basis.tensor_product_quad_rule_2d (   u_rule,
  v_rule 
)

◆ triangle_collocation_nodes()

def triangle_basis.triangle_collocation_nodes (   order)

◆ triangle_exact_quadrature_rule()

def triangle_basis.triangle_exact_quadrature_rule (   order)

◆ triangle_monomials()

def triangle_basis.triangle_monomials (   max_degree)

The monomials in 2 dimensions, with their degrees ordered like [(0, 0), (1, 0), (0, 1), (2, 0), (1, 1), (0, 2), ...].

◆ triangle_optimal_gq_rule()

def triangle_basis.triangle_optimal_gq_rule (   order)

◆ triangle_orthogonal_polynomials()

def triangle_basis.triangle_orthogonal_polynomials (   max_degree)

An orthogonal polynomial family on the [0, 1], [0, 1] triangle, up to total degree max_degree

Returns a list of dictionaries, each of which has two keys: p: the i'th orthogonal polynomial dpdr: the r derivative of the i'th orthogonal polynomial dpds: the s derivative of the i'th orthogonal polynomial

The polynomials are ordered so that the degrees of p go like [(0, 0), (1, 0), (0, 1), (2, 0), (1, 1), (0, 2), ...]

This orthogonal polynomial family is described by Hesthaven and Warburton, equation (6.6) It uses a combination of Legendre and Jacobi polynomials. We modify their formulation slightly to account for the fact that we're defining things over the [0, 1] triangle instead of the [-1, 1] triangle.

◆ triangle_positivity_preserving_extra_quad_nodes()

def triangle_basis.triangle_positivity_preserving_extra_quad_nodes (   order,
  collocation_nodes 
)

Determine the extra positivity-preserving quadrature nodes, in addition to the face LGL nodes, at which to enforce positivity in the positivity-enforcing limiter.

See the positivity_preserving_dg.pdf writeup.

◆ triangle_positivity_preserving_quad_rule()

def triangle_basis.triangle_positivity_preserving_quad_rule (   order)

Computes a quadrature rule on the triangle which is exact for polynomials up to degree order-1, and which has all-positive weights.

See the positivity_preserving_dg.pdf writeup for details on how this is used.

◆ triangle_projected_quadrature_rule()

def triangle_basis.triangle_projected_quadrature_rule (   u_rule,
  v_rule,
  corner = 1 
)

Uses a modification of the procedure described in [1] Xiangxiong Zhang, Yinhua Xia, Chi-Wang Shu.

"Maximum-Principle-Satisfying and Positivity-Preserving High Order Discontinuous Galerkin Schemes for Conservation Laws on Triangular Meshes". J. Sci. Comput (2012)

We take a tensor product of two Legendre-Gauss-Lobatto quadrature rules, and then apply the mapping described in that paper to transform it to the [0, 1] triangle.

◆ triangle_tensor_product_positivity_preserving_quad_rule()

def triangle_basis.triangle_tensor_product_positivity_preserving_quad_rule (   order)