ispercolating#

ispercolating(network, inlets, outlets)[source]#

Determines if a percolating cluster exists in the network spanning the given inlet and outlet nodes

Parameters:
  • conns (array_like) – An N x 2 array connections. If two connected sites are both occupied they are part of the same cluster, as is the bond connecting them.

  • occupied (array_like) – A boolean array with True values indicating if a bond or site is occupied. If the length of this array is equal to the number of bonds (i.e. conns.shape[0]) then bond percolation is assumed, otherwise site percolation is assumed.

  • inlets (array_like) – An array of indices indicating which nodes are part of the inlets

  • outlets (array_like) – An array of indices indicating which nodes are part of the outlets