OpenFCST: The open-source Fuel Cell Simulation Toolbox
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
solver_utils.h
Go to the documentation of this file.
1 //---------------------------------------------------------------------------
2 // $Id: solver_utils.h 1354 2013-08-17 00:01:22Z secanell $
3 //
4 // Copyright (C) 2008 by Marc Secanell
5 //
6 // This file is subject to QPL and may not be distributed
7 // without copyright and license information. Please refer
8 // to the file deal.II/doc/license.html for the text and
9 // further information on this license.
10 //
11 //---------------------------------------------------------------------------
12 
13 
14 #ifndef _SOLVER_UTILS__H
15 #define _SOLVER_UTILS__H
16 
17 // Include deal.II classes
18 #include <lac/block_sparse_matrix.h>
19 #include <lac/full_matrix.h>
20 #include "lac/block_vector.h"
21 #include "appframe/base.h"
22 
23 // Include STD classes
24 #include <vector>
25 #include <fstream>
26 #include <iostream>
27 #include <sstream>
28 
29 // Use namespace of deal.II
30 using namespace dealii;
31 
40 {
41  public:
45  SolverUtils();
46 
51  void check_diagonal(const BlockSparseMatrix<double>& A) const;
52 
56  void output_diagonal(const BlockSparseMatrix<double>& A) const;
57 
62  void print_diagonal(const BlockSparseMatrix<double>& A,
63  const std::string& file = std::string("diag_matrix.dat")) const;
77  void repair_diagonal (BlockSparseMatrix<double>& A);
78 
86  void repair_diagonal (BlockSparseMatrix<double>& A, AppFrame::FEVector& , const AppFrame::FEVector& );
87 };
88 
89 
90 #endif //_SOLVER_UTILS__H