51 if ( dynamic_cast< const SymCompCol * >(&A) ) {
53 }
else if ( dynamic_cast< const CompCol * >(&A) ) {
75 for ( k = 0; k <
dim_ [ 1 ]; k++ ) {
88 for ( k = 0; k < dim_ [ 1 ]; k++ ) {
102 for ( i = 0; i < dim_ [ 1 ]; i++ ) {
134 for ( k = 0; k < n - 1; k++ ) {
138 for ( i = d + 1; i <
pntr_(k + 1); i++ ) {
142 for ( i = d + 1; i <
pntr_(k + 1); i++ ) {
172 for ( i = 0; i < M; i++ ) {
173 work(i) = val = ( dest(i) + work(i) ) /
val_(
pntr_(i) );
174 for ( t =
pntr_(i) + 1; t <
pntr_(i + 1); t++ ) {
181 for ( i = M - 1; i >= 0; i-- ) {
182 for ( t =
pntr_(i) + 1; t <
pntr_(i + 1); t++ ) {
186 dest(i) = ( work(i) + dest(i) ) /
val_(
pntr_(i) );
207 int i = l - 1, j = r;
213 while ( ( src(++i) < v ) ) {
217 while ( ( v < src(--j) ) ) {
void initialize(const CompCol &A)
int qsortRowPartition(IntArray &, FloatArray &, int l, int r)
void solve(const FloatArray &rhs, FloatArray &solution) const
Solves the linear system.
void qsortRow(IntArray &, FloatArray &, int l, int r)
Base class for all matrices stored in sparse format.
const int & row_ind(int i) const
const int & col_ptr(int i) const
Class implementing an array of integers.
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver from given record. Empty implementation.
void ICSolve(FloatArray &dest) const
void resize(int n)
Checks size of receiver towards requested bounds.
Implementation of symmetric sparse matrix stored using compressed column/row storage.
Class representing vector of real numbers.
Abstract class for IML++ compatible preconditioner.
IRResultType
Type defining the return values of InputRecord reading operations.
const double & val(int i) const
void trans_solve(const FloatArray &rhs, FloatArray &solution) const
Solves the transposed system.
void zero()
Zeroes all coefficients of receiver.
virtual void init(const SparseMtrx &a)
Initializes the receiver (constructs the preconditioning matrix M) of given matrix.
int giveSize() const
Returns the size of receiver.
the oofem namespace is to define a context or scope in which all oofem names are defined.
CompCol_ICPreconditioner()
Constructor. The user should call initializeFrom and init services in this given order to ensure cons...
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver from given record. Empty implementation.
void resize(int s)
Resizes receiver towards requested size.