29 matrix.set_size(nrows, ncols);
51 matrix.set_size(nrows, ncols);
62 set_size(rdofs.n_rows, cdofs.n_rows);
109 arma::mat tmp_mat =
matrix;
110 arma::vec tmp_rhs =
rhs;
112 unsigned int ic, ir, row, col;
118 tmp_mat.col( col ).zeros();
124 tmp_rhs( row ) = 0.0;
125 tmp_mat.row( row ).zeros();
133 double new_diagonal =
matrix(row, col);
137 else if(new_diagonal == 0.0)
147 tmp_mat(row,col) = new_diagonal;
156 n_elim_cols=n_elim_rows=0;
170 matrix(row, col) += mat_val;
179 matrix(row, col) += mat_val;
void set_solution_col(uint loc_col, double solution)
#define ASSERT_EQ_DBG(a, b)
Definition of comparative assert macro (EQual) only for debug mode.
void set_matrix(arma::mat matrix)
void set_size(unsigned int nrows, unsigned int ncols)
void set_solution(unsigned int loc_dof, double solution, double diag=0.0)
Set the position and value of known solution. E.g. Dirichlet boundary condition.
arma::vec rhs
local system RHS
void reset()
Resets the matrix, RHS, dofs to zero and clears solution settings.
LocalSystem()
Default constructor.
arma::mat matrix
local system matrix
void set_solution_row(uint loc_row, double solution, double diag=0.0)
Vector classes to support both Iterator, index and Id access and creating co-located vectors...
void set_rhs(arma::vec rhs)
void add_value(unsigned int row, unsigned int col, double mat_val, double rhs_val)
Adds a single entry into the local system.
void eliminate_solution()