Thyra  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Thyra_DefaultDiagonalLinearOpWithSolve_decl.hpp
1 // @HEADER
2 // *****************************************************************************
3 // Thyra: Interfaces and Support for Abstract Numerical Algorithms
4 //
5 // Copyright 2004 NTESS and the Thyra contributors.
6 // SPDX-License-Identifier: BSD-3-Clause
7 // *****************************************************************************
8 // @HEADER
9 
10 #ifndef THYRA_DIAGONAL_LINEAR_OP_WITH_SOLVE_DECL_HPP
11 #define THYRA_DIAGONAL_LINEAR_OP_WITH_SOLVE_DECL_HPP
12 
13 #include "Thyra_DefaultDiagonalLinearOp.hpp"
14 #include "Thyra_LinearOpWithSolveBase.hpp"
15 
16 
17 namespace Thyra {
18 
19 
59 template<class Scalar>
61  : virtual public DefaultDiagonalLinearOp<Scalar>,
62  virtual public LinearOpWithSolveBase<Scalar>
63 {
64 public:
65 
68 
76 
79  const RCP<const VectorBase<Scalar> > &diag
80  );
81 
82 protected:
83 
87  bool solveSupportsImpl(EOpTransp M_trans) const;
90  EOpTransp M_trans, const SolveMeasureType& solveMeasureType) const;
93  const EOpTransp transp,
94  const MultiVectorBase<Scalar> &B,
95  const Ptr<MultiVectorBase<Scalar> > &X,
96  const Ptr<const SolveCriteria<Scalar> > solveCriteria
97  ) const;
99 
100 };
101 
102 
107 template<class Scalar>
110 {
112 }
113 
114 
119 template<class Scalar>
122  const RCP<const VectorBase<Scalar> > &diag
123  )
124 {
126  defaultDiagonalLinearOpWithSolve<Scalar>();
127  ddlows->initialize(diag);
128  return ddlows;
129 }
130 
131 
132 
133 } // end namespace Thyra
134 
135 
136 #endif // THYRA_DIAGONAL_LINEAR_OP_WITH_SOLVE_DECL_HPP
Base class for all linear operators that can support a high-level solve operation.
EOpTransp
Enumeration for determining how a linear operator is applied. `*.
RCP< DefaultDiagonalLinearOpWithSolve< Scalar > > defaultDiagonalLinearOpWithSolve()
Nonmember constructor.
SolveStatus< Scalar > solveImpl(const EOpTransp transp, const MultiVectorBase< Scalar > &B, const Ptr< MultiVectorBase< Scalar > > &X, const Ptr< const SolveCriteria< Scalar > > solveCriteria) const
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
Interface for a collection of column vectors called a multi-vector.
Concrete LinearOpWithSolveBase subclass for diagonal linear operators.
RCP< DefaultDiagonalLinearOpWithSolve< Scalar > > defaultDiagonalLinearOpWithSolve(const RCP< const VectorBase< Scalar > > &diag)
Nonmember constructor.
Abstract interface for finite-dimensional dense vectors.
Simple struct for the return status from a solve.
bool solveSupportsSolveMeasureTypeImpl(EOpTransp M_trans, const SolveMeasureType &solveMeasureType) const
Simple struct that defines the requested solution criteria for a solve.
Default concrete LinearOpBase subclass for diagonal linear operators.