10 #ifndef __Belos_OrthoManagerFactory_hpp 
   11 #define __Belos_OrthoManagerFactory_hpp 
   14 #ifdef HAVE_BELOS_TSQR 
   16 #endif // HAVE_BELOS_TSQR 
   23 #include <Teuchos_StandardCatchMacros.hpp> 
   49   template<
class Scalar, 
class MV, 
class OP>
 
   53     std::vector<std::string> theList_;
 
   58 #ifdef HAVE_BELOS_TSQR 
   62 #endif // HAVE_BELOS_TSQR 
   71 #ifdef HAVE_BELOS_TSQR 
   73       return (name == 
"TSQR");
 
   76 #endif // HAVE_BELOS_TSQR 
   83       theList_[index++] = 
"ICGS";
 
   84       theList_[index++] = 
"IMGS";
 
   85       theList_[index++] = 
"DGKS";
 
   86 #ifdef HAVE_BELOS_TSQR 
   87       theList_[index++] = 
"TSQR";
 
   88 #endif // HAVE_BELOS_TSQR 
   89       theList_[index++] = 
"Simple";
 
  100     const std::vector<std::string>& 
 
  107       return (std::find (theList_.begin(), theList_.end(), name) != theList_.end());
 
  116        "Invalid number " << numValid << 
" of valid MatOrtho" 
  117        "Manager names.  Please report this bug to the Belos " 
  120   for (
int k = 0; k < numValid - 1; ++k)
 
  121     out << 
"\"" << theList_[k] << 
"\", ";
 
  124       out << 
