deal.II version GIT relicensing-1941-ga9013bea74 2024-10-08 06:50:00+00:00
|
#include <deal.II/matrix_free/fe_remote_evaluation.h>
Public Member Functions | |
template<typename MeshType > | |
FERemoteEvaluation (const FERemoteEvaluationCommunicator< dim > &comm, const MeshType &mesh, const unsigned int first_selected_component=0, const VectorTools::EvaluationFlags::EvaluationFlags evaluation_flags=VectorTools::EvaluationFlags::avg) | |
template<typename VectorType > | |
void | gather_evaluate (const VectorType &src, const EvaluationFlags::EvaluationFlags flags) |
internal::PrecomputedEvaluationDataAccessor< dim, n_components, value_type > | get_data_accessor () const |
Private Member Functions | |
void | set_mesh (const Triangulation< dim > &tria) |
void | set_mesh (const DoFHandler< dim > &dof_handler) |
Private Attributes | |
internal::PrecomputedEvaluationData< dim, n_components, value_type > | data |
ObserverPointer< const FERemoteEvaluationCommunicator< dim > > | comm |
ObserverPointer< const Triangulation< dim > > | tria |
ObserverPointer< const DoFHandler< dim > > | dof_handler |
const unsigned int | first_selected_component |
const VectorTools::EvaluationFlags::EvaluationFlags | evaluation_flags |
Class to access data in a matrix-free loop for non-matching discretizations. Interfaces are named with FEEvaluation in mind. The main difference is, that gather_evaluate()
updates and caches all values at once. Therefore, it has to be called on one thread before a matrix-free loop.
To access values and gradients in a thread safe way, get_data_accessor()
has to be called on every thread. It provides the functions get_value()
and get_gradient()
.
Definition at line 538 of file fe_remote_evaluation.h.
FERemoteEvaluation< dim, n_components, value_type >::FERemoteEvaluation | ( | const FERemoteEvaluationCommunicator< dim > & | comm, |
const MeshType & | mesh, | ||
const unsigned int | first_selected_component = 0 , |
||
const VectorTools::EvaluationFlags::EvaluationFlags | evaluation_flags = VectorTools::EvaluationFlags::avg |
||
) |
The constructor needs a corresponding FERemoteEvaluationCommunicator which has to be set up outside of this class. This design choice is motivated since the same FERemoteEvaluationCommunicator can be used for different MeshTypes and number of components.
[in] | comm | FERemoteEvaluationCommunicator. |
[in] | mesh | Triangulation or DoFHandler. |
[in] | evaluation_flags | Specify treatment of values at points which are found on multiple cells. |
[in] | first_selected_component | Select first component of evaluation in DoFHandlers with multiple components. |
Definition at line 1459 of file fe_remote_evaluation.h.
void FERemoteEvaluation< dim, n_components, value_type >::gather_evaluate | ( | const VectorType & | src, |
const EvaluationFlags::EvaluationFlags | flags | ||
) |
Update the data which can be accessed via get_value()
and get_gradient()
.
[in] | src | Solution vector used to update data. |
[in] | flags | Evaluation flags. Currently supported are EvaluationFlags::values and EvaluationFlags::gradients. |
Definition at line 1474 of file fe_remote_evaluation.h.
internal::PrecomputedEvaluationDataAccessor< dim, n_components, value_type > FERemoteEvaluation< dim, n_components, value_type >::get_data_accessor | ( | ) | const |
FERemoteEvaluation
does not provide the functions get_value()
and get_gradient()
. To access values and/or gradients call get_data_accessor()
on every thread, e.g., auto remote_evaluator = get_data_accessor();
The returned object can be used as follows.
Definition at line 1503 of file fe_remote_evaluation.h.
|
private |
Use Triangulation as MeshType.
Definition at line 1512 of file fe_remote_evaluation.h.
|
private |
Use DoFHandler as MeshType.
Definition at line 1520 of file fe_remote_evaluation.h.
|
private |
Precomputed values and/or gradients at remote locations.
Definition at line 607 of file fe_remote_evaluation.h.
|
private |
Underlying communicator which handles update of the ghost values.
Definition at line 612 of file fe_remote_evaluation.h.
|
private |
Pointer to MeshType if used with Triangulation.
Definition at line 617 of file fe_remote_evaluation.h.
|
private |
Pointer to MeshType if used with DoFHandler.
Definition at line 622 of file fe_remote_evaluation.h.
|
private |
First selected component.
Definition at line 627 of file fe_remote_evaluation.h.
|
private |
Flags that indicate which ghost values are updated.
Definition at line 632 of file fe_remote_evaluation.h.