Advanced Multi-Physics (AMP)
On-Line Documentation
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
AMP::Operator::PelletStackOperator Class Referencefinalabstract

#include <PelletStackOperator.h>

Inheritance diagram for AMP::Operator::PelletStackOperator:
Inheritance graph
[legend]

Public Types

typedef std::shared_ptr< AMP::Operator::Operatorshared_ptr
 

Public Member Functions

void apply (AMP::LinearAlgebra::Vector::const_shared_ptr u, AMP::LinearAlgebra::Vector::shared_ptr f) override
 
virtual void apply (std::shared_ptr< const AMP::LinearAlgebra::Vector > u, std::shared_ptr< AMP::LinearAlgebra::Vector > f)=0
 
void applyUnscaling (AMP::LinearAlgebra::Vector::shared_ptr f)
 
virtual std::shared_ptr< AMP::LinearAlgebra::VectorcreateInputVector () const
 Get a input vector ( For \(\mathbf{A(x)}\), \(\mathbf{x}\) is a input vector )
 
virtual std::shared_ptr< AMP::LinearAlgebra::VectorcreateOutputVector () const
 Get a left vector ( For \(\mathbf{y=A(x)}\), \(\mathbf{y}\) is an output vector )
 
virtual std::shared_ptr< AMP::LinearAlgebra::VariablegetInputVariable () const
 Return the input variable.
 
int getLocalIndexForPellet (unsigned int pellId)
 
const autogetLocalMeshes ()
 
const autogetLocalPelletIds ()
 
AMP::Utilities::MemoryType getMemoryLocation () const
 
std::shared_ptr< AMP::Mesh::MeshgetMesh ()
 Return the mesh.
 
std::shared_ptr< const AMP::Mesh::MeshgetMesh () const
 Return the mesh.
 
virtual std::shared_ptr< AMP::LinearAlgebra::VariablegetOutputVariable () const
 Return the output variable.
 
virtual std::shared_ptr< OperatorParametersgetParameters (const std::string &type, std::shared_ptr< const AMP::LinearAlgebra::Vector > u, std::shared_ptr< OperatorParameters > params=nullptr)
 
auto getTotalNumberOfPellets ()
 
virtual bool isValidVector (std::shared_ptr< const AMP::LinearAlgebra::Vector >)
 given a vector return whether it is valid or not
 
virtual void makeConsistent (std::shared_ptr< AMP::LinearAlgebra::Vector > vec)
 
bool onlyZcorrection ()
 
 PelletStackOperator (std::shared_ptr< const PelletStackOperatorParameters > params)
 
virtual void reInitializeVector (std::shared_ptr< AMP::LinearAlgebra::Vector >)
 
void reset (std::shared_ptr< const OperatorParameters > params) override
 
virtual 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)
 
virtual std::shared_ptr< AMP::LinearAlgebra::VectorSelectorselectInputVector () const
 Return the selector for input vectors.
 
virtual std::shared_ptr< AMP::LinearAlgebra::VectorSelectorselectOutputVector () const
 Return the selector for output vectors.
 
virtual void setDebugPrintInfoLevel (int level)
 
std::shared_ptr< AMP::LinearAlgebra::VectorsubsetInputVector (std::shared_ptr< AMP::LinearAlgebra::Vector > vec) const
 Subset input vector.
 
std::shared_ptr< const AMP::LinearAlgebra::VectorsubsetInputVector (std::shared_ptr< const AMP::LinearAlgebra::Vector > vec) const
 Subset input vector.
 
std::shared_ptr< AMP::LinearAlgebra::VectorsubsetOutputVector (std::shared_ptr< AMP::LinearAlgebra::Vector > vec) const
 Subset output vector.
 
std::shared_ptr< const AMP::LinearAlgebra::VectorsubsetOutputVector (std::shared_ptr< const AMP::LinearAlgebra::Vector > vec) const
 Subset output vector.
 
std::string type () const override
 Return the name of the operator.
 
bool useScaling ()
 
bool useSerial ()
 
virtual ~PelletStackOperator ()
 

Protected Member Functions

void applyOnlyZcorrection (AMP::LinearAlgebra::Vector::shared_ptr &u)
 
