46 #ifndef XPETRA_EPETRAVECTOR_HPP 47 #define XPETRA_EPETRAVECTOR_HPP 61 #include <Epetra_Vector.h> 66 template<
class GlobalOrdinal>
67 Epetra_Vector &
toEpetra(Vector<double, int, GlobalOrdinal> &);
69 template<
class GlobalOrdinal>
70 const Epetra_Vector &
toEpetra(
const Vector<double, int, GlobalOrdinal> &);
73 template<
class EpetraGlobalOrdinal>
75 :
public virtual Vector<double,int,EpetraGlobalOrdinal>,
public EpetraMultiVectorT<EpetraGlobalOrdinal>
177 #ifdef HAVE_XPETRA_KOKKOS_REFACTOR 180 typename dual_view_type::t_host_um getHostLocalView ()
const {
184 typename dual_view_type::t_dev_um getDeviceLocalView()
const {
185 throw std::runtime_error(
"Epetra does not support device views!");
186 typename dual_view_type::t_dev ret;
200 template<
class TargetDeviceType>
201 typename Kokkos::Impl::if_c<
202 Kokkos::Impl::is_same<
203 typename dual_view_type::t_dev_um::execution_space::memory_space,
204 typename TargetDeviceType::memory_space>::value,
205 typename dual_view_type::t_dev_um,
206 typename dual_view_type::t_host_um>::type
207 getLocalView ()
const {
221 #ifndef XPETRA_EPETRA_NO_32BIT_GLOBAL_INDICES 225 #ifdef HAVE_XPETRA_INT_LONG_LONG 231 #endif // XPETRA_EPETRAVECTOR_HPP
void sumIntoGlobalValue(GlobalOrdinal globalRow, const Scalar &value)
Adds specified value to existing value at the specified location.
Epetra_Vector * getEpetra_Vector() const
Get the underlying Epetra vector.
Scalar dot(const Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &a) const
Computes dot product of this Vector against input Vector x.
const Epetra_CrsGraph & toEpetra(const RCP< const CrsGraph< int, GlobalOrdinal > > &graph)
EpetraVectorT(const Teuchos::RCP< Epetra_Vector > &vec)
EpetraMultiVectorT constructor to wrap a Epetra_Vector object.
Teuchos::ScalarTraits< Scalar >::magnitudeType normWeighted(const Vector< Scalar, LocalOrdinal, GlobalOrdinal, Node > &weights) const
Compute Weighted 2-norm (RMS Norm) of this Vector.
const RCP< const Epetra_MultiVector > internalRefToBaseMV_
EpetraGlobalOrdinal GlobalOrdinal
void replaceLocalValue(LocalOrdinal myRow, const Scalar &value)
Replace current value at the specified location with specified values.
void sumIntoLocalValue(LocalOrdinal myRow, const Scalar &value)
Adds specified value to existing value at the specified location.
Teuchos::ScalarTraits< Scalar >::magnitudeType norm2() const
Compute 2-norm of this Vector.
EpetraVectorT(const RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &map, bool zeroOut=true)
Sets all vector entries to zero.
void describe(Teuchos::FancyOStream &out, const Teuchos::EVerbosityLevel verbLevel=Teuchos::Describable::verbLevel_default) const
Print the object with some verbosity level to an FancyOStream object.
Teuchos::ScalarTraits< Scalar >::magnitudeType norm1() const
Return 1-norm of this Vector.
EpetraVectorT< int > EpetraVector
std::string description() const
Return a simple one-line description of this object.
Scalar meanValue() const
Compute mean (average) value of this Vector.
static const EVerbosityLevel verbLevel_default
void replaceGlobalValue(GlobalOrdinal globalRow, const Scalar &value)
Replace current value at the specified location with specified value.
KokkosClassic::DefaultNode::DefaultNodeType Node
Teuchos::ScalarTraits< Scalar >::magnitudeType normInf() const
Compute Inf-norm of this Vector.
virtual ~EpetraVectorT()
Vector copy constructor.