[cig-commits] [commit] master: add a test for the composition names (4bf3186)

cig_noreply at geodynamics.org cig_noreply at geodynamics.org
Wed May 21 07:32:29 PDT 2014


Repository : https://github.com/geodynamics/aspect

On branch  : master
Link       : https://github.com/geodynamics/aspect/compare/497a2179702f669476083a98714879503e0dfa90...6aa7541c733b8fd1cc1b0c74536c8804aaeb7015

>---------------------------------------------------------------

commit 4bf31864cc9738787b7aec1253565b457ac7e083
Author: Juliane Dannberg <dannberg at gfz-potsdam.de>
Date:   Wed May 21 05:37:09 2014 +0200

    add a test for the composition names


>---------------------------------------------------------------

4bf31864cc9738787b7aec1253565b457ac7e083
 ...finement_function.prm => composition_names.prm} | 96 ++++------------------
 tests/composition_names/screen-output              | 43 ++++++++++
 tests/composition_names/solution-00000.0000.vtu    | 43 ++++++++++
 tests/composition_names/statistics                 | 19 +++++
 4 files changed, 123 insertions(+), 78 deletions(-)

diff --git a/tests/minimum_refinement_function.prm b/tests/composition_names.prm
similarity index 54%
copy from tests/minimum_refinement_function.prm
copy to tests/composition_names.prm
index 6ea60d7..4a9468b 100644
--- a/tests/minimum_refinement_function.prm
+++ b/tests/composition_names.prm
@@ -11,8 +11,6 @@
 # For more information, see the section in the manual that discusses the
 # general mathematical model.
 
-# MPI: 2
-
 set Adiabatic surface temperature          = 1623               # default: 0
 set CFL number                             = 1.0
 set Composition solver tolerance           = 1e-12
@@ -31,18 +29,13 @@ set Start time                             = 0
 
 set Use years in output instead of seconds = true
 
+subsection Compositional fields
+  set Number of fields = 2
+  set Names of fields = peridotite, eclogite
+end
+
 
 subsection Boundary temperature model
-  # Select one of the following models:
-  # 
-  # `Tan Gurnis': A model for the Tan/Gurnis benchmark.
-  # 
-  # `spherical constant': A model in which the temperature is chosen constant
-  # on the inner and outer boundaries of a spherical shell. Parameters are
-  # read from subsection 'Sherical constant'.
-  # 
-  # `box': A model in which the temperature is chosen constant on all the
-  # sides of a box.
   set Model name = initial temperature
 
   subsection Initial temperature
@@ -55,35 +48,12 @@ subsection Boundary temperature model
 
 end
 
-
-subsection Discretization
-  subsection Stabilization parameters
-
-    # The $\beta$ factor in the artificial viscosity stabilization. An
-    # appropriate value for 2d is 0.078 and 0.117 for 3d. Units: None.
-    set beta  = 0.078
-
-    # The $c_R$ factor in the entropy viscosity stabilization. Units: None.
-    set cR    = 0.33
-  end
-
+subsection Boundary composition model
+  set Model name = initial composition
 end
 
 
 subsection Geometry model
-  # Select one of the following models:
-  # 
-  # `spherical shell': A geometry representing a spherical shell or a pice of
-  # it. Inner and outer radii are read from the parameter file in subsection
-  # 'Spherical shell'.
-  # 
-  # `box': A box geometry parallel to the coordinate directions. The extent of
-  # the box in each coordinate direction is set in the parameter file. The box
-  # geometry labels its 2*dim sides as follows: in 2d, boundary indicators 0
-  # through 3 denote the left, right, bottom and top boundaries; in 3d,
-  # boundary indicators 0 through 5 indicate left, right, front, back, bottom
-  # and top boundaries. See also the documentation of the deal.II class
-  # ``GeometryInfo''.
   set Model name = box # default: 
 
   subsection Box
@@ -95,19 +65,6 @@ end
 
 
 subsection Gravity model
-  # Select one of the following models:
-  # 
-  # `vertical': A gravity model in which the gravity direction is vertically
-  # downward and at a constant magnitude by default equal to one.
-  # 
-  # `radial constant': A gravity model in which the gravity direction is
-  # radially inward and at constant magnitude. The magnitude is read from the
-  # parameter file in subsection 'Radial constant'.
-  # 
-  # `radial earth-like': A gravity model in which the gravity direction is
-  # radially inward and with a magnitude that matches that of the earth at the
-  # core-mantle boundary as well as at the surface and in between is
-  # physically correct under the assumption of a constant density.
   set Model name = vertical # default: 
 
 
