const unsigned int null_space_dimension,
const bool higher_order_elements,
const bool elliptic,
- const bool output_details);
+ const bool output_details,
+ const double drop_tolerance = 1e-13);
void vmult (Vector<double> &dst,
const Vector<double> &src) const;
const unsigned int null_space_dimension,
const bool elliptic,
const bool higher_order_elements,
- const bool output_details
+ const bool output_details,
+ const double drop_tolerance
)
{
const unsigned int n_u = matrix.m();
std::vector<int> row_lengths (n_u);
for (SparseMatrix<double>::const_iterator p = matrix.begin();
p != matrix.end(); ++p)
- if (std::abs(p->value()) > 1e-13)
+ if (std::abs(p->value()) > drop_tolerance)
++row_lengths[p->row()];
Matrix.reset (new Epetra_CrsMatrix(Copy, *Map, &row_lengths[0], true));
unsigned int index = 0;
for (SparseMatrix<double>::const_iterator p = matrix.begin(row);
p != matrix.end(row); ++p)
- if (std::abs(p->value()) > 1e-13)
+ if (std::abs(p->value()) > drop_tolerance)
{
row_indices[index] = p->column();
values[index] = p->value();