Anasazi Version of the Day
Loading...
Searching...
No Matches
AnasaziOrthoManager.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_ORTHOMANAGER_HPP
15#define ANASAZI_ORTHOMANAGER_HPP
16
31#include "AnasaziConfigDefs.hpp"
32#include "AnasaziTypes.hpp"
33#include "Teuchos_ScalarTraits.hpp"
34#include "Teuchos_RCP.hpp"
35#include "Teuchos_SerialDenseMatrix.hpp"
36#include "Teuchos_Array.hpp"
37
38
39
40
41namespace Anasazi {
42
43
45
46
49 class OrthoError : public AnasaziError
50 {public: OrthoError(const std::string& what_arg) : AnasaziError(what_arg) {}};
51
53
54 template <class ScalarType, class MV>
56 public:
58
59
61
63 virtual ~OrthoManager() {};
65
67
68
82 virtual void innerProd( const MV &X, const MV &Y, Teuchos::SerialDenseMatrix<int,ScalarType>& Z ) const = 0;
83
84
97 virtual void norm( const MV& X, std::vector< typename Teuchos::ScalarTraits<ScalarType>::magnitudeType > &normvec ) const = 0;
98
99
100
139 virtual void project (
140 MV &X,
141 Teuchos::Array<Teuchos::RCP<const MV> > Q,
142 Teuchos::Array<Teuchos::RCP<Teuchos::SerialDenseMatrix<int,ScalarType> > > C
143 = Teuchos::tuple(Teuchos::RCP< Teuchos::SerialDenseMatrix<int,ScalarType> >(Teuchos::null))
144 ) const = 0;
145
146
147
188 virtual int normalize (
189 MV &X,
190 Teuchos::RCP<Teuchos::SerialDenseMatrix<int,ScalarType> > B = Teuchos::null) const = 0;
191
192
258 virtual int projectAndNormalize (
259 MV &X,
260 Teuchos::Array<Teuchos::RCP<const MV> > Q,
261 Teuchos::Array<Teuchos::RCP<Teuchos::SerialDenseMatrix<int,ScalarType> > > C
262 = Teuchos::tuple(Teuchos::RCP< Teuchos::SerialDenseMatrix<int,ScalarType> >(Teuchos::null)),
263 Teuchos::RCP<Teuchos::SerialDenseMatrix<int,ScalarType> > B = Teuchos::null
264 ) const = 0;
265
267
269
270
276 virtual typename Teuchos::ScalarTraits< ScalarType >::magnitudeType orthonormError(const MV &X) const = 0;
277
283 virtual typename Teuchos::ScalarTraits<ScalarType>::magnitudeType orthogError(const MV &X1, const MV &X2) const = 0;
284
286
287 };
288
289} // end of Anasazi namespace
290
291
292#endif
293
294// end of file AnasaziOrthoManager.hpp
Anasazi header file which uses auto-configuration information to include necessary C++ headers.
Types and exceptions used within Anasazi solvers and interfaces.
An exception class parent to all Anasazi exceptions.
Exception thrown to signal error in an orthogonalization manager method.
Anasazi's templated virtual class for providing routines for orthogonalization and orthonormalization...
virtual void norm(const MV &X, std::vector< typename Teuchos::ScalarTraits< ScalarType >::magnitudeType > &normvec) const =0
Provides the norm induced by innerProd().
virtual int normalize(MV &X, Teuchos::RCP< Teuchos::SerialDenseMatrix< int, ScalarType > > B=Teuchos::null) const =0
This method takes a multivector X and attempts to compute a basis for . This basis is orthonormal wit...
virtual int projectAndNormalize(MV &X, Teuchos::Array< Teuchos::RCP< const MV > > Q, Teuchos::Array< Teuchos::RCP< Teuchos::SerialDenseMatrix< int, ScalarType > > > C=Teuchos::tuple(Teuchos::RCP< Teuchos::SerialDenseMatrix< int, ScalarType > >(Teuchos::null)), Teuchos::RCP< Teuchos::SerialDenseMatrix< int, ScalarType > > B=Teuchos::null) const =0
Given a set of bases Q[i] and a multivector X, this method computes an orthonormal basis for .
virtual void innerProd(const MV &X, const MV &Y, Teuchos::SerialDenseMatrix< int, ScalarType > &Z) const =0
Provides the inner product defining the orthogonality concepts.
virtual void project(MV &X, Teuchos::Array< Teuchos::RCP< const MV > > Q, Teuchos::Array< Teuchos::RCP< Teuchos::SerialDenseMatrix< int, ScalarType > > > C=Teuchos::tuple(Teuchos::RCP< Teuchos::SerialDenseMatrix< int, ScalarType > >(Teuchos::null))) const =0
Given a list of mutually orthogonal and internally orthonormal bases Q, this method projects a multiv...
virtual Teuchos::ScalarTraits< ScalarType >::magnitudeType orthogError(const MV &X1, const MV &X2) const =0
This method computes the error in orthogonality of two multivectors.
virtual ~OrthoManager()
Destructor.
OrthoManager()
Default constructor.
virtual Teuchos::ScalarTraits< ScalarType >::magnitudeType orthonormError(const MV &X) const =0
This method computes the error in orthonormality of a multivector.
Namespace Anasazi contains the classes, structs, enums and utilities used by the Anasazi package.