void applySerial (AMP::LinearAlgebra::Vector::const_shared_ptr u, AMP::LinearAlgebra::Vector::shared_ptr &f)
 
void applyXYZcorrection (AMP::LinearAlgebra::Vector::const_shared_ptr u, AMP::LinearAlgebra::Vector::shared_ptr &f)
 
void computeZscan (AMP::LinearAlgebra::Vector::const_shared_ptr u, std::vector< double > &finalMaxZdispsList)
 
void getBackendFromInput (std::shared_ptr< AMP::Database > db)
 
virtual std::shared_ptr< OperatorParametersgetJacobianParameters (std::shared_ptr< const AMP::LinearAlgebra::Vector >)
 
void setMemoryAndBackendParameters (std::shared_ptr< AMP::Database > db)
 

Protected Attributes

AMP::Utilities::Backend d_backend = AMP::Utilities::Backend::Serial
 
unsigned int d_currentPellet
 
AMP::LinearAlgebra::Vector::shared_ptr d_frozenVectorForMaps
 
bool d_frozenVectorSet
 
int d_iDebugPrintInfoLevel = 0
 
int d_iObject_id
 
short int d_masterId
 
AMP::Utilities::MemoryType d_memory_location = AMP::Utilities::MemoryType::none
 
std::shared_ptr< AMP::Mesh::Meshd_Mesh
 
std::vector< std::shared_ptr< AMP::Mesh::Mesh > > d_meshes
 
std::shared_ptr< AMP::Operator::AsyncMapColumnOperatord_n2nMaps
 
bool d_onlyZcorrection
 
std::vector< unsigned intd_pelletIds
 
AMP_MPI d_pelletStackComm
 
double d_scalingFactor
 
short int d_slaveId
 
unsigned int d_totalNumberOfPellets
 
bool d_useScaling
 
bool d_useSerial
 
std::shared_ptr< AMP::LinearAlgebra::Variabled_var
 

Static Protected Attributes

static int d_iInstance_id
 

Detailed Description

Definition at line 9 of file PelletStackOperator.h.

Member Typedef Documentation

◆ shared_ptr

Definition at line 29 of file Operator.h.

Constructor & Destructor Documentation

◆ PelletStackOperator()

AMP::Operator::PelletStackOperator::PelletStackOperator ( std::shared_ptr< const PelletStackOperatorParameters params)
explicit

◆ ~PelletStackOperator()

virtual AMP::Operator::PelletStackOperator::~PelletStackOperator ( )
inlinevirtual

Definition at line 14 of file PelletStackOperator.h.

Member Function Documentation

◆ apply() [1/2]

void AMP::Operator::PelletStackOperator::apply ( AMP::LinearAlgebra::Vector::const_shared_ptr  u,
AMP::LinearAlgebra::Vector::shared_ptr  f 
)
override

◆ apply() [2/2]

virtual void AMP::Operator::Operator::apply ( std::shared_ptr< const AMP::LinearAlgebra::Vector u,
std::shared_ptr< AMP::LinearAlgebra::Vector f 
)
pure virtualinherited

This base class can not give a meaningful definition of apply. See the derived classes for how they define apply. Each operator is free to define apply in a way that is appropriate for that operator.

Parameters
ushared pointer to const input vector u
fshared pointer to output vector storing result of applying this operator

Implemented in AMP::Operator::RadDifOp, AMP::Operator::RadDifOpPJac, AMP::Operator::FunctionOperator, AMP::Operator::MemorySpaceMigrationLinearOperator, and AMP::Operator::MemorySpaceMigrationOperator.

◆ applyOnlyZcorrection()

void AMP::Operator::PelletStackOperator::applyOnlyZcorrection ( AMP::LinearAlgebra::Vector::shared_ptr u)
protected

◆ applySerial()

void AMP::Operator::PelletStackOperator::applySerial ( AMP::LinearAlgebra::Vector::const_shared_ptr  u,
AMP::LinearAlgebra::Vector::shared_ptr f 
)
protected

◆ applyUnscaling()

void AMP::Operator::PelletStackOperator::applyUnscaling ( AMP::LinearAlgebra::Vector::shared_ptr  f)