"\"" << theList_[numValid-1] << 
"\"";
 
  135       std::ostringstream os;
 
  160       if (name == 
"DGKS") {
 
  161   return Belos::getDGKSDefaultParameters<Scalar, MV, OP> ();
 
  163 #ifdef HAVE_BELOS_TSQR 
  164       else if (name == 
"TSQR") {
 
  168 #endif // HAVE_BELOS_TSQR 
  169       else if (name == 
"ICGS") {
 
  170   return Belos::getICGSDefaultParameters<Scalar, MV, OP> ();
 
  172       else if (name == 
"IMGS") {
 
  173   return Belos::getIMGSDefaultParameters<Scalar, MV, OP> ();
 
  175       else if (name == 
"Simple") {
 
  181          "Invalid orthogonalization manager name \"" << name 
 
  183          << 
".  For many of the test executables, the " 
  184          "orthogonalization manager name often corresponds " 
  185          "to the \"ortho\" command-line argument.");
 
  208       if (name == 
"DGKS") {
 
  209   return Belos::getDGKSFastParameters<Scalar, MV, OP> ();
 
  211 #ifdef HAVE_BELOS_TSQR 
  212       else if (name == 
"TSQR") {
 
  216 #endif // HAVE_BELOS_TSQR 
  217       else if (name == 
"ICGS") {
 
  218   return Belos::getICGSFastParameters<Scalar, MV, OP> ();
 
  220       else if (name == 
"IMGS") {
 
  221   return Belos::getIMGSFastParameters<Scalar, MV, OP> ();
 
  223       else if (name == 
"Simple") {
 
  229          "Invalid orthogonalization manager name \"" << name 
 
  231          << 
".  For many of the test executables, the " 
  232          "orthogonalization manager name often corresponds " 
  233          "to the \"ortho\" command-line argument.");
 
  263        const std::string& label,
 
  266 #ifdef HAVE_BELOS_TSQR 
  268 #endif // HAVE_BELOS_TSQR 
  275       if (ortho == 
"DGKS") {
 
  277   return rcp (
new ortho_type (params, label, M));
 
  279 #ifdef HAVE_BELOS_TSQR 
  280       else if (ortho == 
"TSQR") {
 
  282   return rcp (
new ortho_type (params, label, M));
 
  284 #endif // HAVE_BELOS_TSQR 
  285       else if (ortho == 
"ICGS") {
 
  287   return rcp (
new ortho_type (params, label, M));
 
  289       else if (ortho == 
"IMGS") {
 
  291   return rcp (
new ortho_type (params, label, M));
 
  293       else if (ortho == 
"Simple") {
 
  295            "SimpleOrthoManager does not yet support " 
  296            "the MatOrthoManager interface");
 
  299          "Invalid orthogonalization manager name: Valid names" 
  301          "the test executables, the orthogonalization manager" 
  302          " name often corresponds to the \"ortho\" command-" 
  327           const std::string& label,
 
  330 #ifdef HAVE_BELOS_TSQR 
  332 #endif // HAVE_BELOS_TSQR 
  335       if (ortho == 
"Simple") {
 
  337            "SimpleOrthoManager is not yet supported " 
  338            "when the operator M is nontrivial (i.e., " 
  342 #ifdef HAVE_BELOS_TSQR 
  351       else if (ortho == 
"TSQR" && M.
is_null()) {
 
  354 #endif // HAVE_BELOS_TSQR 
  364 #endif // __Belos_OrthoManagerFactory_hpp 
Belos's basic output manager for sending information of select verbosity levels to the appropriate ou...
 
Teuchos::RCP< Belos::OrthoManager< Scalar, MV > > makeOrthoManager(const std::string &ortho, const Teuchos::RCP< const OP > &M, const Teuchos::RCP< OutputManager< Scalar > > &outMan, const std::string &label, const Teuchos::RCP< Teuchos::ParameterList > ¶ms)
Return an instance of the specified OrthoManager subclass. 
 
Class which manages the output and verbosity of the Belos solvers. 
 
static bool isRankRevealing(const std::string &name)
Is the given MatOrthoManager subclass rank-reealing? 
 
Teuchos::RCP< const Teuchos::ParameterList > getFastParameters()
Get "fast" parameters for TsqrMatOrthoManager. 
 
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
 
Teuchos::RCP< const Teuchos::ParameterList > getDefaultParameters(const std::string &name) const 
Default parameters for the given MatOrthoManager subclass. 
 
static int numOrthoManagers()
Number of MatOrthoManager subclasses this factory recognizes. 
 
std::string validNamesString() const 
List (as a string) of recognized MatOrthoManager names. 
 
Iterated Modified Gram-Schmidt (IMGS) implementation of the Belos::OrthoManager class. 
 
Simple OrthoManager implementation for benchmarks. 
 
OrthoManagerFactory()
Constructor. 
 
Classical Gram-Schmidt (with DGKS correction) implementation of the Belos::OrthoManager class...
 
Teuchos::RCP< const Teuchos::ParameterList > getFastParameters()
Get a "fast" list of parameters. 
 
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
 
Simple OrthoManager implementation for benchmarks. 
 
bool isValidName(const std::string &name) const 
Whether this factory recognizes the MatOrthoManager with the given name. 
 
std::ostream & printValidNames(std::ostream &out) const 
Print all recognized MatOrthoManager names to the given ostream. 
 
const std::string & defaultName() const 
Name of the "default" MatOrthoManager subclass. 
 
Teuchos::RCP< const Teuchos::ParameterList > getValidParameters() const 
Get a default list of parameters. 
 
Enumeration of all valid Belos (Mat)OrthoManager classes. 
 
Teuchos::RCP< const Teuchos::ParameterList > getValidParameters() const 
Get default parameters for TsqrMatOrthoManager. 
 
Iterated Classical Gram-Schmidt (ICGS) implementation of the Belos::OrthoManager class. 
 
An implementation of the Belos::MatOrthoManager that performs orthogonalization using multiple steps ...
 
An implementation of the Belos::MatOrthoManager that performs orthogonalization using multiple steps ...
 
#define TEUCHOS_UNREACHABLE_RETURN(dummyReturnVal)
 
An implementation of the Belos::MatOrthoManager that performs orthogonalization using (potentially) m...
 
Orthogonalization manager based on Tall Skinny QR (TSQR) 
 
Teuchos::RCP< const Teuchos::ParameterList > getFastParameters(const std::string &name) const 
"Fast" parameters for the given MatOrthoManager subclass. 
 
const std::vector< std::string > & validNames() const 
List of MatOrthoManager subclasses this factory recognizes. 
 
MatOrthoManager subclass using TSQR or DGKS. 
 
Belos header file which uses auto-configuration information to include necessary C++ headers...
 
TSQR-based OrthoManager subclass. 
 
Teuchos::RCP< Belos::MatOrthoManager< Scalar, MV, OP > > makeMatOrthoManager(const std::string &ortho, const Teuchos::RCP< const OP > &M, const Teuchos::RCP< OutputManager< Scalar > > &, const std::string &label, const Teuchos::RCP< Teuchos::ParameterList > ¶ms)
Return an instance of the specified MatOrthoManager subclass.