[cig-commits] r6251 - in short/3D/PyLith/trunk: . libsrc/materials
brad at geodynamics.org
brad at geodynamics.org
Tue Mar 13 16:38:22 PDT 2007
Author: brad
Date: 2007-03-13 16:38:22 -0700 (Tue, 13 Mar 2007)
New Revision: 6251
Modified:
short/3D/PyLith/trunk/TODO
short/3D/PyLith/trunk/libsrc/materials/Material.cc
Log:
Finished implementing material initialization. Now extract cells for material and set fiber dimension only for cells associated with material.
Modified: short/3D/PyLith/trunk/TODO
===================================================================
--- short/3D/PyLith/trunk/TODO 2007-03-13 22:08:54 UTC (rev 6250)
+++ short/3D/PyLith/trunk/TODO 2007-03-13 23:38:22 UTC (rev 6251)
@@ -25,6 +25,7 @@
d. unit tests at Python level
Status: Started on a.
+ Only implement nonlumped and let PETSc "solver" do the lumping.
3. Finish implementing Python Formulation
(e.g., Explicit) with initialization of solid element families.
Modified: short/3D/PyLith/trunk/libsrc/materials/Material.cc
===================================================================
--- short/3D/PyLith/trunk/libsrc/materials/Material.cc 2007-03-13 22:08:54 UTC (rev 6250)
+++ short/3D/PyLith/trunk/libsrc/materials/Material.cc 2007-03-13 23:38:22 UTC (rev 6251)
@@ -75,21 +75,14 @@
mesh->getRealSection("coordinates");
const ALE::Obj<topology_type>& topology = coordinates->getTopology();
const ALE::Obj<topology_type::label_sequence>& cells =
- topology->heightStratum(patch, 0);
+ topology->getLabelStratum(patch, "material-id", _id);
const topology_type::label_sequence::iterator cellsEnd = cells->end();
- // :TODO: Get cells for material only
// Create sections to hold parameters for physical properties
delete _parameters; _parameters = new feassemble::ParameterManager(mesh);
const int numQuadPts = quadrature->numQuadPts();
const int fiberDim = numQuadPts; // number of values in field per cell
- /* :QUESTION: MATT
- *
- * We want to create a section that stores values just for cells in
- * this material, we want to carry around storage for density,
- * etc. for cells not of this material.
- */
const int numParams = _numParameters();
const char** paramNames = _parameterNames();
@@ -99,7 +92,7 @@
for (int iParam=0; iParam < numParams; ++iParam) {
_parameters->addReal(paramNames[iParam]);
paramSections[iParam] = _parameters->getReal(paramNames[iParam]);
- paramSections[iParam]->setFiberDimensionByDepth(patch, 0, fiberDim);
+ paramSections[iParam]->setFiberDimension(patch, cells, fiberDim);
paramSections[iParam]->allocate();
} // for
More information about the cig-commits
mailing list