Sierra Toolkit Version of the Day
stk::linsys::LinearSystem Class Reference

#include <LinearSystem.hpp>

Inherits stk::linsys::LinearSystemInterface.

Collaboration diagram for stk::linsys::LinearSystem:

List of all members.

Public Member Functions

 LinearSystem (MPI_Comm comm, fei::SharedPtr< fei::Factory > factory)
virtual ~LinearSystem ()
void set_parameters (Teuchos::ParameterList &paramlist)
void synchronize_mappings_and_structure ()
void create_fei_LinearSystem ()
void finalize_assembly ()
const DofMapperget_DofMapper () const
DofMapperget_DofMapper ()
void reset_to_zero ()
const fei::SharedPtr
< fei::MatrixGraph > 
get_fei_MatrixGraph () const
fei::SharedPtr< fei::MatrixGraph > get_fei_MatrixGraph ()
const fei::SharedPtr
< fei::LinearSystem > 
get_fei_LinearSystem () const
fei::SharedPtr< fei::LinearSystem > get_fei_LinearSystem ()
void write_files (const std::string &base_name) const
int solve (int &status, const Teuchos::ParameterList &params)

Detailed Description

Container of linear-system (matrix, vectors) and mapping objects.

Definition at line 24 of file LinearSystem.hpp.


Constructor & Destructor Documentation

stk::linsys::LinearSystem::LinearSystem ( MPI_Comm  comm,
fei::SharedPtr< fei::Factory >  factory 
)

Constructor

Definition at line 21 of file LinearSystem.cpp.

stk::linsys::LinearSystem::~LinearSystem ( ) [virtual]

Destructor

Definition at line 30 of file LinearSystem.cpp.


Member Function Documentation

void stk::linsys::LinearSystem::synchronize_mappings_and_structure ( )

This is a collective call -- will hang if only a subset of processors call it. Internally calls fei::MatrixGraph::initComplete() and DofMapper::finalize().

Definition at line 48 of file LinearSystem.cpp.

void stk::linsys::LinearSystem::create_fei_LinearSystem ( )

Uses the fei::Factory (that was passed as a constructor argument) to create a fei::LinearSystem and populate it with a fei::Matrix and fei::Vectors.

Definition at line 55 of file LinearSystem.cpp.

void stk::linsys::LinearSystem::finalize_assembly ( )

This is a collective call -- will hang if only a subset of processors call it. Internally calls fei::LinearSystem::loadComplete(), which in turn calls fei::Matrix::globalAssemble() and fei::Vector::gatherFromOverlap(). These operations perform communication to move shared contributions to owning processors, etc.

Definition at line 70 of file LinearSystem.cpp.

const DofMapper & stk::linsys::LinearSystem::get_DofMapper ( ) const

Return DOF-mapping object

Definition at line 76 of file LinearSystem.cpp.

DofMapper & stk::linsys::LinearSystem::get_DofMapper ( )

Return DOF-mapping object

Definition at line 82 of file LinearSystem.cpp.

const fei::SharedPtr< fei::MatrixGraph > stk::linsys::LinearSystem::get_fei_MatrixGraph ( ) const

Return fei::MatrixGraph object

Definition at line 102 of file LinearSystem.cpp.

fei::SharedPtr< fei::MatrixGraph > stk::linsys::LinearSystem::get_fei_MatrixGraph ( )

Return fei::MatrixGraph object

Definition at line 108 of file LinearSystem.cpp.

const fei::SharedPtr< fei::LinearSystem > stk::linsys::LinearSystem::get_fei_LinearSystem ( ) const

Return fei::LinearSystem object

Definition at line 114 of file LinearSystem.cpp.

fei::SharedPtr< fei::LinearSystem > stk::linsys::LinearSystem::get_fei_LinearSystem ( )

Return fei::LinearSystem object

Definition at line 120 of file LinearSystem.cpp.

int stk::linsys::LinearSystem::solve ( int &  status,
const Teuchos::ParameterList &  params 
)

Solve the linear system

Parameters:
statusOutput flag indicating the termination condition of the underlying linear-solver. Values are solver-specific. In general, 0 indicates that the solver achieved a solution that satisfied the stopping test, within the iteration limit, etc. If an iterative solver fails to converge, this status value will generally be non-zero, but the actual value can vary by solver-library.
paramsTeuchos::ParameterList for the solver
Returns:
error-code 0 if successful. Note that a 0 error-return does not necessarily mean that the underlying solver achieved a solution. It simply means that no fatal errors were encountered, such as allocation failures, etc.

Definition at line 145 of file LinearSystem.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines