Base Library (ibei)

The Bose-Einstein integral appears when calculating quantities pertaining to photons. It is used to derive the Stefan-Boltzmann law, and it also appears when calculating the detailed balance limit of a solar cell and other devices.

The ibei module provides functionality to calculate various forms of the Bose-Einstein integral, along with well-known models of photovoltaic devices. The BEI class implements the full, upper-incomplete, and lower-incomplete Bose-Einstein integrals and is the main feature of this module.

Notes

Arguments passed to the constructor of the BEI class correspond to symbols in the expressions given below. The correspondence is noted in the “Parameters” section of the class docstring.

The (full) Bose-Einstein integral is denoted by \(G_{m} (T, \mu)\) and given by

\[G_{m}(T, \mu) = \frac{2 \pi}{h^{3} c^{2}} \int_{0}^{\infty} E^{m} \frac{1}{\exp(\frac{E-\mu}{kT}) - 1} dE\]

(a glossary of symbols is given at the end of the docstring). The full Bose-Einstein integral can be expressed as a sum of an upper-incomplete (denoted \(G_{m} (E_{g}, T, \mu)\)) and lower-incomplete integral (denoted \(g_{m} (E_{g}, T, \mu)\))

\[G_{m} (T, \mu) = G_{m} (E_{g}, T, \mu) + g_{m} (E_{g}, T, \mu)\]

where

\[G_{m} (E_{g}, T, \mu) = \frac{2 \pi}{h^{3} c^{2}} \int_{E_{g}}^{\infty} E^{m} \frac{1}{\exp(\frac{E-\mu}{kT}) - 1} dE\]

and

\[g_{m} (E_{g}, T, \mu) = \frac{2 \pi}{h^{3} c^{2}} \int_{0}^{E_{g}} E^{m} \frac{1}{\exp(\frac{E-\mu}{kT}) - 1} dE\]

This module provides functionality to compute each integral given above via the BEI class.

Symbols used in the above equations are given as follows.

\(h\): Planck’s constant
\(c\): Speed of light
\(\mu\): Chemical potential of photons
\(E\): Energy of photons
\(T\): Absolute temperature of the radiator
\(k\): Boltzmann’s constant
class ibei.BEI(order, energy_bound, temperature, chemical_potential=0.0)

Bases: object

Bose-Einstein integrals

Parameters
  • order (int) – Order of Bose-Einstein integral. Corresponds to \(m\).

  • energy_bound (Union[float, astropy.units.quantity.Quantity]) – Upper or lower bound of integral depending on which integration method is called. Corresponds to \(E_{g}\).

  • temperature (Union[float, astropy.units.quantity.Quantity]) – Absolute temperature of photon ensemble. Corresponds to \(T\).

  • chemical_potential (Union[float, astropy.units.quantity.Quantity]) – Chemical potential of photon ensemble. Corresponds to \(\mu\).

order

Same as constructor parameter.

Type

int

energy_bound

Same as constructor parameter.

Type

astropy.units.Quantity[astropy.units.eV]

temperature

Same as constructor parameter.

Type

astropy.units.Quantity[astropy.units.K]

chemical_potential

Same as constructor parameter.

Type

astropy.units.Quantity[astropy.units.eV]

Raises
  • TypeError – If non-scalar arguments are passed to the constructor.

  • TypeError – If order param not int type or not coercible to int without truncation.

  • ValueError – If energy_bound param < 0

  • ValueError – If temperature param <= 0

  • ValueError – If chemical_potential param < 0

Notes

The constructor parameters given in the “Parameters” section correspond to symbols in equations that give the full, upper-incomplete, and lower-incomplete Bose-Einstein integral. A brief overview of the equations can be found in the ibei docstring, and a longer explanation can be found in the online documentation of this module 1.

Instance attributes of BEI objects are of type astropy.units.Quantity. Computations involving units can be tricky, and the use of Quantity objects throughout will expose arithmetic implementation errors and unit conversion errors.

