Extracting Information about the BandstructureΒΆ

To ensure that only the scattering events that follow the law of energy conservation are accounted for, the energy necessary for an electron and holes to move to and from the conduction and valence band must be examined.

As the Fermi level is the highest energy of a compound at 0 K, we know that the accumulation of the fermi-dirac density function and the density of states up to this level will yield the valence electrons of the compound.


Fermi-Dirac Function and Integration Function

def fermi_step(e, ef):
      val = (e-ef)/kT
      if (val > 100):
             return 0
      elif (val < -100):
             return 1
      return (1.0/(1.0+math.exp(val)))
      else:
             emax = Fermi

def fermi_integrate(num_kpts, num_bnds, Ef, set_low=None, set_high=None):
      sumq = 0.0
      chunk = 1.0/num_kpts
      for i in range(num_bnds):
              for j in range(num_kpts):
                     if (set_low != None and array[i][j] < set_low):
                             continue
                     if (set_high != None and array[i][j] > set_high):
                             continue
                     E = array[i][j]
                     sumq = sumq + fermi_step(E, Ef)*2.0*chunk
                     if (E >= (Ef + 5*kT)):
                             return sumq
      return sumq

The input files are used to find the number of valence electrons and a bisection search is used to locate the energy closest to the Fermi level.

Bisection Search

for run in range(50):
      Fermi = 0.5*(emin+emax)
      sumq = 0.0
      sumq = fermi_integrate(num_kpts, num_bnds, Fermi)
      if (abs(sumq-val_electrons) < error):
             break
      elif (sumq < val_electrons):
             emin = Fermi
      else:
             emax = Fermi

Finding the number of electrons above this level yields the electrons in the conduction band and above. This number, added to and subtracted from the valence electrons, provides the values for the energy necessary to go to the conduction band and valence band respectively. These energies again are found through integration and bisection search.