Belos  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
BelosMinresIteration.hpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // Belos: Block Linear Solvers Package
4 //
5 // Copyright 2004-2016 NTESS and the Belos contributors.
6 // SPDX-License-Identifier: BSD-3-Clause
7 // *****************************************************************************
8 // @HEADER
9 
10 #ifndef BELOS_MINRES_ITERATION_HPP
11 #define BELOS_MINRES_ITERATION_HPP
12 
17 #include "BelosConfigDefs.hpp"
18 #include "BelosTypes.hpp"
19 #include "BelosIteration.hpp"
20 
21 namespace Belos {
22 
24 
25 
30  template <class ScalarType, class MV>
32 
35 
38 
41 
44 
47 
50 
51  MinresIterationState() : Y(Teuchos::null),
52  R1(Teuchos::null),
53  R2(Teuchos::null),
54  W(Teuchos::null),
55  W1(Teuchos::null),
56  W2(Teuchos::null)
57  {}
58  };
59 
61 
62 
69  class MinresIterateFailure : public BelosError {public:
70  MinresIterateFailure(const std::string& what_arg) : BelosError(what_arg)
71  {}};
72 
74 
75 
76 template<class ScalarType, class MV, class OP>
77 class MinresIteration : virtual public Iteration<ScalarType,MV,OP> {
78 
79  public:
80 
82 
83 
97  virtual void initializeMinres(const MinresIterationState<ScalarType,MV> & newstate) = 0;
98 
105  virtual MinresIterationState<ScalarType,MV> getState() const = 0;
107 
108 };
109 
110 } // end Belos namespace
111 
112 #endif /* BELOS_MINRES_ITERATION_HPP */
Teuchos::RCP< const MV > R1
Previous residual.
Collection of types and exceptions used within the Belos solvers.
virtual void initializeMinres(const MinresIterationState< ScalarType, MV > &newstate)=0
Initialize the solver to an iterate, providing a complete state.
Pure virtual base class which describes the basic interface to the linear solver iteration.
Teuchos::RCP< const MV > R2
Previous residual.
MinresIterateFailure is thrown when the MinresIteration object is unable to compute the next iterate ...
Structure to contain pointers to MinresIteration state variables.
Teuchos::RCP< const MV > W2
Previous direction vector.
virtual MinresIterationState< ScalarType, MV > getState() const =0
Get the current state of the linear solver.
Teuchos::RCP< const MV > Y
The current residual.
Parent class to all Belos exceptions.
Definition: BelosTypes.hpp:28
Belos header file which uses auto-configuration information to include necessary C++ headers...
Teuchos::RCP< const MV > W1
Previous direction vector.
MinresIterateFailure(const std::string &what_arg)
Teuchos::RCP< const MV > W
The current direction vector.

Generated on Fri Dec 20 2024 09:24:49 for Belos by doxygen 1.8.5