[cig-commits] r7281 - short/3D/PyLith/trunk/tests/3d/hex8

brad at geodynamics.org brad at geodynamics.org
Sun Jun 17 23:00:27 PDT 2007


Author: brad
Date: 2007-06-17 23:00:27 -0700 (Sun, 17 Jun 2007)
New Revision: 7281

Added:
   short/3D/PyLith/trunk/tests/3d/hex8/TestShearPlaneStrain.py
   short/3D/PyLith/trunk/tests/3d/hex8/shearplanestrain.cfg
Log:
Added shear plane strain test.

Added: short/3D/PyLith/trunk/tests/3d/hex8/TestShearPlaneStrain.py
===================================================================
--- short/3D/PyLith/trunk/tests/3d/hex8/TestShearPlaneStrain.py	2007-06-18 00:28:00 UTC (rev 7280)
+++ short/3D/PyLith/trunk/tests/3d/hex8/TestShearPlaneStrain.py	2007-06-18 06:00:27 UTC (rev 7281)
@@ -0,0 +1,54 @@
+#!/usr/bin/env python
+#
+# ----------------------------------------------------------------------
+#
+#                           Brad T. Aagaard
+#                        U.S. Geological Survey
+#
+# <LicenseText>
+#
+# ----------------------------------------------------------------------
+#
+
+## @file tests/3d/tet4/TestShearPlaneStrain.py
+##
+## @brief Test suite for testing pylith with shear in y-direction for
+## 3-D box.
+
+import unittest
+import numpy
+import tables
+
+def run_pylith():
+  """
+  Run pylith.
+  """
+  if not "done" in dir(run_pylith):
+    from pylith.PyLithApp import PyLithApp
+    app = PyLithApp("shearelasticisotropic")
+    app.run()
+    run_pylith.done = True
+  return
+
+
+class TestShearPlaneStrain(unittest.TestCase):
+  """
+  Test suite for testing pylith with shear in y-direction for 3-D box.
+  """
+
+  def setUp(self):
+    """
+    Setup for test.
+    """
+    run_pylith()
+    return
+
+
+  def test_disp(self):
+    """
+    Check displacement field.
+    """
+    return
+
+
+# End of file 

Added: short/3D/PyLith/trunk/tests/3d/hex8/shearplanestrain.cfg
===================================================================
--- short/3D/PyLith/trunk/tests/3d/hex8/shearplanestrain.cfg	2007-06-18 00:28:00 UTC (rev 7280)
+++ short/3D/PyLith/trunk/tests/3d/hex8/shearplanestrain.cfg	2007-06-18 06:00:27 UTC (rev 7281)
@@ -0,0 +1,91 @@
+# -*- Python -*-
+[pylithapp]
+
+# ----------------------------------------------------------------------
+# journal
+# ----------------------------------------------------------------------
+[pylithapp.journal.info]
+timedependent = 1
+explicit = 1
+implicit = 1
+petsc = 1
+solverlinear = 1
+meshioascii = 1
+homogeneous = 1
+implicitelasticity = 1
+quadrature3d = 1
+fiatsimplex = 1
+
+# ----------------------------------------------------------------------
+# mesh_generator
+# ----------------------------------------------------------------------
+[pylithapp.mesh_generator]
+debug = 1
+importer = pylith.meshio.MeshIOCubit
+
+[pylithapp.mesh_generator.importer]
+filename = box.exo
+coordsys.space_dim = 3
+
+# ----------------------------------------------------------------------
+# problem
+# ----------------------------------------------------------------------
+[pylithapp.timedependent]
+total_time = 0.0*s
+default_dt = 1.0*s
+dimension = 3
+formulation = pylith.problems.Implicit
+bc = pylith.bc.BCSixSides
+
+# ----------------------------------------------------------------------
+# materials
+# ----------------------------------------------------------------------
+[pylithapp.timedependent.materials]
+material = pylith.materials.ElasticIsotropic3D
+
+[pylithapp.timedependent.materials.material]
+label = elastic material
+id = 1
+db.iohandler.filename = matprops.spatialdb
+quadrature = pylith.feassemble.quadrature.Quadrature3D
+quadrature.cell = pylith.feassemble.FIATLagrange
+quadrature.cell.dimension = 3
+
+# ----------------------------------------------------------------------
+# boundary conditions
+# ----------------------------------------------------------------------
+[pylithapp.timedependent.bc.x_neg]
+fixed_dof = [0, 1]
+label = 3
+db.label = Dirichlet BC -x edge
+db.iohandler.filename = shearxyz.spatialdb
+
+[pylithapp.timedependent.bc.x_pos]
+fixed_dof = [0, 1]
+label = 4
+db.label = Dirichlet BC +x edge
+db.iohandler.filename = shearxyz.spatialdb
+
+[pylithapp.timedependent.bc.z_neg]
+fixed_dof = [2]
+label = 1
+db.label = Dirichlet BC -z edge
+db.iohandler.filename = shearxyz.spatialdb
+
+[pylithapp.timedependent.bc.z_pos]
+fixed_dof = [2]
+label = 2
+db.label = Dirichlet BC +z edge
+db.iohandler.filename = shearxyz.spatialdb
+
+# ----------------------------------------------------------------------
+# PETSc
+# ----------------------------------------------------------------------
+[pylithapp.petsc]
+pc_type = jacobi
+
+# ----------------------------------------------------------------------
+# output
+# ----------------------------------------------------------------------
+[pylithapp.problem.formulation.output.output]
+filename = shearplanestrain.vtk



More information about the cig-commits mailing list