[cig-commits] r18696 - in short/3D/PyLith/branches/v1.6-stable: . libsrc/pylith/faults

brad at geodynamics.org brad at geodynamics.org
Wed Jul 6 09:44:37 PDT 2011


Author: brad
Date: 2011-07-06 09:44:37 -0700 (Wed, 06 Jul 2011)
New Revision: 18696

Modified:
   short/3D/PyLith/branches/v1.6-stable/TODO
   short/3D/PyLith/branches/v1.6-stable/libsrc/pylith/faults/FaultCohesiveKin.cc
   short/3D/PyLith/branches/v1.6-stable/libsrc/pylith/faults/FaultCohesiveLagrange.cc
Log:
Fixed bug in getting fault rupture info with multiple ruptures. Name of rupture left off field name.

Modified: short/3D/PyLith/branches/v1.6-stable/TODO
===================================================================
--- short/3D/PyLith/branches/v1.6-stable/TODO	2011-07-06 16:41:18 UTC (rev 18695)
+++ short/3D/PyLith/branches/v1.6-stable/TODO	2011-07-06 16:44:37 UTC (rev 18696)
@@ -1,3 +1,22 @@
+v1.6.1 changes
+
+Examples
+  3d/hex8
+    step18
+    step19
+  2d/subduction
+    updated geometry.jou file to use Id()
+  meshing/surf_nurbs
+    names of journal files
+    use of nonstandard shell utilities
+    sat versus sab ACIS files
+  greenfns
+    errors when trying to run
+
+Manual
+  tractions - cell_info_fields is out of date [now time dependent]
+
+
 ======================================================================
 CURRENT ISSUES/PRIORITIES (1.7.0)
 ======================================================================

Modified: short/3D/PyLith/branches/v1.6-stable/libsrc/pylith/faults/FaultCohesiveKin.cc
===================================================================
--- short/3D/PyLith/branches/v1.6-stable/libsrc/pylith/faults/FaultCohesiveKin.cc	2011-07-06 16:41:18 UTC (rev 18695)
+++ short/3D/PyLith/branches/v1.6-stable/libsrc/pylith/faults/FaultCohesiveKin.cc	2011-07-06 16:44:37 UTC (rev 18696)
@@ -219,14 +219,36 @@
 
     const srcs_type::const_iterator s_iter = _eqSrcs.find(value);
     assert(s_iter != _eqSrcs.end());
-    return s_iter->second->finalSlip();
 
+    // Need to append name of rupture to final slip label. Because
+    // Field is const, we use a buffer.
+    _allocateBufferVectorField();
+    topology::Field<topology::SubMesh>& buffer =
+        _fields->get("buffer (vector)");
+    buffer.copy(s_iter->second->finalSlip());
+    assert(value.length() > 0);
+    const std::string& label = std::string("final_slip_") + std::string(value);
+    buffer.label(label.c_str());
+
+    return buffer;
+
   } else if (0 == strncasecmp("slip_time_X", name, timeStrLen)) {
     const std::string value = std::string(name).substr(timeStrLen + 1);
     const srcs_type::const_iterator s_iter = _eqSrcs.find(value);
     assert(s_iter != _eqSrcs.end());
-    return s_iter->second->slipTime();
 
+    // Need to append name of rupture to final slip label. Because
+    // Field is const, we use a buffer.
+    _allocateBufferScalarField();
+    topology::Field<topology::SubMesh>& buffer =
+        _fields->get("buffer (scalar)");
+    buffer.copy(s_iter->second->slipTime());
+    assert(value.length() > 0);
+    const std::string& label = std::string("slip_time_") + std::string(value);
+    buffer.label(label.c_str());
+
+    return buffer;
+
   } else if (0 == strcasecmp("traction_change", name)) {
     assert(0 != fields);
     const topology::Field<topology::Mesh>& dispT = fields->get("disp(t)");

Modified: short/3D/PyLith/branches/v1.6-stable/libsrc/pylith/faults/FaultCohesiveLagrange.cc
===================================================================
--- short/3D/PyLith/branches/v1.6-stable/libsrc/pylith/faults/FaultCohesiveLagrange.cc	2011-07-06 16:41:18 UTC (rev 18695)
+++ short/3D/PyLith/branches/v1.6-stable/libsrc/pylith/faults/FaultCohesiveLagrange.cc	2011-07-06 16:44:37 UTC (rev 18696)
@@ -1826,6 +1826,7 @@
   topology::Field<topology::SubMesh>& area = _fields->get("area");
   const topology::Field<topology::SubMesh>& slip = _fields->get("slip");
   area.newSection(slip, 1);
+  area.vectorFieldType(topology::FieldBase::SCALAR);
   area.allocate();
   area.zero();
   const ALE::Obj<RealSection>& areaSection = area.section();



More information about the CIG-COMMITS mailing list