from math import *
- # Definition of environnement variables
+ # Definition of environment variables
spaceDimension = 3
N = 4
nbOfNodes = N*N*N
myCoords = DataArrayDouble.New()
myCoords.setValues(coordinates,nbOfNodes,3)
mesh.setCoords(myCoords)
- mesh.checkCoherency()
+ mesh.checkConsistencyLight()
print "6 ********************"
# Extraction of surfacic meshing
mesh2D = mesh.buildFacePartOfMySelfNode(nodes,True)
#print mesh2D
mesh2D.setName("3Dcube")
- mesh2D.checkCoherency()
+ mesh2D.checkConsistencyLight()
print "7 ********************"
# Creation of field : with following definition
field = MEDCouplingFieldDouble.New(ON_CELLS)
field.setMesh(mesh)
field.setName("field")
- field.setNature(Integral)
+ field.setNature(ExtensiveMaximum)
# Computing and setting field values
myCoords=DataArrayDouble.New()
sampleTab=[]
- bar = mesh.getBarycenterAndOwner()
+ bar = mesh.computeCellCenterOfMass()
print bar.getNbOfElems()
for i in range(nbOfCells):
x = bar.getIJ(i+1,1)
fBF = MEDCouplingFieldDouble.New(ON_CELLS)
fBF.setMesh(mesh2D)
fBF.setName("fieldBottomFace")
- fBF.setNature(Integral)
+ fBF.setNature(ExtensiveMaximum)
Cval = 10.
myCoords2D=DataArrayDouble.New()
sampleTab=[]