56template <
typename T >
60 const typename T::SrcVectorType& src,
61 typename T::DstVectorType& dst,
62 dense::Vec< int, 2 > block ) {
64 typename T::SrcVectorType;
65 typename T::DstVectorType;
75 { self.apply_impl( src, dst ) } -> std::same_as< void >;
80template <
typename Op >
84 const int local_subdomain_id,
90 const dense::Mat< typename Op::ScalarType, Op::LocalMatrixDim, Op::LocalMatrixDim >& mat ) {
96 { Op::LocalMatrixDim } -> std::convertible_to< int >;
103 self_const.get_local_matrix( local_subdomain_id, x_cell, y_cell, r_cell, wedge )
104 } -> std::same_as< dense::Mat< typename Op::ScalarType, Op::LocalMatrixDim, Op::LocalMatrixDim > >;
106 { self_const.set_local_matrix( local_subdomain_id, x_cell, y_cell, r_cell, wedge, mat ) } -> std::same_as< void >;
110 { self_const.get_domain() } -> std::same_as< const grid::shell::DistributedDomain& >;
111 { self_const.get_radii() } -> std::same_as< grid::Grid2DDataScalar< typename Op::ScalarType > >;
116template <
typename T >
122 typename T::Block11Type;
123 typename T::Block12Type;
124 typename T::Block21Type;
125 typename T::Block22Type;
132 { self_const.block_11() } -> std::same_as< const typename T::Block11Type& >;
133 { self_const.block_12() } -> std::same_as< const typename T::Block12Type& >;
134 { self_const.block_21() } -> std::same_as< const typename T::Block21Type& >;
135 { self_const.block_22() } -> std::same_as< const typename T::Block22Type& >;
137 { self.block_11() } -> std::same_as< typename T::Block11Type& >;
138 { self.block_12() } -> std::same_as< typename T::Block12Type& >;
139 { self.block_21() } -> std::same_as< typename T::Block21Type& >;
140 { self.block_22() } -> std::same_as< typename T::Block22Type& >;
144template < OperatorLike Operator >
145using SrcOf = Operator::SrcVectorType;
148template < OperatorLike Operator >
149using DstOf = Operator::DstVectorType;
155template < OperatorLike Operator >
158 A.apply_impl( src, dst );
165template < VectorLike SrcVectorT, VectorLike DstVectorT >
Dummy block 2-vector class for concept checks and testing. Contains two DummyVector blocks.
Definition vector.hpp:253
Dummy block 2x2 operator for concept checks. Contains four DummyConcreteOperator blocks.
Definition operator.hpp:203
Block12Type & block_12()
Get mutable reference to block 12.
Definition operator.hpp:234
DummyConcreteOperator Block21Type
Definition operator.hpp:210
DummyConcreteOperator Block22Type
Definition operator.hpp:211
const Block22Type & block_22() const
Get const reference to block 22.
Definition operator.hpp:229
Block22Type & block_22()
Get mutable reference to block 22.
Definition operator.hpp:238
DummyConcreteOperator Block12Type
Definition operator.hpp:209
const Block21Type & block_21() const
Get const reference to block 21.
Definition operator.hpp:227
const Block11Type & block_11() const
Get const reference to block 11.
Definition operator.hpp:223
void apply_impl(const SrcVectorType &src, DstVectorType &dst) const
Dummy apply_impl, does nothing.
Definition operator.hpp:216
Block11Type & block_11()
Get mutable reference to block 11.
Definition operator.hpp:232
const Block12Type & block_12() const
Get const reference to block 12.
Definition operator.hpp:225
DummyConcreteOperator Block11Type
Definition operator.hpp:208
Block21Type & block_21()
Get mutable reference to block 21.
Definition operator.hpp:236
Dummy concrete operator for concept checks. Uses DummyVector as vector types.
Definition operator.hpp:185
void apply_impl(const SrcVectorType &src, DstVectorType &dst) const
Dummy apply_impl, does nothing.
Definition operator.hpp:193
Dummy operator for testing concepts. Implements apply_impl as a no-op.
Definition operator.hpp:167
DstVectorT DstVectorType
Definition operator.hpp:170
void apply_impl(const SrcVectorType &src, DstVectorType &dst) const
Dummy apply_impl, does nothing.
Definition operator.hpp:175
SrcVectorT SrcVectorType
Definition operator.hpp:169
Dummy vector class for concept checks and testing. Implements required vector operations as no-ops.
Definition vector.hpp:210
Concept for types that behave like block 2-vectors. Extends VectorLike and requires block types and a...
Definition vector.hpp:47
Concept for types that behave like block 2x2 operators. Extends OperatorLike and requires block types...
Definition operator.hpp:117
Concept for types that can be used as Galerkin coarse-grid operators in a multigrid hierarchy....
Definition operator.hpp:81
Concept for types that behave like linear operators.
Definition operator.hpp:57
Concept for types that behave like vectors. Requires exposing ScalarType and implementations for line...
Definition vector.hpp:8
Contains linear algebra utilities and functions for the Terra project.
Definition diagonally_scaled_operator.hpp:8
Operator::SrcVectorType SrcOf
Alias for the source vector type of an operator.
Definition operator.hpp:145
OperatorApplyMode
Modes for applying an operator to a vector.
Definition operator.hpp:30
@ Replace
Overwrite the destination vector.
@ Add
Add to the destination vector.
OperatorStoredMatrixMode
Modes for applying stored matrices.
Definition operator.hpp:47
@ Selective
Use stored matrices on selected, marked elements only, assemble on all others.
@ Full
Use stored matrices on all elements.
@ Off
Do not use stored matrices.
void apply(LinearForm &L, typename LinearForm::DstVectorType &dst)
Apply a linear form and write to a destination vector.
Definition linear_form.hpp:37
Operator::DstVectorType DstOf
Alias for the destination vector type of an operator.
Definition operator.hpp:149
OperatorCommunicationMode
Modes for communication during operator application.
Definition operator.hpp:40
@ SkipCommunication
Do not communicate.
@ CommunicateAdditively
Communicate and add results.