![]() |
PRISMS-PF Manual
|
Class that manages solution initialization and swapping with old solutions. More...
#include <group_solution_handler.h>
Public Types | |
| using | SolutionTransfer |
Public Member Functions | |
| GroupSolutionHandler (SolveBlock _solve_block, const std::vector< FieldAttributes > &_attributes_list, const MatrixFreeManager< dim, number > &_matrix_free_manager) | |
| Constructor. | |
| BlockVector< number > & | get_solution_full_vector () |
| Get the solution vector set. This contains all the normal fields and is typically used for output. | |
| const BlockVector< number > & | get_solution_full_vector () const |
| Get the const solution vector set. This contains all the normal fields and is typically used for output. | |
| SolutionVector< number > & | get_solution_vector (unsigned int global_index) |
| Get a solution vector of a given field index. | |
| const SolutionVector< number > & | get_solution_vector (unsigned int global_index) const |
| Get a solution vector of a given field index. | |
| BlockVector< number > & | get_old_solution_full_vector (unsigned int age) |
| Get the old solution vector set at a given age. | |
| const BlockVector< number > & | get_old_solution_full_vector (unsigned int age) const |
| Get the old solution vector set at a given age. | |
| SolutionVector< number > & | get_old_solution_vector (unsigned int age, unsigned int global_index) |
| Get a solution vector of a given field index at a given age. | |
| const SolutionVector< number > & | get_old_solution_vector (unsigned int age, unsigned int global_index) const |
| Get a solution vector of a given field index at a given age. | |
| SolutionLevel< dim, number > & | get_primary_solutions () |
| Get the solutions object at a level. | |
| const SolutionLevel< dim, number > & | get_primary_solutions () const |
| Get the solutions object at a level. | |
| SolutionLevel< dim, number > & | get_solution_level (unsigned int relative_level=-1) |
| Get the solutions object at a level. | |
| const SolutionLevel< dim, number > & | get_solution_level (unsigned int relative_level=-1) const |
| Get the solutions object at a level. | |
| const std::vector< MatrixFree< dim, number > > & | get_matrix_free_levels () const |
| Get the underlying matrix_free objects. | |
| unsigned int | get_block_index (unsigned int global_index) const |
| Get the block index from the global field index. | |
| const SolveBlock & | get_solve_block () const |
| Get the underlying solve block object. | |
| const std::vector< unsigned int > & | get_global_to_block_index () const |
| Get the block index from the global index. | |
| const std::vector< unsigned int > & | get_block_to_global_index () const |
| Get the global index from the block index. | |
| void | init (const NewDependencyExtents &extents) |
| Initialize the solution set. | |
| void | reinit () |
| Reinitialize the solution set. | |
| void | update_ghosts () const |
| Update the ghost values. | |
| void | zero_out_ghosts () const |
| Zero out the ghost values. | |
| void | apply_constraints () |
| Apply the constraints to the solution vector. | |
| void | apply_constraints (BlockVector< number > &solution_vectors) |
| Apply the constraints to another vector. | |
| void | apply_constraints_to_all () |
| Apply the given constraints to all the solution vectors, including old. | |
| void | apply_initial_condition_for_old_fields () |
| Apply initial condition to the old fields. For now, this simply copies the values in the normal field to the old. | |
| void | update () |
| Update and propagate the old solutions. | |
| void | init_solution_transfer () |
| Reinit the solution transfer objects. | |
| void | prepare_for_solution_transfer () |
| Prepare for solution transfer. | |
| void | execute_solution_transfer () |
| Transfer solutions. | |
| template<unsigned int degree> | |
| void | reinit_mg_transfer (const DoFManager< dim, degree > &dof_manager) |
| Reinit the solution transfer objects. | |
| template<unsigned int degree> | |
| void | mg_transfer_down (const DoFManager< dim, degree > &dof_manager, unsigned int finest_level, bool transfer_old_solutions=false) |
| Transfer solutions to mg levels. | |
| unsigned int | num_levels () |
| Number of refinement levels that will be tracked. | |
| void | print_solution_full_vector (std::ostream &out) const |
| Print the solution vector set. | |
Private Attributes | |
| SolveBlock | solve_block |
| Information about the solve block this handler is responsible for. | |
| std::vector< unsigned int > | block_to_global_index |
| Mapping from block index to global field index. | |
| std::vector< unsigned int > | global_to_block_index |
| Mapping from global field index to block index. | |
| SolutionLevel< dim, number > | primary_solutions |
| Primary solutions. | |
| std::vector< SolutionLevel< dim, number > > | solution_levels |
| Solutions projected to each mg level as dependencies. | |
| const MatrixFreeManager< dim, number > * | matrix_free_manager = nullptr |
| Pointer to MatrixFree manager. | |
| std::vector< SolutionTransfer > | block_solution_transfer |
| Utility for solution transfer to different mesh (for AMR). Can only work on one block at a time. | |
| std::vector< dealii::MGConstrainedDoFs > | mg_constraints |
| Constraints needed for mg transfer object. | |
| std::vector< dealii::MGTransferMatrixFree< dim, number > > | mg_transfer |
| Utility object to transfer solutions between multigrid levels. | |
Class that manages solution initialization and swapping with old solutions.
| using GroupSolutionHandler< dim, number >::SolutionTransfer |
| PRISMS_PF_BEGIN_NAMESPACE GroupSolutionHandler< dim, number >::GroupSolutionHandler | ( | SolveBlock | _solve_block, |
| const std::vector< FieldAttributes > & | _attributes_list, | ||
| const MatrixFreeManager< dim, number > & | _matrix_free_manager ) |
Constructor.
| void GroupSolutionHandler< dim, number >::apply_constraints | ( | ) |
Apply the constraints to the solution vector.
| void GroupSolutionHandler< dim, number >::apply_constraints | ( | BlockVector< number > & | solution_vectors | ) |
Apply the constraints to another vector.
| void GroupSolutionHandler< dim, number >::apply_constraints_to_all | ( | ) |
Apply the given constraints to all the solution vectors, including old.
| void GroupSolutionHandler< dim, number >::apply_initial_condition_for_old_fields | ( | ) |
Apply initial condition to the old fields. For now, this simply copies the values in the normal field to the old.
| void GroupSolutionHandler< dim, number >::execute_solution_transfer | ( | ) |
Transfer solutions.
|
nodiscard |
Get the block index from the global field index.
|
nodiscard |
Get the global index from the block index.
|
nodiscard |
Get the block index from the global index.
| const std::vector< MatrixFree< dim, number > > & GroupSolutionHandler< dim, number >::get_matrix_free_levels | ( | ) | const |
Get the underlying matrix_free objects.
|
nodiscard |
Get the old solution vector set at a given age.
|
nodiscard |
Get the old solution vector set at a given age.
|
nodiscard |
Get a solution vector of a given field index at a given age.
|
nodiscard |
Get a solution vector of a given field index at a given age.
|
nodiscard |
Get the solutions object at a level.
|
nodiscard |
Get the solutions object at a level.
|
nodiscard |
Get the solution vector set. This contains all the normal fields and is typically used for output.
|
nodiscard |
Get the const solution vector set. This contains all the normal fields and is typically used for output.
|
nodiscard |
Get the solutions object at a level.
|
nodiscard |
Get the solutions object at a level.
|
nodiscard |
Get a solution vector of a given field index.
|
nodiscard |
Get a solution vector of a given field index.
|
nodiscard |
Get the underlying solve block object.
| void GroupSolutionHandler< dim, number >::init | ( | const NewDependencyExtents & | extents | ) |
Initialize the solution set.
| void GroupSolutionHandler< dim, number >::init_solution_transfer | ( | ) |
Reinit the solution transfer objects.
|
inline |
Transfer solutions to mg levels.
|
nodiscard |
Number of refinement levels that will be tracked.
| void GroupSolutionHandler< dim, number >::prepare_for_solution_transfer | ( | ) |
Prepare for solution transfer.
| void GroupSolutionHandler< dim, number >::print_solution_full_vector | ( | std::ostream & | out | ) | const |
Print the solution vector set.
| void GroupSolutionHandler< dim, number >::reinit | ( | ) |
Reinitialize the solution set.
|
inline |
Reinit the solution transfer objects.
| void GroupSolutionHandler< dim, number >::update | ( | ) |
Update and propagate the old solutions.
| void GroupSolutionHandler< dim, number >::update_ghosts | ( | ) | const |
Update the ghost values.
| void GroupSolutionHandler< dim, number >::zero_out_ghosts | ( | ) | const |
Zero out the ghost values.
|
private |
Utility for solution transfer to different mesh (for AMR). Can only work on one block at a time.
|
private |
Mapping from block index to global field index.
|
private |
Mapping from global field index to block index.
|
private |
Pointer to MatrixFree manager.
|
private |
Constraints needed for mg transfer object.
|
private |
Utility object to transfer solutions between multigrid levels.
|
private |
Primary solutions.
|
private |
Solutions projected to each mg level as dependencies.
|
private |
Information about the solve block this handler is responsible for.