[MOAB-dev] r5888 - in MOAB/trunk: src/io tools/mbcoupler

iulian at mcs.anl.gov iulian at mcs.anl.gov
Wed Nov 28 12:51:07 CST 2012


Author: iulian
Date: 2012-11-28 12:51:07 -0600 (Wed, 28 Nov 2012)
New Revision: 5888

Modified:
   MOAB/trunk/src/io/ReadNC.cpp
   MOAB/trunk/tools/mbcoupler/Coupler.cpp
Log:
put in the partition set only nodes connected to the quads


Modified: MOAB/trunk/src/io/ReadNC.cpp
===================================================================
--- MOAB/trunk/src/io/ReadNC.cpp	2012-11-28 01:37:26 UTC (rev 5887)
+++ MOAB/trunk/src/io/ReadNC.cpp	2012-11-28 18:51:07 UTC (rev 5888)
@@ -238,13 +238,17 @@
     rval = mbImpl->create_meshset(MESHSET_SET, partn_set);
     ERRORR(rval, "Trouble creating partition set.");
 
+    rval = mbImpl->add_entities(partn_set,quads);
+    ERRORR(rval, "Couldn't add new quads to partition set.");
+
     Range verts;
-    mbImpl->get_entities_by_type(0, MBVERTEX, verts);
-    mbImpl->add_entities(partn_set,quads);
-    mbImpl->add_entities(partn_set,verts);
+    rval = mbImpl->get_connectivity(quads, verts);
+    ERRORR(rval, "Couldn't get verts of quads");
+
+    rval = mbImpl->add_entities(partn_set,verts);
+    ERRORR(rval, "Couldn't add new verts to partition set.");
+
     myPcomm->partition_sets().insert(partn_set);
-    rval = mbImpl->add_entities(partn_set, quads);
-    ERRORR(rval, "Couldn't add new quads to partition set.");
 
 #if  0
     if (ucdMesh && !noVars)

Modified: MOAB/trunk/tools/mbcoupler/Coupler.cpp
===================================================================
--- MOAB/trunk/tools/mbcoupler/Coupler.cpp	2012-11-28 01:37:26 UTC (rev 5887)
+++ MOAB/trunk/tools/mbcoupler/Coupler.cpp	2012-11-28 18:51:07 UTC (rev 5888)
@@ -638,7 +638,7 @@
     // find natural coordinates of point in element(s) in that leaf
   CartVect tmp_nat_coords; 
   Range range_leaf;
-  result = mbImpl->get_entities_by_dimension(closest_leaf, 3, range_leaf, false);
+  result = mbImpl->get_entities_by_dimension(closest_leaf, max_dim, range_leaf, false);
   if(result != MB_SUCCESS) std::cout << "Problem getting leaf in a range" << std::endl;
 
   // loop over the range_leaf



More information about the moab-dev mailing list