@@ -129,6 +86,14 @@ subsection Initial conditions
   end
 end
 
+subsection Compositional initial conditions
+  set Model name = function # default: 
+  subsection Function
+    set Function expression = 0;0
+    set Variable names      = x,y
+  end
+end
+
 
 subsection Material model
 
@@ -138,28 +103,11 @@ end
 
 
 subsection Mesh refinement
-
-  set Additional refinement times              = 
-
   set Coarsening fraction                      = 0.05
   set Refinement fraction                      = 0.3
 
-  set Initial adaptive refinement              = 3                    # default: 2
-  set Initial global refinement                = 3                    # default: 2
-
-  set Normalize individual refinement criteria = true
-  set Refinement criteria merge operation      = max
-
-  set Run postprocessors on initial refinement = true
-
-  set Strategy                                 = temperature, minimum refinement function
-
-  set Time steps between mesh refinement       = 1
-  subsection Minimum refinement function
-    set Function constants  = 
-    set Function expression = 4 + 2*sin(depth*pi/250000)
-    set Variable names      = depth
-  end
+  set Initial adaptive refinement              = 0                    # default: 2
+  set Initial global refinement                = 0                    # default: 2
 end
 
 
@@ -174,15 +122,7 @@ end
 
 subsection Postprocess
 
-  set List of postprocessors = visualization,velocity statistics,temperature statistics,heat flux statistics, depth average # default: all
-
-  subsection Depth average
-    # The time interval between each generation of graphical output files. A
-    # value of zero indicates that output should be generated in each time
-    # step. Units: years if the 'Use years in output instead of seconds'
-    # parameter is set; seconds otherwise.
-    set Time between graphical output = 0 # default: 1e8
-  end
+  set List of postprocessors = visualization,composition statistics
 
   subsection Visualization
 
