MueLu  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MueLu_SmooVecCoalesceDropFactory_decl.hpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // MueLu: A package for multigrid based preconditioning
4 //
5 // Copyright 2012 NTESS and the MueLu contributors.
6 // SPDX-License-Identifier: BSD-3-Clause
7 // *****************************************************************************
8 // @HEADER
9 
10 #ifndef MUELU_SMOOVECCOALESCEDROPFACTORY_DECL_HPP
11 #define MUELU_SMOOVECCOALESCEDROPFACTORY_DECL_HPP
12 
13 #include <Xpetra_Matrix_fwd.hpp>
16 #include <Xpetra_Vector_fwd.hpp>
18 #include <Xpetra_Map_fwd.hpp>
19 
20 #include "MueLu_ConfigDefs.hpp"
23 
24 #include "MueLu_Level_fwd.hpp"
25 #include "MueLu_LWGraph.hpp"
26 
27 #include "MueLu_LWGraph_fwd.hpp"
29 
30 namespace MueLu {
31 
81 template <class Scalar = DefaultScalar,
84  class Node = DefaultNode>
86 #undef MUELU_SMOOVECCOALESCEDROPFACTORY_SHORT
87 #include "MueLu_UseShortNames.hpp"
88 
89  public:
91 
92 
95 
98 
100 
102 
104 
105 
106  void DeclareInput(Level& currentLevel) const;
107 
110 
112 
113  void Build(Level& currentLevel) const; // Build
114 
115  private:
116  // pre-drop function
118 
120  void badGuysCoalesceDrop(const Matrix& Amat, Teuchos::ArrayRCP<Scalar>& dropParams, LO nPDEs, const MultiVector& smoothedTVecs, const MultiVector& smoothedNull, RCP<LWGraph>& filteredGraph) const;
121  void badGuysDropfunc(LO row, const Teuchos::ArrayView<const LocalOrdinal>& indices, const Teuchos::ArrayView<const Scalar>& vals, const MultiVector& smoothedTVecs, LO nPDEs, Teuchos::ArrayRCP<Scalar>& penalties, const MultiVector& smoothedNull, Teuchos::ArrayRCP<LO>& Bcols, Teuchos::ArrayRCP<bool>& keepOrNot, LO& Nbcols, LO nLoc) const;
122 
123 }; // class SmooVecCoalesceDropFactory
124 
125 } // namespace MueLu
126 
127 #define MUELU_SMOOVECCOALESCEDROPFACTORY_SHORT
128 #endif // MUELU_SMOOVECCOALESCEDROPFACTORY_DECL_HPP
MueLu::DefaultLocalOrdinal LocalOrdinal
Tpetra::KokkosClassic::DefaultNode::DefaultNodeType DefaultNode
RCP< const ParameterList > GetValidParameterList() const
Return a const parameter list of valid parameters that setParameterList() will accept.
LocalOrdinal LO
Factory for creating a graph base on a given matrix.
MueLu::DefaultNode Node
void Build(Level &currentLevel) const
Build an object with this factory.
MueLu::DefaultScalar Scalar
Tpetra::Details::DefaultTypes::scalar_type DefaultScalar
MueLu::DefaultGlobalOrdinal GlobalOrdinal
Class that holds all level-specific information.
Definition: MueLu_Level.hpp:63
void SetPreDropFunction(const RCP< MueLu::PreDropFunctionBaseClass< Scalar, LocalOrdinal, GlobalOrdinal, Node > > &predrop)
set predrop function
void DeclareInput(Level &currentLevel) const
Input.
void badGuysDropfunc(LO row, const Teuchos::ArrayView< const LocalOrdinal > &indices, const Teuchos::ArrayView< const Scalar > &vals, const MultiVector &smoothedTVecs, LO nPDEs, Teuchos::ArrayRCP< Scalar > &penalties, const MultiVector &smoothedNull, Teuchos::ArrayRCP< LO > &Bcols, Teuchos::ArrayRCP< bool > &keepOrNot, LO &Nbcols, LO nLoc) const
void badGuysCoalesceDrop(const Matrix &Amat, Teuchos::ArrayRCP< Scalar > &dropParams, LO nPDEs, const MultiVector &smoothedTVecs, const MultiVector &smoothedNull, RCP< LWGraph > &filteredGraph) const
Methods to support compatible-relaxation style dropping.
Base class for factories that use one level (currentLevel).