SimPEG.utils.model_builder.get_indices_sphere#

SimPEG.utils.model_builder.get_indices_sphere(center, radius, cell_centers)[source]#

Get indices for cells whose centers lie inside a sphere

Parameters:
center(dim) numpy.ndarray

Location of the center of the sphere

radiusfloat

Radius of the sphere

cell_centers(n_cells, dim) numpy.ndarray or discretize.base.BaseMesh

A mesh or its gridded cell center locations

Returns:
tuple of int

Indices of the cells whose center lie within the specified sphere