References

1

https://ibei.readthedocs.io/

lower() Quantity

Lower-incomplete Bose-Einstein integral.

upper() Quantity

Upper-incomplete Bose-Einstein integral.

full() Quantity

Full Bose-Einstein integral.

photon_flux() Quantity

Number of photons radiated per unit time per unit area.

Notes

This convenience method is a special case of BEI.full(). This method assumes the value of order is 2.

radiant_power_flux() Quantity

Energy radiated per unit time per unit area.

Notes

This convenience method implements the Stefan-Boltzmann law and is a special case of the BEI.full(). This method assumes the value of order is 3.

property kT: Quantity

Product of Boltzmann’s constant and temperature.

property reduced_energy_bound: Quantity

energy_bound divided by kT.

property reduced_chemical_potential: Quantity

chemical_potential divided by kT.

property prefactor: Quantity

Factor preceding Bose-Einstein integral integration result.

Note

For order equal to 3, this factor is NOT equal to the Stefan-Boltzmann constant because is missing the Riemann-Zeta term.

class ibei.SQSolarcell(bandgap, solar_temperature=5772.0)

Bases: object

Shockley-Queisser single-junction solar cell

This class implements a solar cell as described by Shockley and Queisser [SQ61].

Parameters
  • bandgap (Union[float, astropy.units.quantity.Quantity]) – Bandgap of solar cell material.

  • solar_temperature (Union[float, astropy.units.quantity.Quantity]) – Temperature of the sun.

bandgap

Same as constructor parameter.

Type

astropy.units.Quantity[astropy.units.eV]

solar_temperature

Same as constructor parameter.

Type

astropy.units.Quantity[astropy.units.K]

Raises
  • TypeError – If non-scalar arguments are passed to the constructor.

  • ValueError – If bandgap <= 0

  • ValueError – If solar_temperature <= 0

power_density() Quantity

Solar cell power density

The output power density is calculated according to a slight modification of Shockley & Queisser’s [SQ61] Eq. 2.4.

efficiency() Quantity

Solar cell efficiency

The efficiency is calculated according to Shockley & Queisser’s [SQ61] Eq. 2.8.

class ibei.DeVosSolarcell(bandgap, solar_temperature=5772.0, planetary_temperature=300.0, voltage=0.0)

Bases: SQSolarcell

DeVos model of single-junction solar cell

This class implements a solar cell as described by DeVos [deV92] Ch. 6.

Parameters
  • bandgap (Union[float, astropy.units.quantity.Quantity]) – Bandgap of solar cell material.

  • solar_temperature (Union[float, astropy.units.quantity.Quantity]) – Temperature of the sun.

  • planetary_temperature (Union[float, astropy.units.quantity.Quantity]) – Temperature of planet.

  • voltage (Union[float, astropy.units.quantity.Quantity]) – Voltage across electrodes of device.

bandgap

Same as constructor parameter.

Type

astropy.units.Quantity[astropy.units.eV]

solar_temperature

Same as constructor parameter.

Type

astropy.units.Quantity[astropy.units.K]

planetary_temperature

Same as constructor parameter.

Type

astropy.units.Quantity[astropy.units.K]

voltage

Same as constructor parameter.

Type

astropy.units.Quantity[astropy.units.V]

Raises
  • TypeError – If non-scalar arguments are passed to the constructor.

  • ValueError – If bandgap <= 0

  • ValueError – If solar_temperature <= 0

  • ValueError – If planetary_temperature <= 0

power_density() Quantity

Solar cell power density

The output power density is calculated according to DeVos’s [deV92] Eq. 6.4. Note that this expression assumes fully concentrated sunlight and is therefore not completely general.

efficiency() Quantity

Solar cell efficiency

The efficiency is calculated according to Shockley & Queisser’s [SQ61] Eq. 2.8.