imbibition_fft

imbibition_fft(im, inlets=None, outlets=None, residual=None, steps=None, smooth=True)[source]

Performs a distance transform based imbibition simulation using fft-based convolution for both the erosion and dilation steps

Parameters:
  • im (ndarray) – The boolean image of the void space on which to perform the simulation

  • inlets (ndarray (optional)) – A boolean array with True values indicating the inlet locations for the invading (wetting) fluid. If not provided then access limitations will not be applied, meaning that the invading fluid can appear anywhere within the domain.

  • outlets (ndarray (optional)) – A boolean array with True values indicating the outlet locations through which defending (non-wetting) phase would exit the domain. If not provided then trapping of the non-wetting phase is ignored.

  • steps (scalar or array_like) – A list of which sphere sizes to invade. If None (default) then each unique integer value in the distance transform is used. If a scalar then a list of steps is generated from steps to 1.

  • smooth (boolean) – If True (default) then the spheres are drawn without any single voxel protrusions on the faces.

Returns:

results – An object with the following attributes:

———– —————————————————————- Attribute Description ———– —————————————————————- im_seq The sequence map indicating the sequence or step number at which

each voxels was first invaded.

im_size The size map indicating the size of the sphere being drawn

when each voxel was first invaded.

———– —————————————————————-

Return type:

Dataclass-like object