◆ applyXYZcorrection()

void AMP::Operator::PelletStackOperator::applyXYZcorrection ( AMP::LinearAlgebra::Vector::const_shared_ptr  u,
AMP::LinearAlgebra::Vector::shared_ptr f 
)
protected

◆ computeZscan()

void AMP::Operator::PelletStackOperator::computeZscan ( AMP::LinearAlgebra::Vector::const_shared_ptr  u,
std::vector< double > &  finalMaxZdispsList 
)
protected

◆ createInputVector()

virtual std::shared_ptr< AMP::LinearAlgebra::Vector > AMP::Operator::Operator::createInputVector ( ) const
virtualinherited

◆ createOutputVector()

virtual std::shared_ptr< AMP::LinearAlgebra::Vector > AMP::Operator::Operator::createOutputVector ( ) const
virtualinherited

Get a left vector ( For \(\mathbf{y=A(x)}\), \(\mathbf{y}\) is an output vector )

Returns
A newly created output vector

Reimplemented in AMP::Operator::IdentityOperator, AMP::Operator::LinearOperator, AMP::Operator::MemorySpaceMigrationLinearOperator, and AMP::Operator::MemorySpaceMigrationOperator.

◆ getBackendFromInput()

void AMP::Operator::Operator::getBackendFromInput ( std::shared_ptr< AMP::Database db)
protectedinherited

◆ getInputVariable()

virtual std::shared_ptr< AMP::LinearAlgebra::Variable > AMP::Operator::Operator::getInputVariable ( ) const
inlinevirtualinherited

◆ getJacobianParameters()

virtual std::shared_ptr< OperatorParameters > AMP::Operator::Operator::getJacobianParameters ( std::shared_ptr< const AMP::LinearAlgebra::Vector )
inlineprotectedvirtualinherited

This function returns a OperatorParameters object constructed by the operator which contains parameters from which new Jacobian operators can be created. Returning a parameter object instead of an Operator itself is meant to give users more flexibility.

Definition at line 180 of file Operator.h.

◆ getLocalIndexForPellet()

int AMP::Operator::PelletStackOperator::getLocalIndexForPellet ( unsigned int  pellId)

◆ getLocalMeshes()

const auto & AMP::Operator::PelletStackOperator::getLocalMeshes ( )
inline

Definition at line 22 of file PelletStackOperator.h.

References d_meshes.

◆ getLocalPelletIds()

const auto & AMP::Operator::PelletStackOperator::getLocalPelletIds ( )
inline

Definition at line 24 of file PelletStackOperator.h.

References d_pelletIds.

◆ getMemoryLocation()

AMP::Utilities::MemoryType AMP::Operator::Operator::getMemoryLocation ( ) const
inlineinherited

Definition at line 89 of file Operator.h.

References AMP::Operator::Operator::d_memory_location.

◆ getMesh() [1/2]

std::shared_ptr< AMP::Mesh::Mesh > AMP::Operator::Operator::getMesh ( )
inlineinherited

Return the mesh.

Definition at line 149 of file Operator.h.

References AMP::Operator::Operator::d_Mesh.

◆ getMesh() [2/2]

std::shared_ptr< const AMP::Mesh::Mesh > AMP::Operator::Operator::getMesh ( ) const
inlineinherited

Return the mesh.

Definition at line 152 of file Operator.h.

References AMP::Operator::Operator::d_Mesh.

◆ getOutputVariable()

virtual std::shared_ptr< AMP::LinearAlgebra::Variable > AMP::Operator::Operator::getOutputVariable ( ) const
inlinevirtualinherited

Return the output variable.

