openmc.CylindricalMesh¶
- class openmc.CylindricalMesh(mesh_id=None, name='')[source]¶
A 3D cylindrical mesh
- Parameters
- Variables
id (int) – Unique identifier for the mesh
name (str) – Name of the mesh
dimension (Iterable of int) – The number of mesh cells in each direction.
n_dimension (int) – Number of mesh dimensions (always 3 for a CylindricalMesh).
r_grid (Iterable of float) – Mesh boundary points along the r-axis. Requirement is r >= 0.
phi_grid (Iterable of float) – Mesh boundary points along the phi-axis. The default value is [0, 2π], i.e. the full phi range.
z_grid (Iterable of float) – Mesh boundary points along the z-axis.
indices (Iterable of tuple) – An iterable of mesh indices for each mesh element, e.g. [(1, 1, 1), (2, 1, 1), …]
- calc_mesh_volumes()[source]¶
Return Volumes for every mesh cell
- Returns
volumes – Volumes
- Return type
Iterable of float
- classmethod from_hdf5(group)[source]¶
Create mesh from HDF5 group
- Parameters
group (h5py.Group) – Group in HDF5 file
- Returns
Instance of a MeshBase subclass
- Return type
openmc.MeshBase
- classmethod from_xml_element(elem)[source]¶
Generate a cylindrical mesh from an XML element
- Parameters
elem (xml.etree.ElementTree.Element) – XML element
- Returns
Cylindrical mesh object
- Return type