BEM++  2.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
synthetic_integral_operator.hpp
1 // Copyright (C) 2011-2012 by the BEM++ Authors
2 //
3 // Permission is hereby granted, free of charge, to any person obtaining a copy
4 // of this software and associated documentation files (the "Software"), to deal
5 // in the Software without restriction, including without limitation the rights
6 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 // copies of the Software, and to permit persons to whom the Software is
8 // furnished to do so, subject to the following conditions:
9 //
10 // The above copyright notice and this permission notice shall be included in
11 // all copies or substantial portions of the Software.
12 //
13 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 // THE SOFTWARE.
20 
21 #ifndef bempp_synthetic_integral_operator_hpp
22 #define bempp_synthetic_integral_operator_hpp
23 
24 #include "../common/common.hpp"
25 
26 #include "abstract_boundary_operator.hpp"
27 #include "boundary_operator.hpp"
28 
29 #include "../common/shared_ptr.hpp"
30 
31 namespace Fiber
32 {
33 
35 template <typename ResultType> class LocalAssemblerForOperators;
38 } // namespace Fiber
39 
40 namespace Bempp
41 {
42 
101 template <typename BasisFunctionType_, typename ResultType_>
103  public AbstractBoundaryOperator<BasisFunctionType_, ResultType_>
104 {
106 public:
110  typedef typename Base::ResultType ResultType;
115  typedef typename Fiber::LocalAssemblerForOperators<ResultType>
116  LocalAssembler;
117 
140  const std::vector<BoundaryOperator<BasisFunctionType, ResultType> >& testLocalOps,
142  const std::vector<BoundaryOperator<BasisFunctionType, ResultType> >& trialLocalOps,
143  const std::string& label = "",
144  int syntheseSymmetry = NO_SYMMETRY);
145 
146  virtual bool isLocal() const;
147 
151  const shared_ptr<const Context<BasisFunctionType, ResultType> >& context,
152  shared_ptr<const Context<BasisFunctionType, ResultType> >& internalContext,
153  shared_ptr<const Context<BasisFunctionType, ResultType> >& auxContext);
154 
155 protected:
156  virtual shared_ptr<DiscreteBoundaryOperator<ResultType_> >
158  const Context<BasisFunctionType, ResultType>& context) const;
159 
160 private:
162  void checkIntegralOperator() const;
163  void checkTestLocalOperators() const;
164  void checkTrialLocalOperators() const;
165 
166 private:
168  std::vector<BoundaryOperator<BasisFunctionType, ResultType> > m_testLocalOps;
169  std::vector<BoundaryOperator<BasisFunctionType, ResultType> > m_trialLocalOps;
170  int m_syntheseSymmetry;
172 };
173 
174 } //namespace Bempp
175 
176 #endif
Base::CoordinateType CoordinateType
Type used to represent coordinates.
Definition: synthetic_integral_operator.hpp:112
std::string label() const
Return the label of the operator.
Definition: abstract_boundary_operator.cpp:149
Base::QuadratureStrategy QuadratureStrategy
Type of the appropriate instantiation of Fiber::QuadratureStrategy.
Definition: synthetic_integral_operator.hpp:114
Base class for quadrature strategies.
Definition: quadrature_strategy.hpp:242
Integral operator with weak form assembled from several pieces.
Definition: synthetic_integral_operator.hpp:102
SyntheticIntegralOperator(const std::vector< BoundaryOperator< BasisFunctionType, ResultType > > &testLocalOps, const BoundaryOperator< BasisFunctionType, ResultType > &integralOp, const std::vector< BoundaryOperator< BasisFunctionType, ResultType > > &trialLocalOps, const std::string &label="", int syntheseSymmetry=NO_SYMMETRY)
Constructor.
Definition: synthetic_integral_operator.cpp:217
Assembly context.
Definition: context.hpp:30
BasisFunctionType_ BasisFunctionType
Type of the values of the (components of the) basis functions into which functions acted upon by the ...
Definition: abstract_boundary_operator.hpp:95
Operator acting on functions defined on a surface.
Definition: boundary_operator.hpp:63
static void getContextsForInternalAndAuxiliaryOperators(const shared_ptr< const Context< BasisFunctionType, ResultType > > &context, shared_ptr< const Context< BasisFunctionType, ResultType > > &internalContext, shared_ptr< const Context< BasisFunctionType, ResultType > > &auxContext)
Get contexts appropriate for construction of internal integral operators and auxiliary local operator...
Definition: synthetic_integral_operator.cpp:481
Abstract (non-discretized) boundary operator.
Definition: abstract_boundary_operator.hpp:90
ScalarTraits< ResultType >::RealType CoordinateType
Type used to represent coordinates.
Definition: abstract_boundary_operator.hpp:99
virtual shared_ptr< DiscreteBoundaryOperator< ResultType_ > > assembleWeakFormImpl(const Context< BasisFunctionType, ResultType > &context) const
Assemble and return the operator&#39;s weak form.
Definition: synthetic_integral_operator.cpp:338
Base::ResultType ResultType
Type used to represent elements of the weak form of the operator.
Definition: synthetic_integral_operator.hpp:110
ResultType_ ResultType
Type used to represent elements of the weak form of the operator.
Definition: abstract_boundary_operator.hpp:97
Base::BasisFunctionType BasisFunctionType
Type of the values of the (components of the) basis functions into which functions acted upon by the ...
Definition: synthetic_integral_operator.hpp:108
virtual bool isLocal() const
Return whether this operator is local.
Definition: synthetic_integral_operator.cpp:260