Anasazi Version of the Day
Loading...
Searching...
No Matches
AnasaziOperator.hpp
Go to the documentation of this file.
1// @HEADER
2// *****************************************************************************
3// Anasazi: Block Eigensolvers Package
4//
5// Copyright 2004 NTESS and the Anasazi contributors.
6// SPDX-License-Identifier: BSD-3-Clause
7// *****************************************************************************
8// @HEADER
9
14#ifndef ANASAZI_OPERATOR_HPP
15#define ANASAZI_OPERATOR_HPP
16
17#include "AnasaziConfigDefs.hpp"
19#include "AnasaziMultiVec.hpp"
20#include "Teuchos_ScalarTraits.hpp"
21
22
23namespace Anasazi {
24
34 template <class ScalarType>
35 class Operator {
36 public:
38
39
41
43 virtual ~Operator() {};
45
47
48
52 virtual void Apply ( const MultiVec<ScalarType>& x, MultiVec<ScalarType>& y ) const = 0;
53
55 };
56
58 //
59 // Implementation of the Anasazi::OperatorTraits for Anasazi::Operator
60 // and Anasazi::MultiVec.
61 //
63
72 template <class ScalarType>
73 class OperatorTraits < ScalarType, MultiVec<ScalarType>, Operator<ScalarType> >
74 {
75 public:
76
78
79
83 static void Apply ( const Operator<ScalarType>& Op,
84 const MultiVec<ScalarType>& x,
86 { Op.Apply( x, y ); }
87
89
90 };
91
92} // end of Anasazi namespace
93
94#endif
95
96// end of file AnasaziOperator.hpp
Anasazi header file which uses auto-configuration information to include necessary C++ headers.
Interface for multivectors used by Anasazi' linear solvers.
Virtual base class which defines basic traits for the operator type.
Interface for multivectors used by Anasazi's linear solvers.
static void Apply(const Operator< ScalarType > &Op, const MultiVec< ScalarType > &x, MultiVec< ScalarType > &y)
This method takes the Anasazi::MultiVec x and applies the Anasazi::Operator Op to it resulting in the...
Virtual base class which defines basic traits for the operator type.
Anasazi's templated virtual class for constructing an operator that can interface with the OperatorTr...
virtual ~Operator()
Destructor.
Operator()
Default constructor.
virtual void Apply(const MultiVec< ScalarType > &x, MultiVec< ScalarType > &y) const =0
This method takes the Anasazi::MultiVec x and applies the operator to it resulting in the Anasazi::Mu...
Namespace Anasazi contains the classes, structs, enums and utilities used by the Anasazi package.