reservoirflow.grids.RegularCartesian.set_prop#
- RegularCartesian.set_prop(name, value, id=None, coords=None)#
Set a property in all cells or a selected cell.
This method is used to populate properties values based on grid shape. By default, values are populated in a flatten array which can then be reshaped based on fshape.
- Parameters:
name (str) – property name as a string from props attribute keys.
value (int, float, array-like) – property value. In case of an array, the shape should be equal to grid.shape with boundaries. Vales should be in natural order.
id (int, iterable of int) – cell id based on natural order as int. For multiple cells, list of int [id,id,..] or tuple of int (id,id,…). If None, then all cells are selected. NotFullyImplemented.
coords (iterable of int, iterable of tuples of int, by default) – None 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),..). If None, then all cells are selected. NotFullyImplemented.
- Raises:
ValueError – Property name is unknown or not defined.