1#ifndef included_MemorySpaceMigrationOperator_H_
2#define included_MemorySpaceMigrationOperator_H_
4#include "AMP/operators/Operator.h"
27 std::string
type()
const override {
return "MemorySpaceMigrationOperator"; };
34 void reset( std::shared_ptr<const OperatorParameters> params )
override;
43 void apply( std::shared_ptr<const AMP::LinearAlgebra::Vector>
u,
44 std::shared_ptr<AMP::LinearAlgebra::Vector> f )
override;
52 void residual( std::shared_ptr<const AMP::LinearAlgebra::Vector> f,
53 std::shared_ptr<const AMP::LinearAlgebra::Vector>
u,
54 std::shared_ptr<AMP::LinearAlgebra::Vector> r )
override;
70 std::shared_ptr<OperatorParameters>
72 std::shared_ptr<const AMP::LinearAlgebra::Vector>
u,
73 std::shared_ptr<OperatorParameters> params =
nullptr )
override;
108 bool isValidVector( std::shared_ptr<const AMP::LinearAlgebra::Vector> )
override;
132 std::shared_ptr<AMP::LinearAlgebra::Vector>
d_resVec;
void apply(std::shared_ptr< const AMP::LinearAlgebra::Vector > u, std::shared_ptr< AMP::LinearAlgebra::Vector > f) override
std::shared_ptr< AMP::LinearAlgebra::Vector > d_resVec
scratch space for residuals
std::shared_ptr< AMP::LinearAlgebra::Vector > createInputVector() const override
Get a input vector ( For , is a input vector )
void reset(std::shared_ptr< const OperatorParameters > params) override
void setDebugPrintInfoLevel(int level) override
std::shared_ptr< AMP::LinearAlgebra::VectorSelector > selectOutputVector() const override
Return the selector for output vectors.
std::shared_ptr< OperatorParameters > getParameters(const std::string &type, std::shared_ptr< const AMP::LinearAlgebra::Vector > u, std::shared_ptr< OperatorParameters > params=nullptr) override
std::shared_ptr< AMP::LinearAlgebra::Variable > getOutputVariable() const override
Return the output variable.
MemorySpaceMigrationOperator(std::shared_ptr< const OperatorParameters > params)
Constructor.
std::shared_ptr< AMP::LinearAlgebra::Vector > d_inputVec
scratch space for input vectors
std::shared_ptr< AMP::LinearAlgebra::VectorSelector > selectInputVector() const override
Return the selector for input vectors.
void makeConsistent(std::shared_ptr< AMP::LinearAlgebra::Vector > vec) override
void residual(std::shared_ptr< const AMP::LinearAlgebra::Vector > f, std::shared_ptr< const AMP::LinearAlgebra::Vector > u, std::shared_ptr< AMP::LinearAlgebra::Vector > r) override
MemorySpaceMigrationOperator(void)
Default constructor.
std::shared_ptr< Operator > d_pOperator
Operator being adapted for memory operations.
virtual ~MemorySpaceMigrationOperator()
Destructor.
std::shared_ptr< AMP::LinearAlgebra::Vector > d_outputVec
scratch space for output vectors
void reInitializeVector(std::shared_ptr< AMP::LinearAlgebra::Vector >) override
bool isValidVector(std::shared_ptr< const AMP::LinearAlgebra::Vector >) override
given a vector return whether it is valid or not
std::string type() const override
Return the name of the operator.
std::shared_ptr< AMP::LinearAlgebra::Vector > createOutputVector() const override
Get an output vector ( For , is an output vector )
std::shared_ptr< AMP::LinearAlgebra::Variable > getInputVariable() const override
Return the input variable.
std::shared_ptr< AMP::Operator::Operator > shared_ptr