calc_islands_and_barriers

static ThomasFermi.calc_islands_and_barriers(physics, numerics, n)

Separates n(x) into islands of charge.

Islands / barriers are defined by dividing the x-axis into segments for which n(x) is above / below the cutoff value numerics.island_relative_cutoff * max(n). Islands are defined to be the segments where n(x) is above the cutoff, and barriers are the segments where n(x) is below the cutoff. However, segments bordering the left or right endpoints of physics.x are not included as islands.

Parameters:
  • physics (PhysicsParameters) – The physical device parameters.

  • numerics (NumericsParameters) – Options for numeric calculations.

  • n (ndarray[float]) – A 1D array containing the particle density (in 1/nm).

Returns:

  • islands (ndarray[int]) – An array with shape (num_islands, 2) giving the islands, not including islands bordering the left or right endpoints of physics.x, where islands[i] is a length-2 integer array [begin_index, end_index + 1] giving the indeces of physics.x corresponding to the island.

  • barriers (ndarray[int]) – An array with shape (num_barriers, 2) giving the barriers, where the i-th barrier barriers[i] is a length-2 integer array [begin_index, end_index + 1] giving the indeces of physics.x corresponding to the barrier.

  • all_islands (ndarray[int]) – An array with shape (num_all_islands, 2) giving the islands, including islands bordering the left or right endpoints of physics.x.

  • is_short_circuit (bool) – True if n is above the cutoff threshold everywhere along the x-axis, False otherwise.