[cig-commits] r6818 - cs/cigma/trunk/doc/manual

sue at geodynamics.org sue at geodynamics.org
Wed May 9 17:00:09 PDT 2007


Author: sue
Date: 2007-05-09 17:00:09 -0700 (Wed, 09 May 2007)
New Revision: 6818

Modified:
   cs/cigma/trunk/doc/manual/cigma.lyx
Log:
arranged chapter and section heads as outline guide for new manual

Modified: cs/cigma/trunk/doc/manual/cigma.lyx
===================================================================
--- cs/cigma/trunk/doc/manual/cigma.lyx	2007-05-09 23:57:16 UTC (rev 6817)
+++ cs/cigma/trunk/doc/manual/cigma.lyx	2007-05-10 00:00:09 UTC (rev 6818)
@@ -126,7 +126,7 @@
 \end_layout
 
 \begin_layout Chapter
-Preface
+Introduction
 \end_layout
 
 \begin_layout Section
@@ -208,21 +208,6 @@
 \end_layout
 
 \begin_layout Section
-Support
-\end_layout
-
-\begin_layout Standard
-Gale development is supported by a grant from the National Science Foundation
- to CIG, managed by the California Institute of Technology.
- However, most of the software components below Gale have been developed
- by the Victoria Partnership for Advanced Computing (VPAC) and Monash University.
-\end_layout
-
-\begin_layout Chapter
-Introduction
-\end_layout
-
-\begin_layout Section
 About CIGMA
 \end_layout
 
@@ -249,11106 +234,88 @@
 \end_layout
 
 \begin_layout Section
-CIGMA Computational Approach and Governing Equations
+Support
 \end_layout
 
-\begin_layout Subsection
-Infrastructure
-\end_layout
-
 \begin_layout Standard
-Gale uses both a regular grid and particles.
- The regular grid is used to solve differential equations, and particles
- are used to track material properties (e.g., strain history).
- Note that the regular grid can become distorted, since it may conform to
- an uneven upper surface.
+Gale development is supported by a grant from the National Science Foundation
+ to CIG, managed by the California Institute of Technology.
+ However, most of the software components below Gale have been developed
+ by the Victoria Partnership for Advanced Computing (VPAC) and Monash University.
 \end_layout
 
-\begin_layout Subsection
-Units
+\begin_layout Chapter
+Numerical Methods
 \end_layout
 
-\begin_layout Standard
-Gale has no internal knowledge of units.
- So if you tell Gale that a box is 10 units across, it does not know or
- care whether it is 10 cm or 10 km.
- You only have to make sure that you are consistent.
- For example, if you give velocities in cm/year, make sure that your viscosities
- and lengths also use cm and years.
- 
+\begin_layout Section
+Discretization
 \end_layout
 
-\begin_layout Subsection
-Basic Equations
-\end_layout
-
-\begin_layout Standard
-Christensen's non-dimensionalization
-\end_layout
-
 \begin_layout Paragraph*
-Symbols
-\end_layout
 
-\begin_layout Standard
-\begin_inset Formula \[
-D=r_{o}-r_{i}=1,\,\frac{r_{i}}{r_{o}}=0.35,\, r_{i}=\frac{7}{13},\, r_{o}=\frac{20}{13}\]
-
-\end_inset
-
-
 \end_layout
 
 \begin_layout Standard
-\begin_inset Formula $\nu:$
-\end_inset
-
- kinematic viscosity
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula $\eta:$
-\end_inset
-
- magnetic diffusivity
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula $\kappa:$
-\end_inset
-
- thermal diffusivity
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula $\mu:$
-\end_inset
-
- magnetic permeability
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula $\Omega:$
-\end_inset
-
- basic rotating rate
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula $ $
-\end_inset
-
-
-\begin_inset Formula $\rho:$
-\end_inset
-
- density
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula $\alpha:$
-\end_inset
-
- thermal expansion coefficient
-\end_layout
-
-\begin_layout Paragraph*
-Scales
-\end_layout
-
-\begin_layout Standard
-length: 
-\begin_inset Formula $D$
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-time: 
-\begin_inset Formula $\frac{D^{2}}{v}$
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-velocity: 
-\begin_inset Formula $\frac{v}{D}$
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-temperature: 
-\begin_inset Formula $\Delta T$
-\end_inset
-
- 
-\end_layout
-
-\begin_layout Standard
-magnetic field: 
-\begin_inset Formula $(\rho\mu\eta\Omega)^{\frac{1}{2}}$
-\end_inset
-
- 
-\end_layout
-
-\begin_layout Standard
-pressure: 
-\begin_inset Formula $\rho\nu\Omega$
-\end_inset
-
- 
-\end_layout
-
-\begin_layout Paragraph*
-Parameters:
-\end_layout
-
-\begin_layout Standard
-Modified Rayleigh number: 
-\begin_inset Formula $R_{a}=\frac{\alpha g_{o}\Delta TD}{\nu\Omega}$
-\end_inset
-
- 
-\end_layout
-
-\begin_layout Standard
-Ekman number: 
-\begin_inset Formula $E_{c}=\frac{\nu}{\Omega D^{2}}$
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-Prandtl number: 
-\begin_inset Formula $P_{r}=\frac{\nu}{\kappa}$
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-Magnetic Prandtl number: 
-\begin_inset Formula $P_{m}=\frac{\nu}{\eta}$
-\end_inset
-
- 
-\end_layout
-
-\begin_layout Standard
-Dimensionless equations:
-\end_layout
-
-\begin_layout Standard
-.
-\end_layout
-
-\begin_layout Standard
-The head bar denotes the unit vector.
-\end_layout
-
-\begin_layout Standard
-Kuang?s non-dimensionalization
-\end_layout
-
-\begin_layout Standard
-Symbols:
-\end_layout
-
-\begin_layout Standard
-radial of the outer core
-\end_layout
-
-\begin_layout Standard
-kinematic viscosity
-\end_layout
-
-\begin_layout Standard
-magnetic diffusivity
-\end_layout
-
-\begin_layout Standard
-thermal diffusivity
-\end_layout
-
-\begin_layout Standard
-magnetic permeability
-\end_layout
-
-\begin_layout Standard
-basic rotating rate
-\end_layout
-
-\begin_layout Standard
-density
-\end_layout
-
-\begin_layout Standard
-thermal expansion coefficient
-\end_layout
-
-\begin_layout Standard
-Scales:
-\end_layout
-
-\begin_layout Standard
-length: 
-\end_layout
-
-\begin_layout Standard
-time: 
-\end_layout
-
-\begin_layout Standard
-velocity: 
-\end_layout
-
-\begin_layout Standard
-temperature: 
-\end_layout
-
-\begin_layout Standard
-magnetic field: 
-\end_layout
-
-\begin_layout Standard
-pressure: 
-\end_layout
-
-\begin_layout Standard
-Parameters
-\end_layout
-
-\begin_layout Standard
-Rossby number: 
-\end_layout
-
-\begin_layout Standard
-Prandtl number: 
-\end_layout
-
-\begin_layout Standard
-Rayleigh number: 
-\end_layout
-
-\begin_layout Standard
-Ekman number: 
-\end_layout
-
-\begin_layout Standard
-Dimensionless equations:
-\end_layout
-
-\begin_layout Standard
-Note that r in the buoyant force has been normalized with ro, while it is
- normalized with D in Christensen?s equation.
-\end_layout
-
-\begin_layout Standard
-Parameter conversion:
-\end_layout
-
-\begin_layout Standard
-1.
- Conducting state
-\end_layout
-
-\begin_layout Standard
-In Christensen, 
-\end_layout
-
-\begin_layout Standard
-, (2.1)
-\end_layout
-
-\begin_layout Standard
-In Kuang,
-\end_layout
-
-\begin_layout Standard
-.
- (2.2)
-\end_layout
-
-\begin_layout Standard
-For benchmarking, (2.1) and (2.2) must be identical.
- Therefore
-\end_layout
-
-\begin_layout Standard
-(2.3)
-\end_layout
-
-\begin_layout Standard
-where .
-\end_layout
-
-\begin_layout Standard
-2.
- Non-dimensional parameters
-\end_layout
-
-\begin_layout Standard
-(2.4)
-\end_layout
-
-\begin_layout Standard
-(2.5)
-\end_layout
-
-\begin_layout Standard
-(2.6)
-\end_layout
-
-\begin_layout Standard
-(2.7)
-\end_layout
-
-\begin_layout Standard
-3.
- Non-dimensional physical fields
-\end_layout
-
-\begin_layout Standard
-(2.8)
-\end_layout
-
-\begin_layout Standard
-(2.9)
-\end_layout
-
-\begin_layout Standard
-4.
- Other physical quantities
-\end_layout
-
-\begin_layout Standard
-(2.10)
-\end_layout
-
-\begin_layout Standard
-(2.11)
-\end_layout
-
-\begin_layout Standard
-Initial conditions
-\end_layout
-
-\begin_layout Standard
-The initial conditions on radial magnetic field in Christensen can be written
- as,
-\end_layout
-
-\begin_layout Standard
-Thus, in Kuang?s model, the coefficient should be,
-\end_layout
-
-\begin_layout Standard
-The initial conditions on azimuzal magnetic field is,
-\end_layout
-
-\begin_layout Standard
-In kuang?s model, the initial conditions can be rescaled as,
-\end_layout
-
-\begin_layout Standard
-The initial perturbation of the temperature is
-\end_layout
-
-\begin_layout Standard
-where , x being 2r-ro-ri
-\end_layout
-
-\begin_layout Standard
-In Kuang?s model, 
-\end_layout
-
-\begin_layout Standard
-where , x being 
-\end_layout
-
-\begin_layout Standard
-Benchmark cases
-\end_layout
-
-\begin_layout Standard
-Case 2 : Conducting and freely rotating inner core
-\end_layout
-
-\begin_layout Standard
-Christensen?s parameters:
-\end_layout
-
-\begin_layout Standard
-, 
-\end_layout
-
-\begin_layout Standard
-,
-\end_layout
-
-\begin_layout Standard
-Kuang?s parameters:
-\end_layout
-
-\begin_layout Standard
-MoSST set up
-\end_layout
-
-\begin_layout Standard
-KICBV = 1 (no slip at ICB)
-\end_layout
-
-\begin_layout Standard
-KICMV = 1 (no slip at CMB)
-\end_layout
-
-\begin_layout Standard
-KICBT = 1 (fixed heat flux at ICB)
-\end_layout
-
-\begin_layout Standard
-KCMBT = 1 (fixed heat flux at CMB)
-\end_layout
-
-\begin_layout Standard
-k_icrot = 1 (only axial differential rotation )
-\end_layout
-
-\begin_layout Standard
-navfb = 70 ( truncation level for artificial diffision of B)
-\end_layout
-
-\begin_layout Standard
-navft = 70 ( truncation level for artificial diffision of T)
-\end_layout
-
-\begin_layout Standard
-navfv1 = 70 ( truncation level for artificial diffision of v1) (miner =
- 16) 
-\end_layout
-
-\begin_layout Standard
-navfv1 = 70 ( truncation level for artificial diffision of v2)
-\end_layout
-
-\begin_layout Standard
-Estimation
-\end_layout
-
-\begin_layout Standard
-Time scale
-\end_layout
-
-\begin_layout Standard
-=0.0845tc
-\end_layout
-
-\begin_layout Standard
-tc~15, tk~1
-\end_layout
-
-\begin_layout Standard
-temperature scale
-\end_layout
-
-\begin_layout Standard
-magnetic field
-\end_layout
-
-\begin_layout Standard
---? E_b ~ 1.45 
-\end_layout
-
-\begin_layout Standard
-? E_v ~ 50.03
-\end_layout
-
-\begin_layout Subsection
-Gravity
-\end_layout
-
-\begin_layout Section
-MoSST History
-\end_layout
-
-\begin_layout Standard
-Gale arose from discussions at an NSF-sponsored workshop on Tectonic Modeling
- held in Breckenridge, Colorado, in June 2005; see 
-\begin_inset LatexCommand \htmlurl[Geodynamic Modeling of Tectonics Processes 2005 workshop report]{www.geodynamics.org/cig/workinggroups/long/workshops/2005/issues}
-
-\end_inset
-
-.
- At that workshop, members of the tectonics community advocated that CIG
- develop a new open-source software package based on the Arbitrary Lagrangian
- Eulerian (ALE) method for solving tectonic problems.
- The ALE method, as it is implemented in the tectonics community, was developed
- primarily at Dalhousie University in Canada.
- It solves a Stokes flow problem on an Eulerian grid and uses a Lagrangian
- grid to track material properties and to integrate strain.
- This method has seen a great deal of use in crustal and lithospheric deformatio
-n problems such as orogenesis, rifting, and subduction, as well as in coupling
- to surface erosion models, and has been employed for deeper mantle dynamics
- problems.
- Gale is an open-source code that we hope will be at least as useful as
- SOPALE and MicroFEM 
-\begin_inset LatexCommand \cite{Fullsack}
-
-\end_inset
-
- for addressing these research areas
-\color none
-, with the addition of 3D capability.
- In the future, Gale will run benchmarks such as extension and shortening,
- as well as the traditional subduction model as shown in Fig.
- 
-\begin_inset LatexCommand \ref{fig:General-subduction-model}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Standard
-The development of Gale was jump-started by building on top of Underworld
- 
-\begin_inset LatexCommand \cite{Underworld}
-
-\end_inset
-
-, a mantle convection code developed by Louis Moresi's group at Monash and
- the Victorian Partnership for Advanced Computing (VPAC).
- Underworld was created as a parallel version of Ellipsis3D 
-\begin_inset LatexCommand \cite{Ellipsis}
-
-\end_inset
-
-, a mantle convection code which grew out of CitCom 
-\begin_inset LatexCommand \cite{Citcom}
-
-\end_inset
-
-.
- Walter Landry of CIG and Luke Hodkinson of VPAC are the primary developers
- of the Gale-specific components.
- Roger Buck, Robert Bialis, and Gus Correa of Lamont-Doherty Earth Observatory,
- Columbia University, provided valuable user testing.
-\end_layout
-
-\begin_layout Standard
 \noindent
 \align center
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:General-subduction-model}
-
-\end_inset
-
-General subduction model from 
-\begin_inset LatexCommand \cite{Fullsack}
-
-\end_inset
-
-.
- The basic subduction model can be modified by introducing isostasy and/or
- boundary mass fluxes.
- (a) Flexural or local isostasy.
- Every Eulerian column is displaced by the corresponding local or flexural
- deflection 
-\emph on
-w
-\emph default
- of the base.
- (b) Mass fluxes crossing the boundaries may be: (1) the tectonic flux 
-\emph on
-t
-\emph default
-
-\begin_inset Formula $^{\text{+}}$
-\end_inset
-
- into the domain, due to tectonic convergence; (2) the deposition flux 
-\begin_inset Formula $\text{e}^{+}$
-\end_inset
-
- onto the domain, due to surface processes; (3) the deposition flux 
-\begin_inset Formula $\text{e}^{-}$
-\end_inset
-
- from the domain, due to surface processes; (4) the crustal subduction flux
  
-\begin_inset Formula $\text{cs}^{-}$
-\end_inset
-
- from the domain, due to the entrainment of crustal material from the subducting
- plate.
- 
 \end_layout
 
-\begin_layout Standard
-\noindent
-\align center
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/GALE_image1.eps
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
- 
-\end_layout
-
 \begin_layout Chapter
-Installation and Getting Help
+Implementation
 \end_layout
 
 \begin_layout Section
-Introduction
+Sparce Matrix Representation
 \end_layout
 
 \begin_layout Standard
-Installation of Gale on a desktop or laptop machine is, in most cases, very
- easy.
- Binary packages have been created for the most common platforms, i.e., Linux,
- Mac OS X, and Windows.
- Installation on other architectures or on parallel machines requires building
- the software from the source code, which can be difficult for inexperienced
- users.
- 
+You must also have pyth
 \end_layout
 
 \begin_layout Section
-Binaries
+Subroutines
 \end_layout
 
-\begin_layout Standard
-If you do not need to run on parallel machines, the easiest way to install
- Gale is to download binaries for your platform from the 
-\begin_inset LatexCommand \htmlurl[Gale website]{geodynamics.org/cig/software/packages/long/gale/}
-
-\end_inset
-
-.
- Then you can run Gale from the command line or DOS prompt.
- CIG provides binaries for Linux, Mac OS X (10.4 or greater), and Windows
- (2000 and XP).
-\end_layout
-
 \begin_layout Section
-Building from Source
+Running the Code
 \end_layout
 