diff --git a/tests/composition_names/screen-output b/tests/composition_names/screen-output
new file mode 100644
index 0000000..a1d84ee
--- /dev/null
+++ b/tests/composition_names/screen-output
@@ -0,0 +1,43 @@
+-----------------------------------------------------------------------------
+-- This is ASPECT, the Advanced Solver for Problems in Earth's ConvecTion.
+--     . running in DEBUG mode
+--     . running with 2 MPI processes
+--     . using Trilinos
+-----------------------------------------------------------------------------
+
+Number of active cells: 1 (on 1 levels)
+Number of degrees of freedom: 49 (18+4+9+9+9)
+
+*** Timestep 0:  t=0 years
+   Solving temperature system... 0 iterations.
+   Solving composition system 1... 0 iterations.
+   Solving composition system 2... 0 iterations.
+   Rebuilding Stokes preconditioner...
+   Solving Stokes system... 6 iterations.
+
+   Postprocessing:
+     Writing graphical output:  output-composition_names/solution-00000
+     Compositions min/max/mass: 0/0/0 // 0/0/0
+
+Termination requested by criterion: end time
+
+
++---------------------------------------------+------------+------------+
+| Total wallclock time elapsed since start    |     0.449s |            |
+|                                             |            |            |
+| Section                         | no. calls |  wall time | % of total |
++---------------------------------+-----------+------------+------------+
+| Assemble Stokes system          |         1 |    0.0143s |       3.2% |
+| Assemble composition system     |         2 |    0.0916s |        20% |
+| Assemble temperature system     |         1 |    0.0493s |        11% |
+| Build Stokes preconditioner     |         1 |    0.0233s |       5.2% |
+| Build composition preconditioner|         2 |   0.00547s |       1.2% |
+| Build temperature preconditioner|         1 |    0.0466s |        10% |
+| Solve Stokes system             |         1 |    0.0101s |       2.3% |
+| Solve composition system        |         2 |    0.0047s |         1% |
+| Solve temperature system        |         1 |   0.00261s |      0.58% |
+| Initialization                  |         2 |     0.108s |        24% |
+| Postprocessing                  |         1 |    0.0134s |         3% |
+| Setup dof systems               |         1 |    0.0475s |        11% |
++---------------------------------+-----------+------------+------------+
+
diff --git a/tests/composition_names/solution-00000.0000.vtu b/tests/composition_names/solution-00000.0000.vtu
new file mode 100644
index 0000000..d693e4a
--- /dev/null
+++ b/tests/composition_names/solution-00000.0000.vtu
@@ -0,0 +1,43 @@
+<?xml version="1.0" ?> 
+<!-- 
+# vtk DataFile Version 3.0
+#This file was generated 
+-->
+<VTKFile type="UnstructuredGrid" version="0.1" compressor="vtkZLibDataCompressor" byte_order="LittleEndian">
+<UnstructuredGrid>
+<FieldData>
+<DataArray type="Float32" Name="TIME" NumberOfTuples="1" format="ascii">0</DataArray>
+</FieldData>
+<Piece NumberOfPoints="4" NumberOfCells="1" >
+  <Points>
+    <DataArray type="Float64" NumberOfComponents="3" format="binary">
+AQAAAGAAAABgAAAAFgAAAA==eNpjYMANGlrkHBlIkIfxkcUBtuwFjQ==
+    </DataArray>
+  </Points>
+
+  <Cells>
+    <DataArray type="Int32" Name="connectivity" format="binary">
+AQAAABAAAAAQAAAAEwAAAA==eNpjYGBgYARiZiBmAmIAADwABw==
+    </DataArray>
+    <DataArray type="Int32" Name="offsets" format="binary">
+AQAAAAQAAAAEAAAADAAAAA==eNpjYWBgAAAAFAAF
+    </DataArray>
+    <DataArray type="UInt8" Name="types" format="binary">
+AQAAAAEAAAABAAAACQAAAA==eNrjBAAACgAK
+    </DataArray>
+  </Cells>
+  <PointData Scalars="scalars">
+    <DataArray type="Float64" Name="velocity" NumberOfComponents="3" format="binary">
+AQAAAGAAAABgAAAADAAAAA==eNpjYKAtAAAAYAAB    </DataArray>
+    <DataArray type="Float64" Name="p" format="binary">
+AQAAACAAAAAgAAAAIAAAAA==eNpjYGBQED7F68TAwHDgxWUw3ZC2OtkRSh8EAHojCQE=    </DataArray>
+    <DataArray type="Float64" Name="T" format="binary">
+AQAAACAAAAAgAAAAFwAAAA==eNpjYAACl7kOIIohZiaERuIDAEEoBK0=    </DataArray>
+    <DataArray type="Float64" Name="peridotite" format="binary">
+AQAAACAAAAAgAAAACwAAAA==eNpjYMAPAAAgAAE=    </DataArray>
+    <DataArray type="Float64" Name="eclogite" format="binary">
+AQAAACAAAAAgAAAACwAAAA==eNpjYMAPAAAgAAE=    </DataArray>
+  </PointData>
+ </Piece>
+ </UnstructuredGrid>
+</VTKFile>
diff --git a/tests/composition_names/statistics b/tests/composition_names/statistics
new file mode 100644
index 0000000..0f1dc50
--- /dev/null
+++ b/tests/composition_names/statistics
@@ -0,0 +1,19 @@
+# 1: Time step number
+# 2: Time (years)
+# 3: Number of mesh cells
+# 4: Number of Stokes degrees of freedom
+# 5: Number of temperature degrees of freedom
+# 6: Number of degrees of freedom for all compositions
+# 7: Iterations for temperature solver
+# 8: Iterations for composition solver 1
+# 9: Iterations for composition solver 2
+# 10: Iterations for Stokes solver
+# 11: Time step size (years)
+# 12: Visualization file name
+# 13: Minimal value for composition peridotite
+# 14: Maximal value for composition peridotite
+# 15: Global mass for composition peridotite
+# 16: Minimal value for composition eclogite
+# 17: Maximal value for composition eclogite
+# 18: Global mass for composition eclogite
+0 0.0000e+00 1 22 9 18 0 0 0 6 5.5412e+10 output-composition_names/solution-00000 0.00000000e+00 0.00000000e+00 0.00000000e+00 0.00000000e+00 0.00000000e+00 0.00000000e+00 



More information about the CIG-COMMITS mailing list