[cig-commits] r21517 - short/3D/PyLith/trunk/libsrc/pylith/topology

brad at geodynamics.org brad at geodynamics.org
Tue Mar 12 17:00:36 PDT 2013


Author: brad
Date: 2013-03-12 17:00:35 -0700 (Tue, 12 Mar 2013)
New Revision: 21517

Modified:
   short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorMesh.hh
   short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorMesh.icc
   short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorSubMesh.icc
Log:
Small fixes.

Modified: short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorMesh.hh
===================================================================
--- short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorMesh.hh	2013-03-12 23:05:18 UTC (rev 21516)
+++ short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorMesh.hh	2013-03-13 00:00:35 UTC (rev 21517)
@@ -170,7 +170,7 @@
    * @param mat PETSc matrix.
    * @param field Field associated with matrix layout.
    */
-  MatVisitorMesh(const PetscMat& mat,
+  MatVisitorMesh(const PetscMat mat,
 		 const Field<Mesh>& field);
 
   /// Default destructor

Modified: short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorMesh.icc
===================================================================
--- short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorMesh.icc	2013-03-12 23:05:18 UTC (rev 21516)
+++ short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorMesh.icc	2013-03-13 00:00:35 UTC (rev 21517)
@@ -174,7 +174,6 @@
   clear();
 
   _dm = NULL;
-  _mat = NULL;
   _section = NULL;
 } // destructor
 

Modified: short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorSubMesh.icc
===================================================================
--- short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorSubMesh.icc	2013-03-12 23:05:18 UTC (rev 21516)
+++ short/3D/PyLith/trunk/libsrc/pylith/topology/VisitorSubMesh.icc	2013-03-13 00:00:35 UTC (rev 21517)
@@ -160,17 +160,15 @@
 						       const SubMeshIS& submeshIS) :
   _mat(mat),
   _dm(NULL),
-  _section(NULL),
+  _subsection(NULL),
   _globalSection(NULL),
   _globalSubsection(NULL)
 { // constructor
   _dm = submeshIS.submesh().dmMesh();assert(_dm);
-  _section = field.petscSection();assert(_section);
 
   PetscIS subpointIS = submeshIS.indexSet();
+  PetscSection section = field.petscSection();assert(section);
   PetscSF sf = NULL;
-  PetscSection section = NULL;
-
   PetscErrorCode err;
   err = PetscSectionCreateSubmeshSection(section, subpointIS, &_subsection);CHECK_PETSC_ERROR(err);assert(_subsection);
   err = DMGetPointSF(_dm, &sf);CHECK_PETSC_ERROR(err);assert(sf);
@@ -192,7 +190,7 @@
 // Initialized cached data members.
 inline
 void
-pylith::topology::MatVisitorSubMesh::initialize(const SubMeshIS& submeshIS)
+pylith::topology::MatVisitorSubMesh::initialize(void)
 { // initialize
 } // initialize
 
@@ -252,9 +250,9 @@
 						const InsertMode mode) const
 { // setClosure
   assert(_dm);
-  assert(_section);
-  assert(_localVec);
-  err = DMPlexMatSetClosure(_dm, _subsection, _globalSubsection, _mat, cell, valuesCell, ADD_VALUES);CHECK_PETSC_ERROR(err);
+  assert(_subsection);
+  assert(_globalSubsection);
+  PetscErrorCode err = DMPlexMatSetClosure(_dm, _subsection, _globalSubsection, _mat, cell, valuesCell, ADD_VALUES);CHECK_PETSC_ERROR(err);
 } // setClosure
 
 // ----------------------------------------------------------------------



More information about the CIG-COMMITS mailing list