From: Lucas Campos Date: Tue, 29 Aug 2017 07:50:35 +0000 (+0200) Subject: Added justification for redundancy in step-44 X-Git-Tag: v9.0.0-rc1~1147^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F4980%2Fhead;p=dealii.git Added justification for redundancy in step-44 --- diff --git a/examples/step-44/step-44.cc b/examples/step-44/step-44.cc index ab2e576c63..3ca1c3bd8c 100644 --- a/examples/step-44/step-44.cc +++ b/examples/step-44/step-44.cc @@ -2470,6 +2470,17 @@ namespace Step44 constraints.clear(); const bool apply_dirichlet_bc = (it_nr == 0); + // In this particular example, the boundary values will be calculated for + // the two first iterations of Newton's algorithm. In general, one would + // build non-homogeneous constraints in the zeroth iteration (that is, when + // `apply_dirichlet_bc == true`) and build only the corresponding + // homogeneous constraints in the following step. While the current + // example has only homogenous constraints, previous experiences have + // shown that a common error is forgetting to add the extra condition when + // refactoring the code to specific uses. This could lead errors that are + // hard to debug. In this spirit, we choose to make the code more verbose + // in terms of what operations are performed at each Newton step. + // // The boundary conditions for the indentation problem are as follows: On // the -x, -y and -z faces (IDs 0,2,4) we set up a symmetry condition to // allow only planar movement while the +x and +z faces (IDs 1,5) are