jacobi_oo_STL
Loading...
Searching...
No Matches
getmatrix.h
Go to the documentation of this file.
1#ifndef GETMATRIX_FILE
2#define GETMATRIX_FILE
3
4#include "geom.h"
5#include <vector>
6
15void CalcElem(int const ial[3], double const xc[], double ske[3][3], double fe[3]);
16
33void AddElem(int const ial[3], double const ske[3][3], double const fe[3],
34 int const id[], int const ik[], double sk[], double f[]);
35
36
37// #####################################################################
43{
44 public:
58 explicit CRS_Matrix(Mesh const & mesh);
59
64 {}
65
72
79 void CalculateLaplace(std::vector<double> &f);
80
89 void ApplyDirichletBC(std::vector<double> const &u, std::vector<double> &f);
90
96 void GetDiag(std::vector<double> &d) const;
97
104 void Mult(std::vector<double> &w, std::vector<double> const &u) const;
105
113 void Defect(std::vector<double> &w,
114 std::vector<double> const &f, std::vector<double> const &u) const;
115
120 int Nrows() const
121 {return _nrows;}
122
126 void Debug() const;
127
137 int fetch(int row, int col) const;
138
151 void AddElem_3(int const ial[3], double const ske[3][3], double const fe[3], std::vector<double> &f);
152
165 bool Compare2Old(int nnode, int const id[], int const ik[], double const sk[]) const;
166
167 private:
168 Mesh const & _mesh;
169 int _nrows;
170 int _nnz;
171 std::vector<int> _id;
172 std::vector<int> _ik;
173 std::vector<double> _sk;
174
175};
176
177
178#endif
function vertex minimal boundary edge info in an ASCII file Matlab indexing is stored(starts with 1). % % The output file format is compatible with Mesh_2d_3_matlab nnode
int Nrows() const
Definition getmatrix.h:120
int fetch(int row, int col) const
void CalculateLaplace(std::vector< double > &f)
void Debug() const
void ApplyDirichletBC(std::vector< double > const &u, std::vector< double > &f)
void Defect(std::vector< double > &w, std::vector< double > const &f, std::vector< double > const &u) const
void Derive_Matrix_Pattern()
Definition getmatrix.cpp:95
void GetDiag(std::vector< double > &d) const
void Mult(std::vector< double > &w, std::vector< double > const &u) const
void AddElem_3(int const ial[3], double const ske[3][3], double const fe[3], std::vector< double > &f)
bool Compare2Old(int nnode, int const id[], int const ik[], double const sk[]) const
Definition geom.h:12
void AddElem(int const ial[3], double const ske[3][3], double const fe[3], int const id[], int const ik[], double sk[], double f[])
Definition getmatrix.cpp:46
void CalcElem(int const ial[3], double const xc[], double ske[3][3], double fe[3])
Definition getmatrix.cpp:16