Commit 8db78585 authored by Benoit LE's avatar Benoit LE

Added and xAssemblerBasicAndTranspose to the assemblers of LinearSystem.

Added typedef, class member, modified initAssembler, setAssemblerCoeff and added
getAssemblerTranspose accordingly.
parent 133bef85
......@@ -82,11 +82,14 @@ void LinearSystem::axpy(double a, std::string x_name, std::string y_name) {
void LinearSystem::initAssembler(std::string name) {
assembler.setTarget(*matrix, getVector(name));
assembler_transpose.setTarget(*matrix);
assembler_lumped.setTarget(*matrix);
}
void LinearSystem::setAssemblerCoeff(double coeff) {
assembler.setCoeff(coeff);
assembler_transpose.setCoeff(coeff);
assembler_lumped.setCoeff(coeff);
}
void LinearSystem::exportVector(std::string vector_name, std::string file_name) {
......
......@@ -56,6 +56,7 @@ public:
static const bool is_sym=false;
#endif
typedef xfem::xAssemblerBasic<Matrix_t, xlinalg::xCSRVector, double> Assembler_t;
typedef xfem::xAssemblerBasicAndTranspose<Matrix_t, xlinalg::xCSRVector, double> AssemblerTranspose_t;
typedef xfem::xAssemblerLumped<Matrix_t, xlinalg::xCSRVector, double> AssemblerLumpedEqu_t; // TODO Equ doesn't work anymore
// Constructor and destructor
......@@ -120,6 +121,7 @@ public:
// Gets assembler
Assembler_t& getAssembler() { return assembler; }
AssemblerTranspose_t& getAssemblerTranspose() { return assembler_transpose; }
AssemblerLumpedEqu_t& getAssemblerLumpedEqu() { return assembler_lumped; }
// Export vector in text file for debug
......@@ -137,6 +139,7 @@ private:
Solver_t solver;
Assembler_t assembler;
AssemblerTranspose_t assembler_transpose;
AssemblerLumpedEqu_t assembler_lumped;
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment