Sierra Toolkit  Version of the Day
LinearSystem.hpp
1 /*------------------------------------------------------------------------*/
2 /* Copyright 2010 Sandia Corporation. */
3 /* Under terms of Contract DE-AC04-94AL85000, there is a non-exclusive */
4 /* license for use of this work by or on behalf of the U.S. Government. */
5 /* Export of this program may require a license from the */
6 /* United States Government. */
7 /*------------------------------------------------------------------------*/
8 
9 #ifndef stk_linsys_LinearSystem_hpp
10 #define stk_linsys_LinearSystem_hpp
11 
12 #include <stk_linsys/FeiBaseIncludes.hpp>
13 #include <stk_linsys/DofMapper.hpp>
14 #include <stk_linsys/LinearSystemInterface.hpp>
15 
16 #include <Teuchos_ParameterList.hpp>
17 
18 namespace stk_classic {
19 namespace linsys {
20 
24 class LinearSystem : public LinearSystemInterface {
25  public:
27  LinearSystem(MPI_Comm comm, fei::SharedPtr<fei::Factory> factory);
28 
30  virtual ~LinearSystem();
31 
32  void set_parameters(Teuchos::ParameterList& paramlist);
33 
40 
46 
54  void finalize_assembly();
55 
57  const DofMapper& get_DofMapper() const;
58 
61 
62  void reset_to_zero();
63 
65  const fei::SharedPtr<fei::MatrixGraph> get_fei_MatrixGraph() const;
66 
68  fei::SharedPtr<fei::MatrixGraph> get_fei_MatrixGraph();
69 
71  const fei::SharedPtr<fei::LinearSystem> get_fei_LinearSystem() const;
72 
74  fei::SharedPtr<fei::LinearSystem> get_fei_LinearSystem();
75 
76  void write_files(const std::string& base_name) const;
77 
94  int solve(int & status, const Teuchos::ParameterList & params);
95 
96  private:
97 
98  fei::SharedPtr<fei::Factory> m_fei_factory;
99  DofMapper m_dof_mapper;
100  fei::SharedPtr<fei::MatrixGraph> m_fei_mgraph;
101 
102  fei::SharedPtr<fei::LinearSystem> m_fei_linearsystem;
103  fei::ParameterSet m_param_set;
104 };//class LinearSystem
105 
106 }//namespace linsys
107 }//namespace stk_classic
108 
109 #endif
110 
const fei::SharedPtr< fei::MatrixGraph > get_fei_MatrixGraph() const
const fei::SharedPtr< fei::LinearSystem > get_fei_LinearSystem() const
const DofMapper & get_DofMapper() const
int solve(int &status, const Teuchos::ParameterList &params)
Sierra Toolkit.
LinearSystem(MPI_Comm comm, fei::SharedPtr< fei::Factory > factory)