Peano
Loading...
Searching...
No Matches
test5 Namespace Reference

This test checks that R * A_DG * P * u_random = A_CG * u_random and R * M_DG * P * u_random = M_CG * u_random for some random vector u_random. More...

Variables

 parser = argparse.ArgumentParser(description='Multigrid - Poisson solver')
 
 dest
 
 type
 
 int
 
 default
 
 help
 
 action
 
 False
 
 choices
 
 required
 
 True
 
 args = parser.parse_args()
 
 project
 
 matrices
 
 assembly_matrix
 
 assembly_matrix_scaling
 
 mass_matrix
 
 mass_matrix_scaling
 
 face_from_cell_projection_scaling = matrices.get_face_from_cell_matrix()
 
 cell_from_face_projection_scaling = matrices.get_cell_from_face_matrix()
 
 approximate_system_matrix_scaling = matrices.get_A_tilde()
 
 dg_solver
 
int num_dg_face_solutions = 2 * (args.poly_degree + 1) ** (args.dimensions-1)
 
int num_dg_face_projections = 4 * (args.poly_degree + 1) ** (args.dimensions-1)
 
 correction_equation_matrices
 
 system_matrix
 
 system_matrix_scaling
 
 maxx_matrix_scaling
 
 collocated_solver
 
 intergrid_operators
 
list prolongation_matrix = [intergrid_operators.prolongation()]
 
list prolongation_matrix_scaling = [0]
 
list restriction_matrix = [intergrid_operators.restriction()]
 
list restriction_matrix_scaling = [0]
 
list injection_matrix = [intergrid_operators.injection()]
 
list injection_matrix_scaling = [0]
 
 preprocessing_action_set
 
 auxiliary
 
 build_mode = peano4.api.output.CompileMode.RELEASE
 
float cube_size = 1.0
 
 dimensions
 
 offset
 
 domain_size
 
 plot_after_each_mesh_sweep
 
 max_iterations
 
 peano4_project = project.generate_Peano4_project(args.verbose)
 

Detailed Description

This test checks that R * A_DG * P * u_random = A_CG * u_random and R * M_DG * P * u_random = M_CG * u_random for some random vector u_random.

Here R and P are the restriction and prolongation operators, respectively, A_DG, A_CG are system matrices and M_DG, M_CG are mass matrices for DG and CG, respectively.

Variable Documentation

◆ action

test5.action

Definition at line 20 of file test5.py.

◆ approximate_system_matrix_scaling

test5.approximate_system_matrix_scaling = matrices.get_A_tilde()

Definition at line 50 of file test5.py.

◆ args

test5.args = parser.parse_args()

Definition at line 29 of file test5.py.

◆ assembly_matrix

test5.assembly_matrix

Definition at line 43 of file test5.py.

◆ assembly_matrix_scaling

test5.assembly_matrix_scaling

Definition at line 43 of file test5.py.

◆ auxiliary

test5.auxiliary

Definition at line 143 of file test5.py.

◆ build_mode

test5.build_mode = peano4.api.output.CompileMode.RELEASE

Definition at line 150 of file test5.py.

◆ cell_from_face_projection_scaling

test5.cell_from_face_projection_scaling = matrices.get_cell_from_face_matrix()

Definition at line 48 of file test5.py.

◆ choices

test5.choices

Definition at line 28 of file test5.py.

◆ collocated_solver

test5.collocated_solver
Initial value:
1= mghype.matrixfree.solvers.api.CollocatedDLinearDiscretisationWithPointJacobi(
2 name = "Test5CG",
3 unknowns_per_vertex = 1,
4 dimensions = args.dimensions,
5 min_h = args.meshsize,
6 max_h = args.meshsize,
7 local_assembly_matrix = system_matrix,
8 local_assembly_matrix_scaling=system_matrix_scaling,
9 mass_matrix = mass_matrix,
10 mass_matrix_scaling = maxx_matrix_scaling,
11 solver_tolerance = 1e-12,
12 smoother_relaxation = 0.5,
13 custom_plot_actionset=[("rand", "getRand"), ("vrestrictADG", "getVrestrictADG"), ("vrestrictMDG", "getVrestrictMDG"), ("acg", "getAcg"), ("mcg", "getMcg")],
14 custom_init_actionset=InitCollocatedTest5
15)

Definition at line 98 of file test5.py.

◆ correction_equation_matrices

test5.correction_equation_matrices
Initial value:
2 dimensions = args.dimensions,
3 unknowns_per_node = 1
4)
Simple matrix generator for continuous d-linear finite elements.
Definition DLinear.py:10

Definition at line 90 of file test5.py.

◆ cube_size

float test5.cube_size = 1.0

Definition at line 159 of file test5.py.

◆ default

test5.default

Definition at line 19 of file test5.py.

◆ dest

test5.dest

Definition at line 19 of file test5.py.

◆ dg_solver

