[cig-commits] r7214 - in short/3D/PyLith/trunk: . libsrc/faults libsrc/feassemble modulesrc/faults modulesrc/feassemble modulesrc/utils pylith/faults pylith/feassemble pylith/problems unittests/libtests/faults unittests/libtests/faults/data unittests/libtests/feassemble unittests/pytests/faults unittests/pytests/feassemble

brad at geodynamics.org brad at geodynamics.org
Wed Jun 13 13:26:24 PDT 2007


Author: brad
Date: 2007-06-13 13:26:23 -0700 (Wed, 13 Jun 2007)
New Revision: 7214

Modified:
   short/3D/PyLith/trunk/TODO
   short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveDyn.cc
   short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveDyn.hh
   short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveKin.cc
   short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveKin.hh
   short/3D/PyLith/trunk/libsrc/feassemble/ElasticityExplicit.cc
   short/3D/PyLith/trunk/libsrc/feassemble/ElasticityExplicit.hh
   short/3D/PyLith/trunk/libsrc/feassemble/ElasticityImplicit.cc
   short/3D/PyLith/trunk/libsrc/feassemble/ElasticityImplicit.hh
   short/3D/PyLith/trunk/libsrc/feassemble/Integrator.cc
   short/3D/PyLith/trunk/libsrc/feassemble/Integrator.hh
   short/3D/PyLith/trunk/modulesrc/faults/faults.pyxe.src
   short/3D/PyLith/trunk/modulesrc/feassemble/feassemble.pyxe.src
   short/3D/PyLith/trunk/modulesrc/utils/petsc.pyxe.src
   short/3D/PyLith/trunk/pylith/faults/FaultCohesiveKin.py
   short/3D/PyLith/trunk/pylith/feassemble/Integrator.py
   short/3D/PyLith/trunk/pylith/problems/Explicit.py
   short/3D/PyLith/trunk/pylith/problems/Formulation.py
   short/3D/PyLith/trunk/pylith/problems/Implicit.py
   short/3D/PyLith/trunk/pylith/problems/TimeDependent.py
   short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKin.cc
   short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKin.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinHex8.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinLine2.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinQuad4.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinTet4.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinTri3.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinData.cc
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinData.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataHex8.cc
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataHex8.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataLine2.cc
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataLine2.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataQuad4.cc
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataQuad4.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTet4.cc
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTet4.hh
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTri3.cc
   short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTri3.hh
   short/3D/PyLith/trunk/unittests/libtests/feassemble/TestElasticityExplicit.cc
   short/3D/PyLith/trunk/unittests/libtests/feassemble/TestElasticityImplicit.cc
   short/3D/PyLith/trunk/unittests/pytests/faults/TestFaultCohesiveKin.py
   short/3D/PyLith/trunk/unittests/pytests/feassemble/TestElasticityExplicit.py
   short/3D/PyLith/trunk/unittests/pytests/feassemble/TestElasticityImplicit.py
