hanging_node_constraints, false);
@endcode
-Note also the last argument <tt>false</tt> for the creation of the
-sparsity pattern. It tells the sparsity pattern that constrained
-entries should not be inserted into the sparsity pattern. This makes
-sense for the way we're going to do assembly, which does the
-elimination of constraints already locally. Hence, we will never write
-touch the constrained entries. This gives some additional performance
-gain, since the system matrix will use have less entries — this
-saves both memory and computing time when doing matrix-vector
-multiplications or using a preconditioner.
+Note the last <tt>false</tt> argument we pass when creating the sparsity
+pattern. It tells the sparsity pattern that constrained entries should not
+be inserted into the sparsity pattern. This makes sense for the way we're
+going to do assembly, which does the elimination of constraints already
+locally. Hence, we will never write touch the constrained entries. This is
+the second key to increase this program's performance, since the system
+matrix will have less entries — this saves both memory and computing
+time when doing matrix-vector multiplications or applying a preconditioner.
In a similar vein, we have to slightly modify the way we copy local
contributions into global matrices and vectors. In previous tutorial programs,
// @sect4{LaplaceProblem::setup_system}
//
// This function is again an almost
- // verbatim copy of what we already
- // did in step-6, with the main
- // difference that we don't directly
- // build the sparsity pattern, but
- // first create an intermediate
- // object that we later copy into the
- // right data structure. In another
- // slight deviation, we do not first
- // build the sparsity pattern then
- // condense away constrained degrees
- // of freedom, but pass the
- // constraint matrix object directly
- // to the function that builds the
- // sparsity pattern. We disable the
- // insertion of constrained entries
- // with <tt>false</tt> as fourth
- // argument in the
- // DoFTools::make_sparsity_pattern
- // function. Both of these steps are
- // explained in the introduction of
- // this program.
+ // verbatim copy of what we already did in
+ // step-6, with the main difference that we
+ // don't directly build the sparsity
+ // pattern, but first create an
+ // intermediate object that we later copy
+ // into the right data structure. In
+ // another slight deviation, we do not
+ // first build the sparsity pattern then
+ // condense away constrained degrees of
+ // freedom, but pass the constraint matrix
+ // object directly to the function that
+ // builds the sparsity pattern. We disable
+ // the insertion of constrained entries
+ // with <tt>false</tt> as fourth argument
+ // in the DoFTools::make_sparsity_pattern
+ // function. Both of these changes are
+ // explained in the introduction of this
+ // program.
//
// The second change, maybe hidden in plain
// sight, is that the dof_handler variable