Belos Version of the Day
Loading...
Searching...
No Matches
BelosStubTsqrAdapter.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_StubTsqrAdapter_hpp
11#define __Belos_StubTsqrAdapter_hpp
12
13#include <BelosConfigDefs.hpp>
14#include <Teuchos_ParameterListAcceptorDefaultBase.hpp>
15#include <Teuchos_ScalarTraits.hpp>
16#include <Teuchos_TypeNameTraits.hpp>
17#include <stdexcept>
18
21
22namespace Belos {
23namespace details {
24
50 template<class MultiVectorType, class DM = DefaultDenseMatrix<int,double>>
51 class StubTsqrAdapter : public Teuchos::ParameterListAcceptorDefaultBase {
52 public:
54 typedef double scalar_type; // This doesn't really matter
55 typedef int ordinal_type; // This doesn't matter either
56 typedef int node_type; // Nor does this
57 typedef typename Teuchos::ScalarTraits<scalar_type>::magnitudeType magnitude_type;
58
65 StubTsqrAdapter (const Teuchos::RCP<Teuchos::ParameterList>& plist)
66 {
67 TEUCHOS_TEST_FOR_EXCEPTION(true, std::logic_error, "TSQR adapter for "
68 "multivector type \"" << Teuchos::TypeNameTraits<MV>::name()
69 << " is not yet implemented.");
70 }
71
74 {
75 TEUCHOS_TEST_FOR_EXCEPTION(true, std::logic_error, "TSQR adapter for "
76 "multivector type \"" << Teuchos::TypeNameTraits<MV>::name()
77 << " is not yet implemented.");
78 }
79
82 {
83 (void) rhs;
84 TEUCHOS_TEST_FOR_EXCEPTION(true, std::logic_error, "TSQR adapter for "
85 "multivector type \"" << Teuchos::TypeNameTraits<MV>::name()
86 << " is not yet implemented.");
87 }
88
90 Teuchos::RCP<const Teuchos::ParameterList>
92 {
93 TEUCHOS_TEST_FOR_EXCEPTION(true, std::logic_error, "TSQR adapter for "
94 "multivector type \"" << Teuchos::TypeNameTraits<MV>::name()
95 << " is not yet implemented.");
96 }
97
99 void
100 setParameterList (const Teuchos::RCP<Teuchos::ParameterList>& plist)
101 {
102 TEUCHOS_TEST_FOR_EXCEPTION(true, std::logic_error, "TSQR adapter for "
103 "multivector type \"" << Teuchos::TypeNameTraits<MV>::name()
104 << " is not yet implemented.");
105 }
106
108 void
110 MV& Q,
111 DM& R,
112 const bool forceNonnegativeDiagonal=false)
113 {
114 TEUCHOS_TEST_FOR_EXCEPTION(true, std::logic_error, "TSQR adapter for "
115 "multivector type \"" << Teuchos::TypeNameTraits<MV>::name()
116 << " is not yet implemented.");
117 }
118
120 int
122 DM& R,
123 const magnitude_type& tol)
124 {
125 // mfh 07 Sep 2012: In order to prevent compiler warnings on
126 // some platforms, we simply return some value. This code can
127 // never execute anyway, since it is in an instance method and
128 // all of the constructors throw exceptions. (We've overridden
129 // the default and copy constructors to throw exceptions.)
130 return 0;
131 }
132 };
133
134} // namespace details
135} // namespace Belos
136
137#endif // __Belos_StubTsqrAdapter_hpp
138
Belos header file which uses auto-configuration information to include necessary C++ headers.
Alternative run-time polymorphic interface for operators.
"Stub" TSQR adaptor for unsupported multivector types.
Teuchos::RCP< const Teuchos::ParameterList > getValidParameters() const
Get list of valid default parameters (stub; throws std::logic_error).
void setParameterList(const Teuchos::RCP< Teuchos::ParameterList > &plist)
Set parameters (stub; throws std::logic_error).
void factorExplicit(MV &A, MV &Q, DM &R, const bool forceNonnegativeDiagonal=false)
Compute QR factorization [Q,R] = qr(A,0) (stub; throws std::logic_error).
StubTsqrAdapter(const Teuchos::RCP< Teuchos::ParameterList > &plist)
Constructor (that accepts a parameter list).
Teuchos::ScalarTraits< scalar_type >::magnitudeType magnitude_type
StubTsqrAdapter()
Default constructor (stub; throws std::logic_error).
StubTsqrAdapter(const StubTsqrAdapter &rhs)
Copy constructor (throws std::logic_error).
int revealRank(MV &Q, DM &R, const magnitude_type &tol)
Rank-revealing decomposition (stub; does nothing).
Namespace containing implementation details of Belos solvers.

Generated for Belos by doxygen 1.9.8