mass_matrix module#
Created on Thu Aug 31 16:29:13 2023
@author: Pavan Pranjivan Mehta
- class mass_matrix.mass_matrix#
- Bases: - object- Computes mass matrix - legendre()#
- Computes Mass matrix Legendre Polynomials in [-1,1] of dim = (k) x (k), where k-1 is highest degree - Parameters#- degreeint
- degree of the polynomial 
 - Returns#- Mass martix Legendre polynomials within the interval [-1,1] - M: numpy array
- Matrix of dim (k) X (k), where k-1 is the highest degree of Legengre Polynomials 
 
 - shift_legendre()#
- Computes Mass matrix Shifted Legendre Polynomials in [0,1] of dim = (k) x (k), where k-1 is highest degree - Parameters#- degreeint
- degree of the polynomial 
 - Returns#- Mass martix Legendre polynomials within the interval [0,1] - M: numpy array
- Matrix of dim (k) X (k), where k-1 is the highest degree of Shifted Legengre Polynomials 
 
 - jacobi(beta, degree)#
- Computes Mass matrix Jacobi Polynomials in [-1,1] of dim = (k) x (k), where k-1 is highest degree - Parameters#- alphafloat
- paramter assocated with Jacobi Polynomials, alpha > -1 
- betafloat
- paramter assocated with Jacobi Polynomials, beta > -1 
- degreeint
- degree of the polynomial 
 - Returns#- Mass martix Jacobi polynomials within the interval [-1,1] - M: numpy array
- Matrix of dim (k) X (k), where k-1 is the highest degree of Jacobi Polynomials 
 
 - shift_jacobi(beta, degree)#
- Computes Mass matrix Shifted Jacobi Polynomials in [0,1] of dim = (k) x (k), where k-1 is highest degree - Parameters#- alphafloat
- paramter assocated with Jacobi Polynomials, alpha > -1 
- betafloat
- paramter assocated with Jacobi Polynomials, beta > -1 
- degreeint
- degree of the polynomial 
 - Returns#- Mass martix Jacobi polynomials within the interval [0,1] - M: numpy array
- Matrix of dim (k) X (k), where k-1 is the highest degree of Shifted Jacobi Polynomials 
 
 - Q_poly(beta, degree)#
- Computes Mass matrix Q Polynomials in [0,1] of dim = (k) x (k), where k-1 is highest degree - Parameters#- alphafloat
- paramter assocated with Q Polynomials, alpha > -1 
- betafloat
- paramter assocated with Q Polynomials, beta > -1 
- degreeint
- degree of the polynomial 
 - Returns#- Mass martix Q polynomials within the interval [0,1] - M: numpy array
- Matrix of dim (k) X (k), where k-1 is the highest degree of Q Polynomials 
 - Notes#- Q (x) := P_n (1-2x), where P_n is a Jacobi polynomial with paramter, alpha and beta. 
 - shift_arbitary_jacobi(b, alpha, beta, degree)#
- Computes Mass matrix Shifted (arbitary) Jacobi Polynomials in [a,b] of dim = (k) x (k), where k-1 is highest degree - Parameters#- afloat
- min of interval [a, b] 
- bfloat
- max of interval [a, b] 
- alphafloat
- paramter assocated with Jacobi Polynomials, alpha > -1 
- betafloat
- paramter assocated with Jacobi Polynomials, beta > -1 
- degreeint
- degree of the polynomial 
 - Returns#- Mass martix Jacobi polynomials within the interval [0,1] - M: numpy array
- Matrix of dim (k) X (k), where k-1 is the highest degree of Shifted Jacobi Polynomials 
 
 - homogenous_legendre()#
- Computes Mass matrix Homogenous basis function using Legendre Polynomials in [-1,1] of dim = (k-1) x (k-1), where k-1 is highest degree of homogeous legendre Polynomials - Parameters#- degreeint
- max degree of the polynomial 
 - Returns#- Mass martix Legendre polynomials within the interval [-1,1] - M: numpy array
- Matrix of dim (k) X (k), where k-1 is the highest degree of homogeous legendre Polynomials 
 
 - homogenous_shift_legendre()#
- Computes Mass matrix Homogenous basis function using Shifted Legendre Polynomials in [0,1] of dim = (k-1) x (k-1), where k-1 is highest degree of homogeous shifted legendre Polynomials - Parameters#- degreeint
- max degree of the polynomial 
 - Returns#- Mass martix Shifted Legendre polynomials within the interval [0,1] - M: numpy array
- Matrix of dim (k) X (k), where k-1 is the highest degree of homogeous shifted legendre Polynomials 
 
 
- class mass_matrix.test#
- Bases: - object- legendre()#
 - shift_legendre()#
 - homogenous_legendre()#
 - runge()#
 - runge_arb(b, x)#
 - func()#
 - legendre_proj()#
 - legendre_proj_err()#
 - shift_legendre_proj()#
 - Q_proj(beta, degree)#
 - shift_jacob_arb_proj(b, alpha, beta, degree)#
 - shift_legendre_proj_err()#
 - shift_jacobi_project_coeff(beta, degree)#
- Comuptes the coeffients for L2 projection over shifted Jacobi basis 
 - homogenous_legendre_proj()#
 - homogenous_legendre_proj_err()#
 - homogenous_shift_legendre_proj()#
 - homogenous_shift_legendre_proj_err()#
 - proj_err()#