[cig-commits] r7368 -
short/3D/PyLith/trunk/examples/twocells/twotri3
willic3 at geodynamics.org
willic3 at geodynamics.org
Thu Jun 21 20:48:19 PDT 2007
Author: willic3
Date: 2007-06-21 20:48:19 -0700 (Thu, 21 Jun 2007)
New Revision: 7368
Added:
short/3D/PyLith/trunk/examples/twocells/twotri3/sheardisp.cfg
short/3D/PyLith/trunk/examples/twocells/twotri3/shearxy.spatialdb
Modified:
short/3D/PyLith/trunk/examples/twocells/twotri3/axialdisp.spatialdb
short/3D/PyLith/trunk/examples/twocells/twotri3/twotri3.mesh
Log:
More work on examples.
Changed mesh to align with coordinate axes.
Added initial verions of files for shear problem (not tested yet).
Modified: short/3D/PyLith/trunk/examples/twocells/twotri3/axialdisp.spatialdb
===================================================================
--- short/3D/PyLith/trunk/examples/twocells/twotri3/axialdisp.spatialdb 2007-06-22 01:02:53 UTC (rev 7367)
+++ short/3D/PyLith/trunk/examples/twocells/twotri3/axialdisp.spatialdb 2007-06-22 03:48:19 UTC (rev 7368)
@@ -11,5 +11,5 @@
space-dim = 2
}
}
--1.0 0.0 -0.1 0.0
- 1.0 0.0 0.1 0.0
+-0.5 -0.5 -0.01 -0.01
+ 0.5 0.5 0.01 0.01
Added: short/3D/PyLith/trunk/examples/twocells/twotri3/sheardisp.cfg
===================================================================
--- short/3D/PyLith/trunk/examples/twocells/twotri3/sheardisp.cfg 2007-06-22 01:02:53 UTC (rev 7367)
+++ short/3D/PyLith/trunk/examples/twocells/twotri3/sheardisp.cfg 2007-06-22 03:48:19 UTC (rev 7368)
@@ -0,0 +1,75 @@
+# -*- Python -*-
+
+# The settings in this file (sheardisp.cfg) will be read if it is
+# specified on the command line:
+# 'pylith sheardisp.cfg'
+
+# If this file is given, the settings in this file will override all
+# others except for parameters specified directly on the command line.
+
+# These setting define an implicit problem with Dirichlet (displacement)
+# boundary conditions that shear the mesh.
+[pylithapp]
+
+# ----------------------------------------------------------------------
+# mesh_generator
+# ----------------------------------------------------------------------
+[pylithapp.mesh_generator]
+debug = 1
+importer = pylith.meshio.MeshIOCubit
+
+[pylithapp.mesh_generator.importer]
+filename = box.exo
+coordsys.space_dim = 2
+
+# ----------------------------------------------------------------------
+# problem
+# ----------------------------------------------------------------------
+[pylithapp.timedependent]
+total_time = 0.0*s
+default_dt = 1.0*s
+dimension = 2
+formulation = pylith.problems.Implicit
+bc = pylith.bc.BCFourSides
+
+# ----------------------------------------------------------------------
+# materials
+# ----------------------------------------------------------------------
+[pylithapp.timedependent.materials]
+material = pylith.materials.ElasticPlaneStrain
+
+[pylithapp.timedependent.materials.material]
+label = elastic material
+id = 1
+db.iohandler.filename = matprops.spatialdb
+quadrature = pylith.feassemble.quadrature.Quadrature2D
+quadrature.cell.shape = triangle
+
+# ----------------------------------------------------------------------
+# boundary conditions
+# ----------------------------------------------------------------------
+[pylithapp.timedependent.bc.x_neg]
+fixed_dof = [0, 1]
+id = 10
+label = 10
+db.label = Dirichlet BC -x edge
+db.iohandler.filename = shearxy.spatialdb
+
+[pylithapp.timedependent.bc.x_pos]
+fixed_dof = [0, 1]
+id = 11
+label = 11
+db.label = Dirichlet BC +x edge
+db.iohandler.filename = shearxy.spatialdb
+
+# ----------------------------------------------------------------------
+# PETSc
+# ----------------------------------------------------------------------
+[pylithapp.petsc]
+pc_type = jacobi
+
+# ----------------------------------------------------------------------
+# output
+# ----------------------------------------------------------------------
+[pylithapp.problem.formulation.output.output]
+filename = shearplanestrain.vtk
Added: short/3D/PyLith/trunk/examples/twocells/twotri3/shearxy.spatialdb
===================================================================
--- short/3D/PyLith/trunk/examples/twocells/twotri3/shearxy.spatialdb 2007-06-22 01:02:53 UTC (rev 7367)
+++ short/3D/PyLith/trunk/examples/twocells/twotri3/shearxy.spatialdb 2007-06-22 03:48:19 UTC (rev 7368)
@@ -0,0 +1,15 @@
+#SPATIAL.ascii 1
+SimpleDB {
+ num-values = 2
+ value-names = dof-0 dof-1
+ value-units = m m
+ num-locs = 2
+ data-dim = 1
+ space-dim = 2
+ cs-data = cartesian {
+ to-meters = 1.0
+ space-dim = 2
+ }
+}
+-0.5 0.0 0.0 -0.01
++0.5 0.0 0.0 +0.01
Modified: short/3D/PyLith/trunk/examples/twocells/twotri3/twotri3.mesh
===================================================================
--- short/3D/PyLith/trunk/examples/twocells/twotri3/twotri3.mesh 2007-06-22 01:02:53 UTC (rev 7367)
+++ short/3D/PyLith/trunk/examples/twocells/twotri3/twotri3.mesh 2007-06-22 03:48:19 UTC (rev 7368)
@@ -1,6 +1,5 @@
// Global mesh object.
-// This mesh defines a square domain with the corners lying along the
-// x and y axes.
+// This defines a square mesh with unit edge lengths.
mesh = {
// This is a two-dimensional mesh.
@@ -15,12 +14,14 @@
// There are 4 vertices.
count = 4
- // List node number (starting from 0), x-coord, and y-coord.
+ // List the coordinates as:
+ // Vertex number (starting from zero), x-coord, y-coord
+ // Use coordinate units that are consistent with the other units used.
coordinates = {
- 0 -1.0 0.0
- 1 0.0 1.0
- 2 0.0 -1.0
- 3 1.0 0.0
+ 0 -0.5 -0.5
+ 1 0.5 -0.5
+ 2 -0.5 0.5
+ 3 0.5 0.5
}
}
@@ -33,26 +34,33 @@
// There are 2 cells
count = 2
- // List cell number, and then vertices moving counter-clockwise around the cell.
+ // List the vertices composing each cell,
+ // moving counter-clockwise around the cell.
+ // List the information as:
+ // Cell number (starting from zero), vertex 0, vertex 1, vertex 2
simplices = {
- 0 0 2 1
- 1 1 2 3
+ 0 0 1 2
+ 1 1 3 2
}
- // List the material ID's associated with each cell (both have an ID of 1).
+ // List the material ID's associated with each cell.
+ // Different ID's may be used to specify a different material type, or
+ // to use a different spatial database for each material ID.
+ // In this example, cells 0 and 1 both are associated with material ID 1.
material-ids = {
0 1
1 1
}
}
+ // Here we list different groups (cells or vertices) that we want to associate
+ // with a particular name (ID).
// This group of vertices may be used to define a fault.
+ // There are 2 vertices corresponding to indices 1 and 2.
group = {
type = vertices
name = fault
-
- // There are 2 vertices corresponding to indices 1 and 2.
count = 2
indices = {
1
@@ -61,14 +69,37 @@
}
// This group of vertices may be used to specify boundary conditions.
+ // There are 2 vertices corresponding to indices 0 and 3.
group = {
type = vertices
name = end points
+ count = 2
+ indices = {
+ 0
+ 3
+ }
+ }
- // There are 2 vertices corresponding to indices 0 and 3.
+ // This group of vertices may be used to specify boundary conditions.
+ // There are 2 vertices corresponding to indices 0 and 2.
+ group = {
+ type = vertices
+ name = x_neg
count = 2
indices = {
0
+ 2
+ }
+ }
+
+ // This group of vertices may be used to specify boundary conditions.
+ // There are 2 vertices corresponding to indices 1 and 3.
+ group = {
+ type = vertices
+ name = x_pos
+ count = 2
+ indices = {
+ 1
3
}
}
More information about the cig-commits
mailing list