DUNE-FEM (unstable)

eigenoperator.hh
1#ifndef DUNE_FEM_EIGENOPERATOR_HH
2#define DUNE_FEM_EIGENOPERATOR_HH
3
4#ifdef HAVE_EIGEN
5
6// system includes
7#include <string>
8
9// local includes
10#include <dune/fem/operator/matrix/eigenmatrix.hh>
11
12namespace Dune
13{
14
15 namespace Fem
16 {
17
19 template< class DomainFunction, class RangeFunction >
20 struct EigenLinearOperator
21 : public EigenMatrixObject< typename DomainFunction::DiscreteFunctionSpaceType, typename RangeFunction::DiscreteFunctionSpaceType >,
22 public Fem::AssembledOperator< DomainFunction, RangeFunction >
23 {
24 typedef typename DomainFunction::DiscreteFunctionSpaceType DomainSpaceType;
25 typedef typename RangeFunction::DiscreteFunctionSpaceType RangeSpaceType;
26 typedef EigenLinearOperator< DomainFunction, RangeFunction > ThisType;
27 typedef EigenMatrixObject< DomainSpaceType, RangeSpaceType > BaseType;
28
29 static constexpr bool assembled = true ;
30
31 using BaseType::apply;
32 using BaseType::exportMatrix;
33
34 EigenLinearOperator( const std::string & ,
35 const DomainSpaceType &domainSpace,
36 const RangeSpaceType &rangeSpace,
37 const SolverParameter& param = SolverParameter() ) :
38 BaseType( domainSpace, rangeSpace, param )
39 {}
40
41 virtual void clear() { BaseType::clear(); }
42
43 virtual void operator()( const DomainFunction &arg, RangeFunction &dest ) const
44 {
45 apply( arg, dest );
46 }
47
48 };
49 } // namespace Fem
50
51} // namespace Dune
52
53#endif
54
55#endif // #ifndef DUNE_FEM_SPLINEAR_HH
Dune namespace.
Definition: alignedallocator.hh:13
Creative Commons License   |  Legal Statements / Impressum  |  Hosted by TU Dresden  |  generated with Hugo v0.111.3 (Jul 27, 22:29, 2024)