Reimplemented in AMP::Operator::DirichletMatrixCorrection, AMP::Operator::NeumannVectorCorrection, AMP::Operator::ColumnOperator, AMP::Operator::ConstraintsEliminationOperator, AMP::Operator::ContactResidualCorrection, AMP::Operator::CoupledOperator, AMP::Operator::DiffusionNonlinearFEOperator, AMP::Operator::FickSoretNonlinearFEOperator, AMP::Operator::GradientOperator, AMP::Operator::MassLinearFEOperator, AMP::Operator::NodeToGaussPointOperator, AMP::Operator::VolumeIntegralOperator, AMP::Operator::LinearBVPOperator, AMP::Operator::LinearOperator, AMP::Operator::AsyncMapOperator, AMP::Operator::Map1Dto3D, AMP::Operator::Map3Dto1D, AMP::Operator::MapSurface, AMP::Operator::MechanicsNonlinearFEOperator, AMP::Operator::MemorySpaceMigrationLinearOperator, AMP::Operator::MemorySpaceMigrationOperator, AMP::Operator::NeutronicsRhs, AMP::Operator::FirstOperator, AMP::Operator::SecondOperator, AMP::Operator::NonlinearBVPOperator, AMP::Operator::PetscMatrixShellOperator, AMP::Operator::CoupledChannelToCladMapOperator, AMP::Operator::CoupledFlowFrapconOperator, AMP::Operator::FlowFrapconJacobian, AMP::Operator::FlowFrapconOperator, AMP::Operator::SubchannelFourEqNonlinearOperator, AMP::Operator::SubchannelToPointMap, AMP::Operator::SubchannelTwoEqNonlinearOperator, AMP::Operator::TrilinosMatrixShellOperator, AMP::Operator::VectorCopyOperator, AMP::TimeIntegrator::LinearTimeOperator, and AMP::TimeIntegrator::TimeOperator.

Definition at line 100 of file Operator.h.

◆ getParameters()

virtual std::shared_ptr< OperatorParameters > AMP::Operator::Operator::getParameters ( const std::string &  type,
std::shared_ptr< const AMP::LinearAlgebra::Vector u,
std::shared_ptr< OperatorParameters params = nullptr 
)
virtualinherited

This function returns a OperatorParameters object constructed by the operator which contains parameters from which new operators can be created. Returning a parameter object instead of an Operator itself is meant to give users more flexibility. Examples of how this functionality might be used would be the construction of Jacobian, frozen Jacobian, preconditioner approximations to the Jacobian, adjoint operators etc

Parameters
typestd:string specifying type of return operator parameters being requested. Currently the valid option is Jacobian
uconst pointer to current solution vector
paramspointer to additional parameters that might be required to construct the return parameters

Reimplemented in AMP::Operator::IdentityOperator, AMP::Operator::MemorySpaceMigrationLinearOperator, and AMP::Operator::MemorySpaceMigrationOperator.

◆ getTotalNumberOfPellets()

auto AMP::Operator::PelletStackOperator::getTotalNumberOfPellets ( )
inline

Definition at line 20 of file PelletStackOperator.h.

References d_totalNumberOfPellets.

◆ isValidVector()

virtual bool AMP::Operator::Operator::isValidVector ( std::shared_ptr< const AMP::LinearAlgebra::Vector )
inlinevirtualinherited

◆ makeConsistent()

virtual void AMP::Operator::Operator::makeConsistent ( std::shared_ptr< AMP::LinearAlgebra::Vector vec)
virtualinherited

virtual interface used to make a vector consistent in an operator defined way. An example of where an operator is required to make a vector consistent is in the context of AMR where ghost values on coarse-fine interfaces are filled in an operator dependent way. The default implementation is to simply call the vector makeConsistent(SET)

Reimplemented in AMP::Operator::MemorySpaceMigrationLinearOperator, AMP::Operator::MemorySpaceMigrationOperator, and AMP::TimeIntegrator::TimeOperator.

◆ onlyZcorrection()

bool AMP::Operator::PelletStackOperator::onlyZcorrection ( )
inline

Definition at line 28 of file PelletStackOperator.h.

References d_onlyZcorrection.

◆ reInitializeVector()

virtual void AMP::Operator::Operator::reInitializeVector ( std::shared_ptr< AMP::LinearAlgebra::Vector )
inlinevirtualinherited

re-initialize a vector, e.g. after a regrid operation has happened. This is useful for example when numerical overshoots or undershoots have happened due to interpolation for example The default is a null op

Reimplemented in AMP::TimeIntegrator::TimeOperator, AMP::Operator::MemorySpaceMigrationLinearOperator, and AMP::Operator::MemorySpaceMigrationOperator.

Definition at line 167 of file Operator.h.

◆ reset()

