Tpetra parallel linear algebra  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Tpetra_leftAndOrRightScaleCrsMatrix_decl.hpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // Tpetra: Templated Linear Algebra Services Package
4 //
5 // Copyright 2008 NTESS and the Tpetra contributors.
6 // SPDX-License-Identifier: BSD-3-Clause
7 // *****************************************************************************
8 // @HEADER
9 
10 #ifndef TPETRA_LEFTANDORRIGHTSCALECRSMATRIX_DECL_HPP
11 #define TPETRA_LEFTANDORRIGHTSCALECRSMATRIX_DECL_HPP
12 
15 
16 #include "TpetraCore_config.h"
17 #include "Kokkos_ArithTraits.hpp"
18 #include "Kokkos_Core.hpp"
19 #include "Tpetra_CrsMatrix_fwd.hpp"
20 #include "Tpetra_Vector_fwd.hpp"
21 
22 namespace Tpetra {
23 
28 enum EScaling {
29  SCALING_MULTIPLY,
30  SCALING_DIVIDE
31 };
32 
59 template<class SC, class LO, class GO, class NT>
60 void
62  const Kokkos::View<
63  const typename Kokkos::ArithTraits<SC>::mag_type*,
64  typename NT::device_type>& rowScalingFactors,
65  const Kokkos::View<
66  const typename Kokkos::ArithTraits<SC>::mag_type*,
67  typename NT::device_type>& colScalingFactors,
68  const bool leftScale,
69  const bool rightScale,
70  const bool assumeSymmetric,
71  const EScaling scaling);
72 
100 template<class SC, class LO, class GO, class NT>
101 void
103  const Tpetra::Vector<typename Kokkos::ArithTraits<SC>::mag_type,
104  LO, GO, NT>& rowScalingFactors,
105  const Tpetra::Vector<typename Kokkos::ArithTraits<SC>::mag_type,
106  LO, GO, NT>& colScalingFactors,
107  const bool leftScale,
108  const bool rightScale,
109  const bool assumeSymmetric,
110  const EScaling scaling);
111 
112 } // namespace Tpetra
113 
114 #endif // TPETRA_LEFTANDORRIGHTSCALECRSMATRIX_DECL_HPP
Sparse matrix that presents a row-oriented interface that lets users read or modify entries...
void leftAndOrRightScaleCrsMatrix(Tpetra::CrsMatrix< SC, LO, GO, NT > &A, const Kokkos::View< const typename Kokkos::ArithTraits< SC >::mag_type *, typename NT::device_type > &rowScalingFactors, const Kokkos::View< const typename Kokkos::ArithTraits< SC >::mag_type *, typename NT::device_type > &colScalingFactors, const bool leftScale, const bool rightScale, const bool assumeSymmetric, const EScaling scaling)
Left-scale and/or right-scale (in that order) the entries of the input Tpetra::CrsMatrix A...
EScaling
Whether &quot;scaling&quot; a matrix means multiplying or dividing its entries.
Forward declaration of Tpetra::CrsMatrix.
Forward declaration of Tpetra::Vector.
A distributed dense vector.