]> https://gitweb.dealii.org/ - dealii.git/commitdiff
step-27: Changed relative threshold. Updated output. 11488/head
authorMarc Fehling <marc.fehling@gmx.net>
Thu, 7 Jan 2021 01:31:47 +0000 (18:31 -0700)
committerMarc Fehling <mafehling.git@gmail.com>
Thu, 7 Jan 2021 05:25:45 +0000 (22:25 -0700)
examples/step-27/doc/results.dox
examples/step-27/step-27.cc

index 1347c087b508d1bad0349f9a835e543340df1804..afc00d258a1a9f84569a0ef169a7397975fb4fe7 100644 (file)
@@ -16,25 +16,25 @@ Cycle 0:
    Number of degrees of freedom: 3264
    Number of constraints       : 384
 Cycle 1:
-   Number of active cells      : 966
-   Number of degrees of freedom: 5245
-   Number of constraints       : 936
+   Number of active cells      : 807
+   Number of degrees of freedom: 4764
+   Number of constraints       : 756
 Cycle 2:
-   Number of active cells      : 1143
-   Number of degrees of freedom: 8441
-   Number of constraints       : 1929
+   Number of active cells      : 927
+   Number of degrees of freedom: 7978
+   Number of constraints       : 1760
 Cycle 3:
-   Number of active cells      : 1356
-   Number of degrees of freedom: 12349
-   Number of constraints       : 3046
+   Number of active cells      : 1020
+   Number of degrees of freedom: 11750
+   Number of constraints       : 2898
 Cycle 4:
-   Number of active cells      : 1644
-   Number of degrees of freedom: 18178
-   Number of constraints       : 4713
+   Number of active cells      : 1158
+   Number of degrees of freedom: 16342
+   Number of constraints       : 3892
 Cycle 5:
-   Number of active cells      : 1728
-   Number of degrees of freedom: 22591
-   Number of constraints       : 6095
+   Number of active cells      : 1197
+   Number of degrees of freedom: 20569
+   Number of constraints       : 4954
 @endcode
 
 The first thing we learn from this is that the number of constrained degrees
@@ -64,36 +64,36 @@ Secondly, let us look at the sequence of meshes generated:
 
 <div class="threecolumn" style="width: 80%">
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-0.svg"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-00.svg"
          alt="Triangulation containing reentrant corners without adaptive refinement."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-1.svg"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-01.svg"
          alt="Triangulation containing reentrant corners with one level of
          refinement. New cells are placed near the corners."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-2.svg"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-02.svg"
          alt="Triangulation containing reentrant corners with two levels of
          refinement. New cells are placed near the corners."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-3.svg"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-03.svg"
          alt="Triangulation containing reentrant corners with three levels of
          refinement. New cells are placed near the corners."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-4.svg"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-04.svg"
          alt="Triangulation containing reentrant corners with four levels of
          refinement. New cells are placed near the corners."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-5.svg"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-mesh-05.svg"
          alt="Triangulation containing reentrant corners with five levels of
          refinement. New cells are placed near the corners."
          width="200" height="200">
@@ -103,36 +103,37 @@ Secondly, let us look at the sequence of meshes generated:
 It is clearly visible how the mesh is refined near the corner singularities,
 as one would expect it. More interestingly, we should be curious to see the
 distribution of finite element polynomial degrees to these mesh cells, where
-grey corresponds to degree two and pink corresponds to degree seven:
+the lightest color corresponds to degree two and the darkest one corresponds
+to degree seven:
 
 <div class="threecolumn" style="width: 80%">
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-cell-degree-0.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-fe_degree-00.svg"
          alt="Initial grid where all cells contain just biquadratic functions."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-cell-degree-1.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-fe_degree-01.svg"
          alt="Depiction of local approximation degrees after one refinement."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-cell-degree-2.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-fe_degree-02.svg"
          alt="Depiction of local approximation degrees after two refinements."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-cell-degree-3.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-fe_degree-03.svg"
          alt="Depiction of local approximation degrees after three refinements."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-cell-degree-4.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-fe_degree-04.svg"
          alt="Depiction of local approximation degrees after four refinements."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-cell-degree-5.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-fe_degree-05.svg"
          alt="Depiction of local approximation degrees after five refinements."
          width="200" height="200">
   </div>
@@ -151,32 +152,32 @@ indicating least smoothness and lighter indicating the smoothest areas:
 
 <div class="threecolumn" style="width: 80%">
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-0.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-00.svg"
          alt="Estimated regularity per cell on the initial grid."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-1.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-01.svg"
          alt="Depiction of the estimated regularity per cell after one refinement."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-2.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-02.svg"
          alt="Depiction of the estimated regularity per cell after two refinements."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-3.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-03.svg"
          alt="Depiction of the estimated regularity per cell after three refinements."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-4.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-04.svg"
          alt="Depiction of the estimated regularity per cell after four refinements."
          width="200" height="200">
   </div>
   <div>
-    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-5.png"
+    <img src="https://www.dealii.org/images/steps/developer/step-27-smoothness-05.svg"
          alt="Depiction of the estimated regularity per cell after five refinements."
          width="200" height="200">
   </div>
index dce22f0a9dabf2c386442b43d76a683c5cb3b179..dcda4a9e52417aa693236d17f381ec2c0a75d4c7 100644 (file)
@@ -425,15 +425,16 @@ namespace Step27
       // collection, we will assign a future FE index that corresponds to a
       // polynomial with degree one higher than it currently is. The following
       // function is capable of doing exactly this. Absent any better
-      // strategies, we will set the threshold as the mean value between minimal
-      // and maximal smoothness indicators on cells flagged for refinement. This
-      // is achieved by setting the corresponding fraction parameter to a value
-      // of 0.5. In the same way, we deal with cells that are going to be
-      // coarsened and decrease their polynomial degree when their smoothness
-      // indicator is below the corresponding threshold determined on cells to
-      // be coarsened.
+      // strategies, we will set the threshold via interpolation between the
+      // minimal and maximal smoothness indicators on cells flagged for
+      // refinement. Since the corner singularities are strongly localized, we
+      // will favor $p$- over $h$-refinement quantitatively. We achieve this
+      // with a low threshold by setting a small interpolation factor of 0.2. In
+      // the same way, we deal with cells that are going to be coarsened and
+      // decrease their polynomial degree when their smoothness indicator is
+      // below the corresponding threshold determined on cells to be coarsened.
       hp::Refinement::p_adaptivity_from_relative_threshold(
-        dof_handler, smoothness_indicators, 0.5, 0.5);
+        dof_handler, smoothness_indicators, 0.2, 0.2);
 
       // The above function only determines whether the polynomial degree will
       // change via future FE indices, but does not manipulate the

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.