Log:
Fixed fault implementation. Kinematic formulation with Lagrange multiplier constraints are implemented using integrator interface (don't need to be constraints). Added time as an argument to Integrator integrateResidual(), integrateJacobian(), and updateState(). Propagated changes through source code and unit tests. Faults work for 1-D test problem.

Modified: short/3D/PyLith/trunk/TODO
===================================================================
--- short/3D/PyLith/trunk/TODO	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/TODO	2007-06-13 20:26:23 UTC (rev 7214)
@@ -10,23 +10,6 @@
 
   dislocation.cfg
 
-1. Simple tests with analytical solutions
-
-   a. 2-D
-     i. tri3 cells
-       (1) axial compression
-       (2) shear
-     ii. quad4 cells
-       (1) axial compression
-       (2) shear
-   b. 3-D
-     i. tet4 cells
-       (1) axial compression
-       (2) shear
-     ii. hex8 cells
-       (1) axial compression
-       (2) shear
-
 5. Additional unit tests
   b. ElasticityExplicit and ElasticityImplicit
     i. multiple materials
@@ -34,6 +17,7 @@
 
   a. FaultCohesive
     i. Add checking of faultMesh [not currently used]
+    ii. Tests for cases with multiple cohesive cells
 
 examples/templates
   containers

Modified: short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveDyn.cc
===================================================================
--- short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveDyn.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveDyn.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -49,6 +49,7 @@
 void
 pylith::faults::FaultCohesiveDyn::integrateResidual(
 				const ALE::Obj<real_section_type>& residual,
+				const double t,
 				topology::FieldsManager* const fields,
 				const ALE::Obj<Mesh>& mesh)
 { // integrateResidual
@@ -60,6 +61,7 @@
 void
 pylith::faults::FaultCohesiveDyn::integrateJacobian(
 				    PetscMat* mat,
+				    const double t,
 				    topology::FieldsManager* const fields,
 				    const ALE::Obj<Mesh>& mesh)
 { // integrateJacobian

Modified: short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveDyn.hh
===================================================================
--- short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveDyn.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveDyn.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -67,20 +67,24 @@
   /** Integrate contribution of cohesive cells to residual term.
    *
    * @param residual Residual field (output)
+   * @param t Current time
    * @param fields Solution fields
    * @param mesh Finite-element mesh
    */
   void integrateResidual(const ALE::Obj<real_section_type>& residual,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh);
 
   /** Compute Jacobian matrix (A) associated with operator.
    *
    * @param mat Sparse matrix
+   * @param t Current time
    * @param fields Solution fields
    * @param mesh Finite-element mesh
    */
   void integrateJacobian(PetscMat* mat,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh);
   

Modified: short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveKin.cc
===================================================================
--- short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveKin.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveKin.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -233,6 +233,7 @@
 void
 pylith::faults::FaultCohesiveKin::integrateResidual(
 				const ALE::Obj<real_section_type>& residual,
+				const double t,
 				topology::FieldsManager* const fields,
 				const ALE::Obj<Mesh>& mesh)
 { // integrateResidual
@@ -240,56 +241,22 @@
   assert(0 != fields);
   assert(!mesh.isNull());
 
-  // Subtract constraint forces (which are disp at the constraint DOF)
-  // to residual; contributions are at DOF of non-constraint vertices
-  // (i and j) of the cohesive cells
+  // Set slip values in residual vector; contributions are at DOF of
+  // constraint vertices (k) of the cohesive cells
 
-  // Get cohesive cells
-  const ALE::Obj<ALE::Mesh::label_sequence>& cellsCohesive = 
-    mesh->getLabelStratum("material-id", id());
-  assert(!cellsCohesive.isNull());
-  const Mesh::label_sequence::iterator cellsCohesiveBegin =
-    cellsCohesive->begin();
-  const Mesh::label_sequence::iterator cellsCohesiveEnd =
-    cellsCohesive->end();
+  typedef std::set<Mesh::point_type>::const_iterator vert_iterator;
 
-  // Get section information
-  const ALE::Obj<real_section_type>& disp = fields->getSolution();
-  assert(!disp.isNull());  
+  assert(0 != _eqsrc);
+  const ALE::Obj<real_section_type>& slip = _eqsrc->slip(t, _constraintVert);
+  assert(!slip.isNull());
+  const vert_iterator vBegin = _constraintVert.begin();
+  const vert_iterator vEnd = _constraintVert.end();
   
-  // Allocate vector for cell values
-  const int spaceDim = _quadrature->spaceDim();
-  const int numConstraintVert = _quadrature->numBasis();
-  const int numCorners = 3*numConstraintVert; // cohesive cell
-  double_array cellVector(numCorners*spaceDim);
-
-  // Loop over cohesive cells
-  for (Mesh::label_sequence::iterator c_iter=cellsCohesiveBegin;
-       c_iter != cellsCohesiveEnd;
-       ++c_iter) {
-    cellVector = 0.0;
-
-    // Get values at vertices (want constraint forces in disp vector)
-    const real_section_type::value_type* cellDisp = 
-      mesh->restrict(disp, *c_iter);
-
-    // Transfer constraint forces to cell's constribution to residual vector
-    for (int iConstraint=0; iConstraint < numConstraintVert; ++iConstraint)
-      for (int iDim=0; iDim < spaceDim; ++iDim) {
-	const int indexI = iConstraint;
-	const int indexJ = iConstraint +   numConstraintVert;
-	const int indexK = iConstraint + 2*numConstraintVert;
-	const double constraintForce = cellDisp[indexK*spaceDim+iDim];
-      cellVector[indexI*spaceDim+iDim] = -constraintForce;
-      cellVector[indexJ*spaceDim+iDim] = +constraintForce;
-    } // for
-    PetscErrorCode err = 
-      PetscLogFlops(numConstraintVert*2);
-    if (err)
-      throw std::runtime_error("Logging PETSc flops failed.");
-
-    // Update residual (replace, do not add)
-    mesh->update(residual, *c_iter, &cellVector[0]);
+  for (vert_iterator v_iter=vBegin; v_iter != vEnd; ++v_iter) {
+    const int fiberDim = slip->getFiberDimension(*v_iter);
+    const real_section_type::value_type* values = slip->restrictPoint(*v_iter);
+    assert(fiberDim == residual->getFiberDimension(*v_iter));
+    residual->updatePoint(*v_iter, values);
   } // for
 } // integrateResidual
 
@@ -298,6 +265,7 @@
 void
 pylith::faults::FaultCohesiveKin::integrateJacobian(
 				    PetscMat* mat,
+				    const double t,
 				    topology::FieldsManager* const fields,
 				    const ALE::Obj<Mesh>& mesh)
 { // integrateJacobian
@@ -394,53 +362,5 @@
   _needNewJacobian = false;
 } // integrateJacobian
   
-// ----------------------------------------------------------------------
-// Set number of degrees of freedom that are constrained at points
-void
-pylith::faults::FaultCohesiveKin::setConstraintSizes(
-				    const ALE::Obj<real_section_type>& field,
-				    const ALE::Obj<ALE::Mesh>& mesh)
-{ // setConstraintSizes
-  /* No DOF are eliminated from the system of equations with the 
-   * Lagrange multiplier formulation
-   */
-} // setConstraintSizes
 
-// ----------------------------------------------------------------------
-// Set which degrees of freedom are constrained at points in field.
-void
-pylith::faults::FaultCohesiveKin::setConstraints(
-				     const ALE::Obj<real_section_type>& field,
-				     const ALE::Obj<ALE::Mesh>& mesh)
-{ // setConstraints
-  /* No DOF are eliminated from the system of equations with the 
-   * Lagrange multiplier formulation
-   */
-} // setConstraints
-
-// ----------------------------------------------------------------------
-// Set field.
-void
-pylith::faults::FaultCohesiveKin::setField(
-				     const double t,
-				     const ALE::Obj<real_section_type>& disp,
-				     const ALE::Obj<Mesh>& mesh)
-{ // setField
-  typedef std::set<Mesh::point_type>::const_iterator vert_iterator;
-
-  assert(0 != _eqsrc);
-  const ALE::Obj<real_section_type>& slip = _eqsrc->slip(t, _constraintVert);
-  assert(!slip.isNull());
-  const vert_iterator vBegin = _constraintVert.begin();
-  const vert_iterator vEnd = _constraintVert.end();
-  
-  for (vert_iterator v_iter=vBegin; v_iter != vEnd; ++v_iter) {
-    const int fiberDim = slip->getFiberDimension(*v_iter);
-    const real_section_type::value_type* values = slip->restrictPoint(*v_iter);
-    assert(fiberDim == disp->getFiberDimension(*v_iter));
-    disp->updatePoint(*v_iter, values);
-  } // for
-} // setField
-
-
 // End of file 

Modified: short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveKin.hh
===================================================================
--- short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveKin.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/faults/FaultCohesiveKin.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -30,7 +30,6 @@
 #define pylith_faults_faultcohesivekin_hh
 
 #include "FaultCohesive.hh" // ISA FaultCohesive
-#include "pylith/feassemble/Constraint.hh" // ISA Constraint
 #include "pylith/feassemble/Integrator.hh" // ISA Integrator
 
 /// Namespace for pylith package
@@ -46,8 +45,7 @@
 /// C++ implementation for a fault surface with kinematic (prescribed)
 /// slip implemented with cohesive elements.
 class pylith::faults::FaultCohesiveKin : public FaultCohesive,
-					 public feassemble::Integrator,
-					 public feassemble::Constraint
+					 public feassemble::Integrator
 { // class FaultCohesiveKin
   friend class TestFaultCohesiveKin; // unit testing
 
@@ -83,10 +81,12 @@
   /** Integrate contributions to residual term (r) for operator.
    *
    * @param residual Field containing values for residual
+   * @param t Current time
    * @param fields Solution fields
    * @param mesh Finite-element mesh
    */
   void integrateResidual(const ALE::Obj<real_section_type>& residual,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh);
 
@@ -94,40 +94,15 @@
    * operator.
    *
    * @param mat Sparse matrix
+   * @param t Current time
    * @param fields Solution fields
    * @param mesh Finite-element mesh
    */
   void integrateJacobian(PetscMat* mat,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh);
 
-  /** Set number of degrees of freedom that are constrained at points
-   * in field.
-   *
-   * @param field Solution field
-   * @param mesh PETSc mesh
-   */
-  void setConstraintSizes(const ALE::Obj<real_section_type>& field,
-			  const ALE::Obj<ALE::Mesh>& mesh);
-
-  /** Set which degrees of freedom are constrained at points in field.
-   *
-   * @param field Solution field
-   * @param mesh PETSc mesh
-   */
-  void setConstraints(const ALE::Obj<real_section_type>& field,
-		      const ALE::Obj<ALE::Mesh>& mesh);
-
-  /** Set field.
-   *
-   * @param t Current time.
-   * @param disp Displacement field at time t.
-   * @param mesh Finite-element mesh.
-   */
-  void setField(const double t,
-		const ALE::Obj<real_section_type>& disp,
-		const ALE::Obj<Mesh>& mesh);
-  
   // PROTECTED METHODS //////////////////////////////////////////////////
 protected :
 

Modified: short/3D/PyLith/trunk/libsrc/feassemble/ElasticityExplicit.cc
===================================================================
--- short/3D/PyLith/trunk/libsrc/feassemble/ElasticityExplicit.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/feassemble/ElasticityExplicit.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -83,6 +83,7 @@
 void
 pylith::feassemble::ElasticityExplicit::integrateResidual(
 			      const ALE::Obj<real_section_type>& residual,
+			      const double t,
 			      topology::FieldsManager* const fields,
 			      const ALE::Obj<Mesh>& mesh)
 { // integrateResidual
@@ -297,6 +298,7 @@
 void
 pylith::feassemble::ElasticityExplicit::integrateJacobian(
 					PetscMat* jacobian,
+					const double t,
 					topology::FieldsManager* fields,
 					const ALE::Obj<Mesh>& mesh)
 { // integrateJacobian
@@ -392,6 +394,7 @@
 // Update state variables as needed.
 void
 pylith::feassemble::ElasticityExplicit::updateState(
+				   const double t,
 				   const ALE::Obj<real_section_type>& disp,
 				   const ALE::Obj<Mesh>& mesh)
 { // updateState

Modified: short/3D/PyLith/trunk/libsrc/feassemble/ElasticityExplicit.hh
===================================================================
--- short/3D/PyLith/trunk/libsrc/feassemble/ElasticityExplicit.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/feassemble/ElasticityExplicit.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -111,10 +111,12 @@
   /** Integrate contributions to residual term (r) for operator.
    *
    * @param residual Field containing values for residual
+   * @param t Current time
    * @param fields Solution fields
    * @param mesh Finite-element mesh
    */
   void integrateResidual(const ALE::Obj<real_section_type>& residual,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh);
 
@@ -122,19 +124,23 @@
    * operator.
    *
    * @param jacobian Sparse matrix to hold Jacobian of operator.
+   * @param t Current time
    * @param fields Solution fields.
    * @param mesh Finite-element mesh.
    */
   void integrateJacobian(PetscMat* jacobian,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh);
 
   /** Update state variables as needed.
    *
+   * @param t Current time
    * @param field Current solution field.
    * @param mesh Finite-element mesh
    */
-  void updateState(const ALE::Obj<real_section_type>& field,
+  void updateState(const double t,
+		   const ALE::Obj<real_section_type>& field,
 		   const ALE::Obj<Mesh>& mesh);
 
 // PRIVATE METHODS //////////////////////////////////////////////////////

Modified: short/3D/PyLith/trunk/libsrc/feassemble/ElasticityImplicit.cc
===================================================================
--- short/3D/PyLith/trunk/libsrc/feassemble/ElasticityImplicit.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/feassemble/ElasticityImplicit.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -83,6 +83,7 @@
 void
 pylith::feassemble::ElasticityImplicit::integrateResidual(
 			      const ALE::Obj<real_section_type>& residual,
+			      const double t,
 			      topology::FieldsManager* const fields,
 			      const ALE::Obj<Mesh>& mesh)
 { // integrateResidual
@@ -284,6 +285,7 @@
 void
 pylith::feassemble::ElasticityImplicit::integrateJacobian(
 					PetscMat* mat,
+					const double t,
 					topology::FieldsManager* fields,
 					const ALE::Obj<Mesh>& mesh)
 { // integrateJacobian
@@ -567,6 +569,7 @@
 // Update state variables as needed.
 void
 pylith::feassemble::ElasticityImplicit::updateState(
+				   const double t,
 				   const ALE::Obj<real_section_type>& disp,
 				   const ALE::Obj<Mesh>& mesh)
 { // updateState

Modified: short/3D/PyLith/trunk/libsrc/feassemble/ElasticityImplicit.hh
===================================================================
--- short/3D/PyLith/trunk/libsrc/feassemble/ElasticityImplicit.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/feassemble/ElasticityImplicit.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -104,36 +104,42 @@
    * Includes gravity and element internal force contribution.
    *
    * We assume that the effects of boundary conditions are already
-   * included in b (tractions, concentrated nodal forces, and
-   * contributions to internal force vector due to
+   * included in the residual (tractions, concentrated nodal forces,
+   * and contributions to internal force vector due to
    * displacement/velocity BC).  This routine computes the additional
    * external loads due to body forces (not yet implemented) plus the
    * element internal forces for the current stress state.
    *
-   * @param b Residual field (output)
+   * @param residual Residual field (output)
+   * @param t Current time
    * @param fields Solution fields
    * @param mesh Mesh object
    */
-  void integrateResidual(const ALE::Obj<real_section_type>& b,
+  void integrateResidual(const ALE::Obj<real_section_type>& residual,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh);
 
   /** Compute Jacobian matrix (A) associated with operator.
    *
    * @param mat Sparse matrix
+   * @param t Current time
    * @param fields Solution fields
    * @param mesh Mesh object
    */
   void integrateJacobian(PetscMat* mat,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh);
   
   /** Update state variables as needed.
    *
+   * @param t Current time
    * @param field Current solution field.
    * @param mesh Finite-element mesh
    */
-  void updateState(const ALE::Obj<real_section_type>& field,
+  void updateState(const double t,
+		   const ALE::Obj<real_section_type>& field,
 		   const ALE::Obj<Mesh>& mesh);
   
 // PRIVATE METHODS //////////////////////////////////////////////////////

Modified: short/3D/PyLith/trunk/libsrc/feassemble/Integrator.cc
===================================================================
--- short/3D/PyLith/trunk/libsrc/feassemble/Integrator.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/feassemble/Integrator.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -80,6 +80,7 @@
 // Update state variables as needed.
 void
 pylith::feassemble::Integrator::updateState(
+				     const double t,
 				     const ALE::Obj<real_section_type>& field,
 				     const ALE::Obj<Mesh>& mesh)
 { // updateState

Modified: short/3D/PyLith/trunk/libsrc/feassemble/Integrator.hh
===================================================================
--- short/3D/PyLith/trunk/libsrc/feassemble/Integrator.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/libsrc/feassemble/Integrator.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -87,11 +87,13 @@
   /** Integrate contributions to residual term (r) for operator.
    *
    * @param residual Field containing values for residual
+   * @param t Current time
    * @param fields Solution fields
    * @param mesh Finite-element mesh
    */
   virtual 
   void integrateResidual(const ALE::Obj<real_section_type>& residual,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh) = 0;
 
@@ -99,21 +101,25 @@
    * operator.
    *
    * @param mat Sparse matrix
+   * @param t Current time
    * @param fields Solution fields
    * @param mesh Finite-element mesh
    */
   virtual 
   void integrateJacobian(PetscMat* mat,
+			 const double t,
 			 topology::FieldsManager* const fields,
 			 const ALE::Obj<Mesh>& mesh) = 0;
 
   /** Update state variables as needed.
    *
+   * @param t Current time
    * @param field Current solution field.
    * @param mesh Finite-element mesh
    */
   virtual
-  void updateState(const ALE::Obj<real_section_type>& field,
+  void updateState(const double t,
+		   const ALE::Obj<real_section_type>& field,
 		   const ALE::Obj<Mesh>& mesh);
 
 // PROTECTED METHODS ////////////////////////////////////////////////////

Modified: short/3D/PyLith/trunk/modulesrc/faults/faults.pyxe.src
===================================================================
--- short/3D/PyLith/trunk/modulesrc/faults/faults.pyxe.src	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/modulesrc/faults/faults.pyxe.src	2007-06-13 20:26:23 UTC (rev 7214)
@@ -273,12 +273,12 @@
     return
 
 
-  def integrateResidual(self, residual, fields, mesh):
+  def integrateResidual(self, residual, t, fields, mesh):
     """
     Integrate contributions to residual term (r) for operator.
     """
     # create shim for method 'integrateResidual'
-    #embed{ void FaultCohesiveKin_integrateResidual(void* objVptr, void* residualVptr, void* fieldsVptr, void* meshVptr)
+    #embed{ void FaultCohesiveKin_integrateResidual(void* objVptr, void* residualVptr, double t, void* fieldsVptr, void* meshVptr)
     try {
       assert(0 != objVptr);
       assert(0 != residualVptr);
@@ -291,7 +291,7 @@
       pylith::topology::FieldsManager* fields =
         (pylith::topology::FieldsManager*) fieldsVptr;
       ((pylith::faults::FaultCohesiveKin*) objVptr)->integrateResidual(*residual,
-                                                              fields, *mesh);
+                                                              t, fields, *mesh);
     } catch (const std::exception& err) {
       PyErr_SetString(PyExc_RuntimeError,
                       const_cast<char*>(err.what()));
@@ -307,18 +307,19 @@
       raise TypeError, \
             "Argument must be extension module type 'Mesh'."
     FaultCohesiveKin_integrateResidual(self.thisptr, 
-                                 PyCObject_AsVoidPtr(residual),
-                                 ptrFromHandle(fields),
-                                 ptrFromHandle(mesh))
+                                       PyCObject_AsVoidPtr(residual),
+                                       t,
+                                       ptrFromHandle(fields),
+                                       ptrFromHandle(mesh))
     return
 
 
-  def integrateJacobian(self, mat, fields, mesh):
+  def integrateJacobian(self, mat, t, fields, mesh):
     """
     Compute contributions to Jacobian matrix (A) associated with operator.
     """
     # create shim for method 'integrateJacobian'
-    #embed{ void FaultCohesiveKin_integrateJacobian(void* objVptr, void* matVptr, void* fieldsVptr, void* meshVptr)
+    #embed{ void FaultCohesiveKin_integrateJacobian(void* objVptr, void* matVptr, double t, void* fieldsVptr, void* meshVptr)
     try {
       assert(0 != objVptr);
       assert(0 != matVptr);
@@ -330,7 +331,7 @@
       pylith::topology::FieldsManager* fields =
         (pylith::topology::FieldsManager*) fieldsVptr;
       ((pylith::faults::FaultCohesiveKin*) objVptr)->integrateJacobian(
-                                                        mat, fields, *mesh);
+                                                        mat, t, fields, *mesh);
     } catch (const std::exception& err) {
       PyErr_SetString(PyExc_RuntimeError,
                       const_cast<char*>(err.what()));
@@ -346,18 +347,19 @@
       raise TypeError, \
             "Argument 'mesh' must be extension module type 'Mesh'."
     FaultCohesiveKin_integrateJacobian(self.thisptr,
-                                 PyCObject_AsVoidPtr(mat),
-                                 ptrFromHandle(fields),
-                                 ptrFromHandle(mesh))
+                                       PyCObject_AsVoidPtr(mat),
+                                       t, 
+                                       ptrFromHandle(fields),
+                                       ptrFromHandle(mesh))
     return
 
 
-  def updateState(self, field, mesh):
+  def updateState(self, t, field, mesh):
     """
     Update state variables as needed.
     """
     # create shim for method 'updateState'
-    #embed{ void FaultCohesiveKin_updateState(void* objVptr, void* fieldVptr, void* meshVptr)
+    #embed{ void FaultCohesiveKin_updateState(void* objVptr, double t, void* fieldVptr, void* meshVptr)
     try {
       assert(0 != objVptr);
       assert(0 != fieldVptr);
@@ -366,7 +368,7 @@
         (ALE::Obj<pylith::real_section_type>*) fieldVptr;
       ALE::Obj<ALE::Mesh>* mesh =
         (ALE::Obj<ALE::Mesh>*) meshVptr;
-      ((pylith::faults::FaultCohesiveKin*) objVptr)->updateState(*field, *mesh);
+      ((pylith::faults::FaultCohesiveKin*) objVptr)->updateState(t, *field, *mesh);
     } catch (const std::exception& err) {
       PyErr_SetString(PyExc_RuntimeError,
                       const_cast<char*>(err.what()));
@@ -381,103 +383,13 @@
     if mesh.name != "pylith_topology_Mesh":
       raise TypeError, \
             "Argument 'mesh' must be extension module type 'Mesh'."
-    FaultCohesiveKin_updateState(self.thisptr, PyCObject_AsVoidPtr(field),
-                           ptrFromHandle(mesh))
+    FaultCohesiveKin_updateState(self.thisptr,
+                                 t,
+                                 PyCObject_AsVoidPtr(field),
+                                 ptrFromHandle(mesh))
     return
 
 
-  def setConstraintSizes(self, field, mesh):
-    """
-    Set number of degrees of freedom that are constrained at points in field.
-    """
-    # create shim for method 'setConstraintSizes'
-    #embed{ void FaultCohesiveKin_setConstraintSizes(void* objVptr, void* fieldVptr, void* meshVptr)
-    try {
-      assert(0 != objVptr);
-      assert(0 != fieldVptr);
-      assert(0 != meshVptr);
-      ALE::Obj<pylith::real_section_type>* field = (ALE::Obj<pylith::real_section_type>*) fieldVptr;
-      ALE::Obj<ALE::Mesh>* mesh = (ALE::Obj<ALE::Mesh>*) meshVptr;
-      ((pylith::faults::FaultCohesiveKin*) objVptr)->setConstraintSizes(*field, *mesh);
-      } catch (const std::exception& err) {
-      PyErr_SetString(PyExc_RuntimeError,
-                      const_cast<char*>(err.what()));
-    } catch (...) {
-      PyErr_SetString(PyExc_RuntimeError,
-                      "Caught unknown C++ exception.");
-    } // try/catch      
-    #}embed
-
-    if not mesh.name == "pylith_topology_Mesh":
-      raise TypeError, \
-            "Argument must be extension module type " \
-            "'pylith::topology::Mesh'."
-    FaultCohesiveKin_setConstraintSizes(self.thisptr, PyCObject_AsVoidPtr(field),
-                                  ptrFromHandle(mesh))
-    return
-
-
-  def setConstraints(self, field, mesh):
-    """
-    Set which degrees of freedom that are constrained at points in field.
-    """
-    # create shim for method 'setConstraints'
-    #embed{ void FaultCohesiveKin_setConstraints(void* objVptr, void* fieldVptr, void* meshVptr)
-    try {
-      assert(0 != objVptr);
-      assert(0 != fieldVptr);
-      assert(0 != meshVptr);
-      ALE::Obj<pylith::real_section_type>* field = (ALE::Obj<pylith::real_section_type>*) fieldVptr;
-      ALE::Obj<ALE::Mesh>* mesh = (ALE::Obj<ALE::Mesh>*) meshVptr;
-      ((pylith::faults::FaultCohesiveKin*) objVptr)->setConstraints(*field, *mesh);
-      } catch (const std::exception& err) {
-      PyErr_SetString(PyExc_RuntimeError,
-                      const_cast<char*>(err.what()));
-    } catch (...) {
-      PyErr_SetString(PyExc_RuntimeError,
-                      "Caught unknown C++ exception.");
-    } // try/catch      
-    #}embed
-
-    if not mesh.name == "pylith_topology_Mesh":
-      raise TypeError, \
-            "Argument must be extension module type " \
-            "'pylith::topology::Mesh'."
-    FaultCohesiveKin_setConstraints(self.thisptr, PyCObject_AsVoidPtr(field), ptrFromHandle(mesh))
-    return
-
-
-  def setField(self, t, field, mesh):
-    """
-    Set values in field.
-    """
-    # create shim for method 'setField'
-    #embed{ void FaultCohesiveKin_setField(void* objVptr, double t, void* fieldVptr, void* meshVptr)
-    try {
-      assert(0 != objVptr);
-      assert(0 != fieldVptr);
-      assert(0 != meshVptr);
-      ALE::Obj<pylith::real_section_type>* field = (ALE::Obj<pylith::real_section_type>*) fieldVptr;
-      ALE::Obj<ALE::Mesh>* mesh = (ALE::Obj<ALE::Mesh>*) meshVptr;
-      ((pylith::faults::FaultCohesiveKin*) objVptr)->setField(t, *field, *mesh);
-      } catch (const std::exception& err) {
-      PyErr_SetString(PyExc_RuntimeError,
-                      const_cast<char*>(err.what()));
-    } catch (...) {
-      PyErr_SetString(PyExc_RuntimeError,
-                      "Caught unknown C++ exception.");
-    } // try/catch      
-    #}embed
-
-    if not mesh.name == "pylith_topology_Mesh":
-      raise TypeError, \
-            "Argument must be extension module type " \
-            "'pylith::topology::Mesh'."
-    FaultCohesiveKin_setField(self.thisptr, t, PyCObject_AsVoidPtr(field),
-                          ptrFromHandle(mesh))
-    return
-
-
   property quadrature:
     def __set__(self, q):
       """

Modified: short/3D/PyLith/trunk/modulesrc/feassemble/feassemble.pyxe.src
===================================================================
--- short/3D/PyLith/trunk/modulesrc/feassemble/feassemble.pyxe.src	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/modulesrc/feassemble/feassemble.pyxe.src	2007-06-13 20:26:23 UTC (rev 7214)
@@ -891,12 +891,12 @@
     return
 
 
-  def integrateResidual(self, residual, fields, mesh):
+  def integrateResidual(self, residual, t, fields, mesh):
     """
     Integrate contributions to residual term (r) for operator.
     """
     # create shim for method 'integrateResidual'
-    #embed{ void Integrator_integrateResidual(void* objVptr, void* residualVptr, void* fieldsVptr, void* meshVptr)
+    #embed{ void Integrator_integrateResidual(void* objVptr, void* residualVptr, double t, void* fieldsVptr, void* meshVptr)
     try {
       assert(0 != objVptr);
       assert(0 != residualVptr);
@@ -909,7 +909,7 @@
       pylith::topology::FieldsManager* fields =
         (pylith::topology::FieldsManager*) fieldsVptr;
       ((pylith::feassemble::Integrator*) objVptr)->integrateResidual(*residual,
-                                                              fields, *mesh);
+                                                            t, fields, *mesh);
     } catch (const std::exception& err) {
       PyErr_SetString(PyExc_RuntimeError,
                       const_cast<char*>(err.what()));
@@ -926,17 +926,18 @@
             "Argument must be extension module type 'Mesh'."
     Integrator_integrateResidual(self.thisptr, 
                                  PyCObject_AsVoidPtr(residual),
+                                 t,
                                  ptrFromHandle(fields),
                                  ptrFromHandle(mesh))
     return
 
 
-  def integrateJacobian(self, mat, fields, mesh):
+  def integrateJacobian(self, mat, t, fields, mesh):
     """
     Compute contributions to Jacobian matrix (A) associated with operator.
     """
     # create shim for method 'integrateJacobian'
-    #embed{ void Integrator_integrateJacobian(void* objVptr, void* matVptr, void* fieldsVptr, void* meshVptr)
+    #embed{ void Integrator_integrateJacobian(void* objVptr, void* matVptr, double t, void* fieldsVptr, void* meshVptr)
     try {
       assert(0 != objVptr);
       assert(0 != matVptr);
@@ -948,7 +949,7 @@
       pylith::topology::FieldsManager* fields =
         (pylith::topology::FieldsManager*) fieldsVptr;
       ((pylith::feassemble::Integrator*) objVptr)->integrateJacobian(
-                                                        mat, fields, *mesh);
+                                                        mat, t, fields, *mesh);
     } catch (const std::exception& err) {
       PyErr_SetString(PyExc_RuntimeError,
                       const_cast<char*>(err.what()));
@@ -965,17 +966,18 @@
             "Argument 'mesh' must be extension module type 'Mesh'."
     Integrator_integrateJacobian(self.thisptr,
                                  PyCObject_AsVoidPtr(mat),
+                                 t,
                                  ptrFromHandle(fields),
                                  ptrFromHandle(mesh))
     return
 
 
-  def updateState(self, field, mesh):
+  def updateState(self, t, field, mesh):
     """
     Update state variables as needed.
     """
     # create shim for method 'updateState'
-    #embed{ void Integrator_updateState(void* objVptr, void* fieldVptr, void* meshVptr)
+    #embed{ void Integrator_updateState(void* objVptr, double t, void* fieldVptr, void* meshVptr)
     try {
       assert(0 != objVptr);
       assert(0 != fieldVptr);
@@ -984,7 +986,7 @@
         (ALE::Obj<pylith::real_section_type>*) fieldVptr;
       ALE::Obj<ALE::Mesh>* mesh =
         (ALE::Obj<ALE::Mesh>*) meshVptr;
-      ((pylith::feassemble::Integrator*) objVptr)->updateState(*field, *mesh);
+      ((pylith::feassemble::Integrator*) objVptr)->updateState(t, *field, *mesh);
     } catch (const std::exception& err) {
       PyErr_SetString(PyExc_RuntimeError,
                       const_cast<char*>(err.what()));
@@ -999,7 +1001,9 @@
     if mesh.name != "pylith_topology_Mesh":
       raise TypeError, \
             "Argument 'mesh' must be extension module type 'Mesh'."
-    Integrator_updateState(self.thisptr, PyCObject_AsVoidPtr(field),
+    Integrator_updateState(self.thisptr,
+                           t,
+                           PyCObject_AsVoidPtr(field),
                            ptrFromHandle(mesh))
     return
 

Modified: short/3D/PyLith/trunk/modulesrc/utils/petsc.pyxe.src
===================================================================
--- short/3D/PyLith/trunk/modulesrc/utils/petsc.pyxe.src	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/modulesrc/utils/petsc.pyxe.src	2007-06-13 20:26:23 UTC (rev 7214)
@@ -122,4 +122,20 @@
   return
 
 
+def mat_view(mat):
+  """
+  Dump matrix to stdout.
+  """
+  # create shim for 'MatView'
+  #embed{ int Mat_view(void* matVptr)
+  Mat* mat = (Mat*) matVptr;
+  MatView(*mat, PETSC_VIEWER_STDOUT_WORLD);
+  return 0;
+  #}embed
+  cdef void* matVptr
+  err = Mat_view(PyCObject_AsVoidPtr(mat))
+
+  return
+
+
 # End of file 

Modified: short/3D/PyLith/trunk/pylith/faults/FaultCohesiveKin.py
===================================================================
--- short/3D/PyLith/trunk/pylith/faults/FaultCohesiveKin.py	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/pylith/faults/FaultCohesiveKin.py	2007-06-13 20:26:23 UTC (rev 7214)
@@ -96,13 +96,13 @@
     return self.cppHandle.stableTimeStep*second
 
 
-  def integrateResidual(self, residual, fields):
+  def integrateResidual(self, residual, t, fields):
     """
     Integrate contributions to residual term at time t.
     """
     self._info.log("Integrating residual for fault '%s'." % self.label)
     assert(None != self.cppHandle)
-    self.cppHandle.integrateResidual(residual, fields.cppHandle,
+    self.cppHandle.integrateResidual(residual, t.value, fields.cppHandle,
                                      self.mesh.cppHandle)
     return
 
@@ -116,54 +116,27 @@
     return self.cppHandle.needNewJacobian
 
 
-  def integrateJacobian(self, jacobian, fields):
+  def integrateJacobian(self, jacobian, t, fields):
     """
     Integrate contributions to Jacobian term at time t.
     """
     self._info.log("Integrating Jacobian for fault '%s'." % self.label)
     assert(None != self.cppHandle)
-    self.cppHandle.integrateJacobian(jacobian, fields.cppHandle,
+    self.cppHandle.integrateJacobian(jacobian, t.value, fields.cppHandle,
                                      self.mesh.cppHandle)
     return
 
 
-  def updateState(self, field):
+  def updateState(self, t, field):
     """
     Update state variables as needed.
     """
     self._info.log("Updating state for fault '%s'." % self.label)
     assert(None != self.cppHandle)
-    self.cppHandle.updateState(field, self.mesh.cppHandle)
+    self.cppHandle.updateState(t.value, field, self.mesh.cppHandle)
     return
     
 
-  def setConstraintSizes(self, field):
-    """
-    Set constraint sizes in field.
-    """
-    assert(None != self.cppHandle)
-    self.cppHandle.setConstraintSizes(field, self.mesh.cppHandle)
-    return
-
-
-  def setConstraints(self, field):
-    """
-    Set constraints for field.
-    """
-    assert(None != self.cppHandle)
-    self.cppHandle.setConstraints(field, self.mesh.cppHandle)
-    return
-
-
-  def setField(self, t, field):
-    """
-    Set constrained values in field at time t.
-    """
-    assert(None != self.cppHandle)
-    self.cppHandle.setField(t.value, field, self.mesh.cppHandle)
-    return
-
-
   def finalize(self):
     """
     Cleanup after time stepping.

Modified: short/3D/PyLith/trunk/pylith/feassemble/Integrator.py
===================================================================
--- short/3D/PyLith/trunk/pylith/feassemble/Integrator.py	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/pylith/feassemble/Integrator.py	2007-06-13 20:26:23 UTC (rev 7214)
@@ -90,12 +90,12 @@
     return self.cppHandle.stableTimeStep*second
 
 
-  def integrateResidual(self, residual, fields):
+  def integrateResidual(self, residual, t, fields):
     """
     Integrate contributions to residual term at time t.
     """
     assert(None != self.cppHandle)
-    self.cppHandle.integrateResidual(residual, fields.cppHandle,
+    self.cppHandle.integrateResidual(residual, t.value, fields.cppHandle,
                                      self.mesh.cppHandle)
     return
 
@@ -109,22 +109,22 @@
     return self.cppHandle.needNewJacobian
 
 
-  def integrateJacobian(self, jacobian, fields):
+  def integrateJacobian(self, jacobian, t, fields):
     """
     Integrate contributions to Jacobian term at time t.
     """
     assert(None != self.cppHandle)
-    self.cppHandle.integrateJacobian(jacobian, fields.cppHandle,
+    self.cppHandle.integrateJacobian(jacobian, t.value, fields.cppHandle,
                                      self.mesh.cppHandle)
     return
 
 
-  def updateState(self, field):
+  def updateState(self, t, field):
     """
     Update state variables as needed.
     """
     assert(None != self.cppHandle)
-    self.cppHandle.updateState(field, self.mesh.cppHandle)
+    self.cppHandle.updateState(t.value, field, self.mesh.cppHandle)
     return
     
 

Modified: short/3D/PyLith/trunk/pylith/problems/Explicit.py
===================================================================
--- short/3D/PyLith/trunk/pylith/problems/Explicit.py	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/pylith/problems/Explicit.py	2007-06-13 20:26:23 UTC (rev 7214)
@@ -63,6 +63,8 @@
     """
     Initialize problem for explicit time integration.
     """
+    from pyre.units.time import second
+    t = 0.0*second
     Formulation.initialize(self, mesh, materials, boundaryConditions,
                            interfaceConditions, dimension, dt)
 
@@ -79,7 +81,7 @@
     petsc.mat_setzero(self.jacobian)
     for integrator in self.integrators:
       integrator.timeStep(dt)
-      integrator.integrateJacobian(self.jacobian, self.fields)
+      integrator.integrateJacobian(self.jacobian, t, self.fields)
     petsc.mat_assemble(self.jacobian)
 
     self.solver.initialize(mesh, self.fields.getReal("dispTpdt"))
@@ -114,12 +116,12 @@
       petsc.mat_setzero(self.jacobian)
       for integrator in self.integrators:
         integrator.timeStep(dt)
-        integrator.integrateJacobian(self.jacobian, self.fields)
+        integrator.integrateJacobian(self.jacobian, t, self.fields)
       petsc.mat_assemble(self.jacobian)
     return
 
 
-  def step(self, dt):
+  def step(self, t, dt):
     """
     Advance to next time step.
     """
@@ -129,7 +131,7 @@
     bindings.zeroRealSection(residual)
     for integrator in self.integrators:
       integrator.timeStep(dt)
-      integrator.integrateResidual(residual, self.fields)
+      integrator.integrateResidual(residual, t, self.fields)
 
     self._info.log("Solving equations.")
     self.solver.solve(self.fields.getReal("dispTpdt"), self.jacobian, residual)
@@ -144,7 +146,7 @@
 
     self._info.log("Updating integrators states.")
     for integrator in self.integrators:
-      integrator.updateState(self.fields.getReal("dispT"))
+      integrator.updateState(t, self.fields.getReal("dispT"))
 
     Formulation.poststep(self, t)
     return

Modified: short/3D/PyLith/trunk/pylith/problems/Formulation.py
===================================================================
--- short/3D/PyLith/trunk/pylith/problems/Formulation.py	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/pylith/problems/Formulation.py	2007-06-13 20:26:23 UTC (rev 7214)
@@ -107,15 +107,18 @@
     self._info.log("Initializing boundary conditions.")
     for bc in boundaryConditions.bin:
       bc.initialize(mesh)
+      foundType = False
       if implementsIntegrator(bc):
+        foundType = True
         self.integrators.append(bc)
         self._info.log("Added boundary condition '%s' as an integrator." % \
                        bc.label)
       if implementsConstraint(bc):
+        foundType = True
         self.constraints.append(bc)
         self._info.log("Added boundary condition '%s' as a constraint." % \
                        bc.label)
-      else:
+      if not foundType:
         raise TypeError, \
               "Could not determine whether boundary condition '%s' is an " \
               "integrator or a constraint." % bc.name
@@ -123,15 +126,18 @@
     self._info.log("Initializing interior interfaces.")
     for ic in interfaceConditions.bin:
       ic.initialize(mesh)
+      foundType = False
       if implementsIntegrator(ic):
+        foundType = True
         self.integrators.append(ic)
         self._info.log("Added interface condition '%s' as an integrator." % \
                        ic.label)
       if implementsConstraint(ic):
+        foundType = True
         self.constraints.append(ic)
         self._info.log("Added interface condition '%s' as a constraint." % \
                        ic.label)
-      else:
+      if not foundType:
         raise TypeError, \
               "Could not determine whether interface condition '%s' is an " \
               "integrator or a constraint." % ic.name

Modified: short/3D/PyLith/trunk/pylith/problems/Implicit.py
===================================================================
--- short/3D/PyLith/trunk/pylith/problems/Implicit.py	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/pylith/problems/Implicit.py	2007-06-13 20:26:23 UTC (rev 7214)
@@ -137,12 +137,12 @@
       petsc.mat_setzero(self.jacobian)
       for integrator in self.integrators:
         integrator.timeStep(dt)
-        integrator.integrateJacobian(self.jacobian, self.fields)
+        integrator.integrateJacobian(self.jacobian, t, self.fields)
       petsc.mat_assemble(self.jacobian)
     return
 
 
-  def step(self, dt):
+  def step(self, t, dt):
     """
     Advance to next time step.
     """
@@ -152,7 +152,7 @@
     bindings.zeroRealSection(residual)
     for integrator in self.integrators:
       integrator.timeStep(dt)
-      integrator.integrateResidual(residual, self.fields)
+      integrator.integrateResidual(residual, t, self.fields)
 
     self._info.log("Solving equations.")
     self.solver.solve(self.fields.getReal("dispIncr"), self.jacobian, residual)
@@ -175,7 +175,7 @@
 
     self._info.log("Updating integrators states.")
     for integrator in self.integrators:
-      integrator.updateState(solnField)
+      integrator.updateState(t, solnField)
 
     Formulation.poststep(self, t)
     return
@@ -214,13 +214,16 @@
     dispIncr = self.fields.getReal("dispIncr")
     for integrator in self.integrators:
       integrator.timeStep(dt)
-      integrator.integrateJacobian(self.jacobian, self.fields)
-      integrator.integrateResidual(residual, self.fields)
+      integrator.integrateJacobian(self.jacobian, t, self.fields)
+      integrator.integrateResidual(residual, t, self.fields)
     import pylith.utils.petsc as petsc
     petsc.mat_assemble(self.jacobian)
+    print "Jacobian matrix"
+    petsc.mat_view(self.jacobian)
 
     self._info.log("Solving equations.")
     print "BEFORE SOLVE"
+    bindings.sectionView(solnField, "dispTBctpdt")
     bindings.sectionView(residual, "residual")
     bindings.sectionView(dispIncr, "dispIncr")
     self.solver.solve(dispIncr, self.jacobian, residual)
@@ -233,7 +236,7 @@
 
     self._info.log("Updating integrators states.")
     for integrator in self.integrators:
-      integrator.updateState(solnField)
+      integrator.updateState(t, solnField)
 
     self._info.log("Outputting elastic solution.")
     field = self.fields.getReal(self.solnField['name'])

Modified: short/3D/PyLith/trunk/pylith/problems/TimeDependent.py
===================================================================
--- short/3D/PyLith/trunk/pylith/problems/TimeDependent.py	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/pylith/problems/TimeDependent.py	2007-06-13 20:26:23 UTC (rev 7214)
@@ -128,7 +128,7 @@
       self._prestep(t, dt)
 
       # Advance in time
-      self._step(dt)
+      self._step(t, dt)
 
       # Do stuff after advancing time step
       self._poststep(t+dt)
@@ -183,11 +183,11 @@
     return
 
 
-  def _step(self, dt):
+  def _step(self, t, dt):
     """
     Advance to next time step.
     """
-    self.formulation.step(dt)
+    self.formulation.step(t, dt)
     return
 
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKin.cc
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKin.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKin.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -141,12 +141,8 @@
   // Setup fields
   topology::FieldsManager fields(mesh);
   fields.addReal("residual");
-  fields.addReal("dispTpdt");
   fields.addReal("dispT");
   fields.solutionField("dispT");
-  const char* history[] = { "dispTpdt", "dispT" };
-  const int historySize = 2;
-  fields.createHistory(history, historySize);
   
   const ALE::Obj<real_section_type>& residual = fields.getReal("residual");
   CPPUNIT_ASSERT(!residual.isNull());
@@ -156,9 +152,7 @@
   residual->zero();
   fields.copyLayout("residual");
 
-  const ALE::Obj<real_section_type>& dispTpdt = fields.getReal("dispTpdt");
   const ALE::Obj<real_section_type>& dispT = fields.getReal("dispT");
-  CPPUNIT_ASSERT(!dispTpdt.isNull());
   CPPUNIT_ASSERT(!dispT.isNull());
 
   const ALE::Obj<Mesh::label_sequence>& vertices = mesh->depthStratum(0);
@@ -169,14 +163,14 @@
   for (Mesh::label_sequence::iterator v_iter=vBegin;
        v_iter != vEnd;
        ++v_iter, ++iVertex) {
-    dispTpdt->updatePoint(*v_iter, &_data->fieldTpdt[iVertex*spaceDim]);
     dispT->updatePoint(*v_iter, &_data->fieldT[iVertex*spaceDim]);
   } // for
   
   //dispT->view("DISP T");
 
   // Call integrateResidual()
-  fault.integrateResidual(residual, &fields, mesh);
+  const double t = 2.134;
+  fault.integrateResidual(residual, t, &fields, mesh);
 
   //residual->view("RESIDUAL");
 
@@ -214,12 +208,8 @@
   // Setup fields
   topology::FieldsManager fields(mesh);
   fields.addReal("residual");
-  fields.addReal("dispTpdt");
   fields.addReal("dispT");
   fields.solutionField("dispT");
-  const char* history[] = { "dispTpdt", "dispT" };
-  const int historySize = 2;
-  fields.createHistory(history, historySize);
   
   const ALE::Obj<real_section_type>& residual = fields.getReal("residual");
   CPPUNIT_ASSERT(!residual.isNull());
@@ -229,9 +219,7 @@
   residual->zero();
   fields.copyLayout("residual");
 
-  const ALE::Obj<real_section_type>& dispTpdt = fields.getReal("dispTpdt");
   const ALE::Obj<real_section_type>& dispT = fields.getReal("dispT");
-  CPPUNIT_ASSERT(!dispTpdt.isNull());
   CPPUNIT_ASSERT(!dispT.isNull());
 
   const ALE::Obj<Mesh::label_sequence>& vertices = mesh->depthStratum(0);
@@ -242,15 +230,15 @@
   for (Mesh::label_sequence::iterator v_iter=vBegin;
        v_iter != vEnd;
        ++v_iter, ++iVertex) {
-    dispTpdt->updatePoint(*v_iter, &_data->fieldTpdt[iVertex*spaceDim]);
     dispT->updatePoint(*v_iter, &_data->fieldT[iVertex*spaceDim]);
   } // for
   
   PetscMat jacobian;
-  PetscErrorCode err = MeshCreateMatrix(mesh, dispTpdt, MATMPIBAIJ, &jacobian);
+  PetscErrorCode err = MeshCreateMatrix(mesh, dispT, MATMPIBAIJ, &jacobian);
   CPPUNIT_ASSERT(0 == err);
 
-  fault.integrateJacobian(&jacobian, &fields, mesh);
+  const double t = 2.134;
+  fault.integrateJacobian(&jacobian, t, &fields, mesh);
   CPPUNIT_ASSERT_EQUAL(false, fault.needNewJacobian());
 
   err = MatAssemblyBegin(jacobian, MAT_FINAL_ASSEMBLY);
@@ -297,91 +285,6 @@
 } // testIntegrateJacobian
 
 // ----------------------------------------------------------------------
-// Test setConstraintSizes().
-void
-pylith::faults::TestFaultCohesiveKin::testSetConstraintSizes(void)
-{ // testSetConstraintSizes
-  // Make sure the fiber dimension at each point is equal to the
-  // spatial dimension of the mesh, because the Lagrange multiplier
-  // formation does not eliminate any DOF from the system of
-  // equations.
-
-  ALE::Obj<Mesh> mesh;
-  FaultCohesiveKin fault;
-  _initialize(&mesh, &fault);
-  
-  const int fiberDim = 3;
-  const ALE::Obj<real_section_type>& field = 
-    new real_section_type(mesh->comm(), mesh->debug());
-  CPPUNIT_ASSERT(!field.isNull());
-
-  field->setFiberDimension(mesh->depthStratum(0), fiberDim);
-  fault.setConstraintSizes(field, mesh);
-  mesh->allocate(field);
-
-  const ALE::Obj<Mesh::label_sequence>& vertices = mesh->depthStratum(0);
-  CPPUNIT_ASSERT(!vertices.isNull());
-  const Mesh::label_sequence::iterator vBegin = vertices->begin();
-  const Mesh::label_sequence::iterator vEnd = vertices->end();
-  for (Mesh::label_sequence::iterator v_iter=vBegin;
-       v_iter != vEnd;
-       ++v_iter) {
-    CPPUNIT_ASSERT_EQUAL(fiberDim, field->getFiberDimension(*v_iter));
-    CPPUNIT_ASSERT_EQUAL(0, field->getConstraintDimension(*v_iter));
-  } // for
-} // testSetConstraintSizes
-
-// ----------------------------------------------------------------------
-// Test setField().
-void
-pylith::faults::TestFaultCohesiveKin::testSetField(void)
-{ // testSetField
-  ALE::Obj<Mesh> mesh;
-  FaultCohesiveKin fault;
-  _initialize(&mesh, &fault);
-
-  // Setup fields
-  topology::FieldsManager fields(mesh);
-  fields.addReal("disp");
-  
-  const ALE::Obj<real_section_type>& disp = fields.getReal("disp");
-  CPPUNIT_ASSERT(!disp.isNull());
-  const int spaceDim = _data->spaceDim;
-  disp->setFiberDimension(mesh->depthStratum(0), spaceDim);
-  mesh->allocate(disp);
-  disp->zero();
-
-  const double t = 2.134;
-  fault.setField(t, disp, mesh);
-
-  // Check values
-  const double* valsE = _data->valsSlip;
-  const int fiberDimE = spaceDim;
-  const double tolerance = 1.0e-06;
-
-  const ALE::Obj<Mesh::label_sequence>& vertices = mesh->depthStratum(0);
-  CPPUNIT_ASSERT(!vertices.isNull());
-  const Mesh::label_sequence::iterator vBegin = vertices->begin();
-  const Mesh::label_sequence::iterator vEnd = vertices->end();
-  int iVertex = 0;
-  for (Mesh::label_sequence::iterator v_iter=vBegin;
-       v_iter != vEnd;
-       ++v_iter, ++iVertex) {
-    const int fiberDim = disp->getFiberDimension(*v_iter);
-    CPPUNIT_ASSERT_EQUAL(fiberDimE, fiberDim);
-    const real_section_type::value_type* vals = 
-      disp->restrictPoint(*v_iter);
-    for (int i=0; i < fiberDimE; ++i) {
-      const int index = iVertex*spaceDim+i;
-      if (valsE[index] > tolerance)
-	CPPUNIT_ASSERT_DOUBLES_EQUAL(1.0, vals[i]/valsE[index], tolerance);
-      else
-	CPPUNIT_ASSERT_DOUBLES_EQUAL(valsE[index], vals[i], tolerance);
-    } // for
-  } // for
-} // testSetField
-
-// ----------------------------------------------------------------------
 // Initialize FaultCohesiveKin interface condition.
 void
 pylith::faults::TestFaultCohesiveKin::_initialize(ALE::Obj<ALE::Mesh>* mesh,

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKin.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKin.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKin.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -87,12 +87,6 @@
   /// Test integrateJacobian().
   void testIntegrateJacobian(void);
 
-  /// Test setConstraintSizes().
-  void testSetConstraintSizes(void);
-
-  /// Test setField().
-  void testSetField(void);
-
   // PRIVATE METHODS ////////////////////////////////////////////////////
 private :
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinHex8.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinHex8.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinHex8.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -40,8 +40,6 @@
   CPPUNIT_TEST( testInitialize );
   CPPUNIT_TEST( testIntegrateResidual );
   CPPUNIT_TEST( testIntegrateJacobian );
-  CPPUNIT_TEST( testSetConstraintSizes );
-  CPPUNIT_TEST( testSetField );
 
   CPPUNIT_TEST_SUITE_END();
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinLine2.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinLine2.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinLine2.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -40,8 +40,6 @@
   CPPUNIT_TEST( testInitialize );
   CPPUNIT_TEST( testIntegrateResidual );
   CPPUNIT_TEST( testIntegrateJacobian );
-  CPPUNIT_TEST( testSetConstraintSizes );
-  CPPUNIT_TEST( testSetField );
 
   CPPUNIT_TEST_SUITE_END();
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinQuad4.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinQuad4.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinQuad4.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -40,8 +40,6 @@
   CPPUNIT_TEST( testInitialize );
   CPPUNIT_TEST( testIntegrateResidual );
   CPPUNIT_TEST( testIntegrateJacobian );
-  CPPUNIT_TEST( testSetConstraintSizes );
-  CPPUNIT_TEST( testSetField );
 
   CPPUNIT_TEST_SUITE_END();
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinTet4.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinTet4.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinTet4.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -40,8 +40,6 @@
   CPPUNIT_TEST( testInitialize );
   CPPUNIT_TEST( testIntegrateResidual );
   CPPUNIT_TEST( testIntegrateJacobian );
-  CPPUNIT_TEST( testSetConstraintSizes );
-  CPPUNIT_TEST( testSetField );
 
   CPPUNIT_TEST_SUITE_END();
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinTri3.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinTri3.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/TestFaultCohesiveKinTri3.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -40,8 +40,6 @@
   CPPUNIT_TEST( testInitialize );
   CPPUNIT_TEST( testIntegrateResidual );
   CPPUNIT_TEST( testIntegrateJacobian );
-  CPPUNIT_TEST( testSetConstraintSizes );
-  CPPUNIT_TEST( testSetField );
 
   CPPUNIT_TEST_SUITE_END();
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinData.cc
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinData.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinData.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -30,12 +30,10 @@
   finalSlipFilename(0),
   slipTimeFilename(0),
   peakRateFilename(0),
-  fieldTpdt(0),
   fieldT(0),
   orientation(0),
   constraintVertices(0),
   valsResidual(0),
-  valsSlip(0),
   valsJacobian(0),
   numConstraintVert(0)
 { // constructor

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinData.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinData.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinData.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -60,8 +60,7 @@
 
   /// @name Input fields
   //@{
-  double* fieldTpdt; ///< Input field at time t+dt.
-  double* fieldT; ///< Input field at time t.
+  double* fieldT; ///< Solution field at time t.
   //@}
 
   /// @name Calculated values.
@@ -69,7 +68,6 @@
   double* orientation; ///< Expected values for fault orientation.
   int* constraintVertices; ///< Expected points for constraint vertices
   double* valsResidual; ///< Expected values from residual calculation.
-  double* valsSlip; ///< Expected values from settting field.
   double* valsJacobian; ///< Expected values from Jacobian calculation.
   int numConstraintVert; ///< Number of constraint vertices
   //@}

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataHex8.cc
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataHex8.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataHex8.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -101,7 +101,7 @@
 const char* pylith::faults::CohesiveKinDataHex8::_peakRateFilename = 
   "data/hex8_peakrate.spatialdb";
 
-const double pylith::faults::CohesiveKinDataHex8::_fieldTpdt[] = {
+const double pylith::faults::CohesiveKinDataHex8::_fieldT[] = {
   4.1, 6.1, 8.1,
   4.2, 6.2, 8.2,
   4.3, 6.3, 8.3,
@@ -124,29 +124,6 @@
   5.0, 7.0, 9.0,
 };
 
-const double pylith::faults::CohesiveKinDataHex8::_fieldT[] = {
-  4.1, 6.1, 8.1,
-  4.2, 6.2, 8.2,
-  4.3, 6.3, 8.3,
-  4.4, 6.4, 8.4,
-  4.5, 6.5, 8.5,
-  4.6, 6.6, 8.6,
-  4.7, 6.7, 8.7,
-  4.8, 6.8, 8.8,
-  4.9, 6.9, 8.9,
-  4.0, 6.0, 8.0,
-  5.1, 7.1, 9.1,
-  5.2, 7.2, 9.2,
-  5.3, 7.3, 9.3,
-  1.1, 1.2, 1.3, // 15
-  5.5, 7.5, 9.5,
-  2.1, 2.2, 2.3, // 17
-  5.7, 7.7, 9.7,
-  3.1, 3.2, 3.3, // 19
-  5.9, 7.9, 9.9,
-  1.5, 1.6, 1.7, // 21
-};
-
 const int pylith::faults::CohesiveKinDataHex8::_numConstraintVert = 4;
 
 const double pylith::faults::CohesiveKinDataHex8::_orientation[] = {
@@ -165,38 +142,15 @@
   0.0, 0.0, 0.0,
   0.0, 0.0, 0.0,
   0.0, 0.0, 0.0,
- -1.1,-1.2,-1.3, // 6
- -2.1,-2.2,-2.3, // 7
- -3.1,-3.2,-3.3, // 8
- -1.5,-1.6,-1.7, // 9
   0.0, 0.0, 0.0,
   0.0, 0.0, 0.0,
   0.0, 0.0, 0.0,
   0.0, 0.0, 0.0,
- +1.1,+1.2,+1.3, // 14
-  0.0, 0.0, 0.0, // 15 (constraint)
- +2.1,+2.2,+2.3, // 16
-  0.0, 0.0, 0.0, // 17 (constraint)
- +3.1,+3.2,+3.3, // 18
-  0.0, 0.0, 0.0, // 19 (constraint)
- +1.5,+1.6,+1.7, // 20
-  0.0, 0.0, 0.0, // 21 (constraint)
-};
-
-const double pylith::faults::CohesiveKinDataHex8::_valsSlip[] = {
   0.0, 0.0, 0.0,
   0.0, 0.0, 0.0,
   0.0, 0.0, 0.0,
   0.0, 0.0, 0.0,
   0.0, 0.0, 0.0,
-  0.0, 0.0, 0.0,
-  0.0, 0.0, 0.0,
-  0.0, 0.0, 0.0,
-  0.0, 0.0, 0.0,
-  0.0, 0.0, 0.0,
-  0.0, 0.0, 0.0,
-  0.0, 0.0, 0.0,
-  0.0, 0.0, 0.0,
   1.07974939836, -0.32861938211, 0.04694562602, // 15 (constraint)
   0.0, 0.0, 0.0,
   1.00381374723, -0.33460458241, 0.08365114560, // 17 (constraint)
@@ -1426,12 +1380,10 @@
   finalSlipFilename = const_cast<char*>(_finalSlipFilename);
   slipTimeFilename = const_cast<char*>(_slipTimeFilename);
   peakRateFilename = const_cast<char*>(_peakRateFilename);
-  fieldTpdt = const_cast<double*>(_fieldTpdt);
   fieldT = const_cast<double*>(_fieldT);
   orientation = const_cast<double*>(_orientation);
   constraintVertices = const_cast<int*>(_constraintVertices);
   valsResidual = const_cast<double*>(_valsResidual);
-  valsSlip = const_cast<double*>(_valsSlip);
   valsJacobian = const_cast<double*>(_valsJacobian);
   numConstraintVert = _numConstraintVert;  
 } // constructor

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataHex8.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataHex8.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataHex8.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -56,13 +56,11 @@
   static const char* _peakRateFilename; ///< Name of db for peak rate
   //@}
 
-  static const double _fieldTpdt[]; ///< Input field at time t+dt.
-  static const double _fieldT[]; ///< Input field at time t.
+  static const double _fieldT[]; ///< Solution field at time t.
 
   static const double _orientation[]; ///< Expected values for fault orientation.
   static const int _constraintVertices[]; ///< Expected points for constraint vertices
   static const double _valsResidual[]; ///< Expected values from residual calculation.
-  static const double _valsSlip[]; ///< Expected values from settting field.
   static const double _valsJacobian[]; ///< Expected values from Jacobian calculation.
   static const int _numConstraintVert; ///< Number of constraint vertices
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataLine2.cc
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataLine2.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataLine2.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -67,7 +67,7 @@
   "data/line2_peakrate.spatialdb";
 
 // Don't expect these values to be used, so just use some values.
-const double pylith::faults::CohesiveKinDataLine2::_fieldTpdt[] = {
+const double pylith::faults::CohesiveKinDataLine2::_fieldT[] = {
   7.1,
   7.2,
   7.3,
@@ -75,14 +75,6 @@
   7.5
 };
 
-const double pylith::faults::CohesiveKinDataLine2::_fieldT[] = {
-  0.1,
-  0.2,
-  0.3,
-  0.4,
-  2.3 // force associated with constraint
-};
-
 const int pylith::faults::CohesiveKinDataLine2::_numConstraintVert = 1;
 
 const double pylith::faults::CohesiveKinDataLine2::_orientation[] = {
@@ -95,17 +87,9 @@
 
 const double pylith::faults::CohesiveKinDataLine2::_valsResidual[] = {
   0.0,
- -2.3,
   0.0,
-  2.3,
-  0.0
-};
-
-const double pylith::faults::CohesiveKinDataLine2::_valsSlip[] = {
   0.0,
   0.0,
-  0.0,
-  0.0,
   1.05168389458
 };
 
@@ -134,12 +118,10 @@
   finalSlipFilename = const_cast<char*>(_finalSlipFilename);
   slipTimeFilename = const_cast<char*>(_slipTimeFilename);
   peakRateFilename = const_cast<char*>(_peakRateFilename);
-  fieldTpdt = const_cast<double*>(_fieldTpdt);
   fieldT = const_cast<double*>(_fieldT);
   orientation = const_cast<double*>(_orientation);
   constraintVertices = const_cast<int*>(_constraintVertices);
   valsResidual = const_cast<double*>(_valsResidual);
-  valsSlip = const_cast<double*>(_valsSlip);
   valsJacobian = const_cast<double*>(_valsJacobian);
   numConstraintVert = _numConstraintVert;  
 } // constructor

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataLine2.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataLine2.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataLine2.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -56,13 +56,11 @@
   static const char* _peakRateFilename; ///< Name of db for peak rate
   //@}
 
-  static const double _fieldTpdt[]; ///< Input field at time t+dt.
-  static const double _fieldT[]; ///< Input field at time t.
+  static const double _fieldT[]; ///< Solution field at time t.
 
   static const double _orientation[]; ///< Expected values for fault orientation.
   static const int _constraintVertices[]; ///< Expected points for constraint vertices
   static const double _valsResidual[]; ///< Expected values from residual calculation.
-  static const double _valsSlip[]; ///< Expected values from settting field.
   static const double _valsJacobian[]; ///< Expected values from Jacobian calculation.
   static const int _numConstraintVert; ///< Number of constraint vertices
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataQuad4.cc
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataQuad4.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataQuad4.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -89,7 +89,7 @@
 const char* pylith::faults::CohesiveKinDataQuad4::_peakRateFilename = 
   "data/quad4_peakrate.spatialdb";
 
-const double pylith::faults::CohesiveKinDataQuad4::_fieldTpdt[] = {
+const double pylith::faults::CohesiveKinDataQuad4::_fieldT[] = {
   8.1, 9.1,
   8.2, 9.2,
   8.3, 9.3,
@@ -102,18 +102,6 @@
   8.0, 9.0,
 };
 
-const double pylith::faults::CohesiveKinDataQuad4::_fieldT[] = {
-  6.1, 7.1, // 2
-  6.2, 7.2, // 3
-  6.3, 7.3, // 4
-  6.4, 7.4, // 5
-  6.5, 7.5, // 6
-  6.6, 7.6, // 7
-  6.7, 7.7, // 8
-  1.4, 1.5, // 9 (constraint force)
-  6.8, 7.8, // 10
-  2.6, 2.7, // 11 (constraint force)
-};
 
 const int pylith::faults::CohesiveKinDataQuad4::_numConstraintVert = 2;
 
@@ -127,19 +115,6 @@
 };
 
 const double pylith::faults::CohesiveKinDataQuad4::_valsResidual[] = {
-  0.0,  0.0, // 2
-  0.0,  0.0, // 3
- -1.4, -1.5, // 4
- -2.6, -2.7, // 5
-  0.0,  0.0, // 6
-  0.0,  0.0, // 7
- +1.4, +1.5, // 8
-  0.0,  0.0, // 9
- +2.6, +2.7, // 10
-  0.0,  0.0, // 11
-};
-
-const double pylith::faults::CohesiveKinDataQuad4::_valsSlip[] = {
   0.0,  0.0,
   0.0,  0.0,
   0.0,  0.0,
@@ -372,12 +347,10 @@
   finalSlipFilename = const_cast<char*>(_finalSlipFilename);
   slipTimeFilename = const_cast<char*>(_slipTimeFilename);
   peakRateFilename = const_cast<char*>(_peakRateFilename);
-  fieldTpdt = const_cast<double*>(_fieldTpdt);
   fieldT = const_cast<double*>(_fieldT);
   orientation = const_cast<double*>(_orientation);
   constraintVertices = const_cast<int*>(_constraintVertices);
   valsResidual = const_cast<double*>(_valsResidual);
-  valsSlip = const_cast<double*>(_valsSlip);
   valsJacobian = const_cast<double*>(_valsJacobian);
   numConstraintVert = _numConstraintVert;  
 } // constructor

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataQuad4.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataQuad4.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataQuad4.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -56,13 +56,11 @@
   static const char* _peakRateFilename; ///< Name of db for peak rate
   //@}
 
-  static const double _fieldTpdt[]; ///< Input field at time t+dt.
-  static const double _fieldT[]; ///< Input field at time t.
+  static const double _fieldT[]; ///< Solution field at time t.
 
   static const double _orientation[]; ///< Expected values for fault orientation.
   static const int _constraintVertices[]; ///< Expected points for constraint vertices
   static const double _valsResidual[]; ///< Expected values from residual calculation.
-  static const double _valsSlip[]; ///< Expected values from settting field.
   static const double _valsJacobian[]; ///< Expected values from Jacobian calculation.
   static const int _numConstraintVert; ///< Number of constraint vertices
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTet4.cc
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTet4.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTet4.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -77,7 +77,7 @@
 const char* pylith::faults::CohesiveKinDataTet4::_peakRateFilename = 
   "data/tet4_peakrate.spatialdb";
 
-const double pylith::faults::CohesiveKinDataTet4::_fieldTpdt[] = {
+const double pylith::faults::CohesiveKinDataTet4::_fieldT[] = {
   7.1, 8.1, 9.1,
   7.2, 8.2, 9.2,
   7.3, 8.3, 9.3,
@@ -91,20 +91,6 @@
   7.1, 8.1, 9.1,
 };
 
-const double pylith::faults::CohesiveKinDataTet4::_fieldT[] = {
-  4.1, 5.1, 6.1, // 2
-  4.2, 5.2, 6.2, // 3
-  4.3, 5.3, 6.3, // 4
-  4.4, 5.4, 6.4, // 5
-  4.5, 5.5, 6.5, // 6
-  4.6, 5.6, 6.6, // 7
-  1.2, 1.3, 1.4, // 8 (constraint force)
-  4.8, 5.8, 6.8, // 9
-  2.2, 2.3, 2.4, // 10 (constraint force)
-  4.0, 5.0, 6.0, // 11
-  3.2, 3.3, 3.4, // 12 (constraint force)
-};
-
 const int pylith::faults::CohesiveKinDataTet4::_numConstraintVert = 3;
 
 const double pylith::faults::CohesiveKinDataTet4::_orientation[] = {
@@ -118,20 +104,6 @@
 };
 
 const double pylith::faults::CohesiveKinDataTet4::_valsResidual[] = {
-  0.0,  0.0,  0.0, // 2
- -1.2, -1.3, -1.4, // 3
- -2.2, -2.3, -2.4, // 4
- -3.2, -3.3, -3.4, // 5
-  0.0,  0.0,  0.0, // 6
- +1.2, +1.3, +1.4, // 7
-  0.0,  0.0,  0.0, // 8
- +2.2, +2.3, +2.4, // 9
-  0.0,  0.0,  0.0, // 10
- +3.2, +3.3, +3.4, // 11
-  0.0,  0.0,  0.0, // 12
-};
-
-const double pylith::faults::CohesiveKinDataTet4::_valsSlip[] = {
   0.0,  0.0,  0.0,
   0.0,  0.0,  0.0,
   0.0,  0.0,  0.0,
@@ -528,12 +500,10 @@
   finalSlipFilename = const_cast<char*>(_finalSlipFilename);
   slipTimeFilename = const_cast<char*>(_slipTimeFilename);
   peakRateFilename = const_cast<char*>(_peakRateFilename);
-  fieldTpdt = const_cast<double*>(_fieldTpdt);
   fieldT = const_cast<double*>(_fieldT);
   orientation = const_cast<double*>(_orientation);
   constraintVertices = const_cast<int*>(_constraintVertices);
   valsResidual = const_cast<double*>(_valsResidual);
-  valsSlip = const_cast<double*>(_valsSlip);
   valsJacobian = const_cast<double*>(_valsJacobian);
   numConstraintVert = _numConstraintVert;  
 } // constructor

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTet4.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTet4.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTet4.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -56,13 +56,11 @@
   static const char* _peakRateFilename; ///< Name of db for peak rate
   //@}
 
-  static const double _fieldTpdt[]; ///< Input field at time t+dt.
-  static const double _fieldT[]; ///< Input field at time t.
+  static const double _fieldT[]; ///< Solution field at time t.
 
   static const double _orientation[]; ///< Expected values for fault orientation.
   static const int _constraintVertices[]; ///< Expected points for constraint vertices
   static const double _valsResidual[]; ///< Expected values from residual calculation.
-  static const double _valsSlip[]; ///< Expected values from settting field.
   static const double _valsJacobian[]; ///< Expected values from Jacobian calculation.
   static const int _numConstraintVert; ///< Number of constraint vertices
 

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTri3.cc
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTri3.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTri3.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -92,7 +92,7 @@
 const char* pylith::faults::CohesiveKinDataTri3::_peakRateFilename = 
   "data/tri3_peakrate.spatialdb";
 
-const double pylith::faults::CohesiveKinDataTri3::_fieldTpdt[] = {
+const double pylith::faults::CohesiveKinDataTri3::_fieldT[] = {
   8.1, 9.1,
   8.2, 9.2,
   8.3, 9.3,
@@ -103,17 +103,6 @@
   8.8, 9.8,
 };
 
-const double pylith::faults::CohesiveKinDataTri3::_fieldT[] = {
-  6.1, 7.1, // 2
-  6.2, 7.2, // 3
-  6.3, 7.3, // 4
-  6.4, 7.4, // 5
-  6.5, 7.5, // 6
-  1.4, 1.5, // 7 (constraint force)
-  6.7, 7.7, // 8
-  2.6, 2.7, // 9 (constraint force)
-};
-
 const int pylith::faults::CohesiveKinDataTri3::_numConstraintVert = 2;
 
 const double pylith::faults::CohesiveKinDataTri3::_orientation[] = {
@@ -126,17 +115,6 @@
 };
 
 const double pylith::faults::CohesiveKinDataTri3::_valsResidual[] = {
-  0.0,  0.0, // 2
- -1.4, -1.5, // 3
- -2.6, -2.7, // 4
-  0.0,  0.0, // 5
- +1.4, +1.5, // 6
-  0.0,  0.0, // 7
- +2.6, +2.7, // 8
-  0.0,  0.0  // 9
-};
-
-const double pylith::faults::CohesiveKinDataTri3::_valsSlip[] = {
   0.0,  0.0,
   0.0,  0.0,
   0.0,  0.0,
@@ -295,12 +273,10 @@
   finalSlipFilename = const_cast<char*>(_finalSlipFilename);
   slipTimeFilename = const_cast<char*>(_slipTimeFilename);
   peakRateFilename = const_cast<char*>(_peakRateFilename);
-  fieldTpdt = const_cast<double*>(_fieldTpdt);
   fieldT = const_cast<double*>(_fieldT);
   orientation = const_cast<double*>(_orientation);
   constraintVertices = const_cast<int*>(_constraintVertices);
   valsResidual = const_cast<double*>(_valsResidual);
-  valsSlip = const_cast<double*>(_valsSlip);
   valsJacobian = const_cast<double*>(_valsJacobian);
   numConstraintVert = _numConstraintVert;  
 } // constructor

Modified: short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTri3.hh
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTri3.hh	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/faults/data/CohesiveKinDataTri3.hh	2007-06-13 20:26:23 UTC (rev 7214)
@@ -56,13 +56,11 @@
   static const char* _peakRateFilename; ///< Name of db for peak rate
   //@}
 
-  static const double _fieldTpdt[]; ///< Input field at time t+dt.
-  static const double _fieldT[]; ///< Input field at time t.
+  static const double _fieldT[]; ///< Solution field at time t.
 
   static const double _orientation[]; ///< Expected values for fault orientation.
   static const int _constraintVertices[]; ///< Expected points for constraint vertices
   static const double _valsResidual[]; ///< Expected values from residual calculation.
-  static const double _valsSlip[]; ///< Expected values from settting field.
   static const double _valsJacobian[]; ///< Expected values from Jacobian calculation.
   static const int _numConstraintVert; ///< Number of constraint vertices
 

Modified: short/3D/PyLith/trunk/unittests/libtests/feassemble/TestElasticityExplicit.cc
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/feassemble/TestElasticityExplicit.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/feassemble/TestElasticityExplicit.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -135,7 +135,8 @@
 
   const ALE::Obj<real_section_type>& dispT = fields.getReal("dispT");
   CPPUNIT_ASSERT(!dispT.isNull());
-  integrator.updateState(dispT, mesh);
+  const double t = 1.0;
+  integrator.updateState(t, dispT, mesh);
 } // testUpdateState
 
 // ----------------------------------------------------------------------
@@ -152,7 +153,8 @@
 
   const ALE::Obj<real_section_type>& residual = fields.getReal("residual");
   CPPUNIT_ASSERT(!residual.isNull());
-  integrator.integrateResidual(residual, &fields, mesh);
+  const double t = 1.0;
+  integrator.integrateResidual(residual, t, &fields, mesh);
 
   const double* valsE = _data->valsResidual;
   const int sizeE = _data->spaceDim * _data->numVertices;
@@ -190,7 +192,8 @@
   PetscErrorCode err = MeshCreateMatrix(mesh, dispTpdt, MATMPIBAIJ, &jacobian);
   CPPUNIT_ASSERT(0 == err);
 
-  integrator.integrateJacobian(&jacobian, &fields, mesh);
+  const double t = 1.0;
+  integrator.integrateJacobian(&jacobian, t, &fields, mesh);
   CPPUNIT_ASSERT_EQUAL(false, integrator.needNewJacobian());
 
   err = MatAssemblyBegin(jacobian, MAT_FINAL_ASSEMBLY);

Modified: short/3D/PyLith/trunk/unittests/libtests/feassemble/TestElasticityImplicit.cc
===================================================================
--- short/3D/PyLith/trunk/unittests/libtests/feassemble/TestElasticityImplicit.cc	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/libtests/feassemble/TestElasticityImplicit.cc	2007-06-13 20:26:23 UTC (rev 7214)
@@ -136,7 +136,8 @@
   const ALE::Obj<real_section_type>& dispTBctpdt = 
     fields.getReal("dispTBctpdt");
   CPPUNIT_ASSERT(!dispTBctpdt.isNull());
-  integrator.updateState(dispTBctpdt, mesh);
+  const double t = 1.0;
+  integrator.updateState(t, dispTBctpdt, mesh);
 } // testUpdateState
 
 // ----------------------------------------------------------------------
@@ -153,7 +154,8 @@
 
   const ALE::Obj<real_section_type>& residual = fields.getReal("residual");
   CPPUNIT_ASSERT(!residual.isNull());
-  integrator.integrateResidual(residual, &fields, mesh);
+  const double t = 1.0;
+  integrator.integrateResidual(residual, t, &fields, mesh);
 
   const double* valsE = _data->valsResidual;
   const int sizeE = _data->spaceDim * _data->numVertices;
@@ -191,7 +193,8 @@
   PetscErrorCode err = MeshCreateMatrix(mesh, dispTBctpdt, MATMPIBAIJ, &jacobian);
   CPPUNIT_ASSERT(0 == err);
 
-  integrator.integrateJacobian(&jacobian, &fields, mesh);
+  const double t = 1.0;
+  integrator.integrateJacobian(&jacobian, t, &fields, mesh);
   CPPUNIT_ASSERT_EQUAL(false, integrator.needNewJacobian());
 
   err = MatAssemblyBegin(jacobian, MAT_FINAL_ASSEMBLY);

Modified: short/3D/PyLith/trunk/unittests/pytests/faults/TestFaultCohesiveKin.py
===================================================================
--- short/3D/PyLith/trunk/unittests/pytests/faults/TestFaultCohesiveKin.py	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/pytests/faults/TestFaultCohesiveKin.py	2007-06-13 20:26:23 UTC (rev 7214)
@@ -19,6 +19,7 @@
 from pylith.faults.FaultCohesiveKin import FaultCohesiveKin
 
 from spatialdata.geocoords.CSCart import CSCart
+from pyre.units.time import second
 
 # ----------------------------------------------------------------------
 class TestFaultCohesiveKin(unittest.TestCase):
@@ -36,16 +37,6 @@
     return
     
 
-  def test_implementsConstraint(self):
-    """
-    Test to make sure FaultCohesiveKin satisfies constraint requirements.
-    """
-    fault = FaultCohesiveKin()
-    from pylith.feassemble.Constraint import implementsConstraint
-    self.assertTrue(implementsConstraint(fault))
-    return
-    
-
   def test_constructor(self):
     """
     Test constructor.
@@ -139,7 +130,8 @@
     (mesh, fault, fields) = self._initialize()
 
     residual = fields.getReal("residual")
-    fault.integrateResidual(residual, fields)
+    t = 1.0*second
+    fault.integrateResidual(residual, t, fields)
 
     # We should really add something here to check to make sure things
     # actually initialized correctly    
@@ -158,7 +150,8 @@
     jacobian = mesh.createMatrix(fields.getReal("residual"))
     import pylith.utils.petsc as petsc
     petsc.mat_setzero(jacobian)
-    fault.integrateJacobian(jacobian, fields)
+    t = 1.0*second
+    fault.integrateJacobian(jacobian, t, fields)
 
     # We should really add something here to check to make sure things
     # actually initialized correctly    
@@ -175,70 +168,14 @@
     (mesh, fault, fields) = self._initialize()
 
     disp = fields.getReal("dispT")
-    fault.updateState(disp)
+    t = 1.0*second
+    fault.updateState(t, disp)
 
     # We should really add something here to check to make sure things
     # actually initialized correctly    
     return
   
 
-  def test_setConstraintSizes(self):
-    """
-    Test setConstraintSizes().
-
-    WARNING: This is not a rigorous test of setConstraintSizes() because we
-    don't verify the results.
-    """
-    (mesh, fault, fields) = self._initialize()
-
-    disp = fields.getReal("dispT")
-    fault.setConstraintSizes(disp)
-
-    # We should really add something here to check to make sure things
-    # actually initialized correctly    
-    return
-
-
-  def test_setConstraints(self):
-    """
-    Test setConstraints().
-
-    WARNING: This is not a rigorous test of setConstraints() because we
-    don't verify the results.
-    """
-    (mesh, fault, fields) = self._initialize()
-
-    disp = fields.getReal("dispT")
-    fault.setConstraintSizes(disp)
-    mesh.allocateRealSection(disp)
-    fault.setConstraints(disp)
-
-    # We should really add something here to check to make sure things
-    # actually initialized correctly    
-    return
-
-
-  def test_setField(self):
-    """
-    Test setField().
-
-    WARNING: This is not a rigorous test of setField() because we
-    don't verify the results.
-    """
-    (mesh, fault, fields) = self._initialize()
-
-    disp = fields.getReal("dispT")
-    fault.setConstraintSizes(disp)
-    mesh.allocateRealSection(disp)
-    from pyre.units.time import second
-    t = 1.0*second
-    fault.setField(t, disp)
-
-    # We should really add something here to check to make sure things
-    # actually initialized correctly    
-    return
-
-
   def test_finalize(self):
     """
     Test finalize().
@@ -329,11 +266,8 @@
     from pylith.topology.FieldsManager import FieldsManager
     fields = FieldsManager(mesh)
     fields.addReal("residual")
-    fields.addReal("dispTpdt")
     fields.addReal("dispT")
-    fields.addReal("dispTmdt")
     fields.solutionField("dispT");
-    fields.createHistory(["dispTpdt", "dispT", "dispTmdt"])
     fields.setFiberDimension("residual", cs.spaceDim)
     fields.allocate("residual")
     fields.copyLayout("residual")

Modified: short/3D/PyLith/trunk/unittests/pytests/feassemble/TestElasticityExplicit.py
===================================================================
--- short/3D/PyLith/trunk/unittests/pytests/feassemble/TestElasticityExplicit.py	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/pytests/feassemble/TestElasticityExplicit.py	2007-06-13 20:26:23 UTC (rev 7214)
@@ -18,6 +18,7 @@
 from pylith.feassemble.ElasticityExplicit import ElasticityExplicit
 
 from spatialdata.geocoords.CSCart import CSCart
+from pyre.units.time import second
 
 # ----------------------------------------------------------------------
 class TestElasticityExplicit(unittest.TestCase):
@@ -126,8 +127,10 @@
     (mesh, integrator, fields) = self._initialize()
 
     residual = fields.getReal("residual")
-    integrator.integrateResidual(residual, fields)
 
+    t = 0.45*second
+    integrator.integrateResidual(residual, t, fields)
+
     # We should really add something here to check to make sure things
     # actually initialized correctly    
     return
@@ -145,7 +148,8 @@
     jacobian = mesh.createMatrix(fields.getReal("residual"))
     import pylith.utils.petsc as petsc
     petsc.mat_setzero(jacobian)
-    integrator.integrateJacobian(jacobian, fields)
+    t = 0.145*second
+    integrator.integrateJacobian(jacobian, t, fields)
 
     # We should really add something here to check to make sure things
     # actually initialized correctly    
@@ -162,7 +166,8 @@
     (mesh, integrator, fields) = self._initialize()
 
     dispT = fields.getReal("dispT")
-    integrator.updateState(dispT)
+    t = 3.45*second
+    integrator.updateState(t, dispT)
 
     # We should really add something here to check to make sure things
     # actually initialized correctly    

Modified: short/3D/PyLith/trunk/unittests/pytests/feassemble/TestElasticityImplicit.py
===================================================================
--- short/3D/PyLith/trunk/unittests/pytests/feassemble/TestElasticityImplicit.py	2007-06-13 20:04:14 UTC (rev 7213)
+++ short/3D/PyLith/trunk/unittests/pytests/feassemble/TestElasticityImplicit.py	2007-06-13 20:26:23 UTC (rev 7214)
@@ -18,6 +18,7 @@
 from pylith.feassemble.ElasticityImplicit import ElasticityImplicit
 
 from spatialdata.geocoords.CSCart import CSCart
+from pyre.units.time import year
 
 # ----------------------------------------------------------------------
 class TestElasticityImplicit(unittest.TestCase):
@@ -126,7 +127,8 @@
     (mesh, integrator, fields) = self._initialize()
 
     residual = fields.getReal("residual")
-    integrator.integrateResidual(residual, fields)
+    t = 3.4*year
+    integrator.integrateResidual(residual, t, fields)
 
     # We should really add something here to check to make sure things
     # actually initialized correctly    
@@ -145,7 +147,8 @@
     jacobian = mesh.createMatrix(fields.getReal("residual"))
     import pylith.utils.petsc as petsc
     petsc.mat_setzero(jacobian)
-    integrator.integrateJacobian(jacobian, fields)
+    t = 7.3*year
+    integrator.integrateJacobian(jacobian, t, fields)
 
     # We should really add something here to check to make sure things
     # actually initialized correctly    
@@ -162,7 +165,8 @@
     (mesh, integrator, fields) = self._initialize()
 
     dispTBctpdt = fields.getReal("dispTBctpdt")
-    integrator.updateState(dispTBctpdt)
+    t = 0.27*year
+    integrator.updateState(t, dispTBctpdt)
 
     # We should really add something here to check to make sure things
     # actually initialized correctly    



More information about the cig-commits mailing list