test5.dg_solver
Initial value:
1= mghype.matrixfree.solvers.api.DiscontinuousGalerkinDiscretisationPointWiseRiemannSolver(
2 name = "Test5DG",
3 dimensions = args.dimensions,
4 poly_degree = args.poly_degree,
5 unknowns_per_cell_node = 1,
6 solutions_per_face_node = 2,
7 projections_per_face_node = 2,
8 min_h = args.meshsize,
9 max_h = args.meshsize,
10 assembly_matrix= assembly_matrix,
11 assembly_matrix_scaling = assembly_matrix_scaling,
12 mass_matrix = mass_matrix,
13 mass_matrix_scaling = mass_matrix_scaling,
14 face_from_cell_projection = face_from_cell_projection,
15 face_from_cell_projection_scaling = face_from_cell_projection_scaling,
16 cell_from_face_projection = cell_from_face_projection,
17 cell_from_face_projection_scaling = cell_from_face_projection_scaling,
18 riemann_matrix = matrices.get_face_face_riemann_problem_matrix(),
19 boundary_matrix = matrices.get_boundary_matrix(),
20 cell_relaxation = args.omega_c,
21 face_relaxation = args.omega_f, # default here is 1, i.e. we solve exactly. See class docu
22 approximate_system_matrix = approximate_system_matrix,
23 approximate_system_matrix_scaling = approximate_system_matrix_scaling,
24 solver_tolerance = 1e-6,
25 custom_init_actionset=InitDofsDGTest5,
26)

Definition at line 54 of file test5.py.

◆ dimensions

test5.dimensions

Definition at line 161 of file test5.py.

◆ domain_size

test5.domain_size

Definition at line 163 of file test5.py.

◆ face_from_cell_projection_scaling

test5.face_from_cell_projection_scaling = matrices.get_face_from_cell_matrix()

Definition at line 46 of file test5.py.

◆ False

test5.False

Definition at line 20 of file test5.py.

◆ help

test5.help

Definition at line 19 of file test5.py.

◆ injection_matrix

list test5.injection_matrix = [intergrid_operators.injection()]

Definition at line 129 of file test5.py.

◆ injection_matrix_scaling

list test5.injection_matrix_scaling = [0]

Definition at line 130 of file test5.py.

◆ int

test5.int

Definition at line 19 of file test5.py.

◆ intergrid_operators

test5.intergrid_operators
Initial value:

Definition at line 120 of file test5.py.

◆ mass_matrix

test5.mass_matrix

Definition at line 44 of file test5.py.

◆ mass_matrix_scaling

test5.mass_matrix_scaling

Definition at line 44 of file test5.py.

◆ matrices

test5.matrices
Initial value:
1= mghype.api.matrixgenerators.GLMatrixFree(
2 args.dimensions,
3 args.poly_degree,
4 1, # Unknowns per cell dof. Scalar PDE here
5 2, # We use the penalty formulation (see docu in tutorials)
6 2
7)

Definition at line 35 of file test5.py.

◆ max_iterations

test5.max_iterations

Definition at line 165 of file test5.py.

◆ maxx_matrix_scaling

test5.maxx_matrix_scaling

Definition at line 95 of file test5.py.

◆ num_dg_face_projections

int test5.num_dg_face_projections = 4 * (args.poly_degree + 1) ** (args.dimensions-1)

Definition at line 82 of file test5.py.

◆ num_dg_face_solutions

int test5.num_dg_face_solutions = 2 * (args.poly_degree + 1) ** (args.dimensions-1)

Definition at line 81 of file test5.py.

◆ offset

test5.offset

Definition at line 162 of file test5.py.

◆ parser

test5.parser = argparse.ArgumentParser(description='Multigrid - Poisson solver')

Definition at line 18 of file test5.py.

◆ peano4_project

test5.peano4_project = project.generate_Peano4_project(args.verbose)

Definition at line 171 of file test5.py.

◆ plot_after_each_mesh_sweep

test5.plot_after_each_mesh_sweep

Definition at line 164 of file test5.py.

◆ preprocessing_action_set

test5.preprocessing_action_set

Definition at line 132 of file test5.py.

◆ project

test5.project
Initial value:
1= mghype.matrixfree.api.Project( project_name = "DGPointwise",
2 namespace = [ "tests", "multigrid", "matrixfree", "test5" ]
3 )

Definition at line 31 of file test5.py.

◆ prolongation_matrix

list test5.prolongation_matrix = [intergrid_operators.prolongation()]

Definition at line 125 of file test5.py.

◆ prolongation_matrix_scaling

list test5.prolongation_matrix_scaling = [0]

Definition at line 126 of file test5.py.

◆ required

test5.required

Definition at line 28 of file test5.py.

◆ restriction_matrix

list test5.restriction_matrix = [intergrid_operators.restriction()]

Definition at line 127 of file test5.py.

◆ restriction_matrix_scaling

list test5.restriction_matrix_scaling = [0]

Definition at line 128 of file test5.py.

◆ system_matrix

test5.system_matrix

Definition at line 94 of file test5.py.

◆ system_matrix_scaling

test5.system_matrix_scaling

Definition at line 94 of file test5.py.

◆ True

test5.True

Definition at line 28 of file test5.py.

◆ type

test5.type

Definition at line 19 of file test5.py.