-\begin_layout Standard
-Read this only if the binaries are not sufficient for you.
- 
-\end_layout
-
-\begin_layout Subsection
-System Requirements
-\end_layout
-
-\begin_layout Standard
-Gale works on a variety of computational platforms and has been tested on
- workstations running 
-\end_layout
-
-\begin_layout Itemize
-Mac OS X 10.4.6 (G4 and G5)
-\end_layout
-
-\begin_layout Itemize
-Windows 2000 and XP SP2
-\end_layout
-
-\begin_layout Itemize
-RedHat Fedora Core 5 (x86)
-\end_layout
-
-\begin_layout Itemize
-OpenSuse 10.0 (x86)
-\end_layout
-
-\begin_layout Itemize
-Gentoo (x86)
-\end_layout
-
-\begin_layout Itemize
-Debian stable (x86 and AMD64), testing (x86), and unstable (x86)
-\end_layout
-
-\begin_layout Standard
-Gale has also been tested on clusters running Redhat 7.2 (x86) and RedHat
- Enterprise Linux 3 (EM64T).
-\end_layout
-
-\begin_layout Subsection
-Dependencies
-\end_layout
-
-\begin_layout Standard
-In order to build Gale, you must have the headers and development libraries
- for
-\end_layout
-
-\begin_layout Itemize
-MPI
-\end_layout
-
-\begin_layout Itemize
-PETSc 2.3.2
-\end_layout
-
-\begin_layout Itemize
-libxml2
-\end_layout
-
-\begin_layout Standard
-You must also have python 2.2.1 or greater installed.
- If you do not already have MPI, then in many cases PETSc can install a
- version for you.
- Installing PETSc also requires a Blas/Lapack implementation.
-\end_layout
-
-\begin_layout Subsection
-\begin_inset LatexCommand \label{sec:Downloading-the-Code}
-
-\end_inset
-
-Downloading the Code
-\end_layout
-
-\begin_layout Standard
-You can get the source for the latest release from the 
-\begin_inset LatexCommand \htmlurl[Gale website]{geodynamics.org/cig/software/packages/long/gale/}
-
-\end_inset
-
-.
- In that tarball is the file INSTALL.
- For some platforms, there are platform-specific instructions.
- Generally, the hardest part is not installing Gale itself, but PETSc.
-\end_layout
-
-\begin_layout Subsubsection
-Source Code Repository (Experts Only)
-\end_layout
-
-\begin_layout Standard
-Advanced users and software developers may be interested in downloading
- the latest Gale source code directly from the CIG source code repository,
- instead of using the prepared source package.
- To check whether you have a subversion client installed on your machine,
- type:
-\end_layout
-
-\begin_layout LyX-Code
-svn
-\end_layout
-
-\begin_layout Standard
-You should get a response that looks something like this:
-\end_layout
-
-\begin_layout LyX-Code
-Type `svn help' for usage.
-\end_layout
-
-\begin_layout Standard
-Otherwise, you will need to download and install a Subversion client, available
- at the 
-\begin_inset LatexCommand \htmlurl[Subversion Website]{subversion.tigris.org/project_packages.html}
-
-\end_inset
-
-.
- Then the code can be checked out with the following command: 
-\end_layout
-
-\begin_layout LyX-Code
-svn checkout http://geodynamics.org/svn/cig/long/3D/Gale/trunk Gale
-\end_layout
-
-\begin_layout LyX-Code
-
-\end_layout
-
-\begin_layout Section
-Support
-\end_layout
-
-\begin_layout Standard
-The primary point of support for Gale is the 
-\begin_inset LatexCommand \url[CIG Long-Term Crustal Dynamics Mailing List]{cig-long at geodynamics.org}
-
-\end_inset
-
-.
- Feel free to send questions, comments, feature requests, and bugs to the
- list.
- The mailing list is archived at
-\end_layout
-
-\begin_layout LyX-Code
-\begin_inset LatexCommand \htmlurl[cig-long Archives]{geodynamics.org/pipermail/cig-long/}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-You may also use the bug tracker
-\end_layout
-
-\begin_layout LyX-Code
-\begin_inset LatexCommand \htmlurl[Roundup]{geodynamics.org/roundup}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-to submit bugs and requests for new features.
-\end_layout
-
 \begin_layout Chapter
-Running Gale
+Numerical Results
 \end_layout
 
 \begin_layout Section
-Gale Usage
+Unit Cube and Verification
 \end_layout
 
-\begin_layout Standard
-If you downloaded binaries for your platform, you can run the Gale executable
- directly.
- For example,
-\end_layout
-
-\begin_layout LyX-Code
-./Gale-1_2_0  input/extension.xml
-\end_layout
-
-\begin_layout Standard
-will output 
-\end_layout
-
-\begin_layout LyX-Code
-TimeStep = 1, Start time = 0 + 0 prev timeStep dt
-\end_layout
-
-\begin_layout LyX-Code
-TimeStep = 2, Start time = 0 + 0.0291667 prev timeStep dt
-\end_layout
-
-\begin_layout LyX-Code
-TimeStep = 3, Start time = 0.0291667 + 0.0283326 prev timeStep dt
-\end_layout
-
-\begin_layout LyX-Code
-TimeStep = 4, Start time = 0.0574992 + 0.0274655 prev timeStep dt
-\end_layout
-
-\begin_layout LyX-Code
-TimeStep = 5, Start time = 0.0849647 + 0.0265162 prev timeStep dt
-\end_layout
-
-\begin_layout LyX-Code
-...
-\end_layout
-
-\begin_layout Standard
-If you do not specify an input file, you will get an error like
-\end_layout
-
-\begin_layout LyX-Code
-
-\size small
-Error in _AbstractContext_New: The dictionary is empty, meaning no input
- parameters have been feed
-\end_layout
-
-\begin_layout LyX-Code
-
-\size small
-into your program.
- Perhaps you've forgot to pass any input files ( or command-line arguments
- ) in.
-\end_layout
-
-\begin_layout LyX-Code
-
-\size small
-Gale: build/StGermain/Base/IO/src/Journal.c:603: Journal_Firewall: Assertion
- `expression' failed.
-\end_layout
-
-\begin_layout LyX-Code
-
-\size small
-p0_27845:  p4_error: interrupt SIGx: 6 
-\end_layout
-
-\begin_layout LyX-Code
-
-\end_layout
-
-\begin_layout Standard
-If Gale cannot find the file, you will get a different error:
-\end_layout
-
-\begin_layout LyX-Code
-
-\size small
-Error: File input/extension.xml doesn't exist, not readable, or not valid.
-\end_layout
-
-\begin_layout LyX-Code
-
-\size small
-Gale: build/StGermain/Base/IO/src/Journal.c:603: Journal_Firewall: Assertion
- `expression' failed.
-\end_layout
-
-\begin_layout LyX-Code
-
-\size small
-p0_16810:  p4_error: interrupt SIGx: 6
-\end_layout
-
-\begin_layout Standard
-Due to quirks in some implementations of MPI, you may have to specify the
- complete path to the input file (e.g., 
-\family typewriter
-./Gale-1_2_0 /home/juser/gale/input/extension.xml
-\family default
-).
-\end_layout
-
-\begin_layout Standard
-In general, Gale does not have many defaults, so almost everything must
- be specified in the input file.
- For examples of how to create your own input files, see Chapter 
-\begin_inset LatexCommand \ref{cha:Cookbooks}
-
-\end_inset
-
-.
- For a complete description of the input file format, see Appendix 
-\begin_inset LatexCommand \ref{cha:Input-File-Format}
-
-\end_inset
-
-.
- 
-\end_layout
-
-\begin_layout Standard
-If you compile Gale yourself, you can run it from where you installed it.
- If running in parallel on your own machine, prepend 
-\family typewriter
-mpirun
-\family default
- or 
-\family typewriter
-mpiexec
-\family default
- (depending on your local implementation of MPI).
- For example, if your computer has two processors, then
-\end_layout
-
-\begin_layout LyX-Code
-mpirun -np 2 bin/Gale /home/juser/gale/input/extension.xml
-\end_layout
-
-\begin_layout Standard
-will use both processors.
-\end_layout
-
-\begin_layout Standard
-The 
-\family typewriter
-extension.xml
-\family default
- example should run for 100 time steps and generate a great deal of output
- in the 
-\family typewriter
-output.extension
-\family default
- directory.
- There are also examples of shortening, subduction, and relaxation of topography.
-\end_layout
-
-\begin_layout Standard
-Gale uses PETSc's GMRES linear solver by default.
- However, PETSc has a facility where you can use command line arguments
- to change the solver.
- For example, on serial machines with small problems, a direct solve can
- be much faster than GMRES.
- To use a direct LU solve, you only need to append arguments to the command
- line
-\end_layout
-
-\begin_layout LyX-Code
-./Gale-1_2_0  input/extension.xml -pc_type lu -ksp_type preonly
-\end_layout
-
-\begin_layout Standard
-You can also change the default values of 
-\family typewriter
-extension.xml
-\family default
- without modifying that file by appending arguments.
- For example, to just change the number of time steps from the default value
- 100 to 10, use the following command
-\end_layout
-
-\begin_layout LyX-Code
-./Gale-1_2_0  input/extension.xml --maxTimeSteps=10
-\end_layout
-
-\begin_layout Standard
-You can append any number of modified parameters in one unbroken line
-\end_layout
-
-\begin_layout LyX-Code
-
-\size small
-./Gale-1_2_0  input/extension.xml --maxTimeSteps=10 --dim=3 --elementResI=64
- 
-\end_layout
-
-\begin_layout LyX-Code
-
-\size small
---elementResJ=64 --elementResK=64 --particlesPerCell=60 --dumpEvery=10
-\end_layout
-
 \begin_layout Section
-Output and Visualization
+Complex Geometries
 \end_layout
 
-\begin_layout Standard
-The sample input files will produce a directory in which you will find a
- number of 
-\family typewriter
-.dat
-\family default
-, 
-\family typewriter
-.txt
-\family default
-, and 
-\family typewriter
-\color none
-.vtk
-\family default
- files.
- The formats of the 
-\family typewriter
-.dat
-\family default
- and 
-\family typewriter
-.txt
-\family default
- files are described fully in Appendix 
-\begin_inset LatexCommand \ref{cha:Output-File-Format}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Standard
-The default setting is to create files for every time step.
- To change the frequency of creating the 
-\family typewriter
-.dat
-\family default
- files, you need to change the parameter 
-\family typewriter
-checkpointEvery
-\family default
-.
- For example, if you modify the line with 
-\family typewriter
-checkpointEvery
-\family default
- to 
-\end_layout
-
-\begin_layout LyX-Code
-<param name="checkpointEvery">25</param>
-\end_layout
-
-\begin_layout Standard
-then the 
-\family typewriter
-.dat
-\family default
- files will only be created every 25 time steps.
- You can change the value to any number you want.
- On the other hand, to change the frequency for creating 
-\family typewriter
-.txt
-\family default
- and 
-\family typewriter
-.vtk
-\family default
- files, you need to change the parameter 
-\family typewriter
-dumpEvery
-\family default
-.
-\end_layout
-
-\begin_layout LyX-Code
-<param name="dumpEvery">25</param>
-\end_layout
-
-\begin_layout Quote
-
-\color red
-Note:
-\color none
- In order to get viscosity information out, you must add a 
-\family typewriter
-StoreViscosity
-\family default
- struct to your rheology as in Section 
-\begin_inset LatexCommand \ref{sec:Viscous-Material}
-
-\end_inset
-
- (see also Section 
-\begin_inset LatexCommand \ref{sub:StoreViscosity}
-
-\end_inset
-
-).
- This is already done in all of the example input files.
-\end_layout
-
-\begin_layout Standard
-
-\color none
-There are a number of different options for visualizing the data.
- The easiest way is to use the 
-\family typewriter
-.vtk
-\family default
- files.
- These files are in a standard, self-describing file format that can be
- easily visualized with several different visualization programs, e.g., 
-\begin_inset LatexCommand \htmlurl[ParaView]{paraview.org}
-
-\end_inset
-
-, 
-\begin_inset LatexCommand \htmlurl[MayaVI]{mayavi.sf.net}
-
-\end_inset
-
-, and 
-\begin_inset LatexCommand \htmlurl[Visit]{www.llnl.gov/visit}
-
-\end_inset
-
-.
- ParaView is recommended as it is easy to get working, easy to use, and
- scales to large data sets.
-\end_layout
-
-\begin_layout Standard
-Another option is to use the Matlab scripts in the 
-\family typewriter
-tools/
-\family default
- directory.
- These scripts only work in 2D and only when running simulations with yielding
- material.
-\end_layout
-
-\begin_layout Standard
-The last option is to use a spreadsheet program such as Excel.
- This is very limited, as you only see the location of the particles.
- You cannot visualize the viscosity or degree of yielding of the particles,
- nor can you visualize the fields (e.g.
- strain rate, pressure, etc.).
-\end_layout
-
-\begin_layout Subsection
-Visualization with ParaView
-\begin_inset LatexCommand \label{sub:Visualization-with-ParaView}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-
-\color none
-To visualize step #10 of 
-\family typewriter
-input/extension.xml
-\family default
-, 
-\end_layout
-
-\begin_layout Enumerate
-
-\color none
-Start Paraview and open new data: 
-\family sans
-File
-\family default
- 
-\begin_inset Formula $\triangleright$
-\end_inset
-
- 
-\family sans
-Open Data
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-
-\color none
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_open_data.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\newpage
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-A file dialog screen will appear.
- Navigate to the output directory and select 
-\family typewriter
-\color none
-pressure.0.00010.vtk
-\family default
-.
- Paraview will display a pseudocolor plot of the pressure.
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-
-\color none
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_pressure.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-You can also look at the velocities and strains by opening 
-\family typewriter
-\color none
-fields.0.00010.vtk
-\family default
- (with 
-\family sans
-File
-\family default
- 
-\begin_inset Formula $\triangleright$
-\end_inset
-
- 
-\family sans
-Open Data
-\family default
-).
- By default, Paraview will obscure the pressure with the velocity magnitude.
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-
-\color none
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-
-\color none
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_vmag.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\newpage
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-You can remove the velocity magnitude by clicking on the ``eye'' symbol
- next to 
-\family typewriter
-\color none
-fields.0.00010.vtk
-\family default
-, graying it out.
-\newline
-
-\newline
-
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_grey_eye.png
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Enumerate
-Now you can plot the velocity as arrows on top of the pressure: Click on
- the ``Glyph'' symbol
-\newline
-
-\newline
-
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_glyph.png
-
-\end_inset
-
-
-\newline
-
-\newline
-and then press the green ``Accept'' button.
- The result will look like this:
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_pressure_velocity.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\newpage
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-You can also visualize the Strain Rate Invariant: Click on the grayed-out
- eye next to 
-\family typewriter
-\color none
-fields.0.00010.vtk
-\family default
-, and then click on the ``Display'' tab.
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-
-\color none
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_v_vector.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Finish by clicking on the drop down list to the right of ``Color by'' and
- selecting ``Point StrainRateInvariantField.''
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_strainrate.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\newpage
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Now look at the particles.
- Starting over, open 
-\family typewriter
-\color none
-particles.0.00010.vtk
-\family default
- and click on the ``Glyph'' button.
- Change Glyph to Sphere0, Scale Mode to ``Data Scaling Off,'' the Scale
- Factor to 0.01, and press the Accept button.
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-
-\color none
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-
-\color none
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_particles_viscosity.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-
-\color none
-This displays the viscosity of the particles.
- The blue points represent low viscosity material, either the material at
- the bottom that was originally low viscosity, or the material that has
- yielded.
- 
-\newpage
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-To see explicitly which material has yielded, click on the ``Display'' tab
- and change the ``Color by'' box to ``Point Yielding_fraction.''
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_particles_yielding.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\end_deeper
-\begin_layout Subsection
-Visualization with Matlab or Octave
-\end_layout
-
-\begin_layout Standard
-
-\color none
-Gale includes a number of Matlab visualization scripts in the 
-\family typewriter
-tools/
-\family default
- directory.
- The scripts also work with Octave, a free Matlab clone.
- However, they only work for 2D runs with yielding rheologies.
- To use these scripts, 
-\end_layout
-
-\begin_layout Enumerate
-
-\color none
-Navigate into the 
-\family typewriter
-tools/
-\family default
- directory 
-\end_layout
-
-\begin_layout Enumerate
-
-\color none
-Modify 
-\family typewriter
-fname
-\family default
- in 
-\family typewriter
-PlotGaleOutput.m
-\family default
- to point to the output directory
-\end_layout
-
-\begin_layout Enumerate
-
-\color none
-Change 
-\family typewriter
-step
-\family default
- to the time step
-\end_layout
-
-\begin_layout Enumerate
-
-\color none
-Start Matlab or Octave and type
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-PlotGaleOutput
-\end_layout
-
-\begin_layout Enumerate
-Using Octave to visualize the 10th step of 
-\family typewriter
-input/extension.xml
-\family default
- results in
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Octave_fig1.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Octave_fig2.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Octave_fig3.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\newpage
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Using Matlab results in
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Matlab_fig111.png
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Matlab_fig112.png
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\end_deeper
-\end_deeper
-\begin_layout Subsection
-Visualization with Excel
-\end_layout
-
-\begin_layout Standard
-
-\color none
-You can set the DumpSwarm plugin (see Section 
-\begin_inset LatexCommand \ref{sec:.txt-Files-(Particle}
-
-\end_inset
-
-) to directly output 
-\family typewriter
-.csv
-\family default
- files, which you can use for limited visualization with a spreadsheet program
- such as Excel.
- For example, for the 
-\family typewriter
-input/extension.xml
-\family default
- input file, 
-\end_layout
-
-\begin_layout Enumerate
-
-\color none
-Open the file 
-\family typewriter
-output.extension/particles.00010.csv
-\family default
- with your spreadsheet program.
- Select the second two columns
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-
-\color none
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-
-\color none
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Gnumeric_two_columns.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Create a chart
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-
-\color none
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Gnumeric_new_chart.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\newpage
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Select an XY plot and press Insert
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Gnumeric_xy_plot.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\newpage
-
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Then press anywhere on the spreadsheet, and you will have a plot of the
- particles.
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Gnumeric_final.png
-	lyxscale 50
-	scale 50
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\end_deeper
-\begin_layout LyX-Code
-
-\end_layout
-
 \begin_layout Section
-Gauging Accuracy
+Performance
 \end_layout
 
 \begin_layout Standard
-Gale makes a number of approximations.
- Before trusting any results you get from Gale, you must vary a number of
- parameters to insure that the results are not an artifact of Gale's approximati
-ons.
- Specifically, for every simulation, vary the resolution (
-\family typewriter
-elementResI
-\family default
-, 
-\family typewriter
-elementResJ
-\family default
-, 
-\family typewriter
-elementResK
-\family default
-) and the number of particles in each element (
-\family typewriter
-particlesPerCell
-\family default
-).
- For problems with inflow boundaries (see Sections 
-\begin_inset LatexCommand \ref{sec:Viscous-In-Outflow}
 
-\end_inset
-
- and 
-\begin_inset LatexCommand \ref{sub:Flux-Boundary-Conditions}
-
-\end_inset
-
-), you must vary the size of the boundary box.
- In addition, depending on the boundary conditions, you may need to vary
- the size of the box (
-\family typewriter
-minX
-\family default
-, 
-\family typewriter
-minY
-\family default
-, 
-\family typewriter
-minZ
-\family default
-, 
-\family typewriter
-maxX
-\family default
-, 
-\family typewriter
-maxY
-\family default
-, 
-\family typewriter
-maxZ
-\family default
-).
- Finally, vary the tolerance for each nonlinear iteration (
-\family typewriter
-tolerance
-\family default
- in the 
-\family typewriter
-uzawa
-\family default
- component).
 \end_layout
 
 \begin_layout Chapter
-Cookbooks
-\begin_inset LatexCommand \label{cha:Cookbooks}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-Introduction
-\end_layout
-
-\begin_layout Standard
-In this chapter, you will edit a template file (
-\family typewriter
-input/cookbook/template.xml
-\family default
-) to create customized input files.
- You should be able to use the template file as a basis for most of your
- own input files.
- There are two things in the template file, however, that might need modificatio
-n: the force of gravity, which by default is set to 1 (if you are using
- cgs, for example, the force of gravity must be changed to 980), and the
- normal velocities on all boundaries except the top, which are set to zero.
- Beyond that, you only need to add where different materials are placed
- initially.
-\end_layout
-
-\begin_layout Subsection
-Adding Lines to the Template File
-\end_layout
-
-\begin_layout Standard
-Unless otherwise specified, when you are instructed to add sections to the
- input file
-\begin_inset Foot
-status collapsed
-
-\begin_layout Standard
-To copy and paste from this PDF with Adobe Acrobat, right click to get the
- context menu and select ``Allow Hand Tool to Select Text.''
-\end_layout
-
-\end_inset
-
-, that text should be added after the line
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="components">
-\end_layout
-
-\begin_layout Standard
-at the beginning of the file, and before the lines
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<list name="plugins">
-\end_layout
-
-\begin_layout Standard
-The template file is already indented to prevent you from adding a component
- in the middle of another component, although indentation is not critical.
-\end_layout
-
-\begin_layout Subsection
-Adding Variables to the Template File
-\end_layout
-
-\begin_layout Standard
-When you are instructed to add a variable, you must add it at the end of
- the file before the closing line
-\end_layout
-
-\begin_layout LyX-Code
-</StGermainData>
-\end_layout
-
-\begin_layout Standard
-Finished versions of all of these examples are found in 
-\family typewriter
-input/cookbook
-\family default
-.
- 
-\end_layout
-
-\begin_layout Section
-\begin_inset LatexCommand \label{sec:Viscous-Material}
-
-\end_inset
-
-Viscous Material
-\end_layout
-
-\begin_layout Standard
-This example simply fills up the computational domain with a single viscous
- material.
- It is a valid input file, but will not run as nothing is moving.
- This file mainly serves as the basis for subsequent examples.
-\end_layout
-
-\begin_layout Enumerate
-First, copy 
-\family typewriter
-template.xml
-\family default
- to 
-\family typewriter
-myviscous.xml
-\family default
- to edit as follows.
- 
-\end_layout
-
-\begin_layout Enumerate
-Add in a material.
- The simplest variety is a purely viscous material, so add a box covering
- the whole domain:
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="boxShape">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Box</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startX">minX</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endX">maxX</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startY">minY</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endY">maxY</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startZ">minZ</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endZ">maxZ</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-Note: Default parameters for the box (e.g., 
-\family typewriter
-minX
-\family default
-, 
-\family typewriter
-maxX
-\family default
-, 
-\family typewriter
-minY
-\family default
-, etc.) are already defined in 
-\family typewriter
-template.xml
-\family default
-.
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Then set the material's viscosity
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="backgroundViscosity">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MaterialViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="eta0">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-Remember that Gale has no internal knowledge of units, so if you think of
- everything in cgs, then this implies a viscosity of 
-\begin_inset Formula $1\frac{g}{cm^{2}\, s}$
-\end_inset
-
-.
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-In order for Gale to include the viscosity in the output, we have to store
- the viscosity in a separate field (see Section 
-\begin_inset LatexCommand \ref{sub:StoreViscosity}
-
-\end_inset
-
-).
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="storeViscosity">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StoreVisc</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="MaterialPointsSwarm">materialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-Here, 
-\family typewriter
-materialswarm
-\family default
- is a collection of particles.
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Finally, you create the material, using the components just created.
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="viscous">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">RheologyMaterial</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Shape">boxShape</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="density">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="Rheology">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>backgroundViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>storeViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Save this file, as it will be the basis for other examples that follow.
- 
-\end_layout
-
-\begin_layout Standard
-You can compare your result with the worked example in the file 
-\family typewriter
-input/cookbook/viscous.xml
-\family default
-.
-\end_layout
-
-\begin_layout Section
-\begin_inset LatexCommand \label{sec:Viscous-Material-in}
-
-\end_inset
-
-Viscous Material in Simple Extension
-\end_layout
-
-\begin_layout Standard
-The input file you created in Section 
-\begin_inset LatexCommand \ref{sec:Viscous-Material}
-
-\end_inset
-
- is valid, but nothing moves, so Gale will output errors if you try to run
- it.
- In this next example, you will make the material extend by having the right
- boundary move.
-\end_layout
-
-\begin_layout Enumerate
-Copy 
-\family typewriter
-myviscous.xml
-\family default
- to 
-\family typewriter
-myviscous_extension.xml
-\family default
-.
-\end_layout
-
-\begin_layout Enumerate
-Make the right boundary move by changing the line after this section
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<param name="type">WallVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="wall">right</param>
-\end_layout
-
-\begin_layout LyX-Code
-<list name="variables">
-\end_layout
-
-\begin_layout LyX-Code
-  <struct>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="name">vx</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="type">double</param>
-\end_layout
-
-\begin_layout Standard
-from
-\end_layout
-
-\begin_layout LyX-Code
-<param name="value">0.0</param>
-\end_layout
-
-\begin_layout Standard
-to
-\end_layout
-
-\begin_layout LyX-Code
-<param name="value">1.0</param>
-\end_layout
-
-\begin_layout Quote
-
-\series bold
-\color red
-Warning:
-\series default
-\color none
- There are several 
-\family typewriter
-WallVC
-\family default
- structs: 
-\family typewriter
-front
-\family default
-, 
-\family typewriter
-back
-\family default
-, 
-\family typewriter
-left
-\family default
-, 
-\family typewriter
-right
-\family default
-, 
-\family typewriter
-top
-\family default
- and 
-\family typewriter
-bottom
-\family default
-.
- Here we have only modified the 
-\family typewriter
-right
-\family default
- side.
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-You can now run this example, and the output will go into the directory
- 
-\family typewriter
-output.template
-\family default
-.
- If you want to run in 3D, you only need to change the line after
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<param name="outputPath">./output.template</param> 
-\end_layout
-
-\begin_layout Standard
-from
-\end_layout
-
-\begin_layout LyX-Code
-<param name="dim">2</param>
-\end_layout
-
-\begin_layout Standard
-to
-\end_layout
-
-\begin_layout LyX-Code
-<param name="dim">3</param>
-\end_layout
-
-\end_deeper
-\begin_layout Standard
-A worked example is at 
-\family typewriter
-input/cookbook/viscous_extension.xml
-\family default
-.
- A visualization of the strain rate invariant and velocity (see Section
- 
-\begin_inset LatexCommand \ref{sub:Visualization-with-ParaView}
-
-\end_inset
-
-) is shown in Figure 
-\begin_inset LatexCommand \ref{fig:Strain-viscous-extension}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_viscous_extension.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Strain-viscous-extension}
-
-\end_inset
-
-Strain rate invariant and velocities of viscous material in extension
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-The banding is a numerical artifact that arises from having a finite number
- of particles per cell.
- This example generates no topography, since the material is stretched uniformly.
-\end_layout
-
-\begin_layout Section
-Viscous Material with Complex Boundaries
-\end_layout
-
-\begin_layout Standard
-Another exercise is to make the bottom boundary move differently, and not
- just have the material slide along.
- In particular, this example will simulate a box like in Figure 
-\begin_inset LatexCommand \ref{fig:Split-Boundary}
-
-\end_inset
-
-, where the bottom right side of the box moves, but the viscous material
- sticks to the bottom left.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement h
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\align center
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/splitwall.eps
-	width 80col%
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Split-Boundary}
-
-\end_inset
-
-Split Boundary
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Enumerate
-First, copy 
-\family typewriter
-myviscous_extension.xml
-\family default
- to 
-\family typewriter
-myviscous_split.xml
-\end_layout
-
-\begin_layout Enumerate
-Modify the bottom boundary condition of WallVC to
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="type">WallVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="wall">bottom</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="variables">
-\end_layout
-
-\begin_layout LyX-Code
-    <struct>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="name">vy</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="type">double</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="value">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-    </struct>
-\end_layout
-
-\begin_layout LyX-Code
-    <struct>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="name">vx</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="type">func</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="value">StepFunction</param>
-\end_layout
-
-\begin_layout LyX-Code
-    </struct>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-This makes the velocity of the bottom boundary a step function.
- 
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-You must also specify the parameters of the step function by adding the
- variables
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<param name="StepFunctionLowerOffset">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionUpperOffset">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionValue">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionDim">0</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionLessThan">False</param>
-\end_layout
-
-\begin_layout Standard
-to the end of the file (just before 
-\family typewriter
-</StGermain
-\family default
-Data
-\family typewriter
->
-\family default
-).
- 
-\end_layout
-
-\begin_layout Quote
-
-\series bold
-\color red
-Warning: 
-\series default
-\color none
-Do not add them in the list named 
-\family typewriter
-``variables
-\family default
-.'' 
-\end_layout
-
-\end_deeper
-\begin_layout Standard
-A worked example is in the file 
-\family typewriter
-input/cookbook/viscous_split.xml
-\family default
-.
- A visualization of the strain rate invariant and velocity (see Section
- 
-\begin_inset LatexCommand \ref{sub:Visualization-with-ParaView}
-
-\end_inset
-
-) shown in Figure 
-\begin_inset LatexCommand \ref{fig:Strain-complex}
-
-\end_inset
-
- shows that strain rate is concentrated around the step function in the
- bottom velocity boundary.
- Notice the development of a basin above the discontinuity.
- The ability to track the development of topography on the free surfaces
- is one of the strengths of Gale.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_viscous_split.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Strain-complex}
-
-\end_inset
-
-Strain rate invariant and velocities with complex boundaries
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-\begin_inset LatexCommand \label{sec:Viscous-In-Outflow}
-
-\end_inset
-
-Viscous Material with Inflow/Outflow Boundaries
-\end_layout
-
-\begin_layout Standard
-This example implements a different kind of boundary condition, where material
- flows in one side and out another as in Figure 
-\begin_inset LatexCommand \ref{fig:Inflow/Outflow-Boundary}
-
-\end_inset
-
-.
- The current example is not intended to be geologically realistic in any
- sense, but is meant to illustrate the enormous flexibility we have in the
- development of complex boundary conditions.
- A more realistic model of subduction is included in the sample input file
- 
-\family typewriter
-input/subduction.xml
-\family default
-.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement h
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\align center
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/inflow.eps
-	width 80col%
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Inflow/Outflow-Boundary}
-
-\end_inset
-
-Inflow/Outflow Boundary
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Enumerate
-Copy the file 
-\family typewriter
-myviscous.xml
-\family default
- that you created in Section 
-\begin_inset LatexCommand \ref{sec:Viscous-Material}
-
-\end_inset
-
- to 
-\family typewriter
-myviscous_inflow.xml
-\family default
-.
- 
-\end_layout
-
-\begin_layout Enumerate
-Then, add the following lines after the 
-\family typewriter
-wrapTop
-\family default
- line so that Gale keeps the left and bottom sides fixed:
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<param name="staticLeft">True</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="staticBottom">True</param>
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Now specify the velocities on the boundaries using the 
-\family typewriter
-StepFunctionProduct
-\family default
- functions.
- For the left boundary, modify the left 
-\family typewriter
-WallVC
-\family default
- to
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<param name="type">WallVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="wall">left</param>
-\end_layout
-
-\begin_layout LyX-Code
-<list name="variables">
-\end_layout
-
-\begin_layout LyX-Code
-  <struct>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="name">vx</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="type">func</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="value">StepFunctionProduct3</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </struct>
-\end_layout
-
-\begin_layout LyX-Code
-</list>
-\end_layout
-
-\begin_layout Standard
-and add the variables at the end of the file (just before 
-\family typewriter
-</StGermainData>
-\family default
-)
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct3Start">0.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct3End">0.2</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct3Value">1</param>
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-For the bottom boundary, modify the bottom 
-\family typewriter
-WallVC
-\family default
- to
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<param name="type">WallVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="wall">bottom</param>
-\end_layout
-
-\begin_layout LyX-Code
-<list name="variables">
-\end_layout
-
-\begin_layout LyX-Code
-  <struct>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="name">vy</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="type">func</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="value">StepFunctionProduct2</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </struct>
-\end_layout
-
-\begin_layout LyX-Code
-  <struct>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="name">vx</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="type">func</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="value">StepFunctionProduct1</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </struct>
-\end_layout
-
-\begin_layout LyX-Code
-</list>
-\end_layout
-
-\begin_layout Standard
-and add the variables to the end of the file (just before 
-\family typewriter
-</StGermainData>
-\family default
-)
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct1Start">0.9</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct1End">1.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct1Value">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct2Start">0.9</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct2End">1.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct2Value">-1.0</param>
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Finally, you must alter the way that Gale creates particles.
- The inflow boundary condition will naturally create a space devoid of particles.
- Gale then creates new particles to fill that void.
- Normally, Gale looks at nearby particles and replicates them.
- However, nearby material has already changed a little from the boundary,
- so replicating them will not give the new particles the correct properties.
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-To fix that, create a thin layer next to the boundary where material is
- created anew.
- To do that, first create this shape
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="leftBoundaryShape">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Box</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startX">minX</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endX">0.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startY">minY</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endY">maxY</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startZ">minZ</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endZ">maxZ</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-and then instruct the particle splitting routine to use this shape by adding
- 
-\end_layout
-
-\begin_layout LyX-Code
-<param name="originalParticleShape">leftBoundaryShape</param>
-\end_layout
-
-\begin_layout Standard
-after
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="splittingRoutine">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">ReseedSplitting</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="idealParticleCount">particlesPerCell</param>
-\end_layout
-
-\end_deeper
-\begin_layout Standard
-A worked example is in the file 
-\family typewriter
-input/cookbook/viscous_inflow.xml
-\family default
-.
- A visualization of the strain rate invariant and velocity (see Section
- 
-\begin_inset LatexCommand \ref{sub:Visualization-with-ParaView}
-
-\end_inset
-
-) is shown in Figure 
-\begin_inset LatexCommand \ref{fig:Strain-inflow}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_viscous_inflow.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Strain-inflow}
-
-\end_inset
-
-Strain rate invariant and velocities with inflow/outflow boundaries
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-Viscous Material with Stress Boundaries
-\end_layout
-
-\begin_layout Standard
-This example demonstrates yet another boundary condition, where only the
- stress is specified at the boundary.
- In particular, this example describes a box like Figure 
-\begin_inset LatexCommand \ref{fig:Stress-Boundaries}
-
-\end_inset
-
-.
- There is a tangential stress at the bottom causing a circulation, but otherwise
- the bottom is stress-free.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\align center
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/stressbc.eps
-	width 80col%
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Stress-Boundaries}
-
-\end_inset
-
-Stress Boundaries
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Enumerate
-Copy the file 
-\family typewriter
-myviscous.xml
-\family default
- that you created in Section 
-\begin_inset LatexCommand \ref{sec:Viscous-Material}
-
-\end_inset
-
- to 
-\family typewriter
-myviscous_stressbc.xml
-\family default
-.
- 
-\end_layout
-
-\begin_layout Enumerate
-Add a 
-\family typewriter
-StressBC
-\family default
- component
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="stressBC">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StressBC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ForceVector">mom_force</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Swarm">picIntegrationPoints</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="wall">bottom</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="x_type">func</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="x_value">StepFunctionProduct1</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-and corresponding variables to the end of the file (just before 
-\family typewriter
-</StGermainData>
-\family default
-)
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct1Start">0.9</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct1End">1.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="StepFunctionProduct1Value">1.0</param>
-\end_layout
-
-\end_deeper
-\begin_layout Standard
-A worked example is in the file 
-\family typewriter
-input/cookbook/viscous_stressbc.xml
-\family default
-.
- A visualization of the strain rate invariant and velocity (see Section
- 
-\begin_inset LatexCommand \ref{sub:Visualization-with-ParaView}
-
-\end_inset
-
-) is shown in Figure 
-\begin_inset LatexCommand \ref{fig:Strain-stress}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_viscous_stressbc.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Strain-stress}
-
-\end_inset
-
-Strain rate invariant and velocities with stress boundaries
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-\begin_inset LatexCommand \label{sec:Viscous-Material-with}
-
-\end_inset
-
-Viscous Material with Initially Deformed Upper Boundary
-\end_layout
-
-\begin_layout Standard
-All of the previous examples are set up as a regular rectangular box.
- However, Gale can also start with the top initially deformed, such as if
- we had a mountain range with substantial topography.
- This example will make it sinusoidal as in Figure 
-\begin_inset LatexCommand \ref{fig:Sinusoidal-Top}
-
-\end_inset
-
-.
- This example has no moving boundaries, so the material will simply relax.
- 
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement h
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\align center
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/sinusoid.eps
-	width 80col%
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Sinusoidal-Top}
-
-\end_inset
-
-Sinusoidal Top
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Enumerate
-Copy 
-\family typewriter
-myviscous.xml
-\family default
- to 
-\family typewriter
-myviscous_sinusoid.xml
-\family default
-.
- 
-\end_layout
-
-\begin_layout Enumerate
-Add a 
-\family typewriter
-SurfaceAdaptor
-\family default
- component:
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="surfaceAdaptor">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">SurfaceAdaptor</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="sourceGenerator">linearMesh-generator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="surfaceType">sine</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="origin">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="amplitude">0.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="frequency">6.28318530718</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\end_deeper
-\begin_layout Standard
-A worked example is in 
-\family typewriter
-input/cookbook/viscous_sinusoid.xml
-\family default
-.
- A visualization of the strain rate invariant and velocity (see Section
- 
-\begin_inset LatexCommand \ref{sub:Visualization-with-ParaView}
-
-\end_inset
-
-) is shown in 
-\begin_inset LatexCommand \ref{fig:Strain-initial-deformed}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_viscous_sinusoid.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Strain-initial-deformed}
-
-\end_inset
-
-Strain rate invariant and velocities with initially deformed upper boundary
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-Multiple Viscous Materials
-\end_layout
-
-\begin_layout Standard
-All of the previous examples have only one type of viscous material.
- This example will create a simulation where there are multiple viscous
- materials such as in Figure 
-\begin_inset LatexCommand \ref{fig:Multiple-Viscous-Materials}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement h
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\align center
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/multi-material.eps
-	width 80col%
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Multiple-Viscous-Materials}
-
-\end_inset
-
-Multiple Viscous Materials
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Enumerate
-Copy 
-\family typewriter
-myviscous_extension.xml
-\family default
- (see Section 
-\begin_inset LatexCommand \ref{sec:Viscous-Material-in}
-
-\end_inset
-
-) to 
-\family typewriter
-mymulti_material.xml
-\family default
-.
- 
-\end_layout
-
-\begin_layout Enumerate
-Add the sphere.
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="sphereShape">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Sphere</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="CentreX">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="CentreY">0.15</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="radius">0.10</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-Note: If run in 3D, this is a sphere.
- The example shown here is run in 2D, so the result is a circle.
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Then add the new material.
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="sphereViscosity">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MaterialViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="eta0">10.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="sphereViscous">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">RheologyMaterial</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Shape">sphereShape</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="density">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="Rheology">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>sphereViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>storeViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Change the shape of the original material so it is not inside the sphere.
- To do this, create a new shape which is the old shape minus the sphere:
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="nonSphereShape">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Intersection</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="shapes">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>boxShape</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>!sphereShape</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Finally, modify the original viscous material to use this new 
-\family typewriter
-nonSphereShape
-\family default
- by changing the line after 
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="viscous">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">RheologyMaterial</param>
-\end_layout
-
-\begin_layout Standard
-from 
-\end_layout
-
-\begin_layout LyX-Code
-<param name="Shape">boxShape</param>
-\end_layout
-
-\begin_layout Standard
-to
-\end_layout
-
-\begin_layout LyX-Code
-<param name="Shape">nonSphereShape</param>
-\end_layout
-
-\end_deeper
-\begin_layout Standard
-A worked example is in 
-\family typewriter
-input/cookbook/multi_material.xml
-\family default
-.
- A visualization of the strain rate invariant and velocity (see Section
- 
-\begin_inset LatexCommand \ref{sub:Visualization-with-ParaView}
-
-\end_inset
-
-) is shown in Figure 
-\begin_inset LatexCommand \ref{fig:Strain-multiple}
-
-\end_inset
-
-,
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_multi_material.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Strain-multiple}
-
-\end_inset
-
-Strain rate invariant and velocities with multiple viscous materials
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-and the viscosity of the particles is shown in Figure 
-\begin_inset LatexCommand \ref{fig:Viscosities-with-multiple}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_multi_viscosity.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Viscosities-with-multiple}
-
-\end_inset
-
-Viscosities with multiple viscous materials
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-Yielding Material in Simple Extension
-\end_layout
-
-\begin_layout Standard
-This example replaces the background viscous material with a yielding material.
- This will produce localizations as some material fails.
-\end_layout
-
-\begin_layout Enumerate
-Copy 
-\family typewriter
-mymulti_material.xml
-\family default
- to 
-\family typewriter
-myyielding.xml
-\end_layout
-
-\begin_layout Enumerate
-Add a 
-\family typewriter
-StrainWeakening
-\family default
- component and a 
-\family typewriter
-MohrCoulomb
-\family default
- component
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="strainWeakening">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StrainWeakening</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="TimeIntegrator">timeIntegrator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="MaterialPointsSwarm">materialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="softeningStrain">0.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="initialDamageFraction">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="initialDamageWavenumber">0.5</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="initialDamageFactor">0.5</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="healingRate">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="yielding">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MohrCoulomb</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="PressureField">PressureField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="VelocityGradientsField">VelocityGradientsField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="MaterialPointsSwarm">materialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Context">context</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="StrainWeakening">strainWeakening</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="cohesion">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="cohesionAfterSoftening">0.0001</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="frictionCoefficient">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="frictionCoefficientAfterSoftening">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="minimumYieldStress">0.00001</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-Finally, remove the existing viscous 
-\family typewriter
-RheologyMaterial
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-<struct name="viscous">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">RheologyMaterial</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Shape">nonSphereShape</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="density">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="Rheology">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>backgroundViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>storeViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-and replace it with a yielding 
-\family typewriter
-RheologyMaterial
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="crust">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">RheologyMaterial</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Shape">nonSphereShape</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="Rheology">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>backgroundViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>yielding</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>storeViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\end_deeper
-\begin_layout Standard
-A worked example is in 
-\family typewriter
-input/cookbook/yielding.xml
-\family default
-.
- A visualization of the strain rate invariant and velocity (see Section
- 
-\begin_inset LatexCommand \ref{sub:Visualization-with-ParaView}
-
-\end_inset
-
-) is shown in Figure 
-\begin_inset LatexCommand \ref{fig:strain-yield}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_yielding.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:strain-yield}
-
-\end_inset
-
-Strain rate invariant and velocities of yielding material in extension
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-A visualization of the viscosity of the particles is shown in Figure 
-\begin_inset LatexCommand \ref{fig:Viscosity-of-yielding}
-
-\end_inset
-
-,
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_yielding_viscosity.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Viscosity-of-yielding}
-
-\end_inset
-
-Viscosity of yielding material in extension
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-and a visualization of the yielding of the particles is shown in Figure
- 
-\begin_inset LatexCommand \ref{fig:Degree-of-yielding}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Standard
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/Paraview_yielding_yielding.png
-	lyxscale 75
-	scale 75
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Degree-of-yielding}
-
-\end_inset
-
-Degree of yielding of yielding material in extension
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Chapter
-Modifying Gale
-\begin_inset LatexCommand \label{cha:Modifying-Gale}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-Introduction
-\end_layout
-
-\begin_layout Standard
-If you wish to change material properties, here is a brief overview of how
- to modify the code.
- The following is currently lacking in many areas, but will be expanded
- and refined in future releases.
- 
-\end_layout
-
-\begin_layout Section
-Software Components of Gale
-\end_layout
-
-\begin_layout Standard
-Gale makes use of several physics libraries, including StGermain, StgFEM,
- PiCellerator, and UnderWorld.
- These are proven, capable, open-source finite element method libraries
- written by the Victorian Partnership for Advanced Computing (VPAC) and
- Louis Moresi's group at Monash University (see Fig 
-\begin_inset LatexCommand \ref{fig:Mapping-between-MicroFEM}
-
-\end_inset
-
-).
- Gale also makes use of PETSc, a suite of data structures and routines for
- the parallel solution of scientific applications modeled by partial differentia
-l equations.
- 
-\end_layout
-
-\begin_layout Subsection
-StGermain 
-\end_layout
-
-\begin_layout Standard
-StGermain provides an infrastructure that can be used to create reusable,
- collaborative computational development environments.
- It aims to provide the efficiency and style of coding near that of traditional
- HPC as well as new techniques and methods in scientific computing.
- Effectively, it is the application of contemporary software engineering
- on multi-disciplinary computational research.
- In particular, StGermain can be used in the development of computational
- finite element codes.
- It permits the interchanging of numerical schemes without having to change
- the problem description or the constitutive rules utilized.
- It also allows numerical schemes and constitutive rules to be reused for
- different problems in different disciplines.
- Scientists can then switch to new computational technologies as they become
- available.
- StGermain also capitalizes on the resources invested in software development
- on a research project, rendering that software effectively reusable for
- subsequent projects.
- In turn, intellectual property, skills and adaptability of the recipients
- develop over time.
- 
-\begin_inset LatexCommand \htmlurl[StGermain Web Site]{csd.vpac.org/twiki/bin/view/Stgermain/WebHome}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-PETSc
-\end_layout
-
-\begin_layout Standard
-PETSc, the Portable, Extensible Toolkit for Scientific Computation, is a
- suite of data structures and routines for the uni- and parallel-processor
- solution of large-scale scientific application problems modeled by partial
- differential equations.
- It employs the MPI standard for all message-passing communication.
- 
-\begin_inset LatexCommand \htmlurl[PETSc Web Site]{www-unix.mcs.anl.gov/petsc/petsc-as/}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-\noindent
-\align center
-\begin_inset Float figure
-placement H
-wide false
-sideways false
-status open
-
-\begin_layout Caption
-\begin_inset LatexCommand \label{fig:Mapping-between-MicroFEM}
-
-\end_inset
-
-Mapping between MicroFEM and Gale
-\end_layout
-
-\begin_layout LyX-Code
-
-\end_layout
-
-\begin_layout Standard
-\noindent
-\align center
-\begin_inset Graphics
-	filename ../../Gale/documentation/images/GALE_imag.eps
-	lyxscale 80
-	scale 80
-
-\end_inset
-
-
-\end_layout
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-StgFEM 
-\end_layout
-
-\begin_layout Standard
-StgFEM uses the StGermain philosophy of reusability and collaborative developmen
-t to create a finite element problem composer in terms of both the linear
- system to be solved and the finite element discretization of the problem
- domain.
- The composition can be described in XML and could be represented in a network
- diagram with an appropriate tool.
- StgFEM describes finite element systems for various formulations in a manner
- that can allow the underlying numerics to be interchanged.
- 
-\begin_inset LatexCommand \htmlurl[StgFEM Web Site]{csd.vpac.org/twiki/bin/view/Stgfem/WebHome}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-PiCellerator 
-\end_layout
-
-\begin_layout Standard
-PICellerator (Particle In Cellerator), a Lagrangian Integration Point Finite
- Element framework, is implemented as an integration scheme substitute for
- the default Gaussian scheme implemented in StgFEM.
- The PICellerator concept has since grown to become a general Lagrangian
- integration scheme framework and a Lagrangian constitutive rule framework.
- The PIC scheme is provided and other Arbitrary Lagrangian Eulerian schemes
- are in development.
- Constitutive rules are reusable across these schemes.
- 
-\begin_inset LatexCommand \htmlurl[PICellerator Web Site]{csd.vpac.org/twiki/bin/view/PICellerator/WebHome}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-UnderWorld 
-\end_layout
-
-\begin_layout Standard
-UnderWorld is a StGermain parallel modeling framework Geoscience research
- code which utilizes a Lagrangian particle-in-cell finite element scheme
- (the prototype of which is the Ellipsis code), visualised using gLucifer.
- UnderWorld (Monash University), StGermain (Victorian Partnership for Advanced
- Computing or VPAC) and gLucifer (Monash University) are under development
- as part of the Australian Computational Earth Systems Simulator (ACcESS),
- an Australian Government National Research Facility, a node of which is
- located at the Australian Crustal Research Centre (ACRC) at Monash University
- (Clayton Campus).
- 
-\begin_inset LatexCommand \htmlurl[UnderWorld Web Site]{wasabi.maths.monash.edu.au/twiki/view/Software/Underworld}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-System Description
-\end_layout
-
-\begin_layout Standard
-Gale uses StgFEM to formulate implicit finite element systems, with the
- bulk of the information placed in a stiffness matrix and a force vector.
- Depending on the type of solver used, there may be several matrices and
- vectors.
- The stiffness matrix class has a member whose purpose is to assemble the
- entire matrix.
- It does this through the use of 
-\begin_inset Quotes eld
-\end_inset
-
-stiffness matrix terms.
-\begin_inset Quotes erd
-\end_inset
-
- The 
-\family typewriter
-StiffnessMatrixTerm
-\family default
- class provides an interface through which the elemental contributions to
- the matrix may be influenced.
- In typical fluid flow systems, the majority of the physics is applied to
- the model through constitutive laws which modify the stiffness matrix to
- reflect certain physical situations.
- The 
-\family typewriter
-ConstitutiveMatrix
-\family default
- class inherits from 
-\family typewriter
-StiffnessMatrixTerm
-\family default
-, providing an interface tailored to implementing material-based continuum
- physics.
- 
-\end_layout
-
-\begin_layout Standard
-So, where does the actual physics take place? The answer is in the Rheology
- class, but first look at the PIC (particle in cell) scheme.
- There are a number of benefits to using a PIC scheme, but the main use
- is to store material properties on each particle.
- These properties can then be used to drive our constitutive laws, in turn
- modifying the produced stiffness matrices.
- For each defined material in the domain, there may be a number of associated
- rheological laws.
- Whenever an element in the system is assembled, each stiffness matrix term
- is evaluated, implying that the constitutive matrix will be evaluated for
- each element.
- For each particle internal to an element, the 
-\family typewriter
-ConstitutiveMatrix
-\family default
- class will evaluate all associated rheologies, each rheology modifying
- the constitutive matrix.
- 
-\end_layout
-
-\begin_layout Standard
-Modifying the constitutive matrix takes place in the form of viscosity values.
- In this, probably the simplest of rheological laws, the 
-\family typewriter
-ModifyConstitutiveMatrix
-\family default
- method simply sets a specific viscosity value for the current element/material
- point tuple.
- 
-\end_layout
-
-\begin_layout Section
-Sample Rheologies 
-\end_layout
-
-\begin_layout Subsection
-Simple Viscous 
-\end_layout
-
-\begin_layout Standard
-This excerpt is taken from the file 
-\family typewriter
-src/Underworld/Rheology/src/MaterialViscosity.c
-\family default
-.
- It has been inherited from the Rheology class and thus possesses a virtual
- method named 
-\end_layout
-
-\begin_layout LyX-Code
-
-\family typewriter
-MaterialViscosity_ModifyConstitutiveMatrix
-\family default
- 
-\end_layout
-
-\begin_layout Standard
-which has been overridden to set the viscosity in the constitutive matrix,
- as follows: 
-\end_layout
-
-\begin_layout LyX-Code
-void _MaterialViscosity_ModifyConstitutiveMatrix( 
-\end_layout
-
-\begin_layout LyX-Code
-   void*                rheology, 
-\end_layout
-
-\begin_layout LyX-Code
-   ConstitutiveMatrix*  constitutiveMatrix, 
-\end_layout
-
-\begin_layout LyX-Code
-   MaterialPointsSwarm* swarm,
-\end_layout
-
-\begin_layout LyX-Code
-   Element_LocalIndex   lElement_I,
-\end_layout
-
-\begin_layout LyX-Code
-   MaterialPoint*       materialPoint,
-\end_layout
-
-\begin_layout LyX-Code
-   Coord                xi )
-\end_layout
-
-\begin_layout LyX-Code
-{
-\end_layout
-
-\begin_layout LyX-Code
-   MaterialViscosity* self = (MaterialViscosity*)rheology;
-\end_layout
-
-\begin_layout LyX-Code
-   ConstitutiveMatrix_SetIsotropicViscosity( constitutiveMatrix,
-\end_layout
-
-\begin_layout LyX-Code
-                                             self->eta0 );
-\end_layout
-
-\begin_layout LyX-Code
-}
-\end_layout
-
-\begin_layout Standard
-The parameters passed to this method provide access to the rheology class's
- members/methods, the constitutive matrix, the swarm (material points),
- the index of the element currently being assembled, the material point
- currently being evaluated, and the material point's elemental coordinates.
-\end_layout
-
-\begin_layout Chapter
 \start_of_appendix
-Input File Format
-\begin_inset LatexCommand \label{cha:Input-File-Format}
-
-\end_inset
-
-
+Code
 \end_layout
 
-\begin_layout Section
-Structure
-\end_layout
-
-\begin_layout Standard
-The input files are XML files.
- This leverages a well known format to specify concepts like hierarchies,
- lists, parameters, and arbitrary structures.
- The entire document is placed withing a 
-\family typewriter
-StGermainData
-\family default
- structure.
-\end_layout
-
 \begin_layout LyX-Code
-<?xml version="1.0"?>
-\end_layout
 
-\begin_layout LyX-Code
-<StGermainData xmlns="http://www.vpac.org/StGermain/XML_IO_Handler/Jun2003">
 \end_layout
 
 \begin_layout LyX-Code
-...
-\end_layout
 
-\begin_layout LyX-Code
-</StGermainData>
 \end_layout
 
-\begin_layout Standard
-Within that structure, there are five main parts of every Gale input file:
- the components, the plugins, EulerDeform, Velocity Conditions, and the
- variables.
-\end_layout
-
-\begin_layout Subsection
-Components
-\begin_inset LatexCommand \label{sub:Components}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-The components section is separated off from the rest of the file with an
- enclosing 
-\family typewriter
-components
-\family default
- structure.
- This 
-\family typewriter
-components
-\family default
- structure is where the bulk of the file will be.
- It specifies things like what the mesh will be like, which material goes
- where, what the material properties are, what kind of solver to use, etc.
- Most of the ideas you need to specify your problem will go into the components.
- When adding a new component, it is important to remember to put the new
- component inside the components structure.
- Otherwise Gale will (silently) not use that component.
- For example, an input file such as
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="components">
-\end_layout
-
-\begin_layout LyX-Code
-  <struct name="conditionFunctions">
-\end_layout
-
-\begin_layout LyX-Code
-    <param name="Type">StgFEM_StandardConditionFunctions</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </struct>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-will correctly initialize 
-\family typewriter
-StgFEM_StandardConditionFunctions
-\family default
-, but the input file
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="components">
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="conditionFunctions">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StgFEM_StandardConditionFunctions</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-will not.
-\end_layout
-
-\begin_layout Subsection
-Plugins
-\begin_inset LatexCommand \label{sub:Plugins}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-Gale also has the ability to load modules during runtime.
- To use these plugins, simply list them in a section outside of the 
-\family typewriter
-components
-\family default
- structure.
- For example, the following lines will enable the 
-\family typewriter
-DumpSwarm
-\family default
-, 
-\family typewriter
-EulerDeform
-\family default
-,and 
-\family typewriter
-VTKOutput
-\family default
- plugins
-\end_layout
-
-\begin_layout LyX-Code
-<list name="plugins">
-\end_layout
-
-\begin_layout LyX-Code
-  <param>Underworld_EulerDeform</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param>Underworld_DumpSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param>Underworld_VTKOutput</param>
-\end_layout
-
-\begin_layout LyX-Code
-</list> 
-\end_layout
-
-\begin_layout Standard
-Dynamically loading modules is, in general, difficult to get working on
- multiple platforms.
- To make things easier, Gale is bundled with a number of plugins compiled
- into the code and ready to use:
-\end_layout
-
-\begin_layout LyX-Code
-StgFEM_FrequentOutput
-\end_layout
-
-\begin_layout LyX-Code
-StgFEM_CPUTime
-\end_layout
-
-\begin_layout LyX-Code
-Underworld_MovingMesh
-\end_layout
-
-\begin_layout LyX-Code
-Underworld_Vrms
-\end_layout
-
-\begin_layout LyX-Code
-Underworld_EulerDeform
-\end_layout
-
-\begin_layout LyX-Code
-StgFEM_PrintFeVariableDiscreteValues
-\end_layout
-
-\begin_layout LyX-Code
-Underworld_DumpSwarm
-\end_layout
-
-\begin_layout LyX-Code
-Underworld_VTKOutput
-\end_layout
-
-\begin_layout Standard
-Note that you must still include those plugins in the list of plugins in
- order to use them.
- You can add additional plugins by modifying the list of static plugins
- in 
-\family typewriter
-src/Gale/src/main.c
-\family default
- and making sure that the plugin is compiled into the Gale executable.
-\end_layout
-
-\begin_layout Standard
-If you want to use dynamically loaded plugins, make sure that you compiled
- with shared libraries (use the 
-\family typewriter
---with-shared
-\family default
- option when compiling) and set your 
-\family typewriter
-LD_LIBRARY_PATH 
-\family default
-environment variable appropriately.
-\end_layout
-
-\begin_layout Subsection
-EulerDeform
-\begin_inset LatexCommand \label{sub:EulerDeform}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-The 
-\family typewriter
-Underworld_EulerDeform
-\family default
- component allows the upper surface to move freely or stay rigidly in place.
- An example 
-\family typewriter
-EulerDeform
-\family default
- struct is
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="EulerDeform">
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="systems">
-\end_layout
-
-\begin_layout LyX-Code
-    <struct>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="mesh">mesh-constant</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="remesher">pressureRemesher</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="velocityField">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <list name="fields">
-\end_layout
-
-\begin_layout LyX-Code
-        <struct> 
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="field">PressureField</param>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="variable">pressure</param>
-\end_layout
-
-\begin_layout LyX-Code
-        </struct>
-\end_layout
-
-\begin_layout LyX-Code
-      </list>
-\end_layout
-
-\begin_layout LyX-Code
-    </struct>
-\end_layout
-
-\begin_layout LyX-Code
-    <struct>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="mesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="remesher">velocityRemesher</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="velocityField">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="wrapTop">True</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <list name="fields">
-\end_layout
-
-\begin_layout LyX-Code
-        <struct>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="field">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="variable">velocity</param>
-\end_layout
-
-\begin_layout LyX-Code
-        </struct>
-\end_layout
-
-\begin_layout LyX-Code
-      </list>
-\end_layout
-
-\begin_layout LyX-Code
-    </struct>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-This tells Gale to remesh both the pressure and velocity field.
- The components 
-\family typewriter
-\size small
-pressureRemesher
-\family default
-, 
-\family typewriter
-velocityRemesher
-\family default
-, 
-\family typewriter
-pressureField
-\family default
-, 
-\family typewriter
-velocityField
-\family default
-, 
-\family typewriter
-pressure
-\family default
-\size default
-, and
-\size small
- 
-\family typewriter
-velocity
-\family default
-\size default
- all must be defined earlier (see Section 
-\begin_inset LatexCommand \ref{sub:Components}
-
-\end_inset
-
-).
- 
-\end_layout
-
-\begin_layout Standard
-Note the critical line
-\end_layout
-
-\begin_layout LyX-Code
-<param name="wrapTop">True</param>
-\end_layout
-
-\begin_layout Standard
-that tells Gale to make the top surface conform to the simulation.
- Other options (
-\family typewriter
-wrapBottom
-\family default
-, 
-\family typewriter
-wrapLeft
-\family default
-) are available, but untested.
- 
-\end_layout
-
-\begin_layout Standard
-Additionally, Gale can fix the positions of the boundaries.
- For example, if you are running a shortening model, normally Gale will
- move the boundaries inward as the simulation progresses.
- If different parts of the boundary are moving at different rates (such
- as if you were simulating one slab sliding over the other), then the side
- boundary would quickly become distorted and ruin the simulation.
- To fix the right boundary, set the variable 
-\family typewriter
-staticRight
-\family default
- to 
-\family typewriter
-True
-\end_layout
-
-\begin_layout LyX-Code
-<param name="staticRight">True</param>
-\end_layout
-
-\begin_layout Standard
-Similarly, you can independently set the left, top, bottom, front, and back
- boundaries.
-\end_layout
-
-\begin_layout Standard
-Note that you must include 
-\family typewriter
-Underworld_EulerDeform
-\family default
- in the list of plugins (see Section 
-\begin_inset LatexCommand \ref{sub:Plugins}
-
-\end_inset
-
-) in order for this section to have any effect.
-\end_layout
-
-\begin_layout Subsection
-Velocity Boundary Conditions
-\end_layout
-
-\begin_layout Standard
-This section specifies what the boundary conditions on the velocity will
- be.
- See Section 
-\begin_inset LatexCommand \ref{sub:Velocity-Boundary-Conditions}
-
-\end_inset
-
- for more details.
-\end_layout
-
-\begin_layout Subsection
-Variables
-\begin_inset LatexCommand \label{sub:Variables}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-The last section is where most of our numeric constants are placed.
- For example, how many time steps, how often to print output, etc.
- You may also declare variables for convenience (e.g., the number of grid
- points) and use it elsewhere, such as in the components.
- If you are using the basic set of components, then the more important parameter
-s are:
-\end_layout
-
-\begin_layout Description
-maxTimeSteps The number of time steps to take in the simulation.
- Each time step can cover a different amount of time.
- Gale determines how big of a step to take by dividing the grid size by
- the largest velocity during that time step.
- Unfortunately, there is no way to stop at a maximum time.
-\end_layout
-
-\begin_layout Description
-dumpEvery How often DumpSwarm dumps information to files.
-\end_layout
-
-\begin_layout Description
-checkPointEvery How often to dump every variable to files.
-\end_layout
-
-\begin_layout Description
-outputPath The directory to put output files in.
-\end_layout
-
-\begin_layout Description
-dim The number of dimensions of the problem (2 or 3).
-\end_layout
-
-\begin_layout Description
-minX,minY,minZ,maxX,maxY,maxZ The physical size of the box you are simulating.
- Note that this may be modified by 
-\family typewriter
-SurfaceAdaptor
-\family default
- (Section 
-\begin_inset LatexCommand \ref{sec:Deformed-Upper-Boundary}
-
-\end_inset
-
-).
-\end_layout
-
-\begin_layout Description
-elementResI,elementResJ,elementResK The number of elements in each direction.
- Note that the number of grid points is one larger (e.g., 64 elements -> 65
- grid points).
-\end_layout
-
-\begin_layout Description
-shadowDepth When running in parallel, every parameter only computes quantities
- over a portion of the grid.
- To do this, each processor must keep copies of points that belong to other
- processors.
- This parameter specifies how wide the region of copied points is.
- You should never need to change this from 1.
-\end_layout
-
-\begin_layout Description
-gaussParticlesX,gaussParticlesY,gaussParticlesZ The number of particles
- in each direction when putting down particles using a Gaussian distribution.
- You should never need to change this number.
-\end_layout
-
-\begin_layout Description
-particlesPerCell The ideal number of particles in each element.
- Gale will attempt to keep the number of particles in each element close
- to this number.
- You need to vary this number to gauge how sensitive the results of our
- simulation are to this number.
-\end_layout
-
-\begin_layout Section
-Basic Components
-\begin_inset LatexCommand \label{sec:Basic-Components}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-Gale is built on top of StGermain, which is a very general framework for
- scientific computation.
- Because StGermain is so general, you have to tell it fairly basic things
- that would be implicit in most codes.
- For example, you must tell StGermain that you want to set up a regular
- mesh and solve a finite element problem on it.
- This means you have to include a number of components in every input file.
- These components are
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="mesh-constant">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">FeMesh</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="elementType">constant</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="constantMesh-generator">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">C0Generator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-constant</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="elementMesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="mesh-linear">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">FeMesh</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="elementType">linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="linearMesh-generator">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">CartesianGenerator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="dim">dim</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="shadowDepth">shadowDepth</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="size">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>elementResI</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>elementResJ</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>elementResK</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="minCoord">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>minX</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>minY</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>minZ</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="maxCoord">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>maxX</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>maxY</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>maxZ</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="velocity">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MeshVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Rank">Vector</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="DataType">Double</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="VectorComponentCount">dim</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="names">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>vx</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>vy</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>vz</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="velocityBCs">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">CompositeVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Data">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="velocityICs">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">CompositeVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Data">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="velocityDofLayout">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">DofLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="BaseVariableCount">dim</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="BaseVariables">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>vx</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>vy</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>vz</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="VelocityField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">FeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FEMesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="DofLayout">velocityDofLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="BC">velocityBCs</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="IC">velocityICs</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="LinkedDofInfo">velocityLinkedDofs</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="VelocityMagnitudeField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">Magnitude</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="VelocityGradientsField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">Gradient</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="VelocityGradientsInvariantField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">TensorInvariant</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">VelocityGradientsField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="VelocityXXField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">TakeFirstComponent</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="VelocityYYField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">TakeSecondComponent</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="StrainRateField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">TensorSymmetricPart</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">VelocityGradientsField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="VorticityField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">TensorAntisymmetricPart</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">VelocityGradientsField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="StrainRateInvariantField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">SymmetricTensor_Invariant</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">StrainRateField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="StrainRateXXField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">TakeFirstComponent</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">StrainRateField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="StrainRateYYField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">OperatorFeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Operator">TakeSecondComponent</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">StrainRateField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="pressure">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MeshVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-constant</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Rank">Scalar</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="DataType">Double</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="pressureDofLayout">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">DofLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-constant</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="BaseVariables">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>pressure</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="PressureField">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">FeVariable</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FEMesh">mesh-constant</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="DofLayout">pressureDofLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="LinkedDofInfo">pressureLinkedDofs</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="cellLayout">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">SingleCellLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="particleLayout">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">GaussParticleLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="gaussSwarm">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">IntegrationPointsSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="CellLayout">cellLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ParticleLayout">particleLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeMesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="TimeIntegrator">timeIntegrator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="IntegrationPointMapper">gaussMapper</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="gaussMapper">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">GaussMapper</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="IntegrationPointsSwarm">gaussSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="MaterialPointsSwarm">gaussMaterialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="backgroundLayout">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">BackgroundParticleLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="gaussMaterialSwarm">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MaterialPointsSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="CellLayout">cellLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ParticleLayout">backgroundLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeMesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="timeIntegrator">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">TimeIntegrator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="order">1</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="simultaneous">t</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Context">context</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="elementCellLayout">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">ElementCellLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Mesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="weights">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">PCDVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="resolutionX">10</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="resolutionY">10</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="resolutionZ">10</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="lowerT">0.6</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="upperT">25</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="maxDeletions">3</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="maxSplits">3</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="MaterialPointsSwarm">materialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="localLayout">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MappedParticleLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="picIntegrationPoints">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">IntegrationPointsSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="CellLayout">elementCellLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ParticleLayout">localLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeMesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="WeightsCalculator">weights</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="TimeIntegrator">timeIntegrator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="IntegrationPointMapper">mapper</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="mapper">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">CoincidentMapper</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="IntegrationPointsSwarm">picIntegrationPoints</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="MaterialPointsSwarm">materialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="materialSwarmParticleLayout">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MeshParticleLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="cellParticleCount">particlesPerCell</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="materialSwarm">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MaterialPointsSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="CellLayout">elementCellLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ParticleLayout">materialSwarmParticleLayout</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeMesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="SplittingRoutine">splittingRoutine</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="RemovalRoutine">removalRoutine</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="EscapedRoutine">escapedRoutine</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="materialSwarmAdvector">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">SwarmAdvector</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Swarm">materialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="TimeIntegrator">timeIntegrator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="VelocityField">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="PeriodicBCsManager">periodicBCsManager</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="allowFallbackToFirstOrder">True</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="splittingRoutine">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">ReseedSplitting</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="idealParticleCount">particlesPerCell</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="solutionVelocity">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">SolutionVector</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="solutionPressure">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">SolutionVector</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">PressureField</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="mom_force">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">ForceVector</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ExtraInfo">context</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="cont_force">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">ForceVector</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="FeVariable">PressureField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ExtraInfo">context</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="k_matrix">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StiffnessMatrix</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="RowVariable">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ColumnVariable">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="RHS">mom_force</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="allowZeroElementContributions">False</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="constitutiveMatrix">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">ConstitutiveMatrixCartesian</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Swarm">picIntegrationPoints</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="StiffnessMatrix">k_matrix</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="g_matrix">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StiffnessMatrix</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="RowVariable">VelocityField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ColumnVariable">PressureField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="RHS">cont_force</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="allowZeroElementContributions">False</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="gradientStiffnessMatrixTerm">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">GradientStiffnessMatrixTerm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Swarm">gaussSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="StiffnessMatrix">g_matrix</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="preconditioner">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StiffnessMatrix</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="RowVariable">PressureField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ColumnVariable">PressureField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="RHS">cont_force</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="allowZeroElementContributions">True</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="preconditionerTerm">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">UzawaPreconditionerTerm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Swarm">picIntegrationPoints</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="StiffnessMatrix">preconditioner</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="uzawa">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Stokes_SLE_UzawaSolver</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Preconditioner">preconditioner</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="tolerance">1.0e-5</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="maxIterations">5000</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="stokesEqn">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Stokes_SLE</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="SLE_Solver">uzawa</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Context">context</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="StressTensorMatrix">k_matrix</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="GradientMatrix">g_matrix</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="DivergenceMatrix"></param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="CompressibilityMatrix">c_matrix</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="VelocityVector">solutionVelocity</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="PressureVector">solutionPressure</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ForceVector">mom_force</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ContinuityForceVector">cont_force</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="killNonConvergent">false</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="nonLinearMaxIterations">nonLinearMaxIterations</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="nonLinearTolerance">nonLinearTolerance</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="makeConvergenceFile">false</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="background">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Everywhere</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="escapedRoutine">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">EscapedRoutine</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="idealParticleCount">0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="velocityRemesher">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StripRemesher</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="meshType">regular</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="dim">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>true</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>true</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>true</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="pressureRemesher">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">CellRemesher</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-constant</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="meshType">regular</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="dim">3</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="cellMesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-
-\end_layout
-
-\begin_layout Standard
-For almost all simulations, you will not need to change these components.
-\end_layout
-
-\begin_layout Section
-Shapes
-\begin_inset LatexCommand \label{sec:Shapes}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-When setting up a simulation, Gale reads in shapes to determine what to
- put where.
- For example, you can create a simulation with different materials by creating
- different shapes and putting different materials in them.
- As a simple example, you can create a 3D box
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="simpleBox">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Box</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startX">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endX">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startY">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endY">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startZ">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endZ">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-You can perform operations on shapes to create new shapes.
- For example, if you also create a sphere
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="simpleSphere">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Sphere</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="radius">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-then you can compose it with the box to create a new shape
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="nonSphere">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Intersection</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="shapes">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>simpleBox</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>!simpleSphere</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-Note that the exclamation point ``!'' in front of 
-\family typewriter
-simpleSphere
-\family default
- means ``not.'' So 
-\family typewriter
-Intersection
-\family default
- creates a shape that is the intersection of the box and everywhere outside
- of the sphere.
- You can list an arbitrary number of shapes in 
-\family typewriter
-Intersection
-\family default
-.
- Also, you can use 
-\family typewriter
-Union
-\family default
- to create a shape that covers all of the input shapes.
-\end_layout
-
-\begin_layout Standard
-In addition, every shape accepts the translation variables 
-\family typewriter
-CentreX
-\family default
-, 
-\family typewriter
-CentreY
-\family default
-, and 
-\family typewriter
-CentreZ
-\family default
-, and the Euler angles 
-\family typewriter
-alpha
-\family default
-, 
-\family typewriter
-beta
-\family default
-, and 
-\family typewriter
-gamma
-\family default
-.
- So if you modify the Box example above to
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="simpleBox">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Box</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="CentreX">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startX">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endX">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startY">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endY">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="startZ">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="endZ">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-then the box will actually span from 1 to 2.
-\end_layout
-
-\begin_layout Standard
-The Euler angles use the 
-\begin_inset Formula $y$
-\end_inset
-
- convention, first rotating about the original 
-\begin_inset Formula $z$
-\end_inset
-
- axis an angle 
-\begin_inset Formula $\gamma$
-\end_inset
-
-, then rotating around the new 
-\begin_inset Formula $y$
-\end_inset
-
- axis an angle 
-\begin_inset Formula $\beta$
-\end_inset
-
-, and finally a rotation around the new 
-\begin_inset Formula $z$
-\end_inset
-
- axis an angle 
-\begin_inset Formula $\alpha$
-\end_inset
-
-.
- Specifically, these rotations are expressed through the rotation matrix
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-R=\left(\begin{array}{ccc}
--\sin\alpha\sin\gamma+\cos\alpha\cos\beta\cos\gamma & \sin\alpha\cos\gamma+\cos\beta\sin\gamma\cos\alpha & -\cos\alpha\sin\beta\\
--\cos\alpha\sin\gamma-\cos\beta\cos\gamma\sin\alpha & \cos\alpha\cos\gamma-\cos\beta\sin\gamma\sin\alpha & \sin\alpha\sin\beta\\
-\sin\beta\cos\alpha & \sin\beta\sin\alpha & \cos\beta\end{array}\right).\]
-
-\end_inset
-
- So when Gale is trying to figure out whether a coordinate 
-\begin_inset Formula $(x,y,z)$
-\end_inset
-
- is inside a shape, it creates a new coordinate
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-\left(\begin{array}{c}
-x'\\
-y'\\
-z'\end{array}\right)=\left(\left(\begin{array}{c}
-x\\
-y\\
-z\end{array}\right)-\left(\begin{array}{c}
-CentreX\\
-CentreY\\
-CentreZ\end{array}\right)\right)R,\]
-
-\end_inset
-
- which it uses in the formulas below.
-\end_layout
-
-\begin_layout Standard
-Finally, you may tell Gale to invert the shape with the 
-\family typewriter
-invert
-\family default
- variable, making the inside the outside and vice versa.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="8" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-CentreX
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-CentreY
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-CentreZ
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-alpha
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-beta
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-gamma
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-invert
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-False
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-BelowCosinePlane 
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-y<offset+delta*\cos\left(\frac{\pi period}{180}*x+phase\right)\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="5" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-offset
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-delta
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0.5
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-period
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-phase
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\newline
-
-\newline
-See also the notes for BelowPlane.
-\end_layout
-
-\begin_layout Subsection
-BelowPlane
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-y<offset\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-This shape also uses the variables 
-\begin_inset Formula $minX$
-\end_inset
-
-, 
-\begin_inset Formula $minY$
-\end_inset
-
-, 
-\begin_inset Formula $minZ$
-\end_inset
-
-, 
-\begin_inset Formula $maxX$
-\end_inset
-
-, 
-\begin_inset Formula $maxY$
-\end_inset
-
-, and 
-\begin_inset Formula $maxZ$
-\end_inset
-
-, which are only used when computing the volume of this shape.
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="8" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-offset
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-minX
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-minY
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-minZ
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-maxX
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-maxY
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-maxZ
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-Box
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-\begin{array}{c}
-startX<x<endX\\
-startY<y<endY\\
-startZ<z<endZ\end{array}\]
-
-\end_inset
-
-Alternately, you can use widths, in which case 
-\begin_inset Formula \[
-\begin{array}{c}
-|x|<widthX/2\\
-|y|<widthY/2\\
-|z|<widthZ/2\end{array}.\]
-
-\end_inset
-
-You may mix and match these specification (e.g., use start/end for 
-\begin_inset Formula $x$
-\end_inset
-
-, and width for 
-\begin_inset Formula $y$
-\end_inset
-
-).
- If both are specified for one coordinate, Gale will use start and end.
- 
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="4" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-widthX
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-widthY
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-widthZ
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-ConvexHull
-\end_layout
-
-\begin_layout Standard
-This shape is a convenience function for creating intersections of 
-\family typewriter
-BelowPlane
-\family default
-.
- The input is a list of vertices.
- From each vertex, Gale computes a vector and plane normal to this vector.
- The half spaces below the planes are then intersected to create a shape.
- At present, you may only use three vertices in 2D, and four vertices in
- 3D.
- As an example, the shape
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="triangleShape">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">ConvexHull</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="verticies">
-\end_layout
-
-\begin_layout LyX-Code
-    <asciidata>
-\end_layout
-
-\begin_layout LyX-Code
-      <columnDefinition name = "x" type="double"/>
-\end_layout
-
-\begin_layout LyX-Code
-      <columnDefinition name = "y" type="double"/>
-\end_layout
-
-\begin_layout LyX-Code
-                                      1.0      1.0
-\end_layout
-
-\begin_layout LyX-Code
-                                     -1.0      1.0
-\end_layout
-
-\begin_layout LyX-Code
-                                      0.0     -1.0
-\end_layout
-
-\begin_layout LyX-Code
-    </asciidata>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-creates a shape with vertices at (0,2), (4,-2), (-4,-2).
-\end_layout
-
-\begin_layout Subsection
-Cylinder
-\end_layout
-
-\begin_layout Standard
-This shape uses a variable 
-\begin_inset Formula $perpendicularAxis$
-\end_inset
-
- to determine which direction is perpendicular to the axis of the cylinder.
- This variable accepts any of (x, y, z, X, Y, Z, i, j, k, I, J, K, 0, 1,
- 2).
- For the case where 
-\begin_inset Formula $perpendicularAxis=z$
-\end_inset
-
-, then
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-\begin{array}{c}
-radius^{2}>x^{2}+y^{2}\\
-startX<x<endX\\
-startY<y<endY\\
-startZ<z<endZ\end{array}.\]
-
-\end_inset
-
- 
-\begin_inset Tabular
-<lyxtabular version="3" rows="8" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-radius
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-startX
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-\begin_inset Formula $-\infty$
-\end_inset
-
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-startY
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-\begin_inset Formula $-\infty$
-\end_inset
-
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-startZ
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-\begin_inset Formula $-\infty$
-\end_inset
-
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-endX
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-\begin_inset Formula $\infty$
-\end_inset
-
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-endY
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-\begin_inset Formula $\infty$
-\end_inset
-
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-endZ
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-\begin_inset Formula $\infty$
-\end_inset
-
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-Everywhere
-\end_layout
-
-\begin_layout Standard
-This is a convenience shape simply meaning everywhere.
-\end_layout
-
-\begin_layout Subsection
-PolygonShape
-\end_layout
-
-\begin_layout Standard
-This is primarily a two-dimensional shape.
- The input to this shape is a list of vertices.
- To figure out whether a point is inside the polygon, Gale adds up all of
- the angles of the vectors going to the vertices.
- If the point is inside the polygon, then the angles will sum to 
-\begin_inset Formula $\pm2\pi$
-\end_inset
-
-, depending on the direction you specify vertices.
- If the point is outside the polygon, then the angles sum to 0.
- A simple example is a triangle
-\end_layout
-
-\begin_layout LyX-Code
-    <struct name="triangleShape">
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="Type">PolygonShape</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <list name="verticies">
-\end_layout
-
-\begin_layout LyX-Code
-        <asciidata>
-\end_layout
-
-\begin_layout LyX-Code
-        <columnDefinition name = "x" type="double"/>
-\end_layout
-
-\begin_layout LyX-Code
-        <columnDefinition name = "y" type="double"/>
-\end_layout
-
-\begin_layout LyX-Code
-                                        0.0      0.0
-\end_layout
-
-\begin_layout LyX-Code
-                                        1.0      0.0
-\end_layout
-
-\begin_layout LyX-Code
-                                        1.0      1.0
-\end_layout
-
-\begin_layout LyX-Code
-        </asciidata>
-\end_layout
-
-\begin_layout LyX-Code
-      </list>
-\end_layout
-
-\begin_layout LyX-Code
-    </struct>
-\end_layout
-
-\begin_layout Standard
-This creates a triangle with vertices at (0,0), (1,0), (1,1).
-\end_layout
-
-\begin_layout Standard
-You can extrude this shape into three dimensions by specifying startZ and
- endZ.
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="3" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-startZ
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-endZ
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-Sphere
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-x^{2}+y^{2}+z^{2}<radius^{2}\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="2" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-radius
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-Superellipsoid
-\end_layout
-
-\begin_layout Standard
-In two dimensions
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-\left(\frac{x}{radiusX}\right)^{2/epsilon1}+\left(\frac{y}{radiusY}\right)^{2/epsilon1}<1,\]
-
-\end_inset
-
-and in three dimensions
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-\left(\left(\frac{x}{radiusX}\right)^{2/epsilon2}+\left(\frac{y}{radiusY}\right)^{2/epsilon2}\right)^{epsilon2/epsilon1}+\left(\frac{z}{radiusZ}\right)^{2/epsilon1}<1.\]
-
-\end_inset
-
-
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="6" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-radiusX
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-radiusY
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-radiusZ
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-epsilon1
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-epsilon2
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-Materials
-\begin_inset LatexCommand \label{sec:Materials}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-Gale supports two kinds of rheologies: viscous and yielding.
- You can combine these two rheologies to create a more realistic composite
- rheology.
- You then pair this composite rheology with a shape to actually lay down
- material on the grid.
- As a simple example, you can create a viscous rheology
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="viscousRheology">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">MaterialViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="eta0">10.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-and a Von Mises yielding rheology
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="strainWeakening">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StrainWeakening</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="TimeIntegrator">timeIntegrator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="MaterialPointsSwarm">materialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="softeningStrain">0.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="initialDamageFraction">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="initialDamageWavenumber">0.5</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="initialDamageFactor">0.5</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="healingRate">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\newline
-
-\newline
-<struct name="yieldingRheology">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">VonMises</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="cohesion">10.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="cohesionAfterSoftening">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-and combine them together with 
-\family typewriter
-materialShape
-\family default
- (see Section 
-\begin_inset LatexCommand \ref{sec:Shapes}
-
-\end_inset
-
- on how to create shapes)
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="yieldingMaterial">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">RheologyMaterial</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Shape">yieldingShape</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="Rheology">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>viscousRheology</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>yieldingRheology</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-To output the effective isotropic viscosity, you have to add a 
-\family typewriter
-StoreVisc
-\family default
- component
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="storeViscosity">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StoreVisc</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="MaterialPointsSwarm">materialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-and then add that to the material
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="yieldingMaterial">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">RheologyMaterial</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Shape">yieldingShape</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="Rheology">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>storeViscosity</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>viscousRheology</param>
-\end_layout
-
-\begin_layout LyX-Code
-    <param>yieldingRheology</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Subsection
-StoreVisc
-\begin_inset LatexCommand \label{sub:StoreViscosity}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-This is not a rheology per se, but rather it is an extra field where Gale
- saves the effective isotropic viscosity.
- For pure viscous materials, this will be the same as the viscosity you
- supply.
- For yielding rheologies, the effective viscosity will change as the particle
- yields.
- This component needs a 
-\family typewriter
-MaterialPointsSwarm
-\family default
-, which in all of the sample input files is called 
-\family typewriter
-materialSwarm
-\family default
-.
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="2" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-MaterialPointsSwarm
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-Viscous
-\end_layout
-
-\begin_layout Subsubsection
-MaterialViscosity
-\end_layout
-
-\begin_layout Standard
-This is the simplest rheology.
- There is only one variable, the viscosity 
-\family typewriter
-eta0
-\family default
-.
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="2" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-eta0
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsubsection
-Frank-Kamenetskii
-\end_layout
-
-\begin_layout Standard
-This is a temperature-dependent viscosity
-\begin_inset Formula \[
-eta=eta0*\exp\left(-theta*T\right).\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="3" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-eta0
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-theta
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsection
-Yielding
-\end_layout
-
-\begin_layout Standard
-Yielding rheologies are a bit more complicated.
- 
-\end_layout
-
-\begin_layout Subsubsection
-StrainWeakening
-\end_layout
-
-\begin_layout Standard
-First you need to create a 
-\family typewriter
-StrainWeakening
-\family default
- component.
- 
-\family typewriter
-StrainWeakening
-\family default
- is mainly used to define an initial distribution of strain in a material
- and to calculate the accumulated strain on each particle.
- To that end, it requires a number of parameters.
-\end_layout
-
-\begin_layout Description
-TimeIntegrator This is the component used for time integration to accumulate
- strain.
- Given the standard components in Section 
-\begin_inset LatexCommand \ref{sec:Basic-Components}
-
-\end_inset
-
-, this will be 
-\family typewriter
-timeIntegrator
-\family default
-.
-\end_layout
-
-\begin_layout Description
-MaterialPointsSwarm This is the swarm of particles that this rheology will
- tie itself to.
- Given the standard components in Section 
-\begin_inset LatexCommand \ref{sec:Basic-Components}
-
-\end_inset
-
-, this will be 
-\family typewriter
-materialSwarm
-\family default
-.
-\end_layout
-
-\begin_layout Description
-healingRate With this parameter, accumulated strain can decrease.
- Specifically, the time derivative of accumulated strain becomes
-\begin_inset Formula \[
-\frac{\sigma_{yield}}{\eta}\left(\frac{\beta}{1-\beta}-healingRate\right),\]
-
-\end_inset
-
- where 
-\begin_inset Formula $\beta\equiv\sigma_{yield}/\sigma$
-\end_inset
-
-, 
-\begin_inset Formula $\sigma_{yield}$
-\end_inset
-
- is the yield stress, 
-\begin_inset Formula $\sigma$
-\end_inset
-
- is some measure of the current stress (e.g., the second invariant of the
- stress tensor), and 
-\begin_inset Formula $\eta$
-\end_inset
-
- is the isotropic viscosity.
- Note that the healing rate should be between 0 and 1.
-\end_layout
-
-\begin_layout Description
-softeningStrain The strain at which the material has fully yielded.
-\end_layout
-
-\begin_layout Description
-initialDamageFraction The chance that an individual material particle will
- have a non-zero initial strain.
-\end_layout
-
-\begin_layout Description
-initialDamageWaveNumber The wavenumber for the initial random strain.
- To avoid having initial strain on the edges of the box, this should be
- set to the inverse of the horizontal length of the box.
-\end_layout
-
-\begin_layout Description
-initialDamageFactor The maximum initial random strain for a particle is
-\newline
-
-\family typewriter
-initialDamageFactor
-\family default
-*
-\family typewriter
-softeningStrain
-\family default
-.
- 
-\end_layout
-
-\begin_layout Description
-randomSeed A random number seed used when computing which particles are
- initially strained.
-\end_layout
-
-\begin_layout Description
-initialStrainShape If defined, the initial random strain will only occur
- within this shape (outside the shape the initial random strain will be
- zero).
-\end_layout
-
-\begin_layout Standard
-You can also define a strain weakening ratio 
-\begin_inset Formula $\alpha\equiv\min\left(1,\gamma/\gamma_{softening}\right)$
-\end_inset
-
-, where 
-\begin_inset Formula $\gamma$
-\end_inset
-
- is the accumulated strain, and 
-\begin_inset Formula $\gamma_{softening}$
-\end_inset
-
- is the softening strain.
- This allows us to define quantities like the effective cohesion 
-\begin_inset Formula $C_{effective}\equiv C_{pristine}\left(1-\alpha\right)+C_{yielded}\alpha$
-\end_inset
-
- and effective friction coefficient 
-\begin_inset Formula $\phi_{effective}=\phi_{pristine}\left(1-\alpha\right)+\phi_{yielded}\alpha$
-\end_inset
-
-.
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="10" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-TimeIntegrator
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-none
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-MaterialPointsSwarm
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-none
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-healingRate
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-softeningStrain
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-\begin_inset Formula $\infty$
-\end_inset
-
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-initialDamageFraction
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-initialDamageWaveNumber
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
--1.0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-initialDamageFactor
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-1.0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-randomSeed
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-initialStrainShape
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-none
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsubsection
-\begin_inset LatexCommand \label{sub:VonMises}
-
-\end_inset
-
-VonMises
-\end_layout
-
-\begin_layout Standard
-This is the simplest yielding rheology in Gale.
- The yielding stress is simply the effective cohesion, so this rheology
- only has a few input parameters:
-\end_layout
-
-\begin_layout Itemize
-
-\family typewriter
-cohesion
-\family default
- and 
-\family typewriter
-cohesionAfterSoftening
-\family default
- have the obvious meanings.
- 
-\end_layout
-
-\begin_layout Itemize
-
-\family typewriter
-minimumYieldStress
-\family default
- sets an absolute minimum to the stress required to make the material yield.
-\end_layout
-
-\begin_layout Itemize
-
-\family typewriter
-StrainRateSoftening
-\family default
- is a Boolean variable that changes how the constitutive matrix is modified
- when the material has yielded.
- If 
-\family typewriter
-StrainRateSoftening
-\family default
- is 
-\family typewriter
-True
-\family default
-, then the viscosity is set to 
-\begin_inset Formula \[
-\eta_{effective}=2\sigma_{yield}^{2}\eta/\left(\sigma_{yield}^{2}+I_{2}^{2}\right),\]
-
-\end_inset
-
- where 
-\begin_inset Formula $I_{2}$
-\end_inset
-
- is the second invariant of the stress tensor.
- Otherwise the viscosity is set to
-\end_layout
-
-\begin_deeper
-\begin_layout Standard
-\begin_inset Formula \[
-\eta_{effective}=\eta\sigma_{yield}/I_{2},\]
-
-\end_inset
-
- which essentially sets the stress of the particle to the yield stress.
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="5" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-cohesion
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-cohesionAfterSoftening
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-minimumYieldStress
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-StrainRateSoftening
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-False
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\end_deeper
-\begin_layout Subsubsection
-DruckerPrager
-\end_layout
-
-\begin_layout Standard
-This rheology uses the same parameters as Von Mises, but also adds a friction
- coefficient that can soften.
- Specifically, the yield stress becomes
-\begin_inset Formula \[
-\sigma_{yield}=\alpha p+C_{p},\]
-
-\end_inset
-
-where 
-\begin_inset Formula \[
-\begin{array}{ccc}
-C_{p} & = & \frac{6C_{effective}\cos\phi_{effective}}{\sqrt{3}\left(3-\sin\phi_{effective}\right)}\\
-\alpha & = & \frac{6\sin\phi_{effective}}{\sqrt{3}\left(3-\sin\phi_{effective}\right)}\end{array},\]
-
-\end_inset
-
-and 
-\begin_inset Formula $p$
-\end_inset
-
- is the pressure.
- 
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="3" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-frictionCoefficient
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-frictionCoefficientAfterSoftening
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\newline
-
-\end_layout
-
-\begin_layout Standard
-(See also 
-\begin_inset LatexCommand \ref{sub:VonMises}
-
-\end_inset
-
-.)
-\end_layout
-
-\begin_layout Subsubsection
-MohrCoulomb
-\end_layout
-
-\begin_layout Standard
-This rheology is like Drucker-Prager, but it uses the actual normal stress
- instead of inferring a normal stress from the pressure.
- More explicitly, the yield shear stress is 
-\begin_inset Formula \[
-\sigma_{yield}=\sigma_{n}\tan\phi_{effective}+C_{effective}.\]
-
-\end_inset
-
- When the material is yielding, the viscosity is modified so that the stress
- on the particle is the yield stress.
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="6" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-cohesion
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-cohesionAfterSoftening
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-frictionCoefficient
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-frictionCoefficientAfterSoftening
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-minimumYieldStress
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Subsubsection
-FaultingMoresiMulhaus2006
-\end_layout
-
-\begin_layout Standard
-This is a fairly complicated non-isotropic rheology.
- The full details can be found in Moresi and Mülhaus (2006) 
-\begin_inset LatexCommand \cite{Moresi faulting}
-
-\end_inset
-
-, but essentially it keeps track of which direction a material is strained.
- To do so, it uses a component called 
-\family typewriter
-Director
-\family default
-.
- For the standard components given in Section 
-\begin_inset LatexCommand \ref{sec:Basic-Components}
-
-\end_inset
-
-, this would be
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="director">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">Director</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="TimeIntegrator">timeIntegrator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="VelocityGradientsField">VelocityGradientsField</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="MaterialPointsSwarm">materialSwarm</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="initialDirectionX">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="initialDirectionY">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="initialDirectionZ">0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="dontUpdate">True</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-Otherwise, it adds one variable not present in 
-\family typewriter
-MohrCoulomb
-\family default
-: 
-\family typewriter
-ignoreOldOrientation
-\family default
-.
- This tells Gale whether it should check to see whether material will weaken
- further in the current direction, or if it should try every direction equally
- each time step.
-\newline
-
-\end_layout
-
-\begin_layout Standard
-\begin_inset Tabular
-<lyxtabular version="3" rows="7" columns="2">
-<features>
-<column alignment="center" valignment="top" leftline="true" width="0">
-<column alignment="center" valignment="top" leftline="true" rightline="true" width="0">
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-Defaults
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-cohesion
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-cohesionAfterSoftening
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-frictionCoefficient
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-frictionCoefficientAfterSoftening
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-minimumYieldStress
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" rightline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-0
-\end_layout
-
-\end_inset
-</cell>
-</row>
-<row topline="true" bottomline="true">
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-ignoreOldOrientation
-\end_layout
-
-\end_inset
-</cell>
-<cell alignment="center" valignment="top" topline="true" leftline="true" usebox="none">
-\begin_inset Text
-
-\begin_layout Standard
-False
-\end_layout
-
-\end_inset
-</cell>
-</row>
-</lyxtabular>
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-Boundary Conditions
-\end_layout
-
-\begin_layout Standard
-Gale's computational domain is logically Eulerian.
- So in 2D, there are four boundaries: 
-\family typewriter
-right
-\family default
-, 
-\family typewriter
-left
-\family default
-, 
-\family typewriter
-top
-\family default
-, and 
-\family typewriter
-bottom
-\family default
-.
- 3D adds 
-\family typewriter
-front
-\family default
- and 
-\family typewriter
-back
-\family default
-.
- Note that the boundaries in the 
-\begin_inset Formula $z$
-\end_inset
-
- axis are 
-\family typewriter
-front
-\family default
- and 
-\family typewriter
-back
-\family default
-, not 
-\family typewriter
-top
-\family default
- and 
-\family typewriter
-bottom
-\family default
-.
- In many cases, this makes it simple to switch between 2D and 3D.
- When doing this, you may ignore the warning that the 
-\begin_inset Formula $z$
-\end_inset
-
- boundaries are empty in 2D.
-\end_layout
-
-\begin_layout Subsection
-Velocity Boundary Conditions
-\begin_inset LatexCommand \label{sub:Velocity-Boundary-Conditions}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-To impose boundary conditions on the velocity, add a composite variable
- condition (CompositeVC) to the input file.
- Within that CompositeVC, add a list of conditions.
- Within each condition, specify which boundary and what the velocity's value
- is.
- For example, to set the 
-\begin_inset Formula $y$
-\end_inset
-
- velocity on the bottom to zero, add
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="velocityBCs">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="type">CompositeVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="vcList">
-\end_layout
-
-\begin_layout LyX-Code
-    <struct>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="type">WallVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="wall">bottom</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <list name="variables">
-\end_layout
-
-\begin_layout LyX-Code
-        <struct>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="name">vy</param>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="type">double</param>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="value">0</param>
-\end_layout
-
-\begin_layout LyX-Code
-        </struct>
-\end_layout
-
-\begin_layout LyX-Code
-      </list>
-\end_layout
-
-\begin_layout LyX-Code
-    </struct> 
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-If, instead, you set 
-\family typewriter
-vy
-\family default
- to a non-zero value, then the boundary will move as the simulation proceeds.
- If you want the sides to remain fixed, then you probably want flux boundaries,
- in which case you will also have to specify a few more things (see Section
- 
-\begin_inset LatexCommand \ref{sub:Flux-Boundary-Conditions}
-
-\end_inset
-
-).
-\end_layout
-
-\begin_layout Standard
-You can also set the velocity to a function.
- For example, to also set the 
-\begin_inset Formula $x$
-\end_inset
-
- velocity to have a Gaussian distribution 
-\begin_inset Formula $\exp\left(-\left(\frac{x-0.5}{0.1}\right)^{2}\right)$
-\end_inset
-
-
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="velocityBCs">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="type">CompositeVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="vcList">
-\end_layout
-
-\begin_layout LyX-Code
-    <struct>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="type">WallVC</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <param name="wall">bottom</param>
-\end_layout
-
-\begin_layout LyX-Code
-      <list name="variables">
-\end_layout
-
-\begin_layout LyX-Code
-        <struct>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="name">vy</param>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="type">double</param>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="value">0</param>
-\end_layout
-
-\begin_layout LyX-Code
-        </struct>
-\end_layout
-
-\begin_layout LyX-Code
-        <struct>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="name">vx</param>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="type">func</param>
-\end_layout
-
-\begin_layout LyX-Code
-          <param name="value">Gaussian</param>
-\end_layout
-
-\begin_layout LyX-Code
-        </struct>
-\end_layout
-
-\begin_layout LyX-Code
-      </list>
-\end_layout
-
-\begin_layout LyX-Code
-    </struct> 
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="GaussianHeight">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="GaussianWidth">0.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="GaussianCenter">0.5</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="GaussianDim">0</param>
-\end_layout
-
-\begin_layout Standard
-Note that the parameters are separated out into the variables section (see
- Section 
-\begin_inset LatexCommand \ref{sub:Variables}
-
-\end_inset
-
-).
- In general, you can use any of the Standard Condition Functions (see Section
- 
-\begin_inset LatexCommand \ref{sec:Standard-Condition-Functions}
-
-\end_inset
-
-) to specify the velocities.
-\end_layout
-
-\begin_layout Subsection
-Flux Boundary Conditions
-\begin_inset LatexCommand \label{sub:Flux-Boundary-Conditions}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-Sometimes, you may wish to have material flow across the boundary instead
- of having the boundary move.
- A simple example would be like Figure 
-\begin_inset LatexCommand \ref{fig:General-subduction-model}
-
-\end_inset
-
-, where material flows in from the left and out through the bottom.
- There are three things that you must specify for this to work.
-\end_layout
-
-\begin_layout Enumerate
-
-\series bold
-The boundaries do not move.
- 
-\series default
-For the slab subduction model, you need to ensure that neither the bottom
- nor left boundaries move.
- Do this by specifying
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-
-\family typewriter
-<param name="staticBottom">True</param>
-\newline
-<param name="staticLeft">True</param>
-\end_layout
-
-\begin_layout Standard
-in EulerDeform (see Section 
-\begin_inset LatexCommand \ref{sub:EulerDeform}
-
-\end_inset
-
-).
-\end_layout
-
-\end_deeper
-\begin_layout Enumerate
-
-\series bold
-Velocity conditions on the boundaries.
-
-\series default
- Again, for slab subduction this involves inflow conditions on the left
- boundary and outflow conditions on bottom.
- See Section 
-\begin_inset LatexCommand \ref{sub:Velocity-Boundary-Conditions}
-
-\end_inset
-
- for details.
- The other boundaries have no-slip conditions.
-\end_layout
-
-\begin_layout Enumerate
-
-\series bold
-A region where new particles are created, not split from existing particles.
-
-\series default
- When Gale advects material near an inflowing boundary, this leaves a vacuum.
- Normally, Gale creates new particles by cloning nearby particles.
- However, if the cloned particles have already undergone evolution (e.g.,
- they were strained), then the new particles would no longer be pristine.
- To fix this, you can specify regions where particles should be created
- anew by adding something like
-\end_layout
-
-\begin_deeper
-\begin_layout LyX-Code
-
-\family typewriter
-<param name="originalParticleShape">leftBoundaryShape</param>
-\end_layout
-
-\begin_layout Standard
-to the 
-\family typewriter
-ReseedSplitting
-\family default
- struct.
- An example of this is in the sample input file 
-\family typewriter
-subduction.xml
-\family default
-.
-\end_layout
-
-\end_deeper
-\begin_layout Subsection
-Stress Boundary Conditions
-\end_layout
-
-\begin_layout Standard
-If the nature of our problem is that stresses are specified on the boundary
- rather than velocities, you can specify those conditions using the 
-\family typewriter
-StressBC
-\family default
- component.
- For example, if you want to simulate an extension model that allows material
- to well up in the middle, then you would specify a constant stress on the
- bottom.
-\end_layout
-
-\begin_layout Standard
-StressBC is a component, so it must be inside the list of components (see
- Section 
-\begin_inset LatexCommand \ref{sub:Components}
-
-\end_inset
-
-), not outside the list like the velocity boundary conditions.
- For example, to specify the stress on the bottom boundary in the 
-\begin_inset Formula $y$
-\end_inset
-
- direction as a constant, add
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="stressBC">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StressBC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ForceVector">mom_force</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Swarm">picIntegrationPoints</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="wall">bottom</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="y_type">double</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="y_value">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-You can also use the Standard Condition Functions (see Section 
-\begin_inset LatexCommand \ref{sec:Standard-Condition-Functions}
-
-\end_inset
-
-), but due to technical issues, you must list Standard Condition Functions
- before StressBC in the list of components.
- So, for example, to add a stress condition to the left wall with a Gaussian
- shape, the complete list of components would be
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="conditionFunctions">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StgFEM_StandardConditionFunctions</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="stressBCBottom">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StressBC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ForceVector">mom_force</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Swarm">picIntegrationPoints</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="wall">bottom</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="y_type">double</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="y_value">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="stressBCLeft">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">StressBC</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="ForceVector">mom_force</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Swarm">picIntegrationPoints</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="wall">left</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="x_type">func</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="x_value">Gaussian</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout Standard
-And then in the list of variables (see Section 
-\begin_inset LatexCommand \ref{sub:Variables}
-
-\end_inset
-
-), add the parameters for the 
-\family typewriter
-Gaussian
-\family default
-:
-\end_layout
-
-\begin_layout LyX-Code
-<param name="GaussianHeight">1.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="GaussianWidth">0.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="GaussianCenter">0.5</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="GaussianDim">0</param>
-\end_layout
-
-\begin_layout Section
-Deformed Upper Boundary
-\begin_inset LatexCommand \label{sec:Deformed-Upper-Boundary}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-Normally, Gale starts the simulation in a rectangular box.
- As the simulation proceeds, the boundaries can become distorted, in particular
- the upper boundary.
- However, you can also tell Gale to start with an initially deformed upper
- boundary by adding a 
-\family typewriter
-SurfaceAdaptor
-\family default
- component.
- A simple example is to make the surface a sinusoid
-\end_layout
-
-\begin_layout LyX-Code
-<struct name="surfaceAdaptor">
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="Type">SurfaceAdaptor</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="mesh">mesh-linear</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="sourceGenerator">cartesianGenerator</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="surfaceType">cosine</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <list name="origin">
-\end_layout
-
-\begin_layout LyX-Code
-    <param>0.0</param>
-\end_layout
-
-\begin_layout LyX-Code
-  </list>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="amplitude">0.1</param>
-\end_layout
-
-\begin_layout LyX-Code
-  <param name="frequency">6.28318530718</param>
-\end_layout
-
-\begin_layout LyX-Code
-</struct>
-\end_layout
-
-\begin_layout LyX-Code
-
-\end_layout
-
-\begin_layout Standard
-This sets the height of the surface to
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-h=h_{0}+amplitude*\cos\left(x*frequency\right),\]
-
-\end_inset
-
- where 
-\begin_inset Formula $h_{0}$
-\end_inset
-
- is the original height.
-\end_layout
-
-\begin_layout Standard
-The other supported functions are 
-\family typewriter
-sine
-\family default
- and 
-\family typewriter
-wedge
-\family default
-.
- 
-\family typewriter
-sine
-\family default
- takes the same arguments as the 
-\family typewriter
-cosine
-\family default
- example above.
- 
-\family typewriter
-wedge
-\family default
- takes two arguments, 
-\family typewriter
-offset
-\family default
- and 
-\family typewriter
-gradient
-\family default
-, and sets the height to
-\end_layout
-
-\begin_layout Standard
-\begin_inset Formula \[
-h=\left\{ \begin{array}{cc}
-h_{0} & x<offset\\
-h_{0}+gradient\left(x-offset\right) & x>offset\end{array}\right..\]
-
-\end_inset
-
- If you want to implement your own surface functions, look in
-\end_layout
-
-\begin_layout LyX-Code
-
-\family typewriter
-src/StGermain/Discretisation/Mesh/src/SurfaceAdaptor.c
-\end_layout
-
-\begin_layout Section
-Standard Condition Functions
-\begin_inset LatexCommand \label{sec:Standard-Condition-Functions}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-Standard Condition Functions are functions that you can use to specify initial
- conditions and boundary conditions.
- At present, they take in a coordinate 
-\begin_inset Formula $(x,y,z)$
-\end_inset
-
- and output a function 
-\begin_inset Formula $f(x,y,z)$
-\end_inset
-
-.
- They are all defined in the directory 
-\family typewriter
-src/StgFEM/plugins/StandardConditionFunctions/
-\family default
-.
- For the following descriptions, the sides of the box are at 
-\begin_inset Formula $x_{min}$
-\end_inset
-
- and 
-\begin_inset Formula $x_{max}$
-\end_inset
-
-, and 
-\begin_inset Formula $L\equiv x_{max}-x_{min}$
-\end_inset
-
-, and all names with CamelCase capitalization are variables from the input
- file.
-\end_layout
-
-\begin_layout Description
-Velocity_SolidBodyRotation Returns the coordinates rotated by 
-\family typewriter
-SolidBodyRotationOmega
-\family default
- around the z axis, centered at the coordinate (
-\family typewriter
-SolidBodyRotationCentreX
-\family default
-, 
-\family typewriter
-SolidBodyRotationY
-\family default
-, ), out to a radius 
-\family typewriter
-RadiusCylinder
-\family default
-.
- Specifically, if 
-\begin_inset Formula $r<RadiusCylinder$
-\end_inset
-
-
-\begin_inset Formula \[
-\begin{array}{ccc}
-f(x,y,z)_{x} & = & -SolidBodyRotationOmega(y-SolidBodyRotationCentreY)\\
-f(x,y,z)_{y} & = & SolidBodyRotationOmega(x-SolidBodyRotationCentreX)\end{array},\]
-
-\end_inset
-
- otherwise return 0.
-\end_layout
-
-\begin_layout Description
-Velocity_PartialRotationX Returns the x component of Velocity_SolidBodyRotation.
-\end_layout
-
-\begin_layout Description
-Velocity_PartialRotationY Returns the y component of Velocity_SolidBodyRotation.
-\end_layout
-
-\begin_layout Description
-TaperedRotationX if 
-\begin_inset Formula $r<RadiusCylinder$
-\end_inset
-
-, return Velocity_PartialRotationX.
- If 
-\begin_inset Formula $RadiusCylinder<r<TaperedRadius$
-\end_inset
-
-, return
-\begin_inset Formula \[
-VelocityPartialRotationX\left(\frac{TaperedRadius-r}{TaperedRadius-RadiusCylinder}\right).\]
-
-\end_inset
-
- If 
-\begin_inset Formula $r>TaperedRadius$
-\end_inset
-
-, return 0.
-\end_layout
-
-\begin_layout Description
-TaperedRotationY Similar to TaperedRotationX, but returns Velocity_PartialRotati
-onY.
-\end_layout
-
-\begin_layout Description
-Velocity_SimpleShear 
-\begin_inset Formula $f(x,y,z)=SimpleShearFactor\left(y-SimpleShearCentreY\right)$
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-Velocity_Extension 
-\begin_inset Formula $f(x,y,z)=ExtensionFactor\left(x-ExtensionCentreX\right)$
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-Velocity_PartialLid_TopLayer Returns 0 if the x coordinate is within one
- grid point of the boundary; 1 otherwise.
-\end_layout
-
-\begin_layout Description
-Velocity_LinearInterpolationLid 
-\begin_inset Formula \[
-f(x,y,z)=bcLeftHandSideValue+\left(\frac{bcRightHandSideValue-bcLeftHandSideValue}{L}\right)x\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-Velocity_Lid_RampWithCentralMax 
-\begin_inset Formula $f(x,y,z)=\left\{ \begin{array}{cc}
-2\left(x-x_{min}\right)/L & x<L/2+x_{min}\\
-1-2(x-x_{min}-L/2) & x>L/2+x_{min}\end{array}\right.$
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-Velocity_SinusoidalLid 
-\begin_inset Formula \[
-f(x,y,z)=\sin\left(\frac{\pi\left(x-x_{min}\right)}{L}sinusoidalLidWavenumber\right)\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-Velocity_Lid_CornerOnly Return 1 if the coordinate is on the right boundary.
-\end_layout
-
-\begin_layout Description
-Temperature_CosineHill Returns a hill defined by a cosine.
- Specifically, if we define pre-rotated coordinates
-\begin_inset Formula \[
-\begin{array}{ccc}
-x_{pre-rotate} & = & CosineHillCentreX-SolidBodyRotationCentreX\\
-y_{pre-rotate} & = & CosineHillCentreY-SolidBodyRotationCentreY\\
-z_{pre-rotate} & = & CosineHillCentreZ-SolidBodyRotationCentreZ\end{array},\]
-
-\end_inset
-
- and then rotate them around the z axis by the angle 
-\begin_inset Formula $\theta=SolidBodyRotationOmega*t$
-\end_inset
-
-
-\begin_inset Formula \[
-\begin{array}{ccc}
-x_{hill} & = & x_{pre-rotate}\cos\theta-y_{pre-rotate}\sin\theta\\
-y_{hill} & = & x_{pre-rotate}\sin\theta+y_{pre-rotate}\cos\theta\\
-z_{hill} & = & z_{pre-rotate}\end{array},\]
-
-\end_inset
-
- then
-\begin_inset Formula \[
-f(x,y,z)=\left\{ \begin{array}{cc}
-\frac{CosineHillHeight}{4}\cos\left(\frac{2\pi r}{CosineHillDiameter}\right) & r<CosineHillDiameter\\
-0 & r>CosineHillDiameter\end{array}\right.,\]
-
-\end_inset
-
- where 
-\begin_inset Formula $r$
-\end_inset
-
- is the distance from the center of the hill
-\begin_inset Formula \[
-r\equiv\sqrt{\left(x-x_{hill}\right)^{2}+\left(y-y_{hill}\right)^{2}+\left(z-z_{hill}\right)^{2}}.\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-LinearWithSinusoidalPerturbation If you scale the 
-\begin_inset Formula $y$
-\end_inset
-
- coordinate
-\begin_inset Formula \[
-y_{scaled}=\left(y-y_{min}\right)/\left(y_{max}-y_{min}\right),\]
-
-\end_inset
-
- then this returns 
-\begin_inset Formula \[
-\begin{array}{ccc}
-f(x,y,z) & = & SinusoidalTempIC\_TopLayerBC\\
- &  & +\left(SinusoidalTempIC\_TopLayerBC-SinusoidalTempIC\_TopLayerBC\right)\left(1-y_{scaled}\right)\\
- &  & +SinusoidalTempIC\_PerturbationAmplitude\\
- &  & *\left(\cos\left(\pi x*SinusoidalTempIC\_HorizontalWaveNumber\right)\right.\\
- &  & +\left.sin\left(\pi ySinusoidalTempIC\_VerticalWaveNumber\right)\right)\end{array}.\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-Temperature_Trigonometry 
-\begin_inset Formula \[
-f(x,y,z)=1-\frac{\pi y}{2}\sin\left(\frac{\pi x}{x_{max}-x_{min}}\right).\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-VelicTemperatureIC 
-\begin_inset Formula \[
-f(x,y,z)=sigma*\cos\left(\pi wavenumberX\left(\frac{x-x_{min}}{x_{max}-x_{min}}\right)\right)\sin\left(\pi\left(y-y_{min}\right)wavenumberY\right),\]
-
-\end_inset
-
-where the height of the box is constrained to 
-\begin_inset Formula $y_{max}-y_{min}=1$
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Description
-VelicTemperatureIC_SolB 
-\begin_inset Formula \[
-f(x,y,z)=sigma*\cos\left(\pi wavenumberX\left(\frac{x-x_{min}}{x_{max}-x_{min}}\right)\right)\sinh\left(\pi wavenumberY\left(\frac{y-y_{min}}{x-x_{min}}\right)\right),\]
-
-\end_inset
-
-where the height of the box is constrained to 
-\begin_inset Formula $y_{max}-y_{min}=1$
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Description
-AnalyticalTemperatureIC First, define 
-\begin_inset Formula \[
-\begin{array}{ccc}
-x_{0} & \equiv & x-x_{min}\\
-y_{0} & \equiv & y-y_{min}\\
-L & \equiv & x_{max}-x_{min}\\
-H & \equiv & y_{max}-y_{min}\\
-\lambda & \equiv & L/H\end{array},\]
-
-\end_inset
-
-and then compute some intermediate quantities
-\begin_inset Formula \[
-\begin{array}{ccc}
-u_{0} & = & \frac{\lambda^{7/3}}{\left(1+\lambda^{4}\right)^{2/3}}\left(\frac{Ra}{2\sqrt{pi}}\right)^{2/3}\\
-v_{0} & = & u_{0}/\lambda\\
-Q & = & 2\sqrt{\lambda/\left(\pi u_{0}\right)}\\
-T_{u} & = & \frac{1}{2}erf(\left(\frac{1}{2}\left(1-y_{0}\right)\sqrt{u_{0}/x_{0}}\right)\\
-T_{l} & = & 1-\frac{1}{2}erf\left(\frac{1}{2}y_{0}\sqrt{u_{0}/\left(\lambda-x_{0}\right)}\right)\\
-T_{r} & = & \frac{1}{2}+\frac{1}{2}\left(Q/\sqrt{\pi}\right)\sqrt{v_{0}/\left(y_{0}+1\right)}\exp\left(-x_{0}^{2}v_{0}/\left(4y_{0}+4\right)\right)\\
-T_{s} & = & \frac{1}{2}-\frac{1}{2}\left(Q/\sqrt{\pi}\right)\sqrt{v_{0}/\left(2-y_{0}\right)}\exp\left(-\left(\lambda-x_{0}\right)^{2}v_{0}/\left(8-4y_{0}\right)\right)\\
-g & = & T_{u}+T_{l}+T_{r}+T_{s}-1.5\end{array}.\]
-
-\end_inset
-
- The result then is 
-\begin_inset Formula \[
-f(x,y,z)=\left\{ \begin{array}{cc}
-0 & g<0\\
-g & 0<g<1\\
-1 & g>1\end{array}\right..\]
-
-\end_inset
-
-Note that this requires the error function 
-\begin_inset Formula $erf$
-\end_inset
-
- which is not available on all platforms.
- 
-\end_layout
-
-\begin_layout Description
-SinusoidalExtension 
-\begin_inset Formula \[
-\begin{array}{ccc}
-f(x,y,z) & = & SinusoidalExtensionVelocity+SinusoidalExtensionAmplitude\\
- &  & *\cos\left(2\pi SinusoidalExtensionFrequency\left(t+dt-SinusoidalExtensionPhaseShift\right)\right)\end{array}\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-StepFunction This function returns a ramp function in the axis prescribed
- by the integer 
-\begin_inset Formula $StepFunctionDim$
-\end_inset
-
-, where 
-\begin_inset Formula $0\Rightarrow x$
-\end_inset
-
-, 
-\begin_inset Formula $1\Rightarrow y$
-\end_inset
-
-, 
-\begin_inset Formula $2\Rightarrow z$
-\end_inset
-
-.
- Defining some convenient constants 
-\begin_inset Formula \[
-\begin{array}{ccc}
-w & = & coord[dim]\\
-w_{-} & = & StepFunctionLowerOffset\\
-w_{+} & = & StepFunctionUpperOffset\\
-V & = & StepFunctionValue\end{array},\]
-
-\end_inset
-
-then if 
-\begin_inset Formula $StepFunctionLessThan$
-\end_inset
-
- is 
-\family typewriter
-True
-\family default
-, then 
-\begin_inset Formula \[
-f(x,y,z)=\left\{ \begin{array}{cc}
-0 & w<w_{-}\\
-V\left(\frac{w-w_{-}}{w_{+}-w_{-}}\right) & w_{-}<w<w_{+}\\
-V & w_{+}<w\end{array}\right.,\]
-
-\end_inset
-
- otherwise it is reversed
-\begin_inset Formula \[
-f(x,y,z)=\left\{ \begin{array}{cc}
-V & w<w_{-}\\
-V\left(\frac{w_{+}-w}{w_{+}-w_{-}}\right) & w_{-}<w<w_{+}\\
-0 & w_{+}<w\end{array}\right.,\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-StepFunctionProduct1 Using a similar scheme as StepFunction to specify the
- dimension with 
-\newline
-
-\begin_inset Formula $StepFunctionProduct1Dim$
-\end_inset
-
-, 
-\begin_inset Formula \[
-f(x,y,z)=\left\{ \begin{array}{cc}
-0 & w<StepFunctionProduct1Start\\
-StepFunctionProduct1Value & StepFunctionProduct1Start<w<StepFunctionProduct1End\\
-0 & w>StepFunctionProduct1End\end{array}\right.\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Description
-StepFunctionProduct2 
-\end_layout
-
-\begin_layout Description
-StepFunctionProduct3
-\end_layout
-
-\begin_layout Description
-StepFunctionProduct4 These are the same as StepFunctionProduct1 except that
- they use different variables (e.g., 
-\begin_inset Formula $StepFunctionProduct2Dim$
-\end_inset
-
- instead of 
-\begin_inset Formula $StepFunctionProduct1Dim$
-\end_inset
-
-).
-\end_layout
-
-\begin_layout Description
-Gaussian 
-\begin_inset Formula \[
-f(x,y,z)=\left(GaussianHeight\right)\exp\left[-\left(\frac{GaussianCenter-coord[dim]}{GaussianWidth}\right)^{2}\right]\]
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Section
-Verbosity Options
-\end_layout
-
-\begin_layout Standard
-By default, Gale prints out very little when running.
- To get more information, insert
-\end_layout
-
-\begin_layout LyX-Code
-<param name="journal.info">True</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="journal.debug">True</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="journal-level.info">2</param>
-\end_layout
-
-\begin_layout LyX-Code
-<param name="journal-level.debug">2</param>
-\end_layout
-
-\begin_layout Standard
-into the variables section (see Section 
-\begin_inset LatexCommand \ref{sub:Variables}
-
-\end_inset
-
-).
- This will print out more information than you need about the components,
- the solvers, and the number of iterations.
- In addition, you can get even more information about the solvers from PETSc
- by appending the 
-\begin_inset Quotes sld
-\end_inset
-
-
-\family typewriter
--ksp_monitor
-\family default
-
-\begin_inset Quotes srd
-\end_inset
-
- to the command line.
-\end_layout
-
 \begin_layout Chapter
-Output File Format
-\begin_inset LatexCommand \label{cha:Output-File-Format}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-Gale outputs four types of files.
- 
-\end_layout
-
-\begin_layout Section
-
-\family typewriter
-.dat
-\family default
- ASCII Files
-\end_layout
-
-\begin_layout Standard
-The first type are ASCII files with 
-\family typewriter
-.dat
-\family default
- extensions.
- Inside each 
-\family typewriter
-.dat
-\family default
- file are several columns of data.
- For example, 
-\family typewriter
-PressureField.00001.dat
-\family default
- might have
-\end_layout
-
-\begin_layout LyX-Code
-
-\family typewriter
-0 0.0312539624080715 0.0109361134145122 0 -9.81467103200287
-\end_layout
-
-\begin_layout LyX-Code
-
-\family typewriter
-1 0.0937630718938361 0.0109356986189374 0 17.7373201951569
-\end_layout
-
-\begin_layout LyX-Code
-
-\family typewriter
-2 0.156270066350344 0.0109368543031399 0 -37.0281780188199
-\end_layout
-
-\begin_layout LyX-Code
-
-\family typewriter
-3 0.218780947570009 0.0109343376815161 0 45.6263762140766
-\end_layout
-
-\begin_layout LyX-Code
-
-\family typewriter
-4 0.28128858838265 0.010937987088561 0 -65.2132484518426 
-\end_layout
-
-\begin_layout LyX-Code
-...
-\end_layout
-
-\begin_layout Standard
-The first column (0,1,2,3, ...) is the node number, and the second, third,
- and fourth columns are the x, y, and z coordinates (2D runs still have
- z data that can be ignored).
- The last column(s) show the value.
- The five different types of variables and the order of components is
-\end_layout
-
-\begin_layout Description
-Scalar Value
-\end_layout
-
-\begin_layout Description
-Vector 2D: x y
-\newline
-3D: x, y, z
-\end_layout
-
-\begin_layout Description
-Tensor 2D: xx, xy, yx, yy
-\newline
-3D: xx, xy, xz, yx, yy, yz, zx, zy, zz
-\end_layout
-
-\begin_layout Description
-Symmetric\InsetSpace ~
-Tensor 2D: xx, yy, xy
-\newline
-3D: xx, yy, zz, xy, xz, yz
-\end_layout
-
-\begin_layout Description
-AntiSymmetric\InsetSpace ~
-Tensor 2D: xx, xy, yx, yy
-\newline
-3D: xx, xy, xz, yx, yy, yz, zx, zy,
- zz (note that xx, yy, and zz are identical to zero)
-\end_layout
-
-\begin_layout Standard
-The complete list of output files per time step with the default components
- (see Section 
-\begin_inset LatexCommand \ref{sec:Basic-Components}
-
-\end_inset
-
-) is
-\end_layout
-
-\begin_layout Description
-Scalar Pressure, StrainRateInvariant, VelocityMagnitude, VelocityGradientsInvari
-ant
-\end_layout
-
-\begin_layout Description
-Vector Velocity
-\end_layout
-
-\begin_layout Description
-Tensor VelocityGradients
-\end_layout
-
-\begin_layout Description
-Symmetric\InsetSpace ~
-Tensor StrainRate
-\end_layout
-
-\begin_layout Description
-Antisymmetric\InsetSpace ~
-Tensor Vorticity
-\end_layout
-
-\begin_layout Standard
-There will also be a timeInfo file, which records the start time and dt
- for that time step, and materialSwarm which is described in Section 
-\begin_inset LatexCommand \ref{sec:.dat-Binary-Files}
-
-\end_inset
-
-.
- Finally, there will be 
-\family typewriter
-.txt
-\family default
- files from 
-\family typewriter
-DumpSwarm
-\family default
-, explained below in Section 
-\begin_inset LatexCommand \ref{sec:.txt-Files-(Particle}
-
-\end_inset
-
-.
-\end_layout
-
-\begin_layout Section
-
-\family typewriter
-.dat 
-\family default
-Binary Files (Particle Information) 
-\begin_inset LatexCommand \label{sec:.dat-Binary-Files}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-These are the 
-\family typewriter
-materialSwarm.*.dat
-\family default
- files.
- They are only useful for checkpointing and have a machine dependent format.
-\end_layout
-
-\begin_layout Section
-
-\family typewriter
-.txt
-\family default
- Files (Particle Information)
-\begin_inset LatexCommand \label{sec:.txt-Files-(Particle}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-These files are output by the 
-\family typewriter
-Underworld_DumpSwarm
-\family default
- plugin.
- They provide particle information in a more friendly format.
- The 
-\family typewriter
-Underworld_DumpSwarm
-\family default
- plugin is activated by adding the line
-\end_layout
-
-\begin_layout LyX-Code
-    <param>Underworld_DumpSwarm</param> 
-\end_layout
-
-\begin_layout Standard
-to the list of plugins.
- This line is already in the example input files.
- The default is to output the ASCII files 
-\family typewriter
-yielding.*.txt
-\family default
-.
- The format of the file is
-\end_layout
-
-\begin_layout LyX-Code
-m x y z
-\family typewriter
- yielded viscosity
-\end_layout
-
-\begin_layout Standard
-where 
-\family typewriter
-m
-\family default
- is a unique number for the material, 
-\family typewriter
-yielded
-\family default
- is a number between 
-\family typewriter
-0
-\family default
- and 
-\family typewriter
-1
-\family default
- indicating how much a material point has failed, and 
-\family typewriter
-viscosity
-\family default
- is material's isotropic viscosity.
- If the material does not yield (e.g.
- is purely viscous), then yielded is always zero.
- 
-\end_layout
-
-\begin_layout Standard
-You can also output in csv format for easily reading the data into a spreadsheet
- like Excel.
- To do this, just set the variable 
-\family typewriter
-outputFormat
-\family default
- in the global list of variables
-\end_layout
-
-\begin_layout LyX-Code
-<param name="outputFormat">csv</param>
-\end_layout
-
-\begin_layout Standard
-If you want to print out some other property of the material, e.g., non-isotropic
- viscosity, modify 
-\family typewriter
-DumpSwarm
-\family default
- to provide that information.
- The source for the plugin is found in the directory
-\end_layout
-
-\begin_layout LyX-Code
-src/Underworld/plugins/Output/DumpSwarm/
-\end_layout
-
-\begin_layout Section
-
-\family typewriter
-.vtk
-\family default
- Files (Visualization)
-\begin_inset LatexCommand \label{sec:.vtk-Files-(Visualization)}
-
-\end_inset
-
-
-\end_layout
-
-\begin_layout Standard
-These files are output by the 
-\family typewriter
-Underworld_VTKOutput
-\family default
- plugin.
- These files are in a format understood by a wide variety of visualization
- programs, sich as 
-\begin_inset LatexCommand \htmlurl[ParaView]{paraview.org}
-
-\end_inset
-
- (recommended), 
-\begin_inset LatexCommand \htmlurl[MayaVi]{mayavi.sf.net}
-
-\end_inset
-
-, or 
-\begin_inset LatexCommand \htmlurl[Visit]{www.llnl.gov/visit}
-
-\end_inset
-
-.
- The 
-\family typewriter
-Underworld_VTKOutput
-\family default
- plugin is activated by adding the line
-\end_layout
-
-\begin_layout LyX-Code
-    <param>Underworld_VTKOutput</param> 
-\end_layout
-
-\begin_layout Standard
-to the list of plugins.
- This line is already in the example input files.
-\end_layout
-
-\begin_layout Chapter
 Benchmarks
 \end_layout
 
@@ -11977,120 +944,9 @@
 
 \begin_layout Bibliography
 
-\bibitem {Fullsack}
-Fullsack, Phillipe (1995).
- An arbitrary Lagrangian-Eulerian formulation for creeping flows and its
- application in tectonic models, 
-\emph on
-Geophys.
- J.
- Int., 120
-\emph default
-, 1-23.
-\end_layout
+\bibitem {key-10}
 
-\begin_layout Bibliography
-
-\bibitem {VPAC}
-Quenette, S., B.
- Appelbe, M.
- Gurnis, L.
- Hodkinson, L.
- Moresi, and P.
- Sunter (2005), An Investigation into Design for Performance and Code Maintainab
-ility in High Performance Computing, 
-\emph on
-ANZIAM J
-\emph default
-.
-\emph on
-, 46(e),
-\emph default
- C1001-C1016.
 \end_layout
 
-\begin_layout Bibliography
-
-\bibitem {Underworld}
-Moresi, L.N., F.
- Dufour, and H.-B.
- Mühlhaus (2003), A Lagrangian integration point finite element method for
- large deformation modeling of viscoelastic geomaterials, 
-\emph on
-J.
- Comp.
- Phys., 184
-\series bold
-,
-\series default
-\emph default
- 476-497.
-\end_layout
-
-\begin_layout Bibliography
-
-\bibitem {Moresi faulting}
-Moresi, L.N., and H.-B.
- Mühlhaus (2006), Anisotropic viscous models of large-deformation MohrCoulomb
- failure, 
-\emph on
-Philosophical Magazine, 86,
-\emph default
- 3287-3305.
-\end_layout
-
-\begin_layout Bibliography
-
-\bibitem {Uzawa}
- Moresi, L.N., and V.S.
- Solomatov (1995), Numerical investigation of 2D convection with extremely
- large viscosity variations, 
-\emph on
-Phys.
- Fluids,
-\emph default
- 
-\emph on
-7(9),
-\emph default
- 2154-2162.
-\end_layout
-
-\begin_layout Bibliography
-
-\bibitem {Ellipsis}
-O'Neill, C., Moresi, L., Müller, D., Albert, R., Dufour, F.
- (2006), Ellipsis 3D: a particle-in-cell finite element hybrid code for
- modelling mantle convection and lithospheric deformation, 
-\shape italic
-Computers & Geosciences
-\shape default
-, 
-\shape italic
-32(10)
-\shape default
-, 1769-1779
-\end_layout
-
-\begin_layout Bibliography
-
-\bibitem {Citcom}
-Zhong, S., M.T.
- Zuber, L.N.
- Moresi, and M.
- Gurnis (2000), The role of temperature-dependent viscosity and surface
- plates in spherical shell models of mantle convection, 
-\shape italic
-J.
- Geophys.
- Res.
-\shape default
-, 
-\shape italic
-105
-\shape default
-, 11, 063-11, 082 
-\end_layout
-
 \end_body
 \end_document



More information about the cig-commits mailing list