PyFoam.RunDictionary.BlockMesh module

Manipulate a C{blockMeshDict}

class PyFoam.RunDictionary.BlockMesh.BlockMesh(name, backup=False)[source]

Bases: PyFoam.RunDictionary.FileBasis.FileBasisBackup

Represents a C{blockMeshDict}-file

mergeVertices(other)[source]

Merge in the vertexes from another mesh after our own vertexes

normalizePatches()[source]

Rotate patches so that they start with the lowest number vertex

numberVertices(prefix='')[source]

Add comments with the number of the vertex after them :param prefix: a string to add before the number

refineMesh(factors, offset=(0, 0, 0), getContent=False, addOld=True)[source]

Refine the Mesh by multiplying the number of cells in the blocks :param factors: either a scalar to scale in all directions or a tuple with the value for each direction :param offset: an optional tuple for an additionnal offset value for each direction :param getContent: Return the contents instead of writing a fil. Main purpose of this parameter is not to break compatibility with old versions

renumberVertices(other)[source]

Renumber the vertices in the current mesh according to another mesh

stripVertexNumber()[source]

Remove comments after vertices