Salome HOME
Merge branch 'master' of https://codev-tuleap.cea.fr/plugins/git/salome/medcoupling
[tools/medcoupling.git] / doc / tutorial / atestMEDCouplingDataArray1.rst
index f35e47858ab46f78e53500d0c9f4e2da509d32d2..6af7ac16d02ef595a58fdd2f68bb3c4001d45d85 100644 (file)
@@ -35,7 +35,7 @@ Playing with regular hexagons using DataArrayDouble
        a = cI.deltaShiftIndex()
        b = a - 1
        myNewNbOfTuples = oldNbOfTuples - sum(b.getValues())
-       o2n, newNbOfTuples = mc.DataArrayInt.BuildOld2NewArrayFromSurjectiveFormat2(oldNbOfTuples,c,cI)
+       o2n, newNbOfTuples = mc.DataArrayInt.ConvertIndexArrayToO2N(oldNbOfTuples,c,cI)
        print "Have I got the right number of tuples?"
        print "myNewNbOfTuples = %d, newNbOfTuples = %d" % (myNewNbOfTuples, newNbOfTuples)
        assert(myNewNbOfTuples == newNbOfTuples)
@@ -56,9 +56,8 @@ Playing with regular hexagons using DataArrayDouble
                cell_connec = o2n[6*i:6*(i+1)]
                m.insertNextCell(mc.NORM_POLYGON, cell_connec.getValues())
                pass
-       m.finishInsertingCells()
        # Check that everything is coherent (will throw if not)
-       m.checkCoherency()
+       m.checkConsistencyLight()
        # Write the result into a VTU file that can be read with ParaView
        m.writeVTK("My7hexagons.vtu")