[cig-commits] r1316 - in trunk/aspect: cookbooks doc doc/manual
bangerth at dealii.org
bangerth at dealii.org
Tue Oct 23 06:43:15 PDT 2012
Author: bangerth
Date: 2012-10-23 07:43:14 -0600 (Tue, 23 Oct 2012)
New Revision: 1316
Added:
trunk/aspect/cookbooks/composition-passive.prm
Modified:
trunk/aspect/doc/manual.pdf
trunk/aspect/doc/manual/manual.tex
Log:
Start on the section on compositional fields.
Copied: trunk/aspect/cookbooks/composition-passive.prm (from rev 1315, trunk/aspect/cookbooks/platelike-boundary.prm)
===================================================================
--- trunk/aspect/cookbooks/composition-passive.prm (rev 0)
+++ trunk/aspect/cookbooks/composition-passive.prm 2012-10-23 13:43:14 UTC (rev 1316)
@@ -0,0 +1,109 @@
+#########################################################
+# This is a variation of the platelike-boundary.prm file.
+# All settings are exactly the same with the exception
+# of the ones that pertain to compositional fields.
+
+set Dimension = 2
+set Start time = 0
+set End time = 20
+set Use years in output instead of seconds = false
+set Output directory = output
+
+
+
+subsection Geometry model
+ set Model name = box
+
+ subsection Box
+ set X extent = 2
+ set Y extent = 1
+ end
+end
+
+
+subsection Model settings
+ set Fixed temperature boundary indicators = 2, 3
+ set Zero velocity boundary indicators =
+ set Tangential velocity boundary indicators = 0, 1, 2
+ set Prescribed velocity boundary indicators = 3: function
+end
+
+
+subsection Boundary temperature model
+ set Model name = box
+
+ subsection Box
+ set Bottom temperature = 1
+ set Top temperature = 0
+ end
+end
+
+
+subsection Boundary velocity model
+ subsection Function
+ set Variable names = x,z,t
+ set Function constants = pi=3.1415926
+ set Function expression = if(x>1+sin(0.5*pi*t), 1, -1); 0
+ end
+end
+
+
+subsection Gravity model
+ set Model name = vertical
+end
+
+
+subsection Initial conditions
+ set Model name = function
+
+ subsection Function
+ set Variable names = x,z
+ set Function expression = (1-z)
+ end
+end
+
+
+subsection Material model
+ set Model name = simple
+
+ subsection Simple model
+ set Thermal conductivity = 1e-6
+ set Thermal expansion coefficient = 1e-4
+ set Viscosity = 1
+ end
+end
+
+
+subsection Mesh refinement
+ set Initial adaptive refinement = 0
+ set Initial global refinement = 5
+ set Time steps between mesh refinement = 0
+end
+
+
+subsection Postprocess
+ set List of postprocessors = visualization, temperature statistics, heat flux statistics
+
+ subsection Visualization
+ set Time between graphical output = 0.1
+ end
+end
+
+
+# This is the new part: We declare that there will
+# be a single compositional field that will be
+# advected along. Its initial conditions are given by
+# a function that is one for the lowermost 0.2 height
+# units of the domain and zero otherwise.
+subsection Compositional fields
+ set Number of fields = 1
+end
+
+subsection Compositional initial conditions
+ set Model name = function
+
+ subsection Function
+ set Variable names = x,y
+ set Function expression = if(y<0.2, 1, 0)
+ end
+end
Modified: trunk/aspect/doc/manual/manual.tex
===================================================================
--- trunk/aspect/doc/manual/manual.tex 2012-10-23 12:51:51 UTC (rev 1315)
+++ trunk/aspect/doc/manual/manual.tex 2012-10-23 13:43:14 UTC (rev 1316)
@@ -2944,6 +2944,54 @@
\end{figure}
+\subsubsection{Using passive and active compositional fields}
+\label{sec:cookbooks-composition}
+
+One frequently wants to track where material goes, either because one simply
+wants to see where stuff ends up (e.g., to determine if a particular model
+yields mixing between the lower and upper mantle) or because the material model
+in fact depends not only pressure, temperature and location but also on the
+mass fractions of certain chemical or other species. We will refer to the first
+case as \textit{passive} and the latter as \textit{active} to indicate the role
+of the additional quantities whose distribution we want to track. We refer to
+the whole process as \textit{compositional} since we consider quantities that
+have the flavor of something that denotes the composition of the material at any
+given point.
+
+There are basically two ways to achieve this: one can advect a set of
+particles (``tracers'') along with the velocity field, or one can advect along a
+field. In the first case, where the closest particle came from indicates the
+value of the concentration at any given position. In the latter case, the
+concentration(s) at any given position is simply given by the value of the
+field(s) at this location.
+
+\aspect{} implements both strategies, at least to a certain degree. In this
+cookbook, we will consider the exact same situation as in the previous section
+but we will ask where the material that started in the bottom 20\% of the domain
+ends up.
+
+
+\begin{lstlisting}[frame=single,language=prmfile,escapechar=\%]
+# This is the new part: We declare that there will
+# be a single compositional field that will be
+# advected along. Its initial conditions are given by
+# a function that is one for the lowermost 0.2 height
+# units of the domain and zero otherwise.
+subsection Compositional fields
+ set Number of fields = 1 % \index[prmindex]{Number of fields} \index[prmindexfull]{Compositional fields!Number of fields} %
+end
+
+subsection Compositional initial conditions
+ set Model name = function % \index[prmindex]{Model name} \index[prmindexfull]{Compositional initial conditions!Model name} %
+
+ subsection Function
+ set Variable names = x,y % \index[prmindex]{Variable names} \index[prmindexfull]{Compositional initial conditions!Function!Variable names} %
+ set Function expression = if(y<0.2, 1, 0) % \index[prmindex]{Function expression} \index[prmindexfull]{Compositional initial conditions!Function!Function expression} %
+ end
+end
+\end{lstlisting}
+
+
\subsection{Geophysical setups}
\label{sec:cookbooks-geophysical}
\marginpar{To be written}
Modified: trunk/aspect/doc/manual.pdf
===================================================================
(Binary files differ)
More information about the CIG-COMMITS
mailing list