void AMP::Operator::PelletStackOperator::reset ( std::shared_ptr< const OperatorParameters params)
overridevirtual

This function is useful for re-initializing/updating an operator

Parameters
paramsparameter object containing parameters to change

Reimplemented from AMP::Operator::Operator.

◆ residual()

virtual void AMP::Operator::Operator::residual ( std::shared_ptr< const AMP::LinearAlgebra::Vector f,
std::shared_ptr< const AMP::LinearAlgebra::Vector u,
std::shared_ptr< AMP::LinearAlgebra::Vector r 
)
virtualinherited

Default base class implementation of the residual: f-L(u)

Parameters
fshared pointer to const vector rhs
ushared pointer to const vector u
rshared pointer to vector residual

Reimplemented in AMP::Solver::AMG::HasDeferConsistency< AMP::Operator::LinearOperator >, AMP::Operator::MemorySpaceMigrationLinearOperator, AMP::Operator::MemorySpaceMigrationOperator, AMP::TimeIntegrator::IDATimeOperator, and AMP::TimeIntegrator::TimeOperator.

◆ selectInputVector()

virtual std::shared_ptr< AMP::LinearAlgebra::VectorSelector > AMP::Operator::Operator::selectInputVector ( ) const
virtualinherited

◆ selectOutputVector()

virtual std::shared_ptr< AMP::LinearAlgebra::VectorSelector > AMP::Operator::Operator::selectOutputVector ( ) const
virtualinherited

◆ setDebugPrintInfoLevel()

virtual void AMP::Operator::Operator::setDebugPrintInfoLevel ( int  level)
inlinevirtualinherited

Specify level of diagnostic information printed during iterations.

Parameters
levelzero prints none or minimal information, higher numbers provide increasingly verbose debugging information.

Reimplemented in AMP::Operator::MemorySpaceMigrationLinearOperator, and AMP::Operator::MemorySpaceMigrationOperator.

Definition at line 97 of file Operator.h.

References AMP::Operator::Operator::d_iDebugPrintInfoLevel.

◆ setMemoryAndBackendParameters()

void AMP::Operator::Operator::setMemoryAndBackendParameters ( std::shared_ptr< AMP::Database db)
protectedinherited

◆ subsetInputVector() [1/2]

std::shared_ptr< AMP::LinearAlgebra::Vector > AMP::Operator::Operator::subsetInputVector ( std::shared_ptr< AMP::LinearAlgebra::Vector vec) const
inherited

Subset input vector.

◆ subsetInputVector() [2/2]

std::shared_ptr< const AMP::LinearAlgebra::Vector > AMP::Operator::Operator::subsetInputVector ( std::shared_ptr< const AMP::LinearAlgebra::Vector vec) const
inherited

Subset input vector.

◆ subsetOutputVector() [1/2]

std::shared_ptr< AMP::LinearAlgebra::Vector > AMP::Operator::Operator::subsetOutputVector ( std::shared_ptr< AMP::LinearAlgebra::Vector vec) const
inherited

Subset output vector.

◆ subsetOutputVector() [2/2]

std::shared_ptr< const AMP::LinearAlgebra::Vector > AMP::Operator::Operator::subsetOutputVector ( std::shared_ptr< const AMP::LinearAlgebra::Vector vec) const
inherited

Subset output vector.

◆ type()

std::string AMP::Operator::PelletStackOperator::type ( ) const
inlineoverridevirtual

Return the name of the operator.

Implements AMP::Operator::Operator.

Definition at line 16 of file PelletStackOperator.h.

◆ useScaling()

bool AMP::Operator::PelletStackOperator::useScaling ( )
inline

Definition at line 30 of file PelletStackOperator.h.

References d_useScaling.

◆ useSerial()

bool AMP::Operator::PelletStackOperator::useSerial ( )
inline

Definition at line 26 of file PelletStackOperator.h.

References d_useSerial.

Member Data Documentation

◆ d_backend

AMP::Utilities::Backend AMP::Operator::Operator::d_backend = AMP::Utilities::Backend::Serial
protectedinherited

Definition at line 197 of file Operator.h.

◆ d_currentPellet

