* relation.
*/
bool operator < (const ConstraintLine &) const;
+
+ /**
+ * Determine an estimate for the
+ * memory consumption (in bytes)
+ * of this object.
+ */
+ unsigned int memory_consumption () const;
};
/**
#include <dofs/dof_constraints.h>
#include <dofs/dof_constraints.templates.h>
+#include <base/memory_consumption.h>
#include <lac/sparsity_pattern.h>
#include <lac/vector.h>
#include <lac/block_vector.h>
+unsigned int
+ConstraintMatrix::ConstraintLine::memory_consumption () const
+{
+ return (MemoryConsumption::memory_consumption (line) +
+ MemoryConsumption::memory_consumption (entries));
+};
+
+
+
ConstraintMatrix::ConstraintMatrix () :
lines(),
sorted(false)
-void ConstraintMatrix::print (ostream &out) const {
+void ConstraintMatrix::print (ostream &out) const
+{
for (unsigned int i=0; i!=lines.size(); ++i)
for (unsigned int j=0; j!=lines[i].entries.size(); ++j)
out << " " << lines[i].line
+unsigned int
+ConstraintMatrix::memory_consumption () const
+{
+ return (MemoryConsumption::memory_consumption (lines) +
+ MemoryConsumption::memory_consumption (sorted));
+};
+
+
+
// explicit instantiations