Tpetra parallel linear algebra Version of the Day
Loading...
Searching...
No Matches
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_Core.hpp"
18#include "KokkosKernels_ArithTraits.hpp"
20#include "Tpetra_Vector_fwd.hpp"
21
22namespace Tpetra {
23
29 SCALING_MULTIPLY,
30 SCALING_DIVIDE
31};
32
59template <class SC, class LO, class GO, class NT>
61 const Kokkos::View<
62 const typename KokkosKernels::ArithTraits<SC>::mag_type*,
63 typename NT::device_type>& rowScalingFactors,
64 const Kokkos::View<
65 const typename KokkosKernels::ArithTraits<SC>::mag_type*,
66 typename NT::device_type>& colScalingFactors,
67 const bool leftScale,
68 const bool rightScale,
69 const bool assumeSymmetric,
70 const EScaling scaling);
71
99template <class SC, class LO, class GO, class NT>
101 const Tpetra::Vector<typename KokkosKernels::ArithTraits<SC>::mag_type,
102 LO, GO, NT>& rowScalingFactors,
103 const Tpetra::Vector<typename KokkosKernels::ArithTraits<SC>::mag_type,
104 LO, GO, NT>& colScalingFactors,
105 const bool leftScale,
106 const bool rightScale,
107 const bool assumeSymmetric,
108 const EScaling scaling);
109
110} // namespace Tpetra
111
112#endif // TPETRA_LEFTANDORRIGHTSCALECRSMATRIX_DECL_HPP
Forward declaration of Tpetra::CrsMatrix.
Forward declaration of Tpetra::Vector.
Sparse matrix that presents a row-oriented interface that lets users read or modify entries.
A distributed dense vector.
Namespace Tpetra contains the class and methods constituting the Tpetra library.
EScaling
Whether "scaling" a matrix means multiplying or dividing its entries.
void leftAndOrRightScaleCrsMatrix(Tpetra::CrsMatrix< SC, LO, GO, NT > &A, const Kokkos::View< const typename KokkosKernels::ArithTraits< SC >::mag_type *, typename NT::device_type > &rowScalingFactors, const Kokkos::View< const typename KokkosKernels::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.