unsigned int AMP::Operator::PelletStackOperator::d_currentPellet
protected

Definition at line 52 of file PelletStackOperator.h.

◆ d_frozenVectorForMaps

AMP::LinearAlgebra::Vector::shared_ptr AMP::Operator::PelletStackOperator::d_frozenVectorForMaps
protected

Definition at line 62 of file PelletStackOperator.h.

◆ d_frozenVectorSet

bool AMP::Operator::PelletStackOperator::d_frozenVectorSet
protected

Definition at line 63 of file PelletStackOperator.h.

◆ d_iDebugPrintInfoLevel

int AMP::Operator::Operator::d_iDebugPrintInfoLevel = 0
protectedinherited

Definition at line 187 of file Operator.h.

Referenced by AMP::Operator::Operator::setDebugPrintInfoLevel().

◆ d_iInstance_id

int AMP::Operator::Operator::d_iInstance_id
staticprotectedinherited

Definition at line 191 of file Operator.h.

◆ d_iObject_id

int AMP::Operator::Operator::d_iObject_id
protectedinherited

Definition at line 189 of file Operator.h.

◆ d_masterId

short int AMP::Operator::PelletStackOperator::d_masterId
protected

Definition at line 57 of file PelletStackOperator.h.

◆ d_memory_location

AMP::Utilities::MemoryType AMP::Operator::Operator::d_memory_location = AMP::Utilities::MemoryType::none
protectedinherited

Definition at line 195 of file Operator.h.

Referenced by AMP::Operator::Operator::getMemoryLocation().

◆ d_Mesh

std::shared_ptr<AMP::Mesh::Mesh> AMP::Operator::Operator::d_Mesh
protectedinherited

◆ d_meshes

std::vector<std::shared_ptr<AMP::Mesh::Mesh> > AMP::Operator::PelletStackOperator::d_meshes
protected

Definition at line 59 of file PelletStackOperator.h.

Referenced by getLocalMeshes().

◆ d_n2nMaps

std::shared_ptr<AMP::Operator::AsyncMapColumnOperator> AMP::Operator::PelletStackOperator::d_n2nMaps
protected

Definition at line 65 of file PelletStackOperator.h.

◆ d_onlyZcorrection

bool AMP::Operator::PelletStackOperator::d_onlyZcorrection
protected

Definition at line 54 of file PelletStackOperator.h.

Referenced by onlyZcorrection().

◆ d_pelletIds

std::vector<unsigned int> AMP::Operator::PelletStackOperator::d_pelletIds
protected

Definition at line 60 of file PelletStackOperator.h.

Referenced by getLocalPelletIds().

◆ d_pelletStackComm

AMP_MPI AMP::Operator::PelletStackOperator::d_pelletStackComm
protected

Definition at line 64 of file PelletStackOperator.h.

◆ d_scalingFactor

double AMP::Operator::PelletStackOperator::d_scalingFactor
protected

Definition at line 56 of file PelletStackOperator.h.

◆ d_slaveId

short int AMP::Operator::PelletStackOperator::d_slaveId
protected

Definition at line 58 of file PelletStackOperator.h.

◆ d_totalNumberOfPellets

unsigned int AMP::Operator::PelletStackOperator::d_totalNumberOfPellets
protected

Definition at line 51 of file PelletStackOperator.h.

Referenced by getTotalNumberOfPellets().

◆ d_useScaling

bool AMP::Operator::PelletStackOperator::d_useScaling
protected

Definition at line 55 of file PelletStackOperator.h.

Referenced by useScaling().

◆ d_useSerial

bool AMP::Operator::PelletStackOperator::d_useSerial
protected

Definition at line 53 of file PelletStackOperator.h.

Referenced by useSerial().

◆ d_var

std::shared_ptr<AMP::LinearAlgebra::Variable> AMP::Operator::PelletStackOperator::d_var
protected

Definition at line 61 of file PelletStackOperator.h.


The documentation for this class was generated from the following file:



Advanced Multi-Physics (AMP)
Oak Ridge National Laboratory
Idaho National Laboratory
Los Alamos National Laboratory
This page automatically produced from the
source code by doxygen
Last updated: Tue Mar 10 2026 13:06:44.
Comments on this page