reservoirflow.grids.RegularCartesian.get_cell_id#

RegularCartesian.get_cell_id(coords=[], boundary: bool = True)#

Returns cell/cells id based on natural as int/list.

Parameters:
  • coords (tuple of int, tuple of tuples of int) – cell coordinates (i,j,k) as a tuple of int. For multiple cells, tuple of tuples of int as ((i,j,k),(i,j,k),..). Warning: providing an unhashable type (e.g. list, ndarray) is not supported and will cause TypeError.

  • boundary (bool, optional) – include boundary cells.

Returns:

cell id based on natural order as int for a single cell coords or as list of int for multiple cells coords.

Return type:

int/list