[cig-commits] r12469 - short/3D/PyLith/trunk/examples/3d/hex8

willic3 at geodynamics.org willic3 at geodynamics.org
Thu Jul 24 06:17:41 PDT 2008


Author: willic3
Date: 2008-07-24 06:17:38 -0700 (Thu, 24 Jul 2008)
New Revision: 12469

Added:
   short/3D/PyLith/trunk/examples/3d/hex8/gravity_istress.cfg
   short/3D/PyLith/trunk/examples/3d/hex8/initial_state.spatialdb
Log:
Example problem to test the use of prestresses in conjunction with gravity.
The problem appears to run correctly, yielding zero strains as it should,
but the output stresses are incorrect.  There appears to be some problem
with getting the correct initial state values when computing stresses for
output.  All of the stresses for each material type are constant, rather
than varying with depth as they should.



Added: short/3D/PyLith/trunk/examples/3d/hex8/gravity_istress.cfg
===================================================================
--- short/3D/PyLith/trunk/examples/3d/hex8/gravity_istress.cfg	                        (rev 0)
+++ short/3D/PyLith/trunk/examples/3d/hex8/gravity_istress.cfg	2008-07-24 13:17:38 UTC (rev 12469)
@@ -0,0 +1,104 @@
+# -*- Python -*-
+[pylithapp]
+
+
+# This is not a self-contained simulation configuration file. This
+# file only specifies parameters specific to the boundary
+# conditions. The general parameters are specificed in the pylithapp.cfg
+# file which PyLith reads by default.
+#
+# To run the simulation:
+# pylith gravity_istress.cfg
+
+# ----------------------------------------------------------------------
+# problem
+# ----------------------------------------------------------------------
+[pylithapp.timedependent]
+# Set bc to an array of 5 boundary conditions: 'x_pos','x_neg', 'y_pos',
+# 'y_neg', and 'z_neg'.
+bc = [x_pos,x_neg,y_pos,y_neg,z_neg]
+
+# Use gravity for this problem.
+use_gravity = true
+
+[pylithapp.timedependent.implicit]
+# Set the output to an array of 2 output managers.
+# We will output the solution over the domain and the ground surface.
+output = [domain,subdomain]
+
+# Set subdomain component to OutputSolnSubset (subset of domain).
+output.subdomain = pylith.meshio.OutputSolnSubset
+
+# ----------------------------------------------------------------------
+# initial stresses
+# ----------------------------------------------------------------------
+[pylithapp.timedependent.materials.elastic]
+use_initial_state = True
+initial_state_db.iohandler.filename = initial_state.spatialdb
+# initial_state_db.query_type = linear
+
+[pylithapp.timedependent.materials.viscoelastic]
+use_initial_state = True
+initial_state_db.iohandler.filename = initial_state.spatialdb
+# initial_state_db.query_type = linear
+
+# ----------------------------------------------------------------------
+# boundary conditions
+# ----------------------------------------------------------------------
+# Use the default FixedDOFDB, which has a uniform spatial distribution.
+
+# Set the parameters for Dirichlet boundary conditions applied on the
+# +x, -x, +y, -y, and -z faces of the box. Note that we only use a subset of the
+# boundary conditions provided in the 6 BC container.
+
+# We fix the x degree of freedom on the +x and -x faces, the y degree of
+# freedom on the +y and -y faces, and the z degree of freedom on the
+# bottom face.
+
+# The label corresponds to the nodeset ID in CUBIT.
+
+[pylithapp.timedependent.bc.x_pos]
+fixed_dof = [0]
+label = 11
+db.label = Dirichlet BC on +x
+
+[pylithapp.timedependent.bc.x_neg]
+fixed_dof = [0]
+label = 12
+db.label = Dirichlet BC on -x
+
+[pylithapp.timedependent.bc.y_pos]
+fixed_dof = [1]
+label = 13
+db.label = Dirichlet BC on +y
+
+[pylithapp.timedependent.bc.y_neg]
+fixed_dof = [1]
+label = 14
+db.label = Dirichlet BC on -y
+
+[pylithapp.timedependent.bc.z_neg]
+fixed_dof = [2]
+label = 15
+db.label = Dirichlet BC on -z
+
+# ----------------------------------------------------------------------
+# output
+# ----------------------------------------------------------------------
+# Give basename for VTK domain output of solution over domain.
+[pylithapp.problem.formulation.output.domain.writer]
+filename = gravity_istress.vtk
+
+# Give basename for VTK domain output of solution over ground surface.
+[pylithapp.problem.formulation.output.subdomain]
+label = 17 ; nodeset for subdomain
+writer.filename = gravity_istress-groundsurf.vtk
+
+# Give basename for VTK output of state variables.
+[pylithapp.timedependent.materials.elastic.output]
+cell_filter = pylith.meshio.CellFilterAvg
+writer.filename = gravity_istress-statevars-elastic.vtk
+
+[pylithapp.timedependent.materials.viscoelastic.output]
+cell_filter = pylith.meshio.CellFilterAvg
+writer.filename = gravity_istress-statevars-viscoelastic.vtk

Added: short/3D/PyLith/trunk/examples/3d/hex8/initial_state.spatialdb
===================================================================
--- short/3D/PyLith/trunk/examples/3d/hex8/initial_state.spatialdb	                        (rev 0)
+++ short/3D/PyLith/trunk/examples/3d/hex8/initial_state.spatialdb	2008-07-24 13:17:38 UTC (rev 12469)
@@ -0,0 +1,29 @@
+// -*- C++ -*- (tell Emacs to use C++ mode for syntax highlighting)
+//
+// This spatial database specifies the initial stresses for the model
+// The stresses increase linearly with depth.
+//
+#SPATIAL.ascii 1
+SimpleDB {
+  num-values = 6 // number of stress components
+  value-names =  stress_xx stress_yy stress_zz stress_xy stress_yz stress_xz // names of the stress components
+  value-units =  Pa Pa Pa Pa Pa Pa // units (conversions not supported)
+  num-locs = 4 // number of locations
+  data-dim = 1
+  space-dim = 3
+  cs-data = cartesian {
+    to-meters = 1.0
+    space-dim = 3
+  }
+}
+// Columns are
+// (1) x coordinate (m)
+// (2) y coordinate (m)
+// (3) z coordinate (m)
+// (4) density (kg/m^3)
+// (5) vs (m/s)
+// (6) vp (m/s)
+0.0  0.0 -3500.0 -3.064578125e+07 -3.064578125e+07 -8.58081875e+07 0.0 0.0 0.0
+0.0  0.0 -2500.0 -2.188984375e+07 -2.188984375e+07 -6.12915625e+07 0.0 0.0 0.0
+0.0  0.0 -1500.0 -1.313390625e+07 -1.313390625e+07 -3.67749375e+07 0.0 0.0 0.0
+0.0  0.0  -500.0 -4.37796875e+06 -4.37796875e+06 -1.22583125e+07 0.0 0.0 0.0



More information about the cig-commits mailing list