BEM++
2.0
|
Abstract (non-discretized) boundary operator. More...
#include </home/wojtek/Projects/BEM/bempp-sven/bempp/lib/assembly/abstract_boundary_operator.hpp>
Public Types | |
typedef BasisFunctionType_ | BasisFunctionType |
Type of the values of the (components of the) basis functions into which functions acted upon by the operator are expanded. | |
typedef ResultType_ | ResultType |
Type used to represent elements of the weak form of the operator. | |
typedef ScalarTraits < ResultType >::RealType | CoordinateType |
Type used to represent coordinates. | |
typedef Fiber::QuadratureStrategy < BasisFunctionType, ResultType, GeometryFactory > | QuadratureStrategy |
Type of the appropriate instantiation of Fiber::QuadratureStrategy. | |
Public Member Functions | |
Construction and destruction | |
AbstractBoundaryOperator (const shared_ptr< const Space< BasisFunctionType > > &domain, const shared_ptr< const Space< BasisFunctionType > > &range, const shared_ptr< const Space< BasisFunctionType > > &dualToRange, const std::string &label, int symmetry) | |
Constructor. More... | |
virtual | ~AbstractBoundaryOperator () |
Destructor. | |
virtual BEMPP_DEPRECATED shared_ptr< const AbstractBoundaryOperatorId > | id () const |
Return the identifier of this operator. More... | |
Spaces | |
shared_ptr< const Space < BasisFunctionType > > | domain () const |
Domain. More... | |
shared_ptr< const Space < BasisFunctionType > > | range () const |
Range. More... | |
shared_ptr< const Space < BasisFunctionType > > | dualToRange () const |
Dual to range. More... | |
Other attributes | |
std::string | label () const |
Return the label of the operator. | |
int | symmetry () const |
Return the symmetry properties of the operator. More... | |
virtual bool | isLocal () const =0 |
Return whether this operator is local. More... | |
static std::string | uniqueLabel () |
Generate and return a new unique label "OpN", where N is a number. | |
Assembly | |
shared_ptr < DiscreteBoundaryOperator < ResultType_ > > | assembleWeakForm (const Context< BasisFunctionType_, ResultType_ > &context) const |
Assemble and return the operator's weak form. More... | |
void | collectDataForAssemblerConstruction (const AssemblyOptions &options, shared_ptr< Fiber::RawGridGeometry< CoordinateType > > &testRawGeometry, shared_ptr< Fiber::RawGridGeometry< CoordinateType > > &trialRawGeometry, shared_ptr< GeometryFactory > &testGeometryFactory, shared_ptr< GeometryFactory > &trialGeometryFactory, shared_ptr< std::vector< const Fiber::Shapeset< BasisFunctionType_ > * > > &testShapesets, shared_ptr< std::vector< const Fiber::Shapeset< BasisFunctionType_ > * > > &trialShapesets, shared_ptr< Fiber::OpenClHandler > &openClHandler, bool &cacheSingularIntegrals) const |
Given an AssemblyOptions object, construct objects necessary for subsequent local assembler construction. | |
void | collectOptionsIndependentDataForAssemblerConstruction (shared_ptr< Fiber::RawGridGeometry< CoordinateType > > &testRawGeometry, shared_ptr< Fiber::RawGridGeometry< CoordinateType > > &trialRawGeometry, shared_ptr< GeometryFactory > &testGeometryFactory, shared_ptr< GeometryFactory > &trialGeometryFactory, shared_ptr< std::vector< const Fiber::Shapeset< BasisFunctionType_ > * > > &testShapesets, shared_ptr< std::vector< const Fiber::Shapeset< BasisFunctionType_ > * > > &trialShapesets) const |
Construct those objects necessary for subsequent local assembler construction that are independent from assembly options. | |
void | collectOptionsDependentDataForAssemblerConstruction (const AssemblyOptions &options, const shared_ptr< Fiber::RawGridGeometry< CoordinateType > > &testRawGeometry, const shared_ptr< Fiber::RawGridGeometry< CoordinateType > > &trialRawGeometry, shared_ptr< Fiber::OpenClHandler > &openClHandler, bool &cacheSingularIntegrals) const |
Construct those objects necessary for subsequent local assembler construction that depend on assembly options. | |
virtual shared_ptr < DiscreteBoundaryOperator < ResultType > > | assembleWeakFormImpl (const Context< BasisFunctionType, ResultType > &context) const =0 |
Assemble and return the operator's weak form. More... | |
Abstract (non-discretized) boundary operator.
An AbstractBoundaryOperator represents a linear mapping between two function spaces
(domain) and
(range) defined on
-dimensional surfaces
and
embedded in an
-dimensional domain. Each of the symbols
and
can stand either for the set of real or complex numbers. The surfaces
and
may be equal.
The function assembleWeakForm() can be used to construct the weak form of the operator.
BasisFunctionType_ | Type of the values of the (components of the) basis functions into which functions acted upon by the operator are expanded. |
ResultType_ | Type used to represent elements of the weak form of the operator. |
Both template parameters can take the following values: float
, double
, std::complex<float>
and std::complex<double>
. Both types must have the same precision: for instance, mixing float
with std::complex<double>
is not allowed. If BasisFunctionType_
is set to a complex type, then ResultType_
must be set to the same type.
Bempp::AbstractBoundaryOperator< BasisFunctionType, ResultType >::AbstractBoundaryOperator | ( | const shared_ptr< const Space< BasisFunctionType > > & | domain, |
const shared_ptr< const Space< BasisFunctionType > > & | range, | ||
const shared_ptr< const Space< BasisFunctionType > > & | dualToRange, | ||
const std::string & | label, | ||
int | symmetry | ||
) |
Constructor.
[in] | domain | Function space being the domain of the operator. |
[in] | range | Function space being the range of the operator. |
[in] | dualToRange | Function space dual to the the range of the operator. |
[in] | label | Textual label of the operator. If empty, a unique label is generated automatically. |
[in] | symmetry | Symmetry of the weak form of the operator. Can be any combination of the flags defined in the enumeration type Symmetry. |
None of the shared pointers may be null and the spaces range
and dualToRange
must be defined on the same grid, otherwise an exception is thrown.
References Bempp::AbstractBoundaryOperator< BasisFunctionType_, ResultType_ >::uniqueLabel().
shared_ptr< DiscreteBoundaryOperator< ResultType > > Bempp::AbstractBoundaryOperator< BasisFunctionType, ResultType >::assembleWeakForm | ( | const Context< BasisFunctionType, ResultType > & | context | ) | const |
Assemble and return the operator's weak form.
This function constructs a discrete linear operator representing the matrix with entries of the form
where is the linear operator represented by this object,
denotes the surface on which the domain function space
is defined and which is represented by the grid returned by
domain.grid()
, is a test function from the space
dual to the range of the operator,
, and
is a trial function from the domain space
.
Referenced by Bempp::DiscreteBoundaryOperatorCache< BasisFunctionType, ResultType >::getWeakForm(), and Bempp::Context< BasisFunctionType, ResultType >::getWeakForm().
|
protectedpure virtual |
Assemble and return the operator's weak form.
This virtual function is invoked by assembleWeakForm() to do the actual work.
Implemented in Bempp::SyntheticIntegralOperator< BasisFunctionType_, ResultType_ >, Bempp::HypersingularIntegralOperator< BasisFunctionType_, KernelType_, ResultType_ >, Bempp::ElementaryIntegralOperator< BasisFunctionType_, KernelType_, ResultType_ >, Bempp::ElementaryIntegralOperator< BasisFunctionType, KernelType, ResultType >, Bempp::NullOperator< BasisFunctionType_, ResultType_ >, Bempp::AdjointAbstractBoundaryOperator< BasisFunctionType_, ResultType_ >, Bempp::ElementaryLocalOperator< BasisFunctionType_, ResultType_ >, Bempp::AbstractBoundaryOperatorComposition< BasisFunctionType_, ResultType_ >, Bempp::AbstractBoundaryOperatorPseudoinverse< BasisFunctionType_, ResultType_ >, and Bempp::AbstractBoundaryOperatorSuperpositionBase< BasisFunctionType_, ResultType_ >.
shared_ptr< const Space< BasisFunctionType > > Bempp::AbstractBoundaryOperator< BasisFunctionType, ResultType >::domain | ( | ) | const |
Domain.
Return a shared pointer to the function space being the domain of this operator.
shared_ptr< const Space< BasisFunctionType > > Bempp::AbstractBoundaryOperator< BasisFunctionType, ResultType >::dualToRange | ( | ) | const |
Dual to range.
Return a shared pointer to the function space dual to the range of this operator.
|
virtual |
Return the identifier of this operator.
If the weak form of this operator is cacheable, return a shared pointer to a valid instance of a subclass of AbstractBoundaryOperatorId that is guaranteed to be different for all logically different abstract boundary operators.
If the weak form of this operator is not cacheable, return a null shared pointer. This is the default implementation.
Reimplemented in Bempp::IdentityOperator< BasisFunctionType_, ResultType_ >, Bempp::NullOperator< BasisFunctionType_, ResultType_ >, and Bempp::AbstractBoundaryOperatorPseudoinverse< BasisFunctionType_, ResultType_ >.
Referenced by Bempp::DiscreteBoundaryOperatorCache< BasisFunctionType, ResultType >::getWeakForm().
|
pure virtual |
Return whether this operator is local.
Suppose that an operator acting on a function
produces another function
. We say that
is local if the value of
at any point
depends only on the values of
in an infinitesimal neighbourhood of
.
Multiplicative and differential operators are local and discretization of their weak forms with finite elements leads to sparse matrices. Conversely, integral operators are in general non-local and discretization of their weak forms leads to dense matrices.
Implemented in Bempp::HypersingularIntegralOperator< BasisFunctionType_, KernelType_, ResultType_ >, Bempp::SyntheticIntegralOperator< BasisFunctionType_, ResultType_ >, Bempp::ElementaryIntegralOperator< BasisFunctionType_, KernelType_, ResultType_ >, Bempp::ElementaryIntegralOperator< BasisFunctionType, KernelType, ResultType >, Bempp::NullOperator< BasisFunctionType_, ResultType_ >, Bempp::AdjointAbstractBoundaryOperator< BasisFunctionType_, ResultType_ >, Bempp::ElementaryLocalOperator< BasisFunctionType_, ResultType_ >, Bempp::AbstractBoundaryOperatorComposition< BasisFunctionType_, ResultType_ >, Bempp::AbstractBoundaryOperatorSum< BasisFunctionType_, ResultType_ >, Bempp::AbstractBoundaryOperatorPseudoinverse< BasisFunctionType_, ResultType_ >, and Bempp::ScaledAbstractBoundaryOperator< BasisFunctionType_, ResultType_ >.
shared_ptr< const Space< BasisFunctionType > > Bempp::AbstractBoundaryOperator< BasisFunctionType, ResultType >::range | ( | ) | const |
Range.
Return a shared pointer to the function space being the range of this operator.
int Bempp::AbstractBoundaryOperator< BasisFunctionType, ResultType >::symmetry | ( | ) | const |
Return the symmetry properties of the operator.
The returned value should be treated as a bitwise combination of the flags defined in the Symmetry enumeration type.