Thermodynamical functions (quanguru.QuantumToolbox.thermodynamics
)#
Contains methods to calculate certain quantities used in thermal states, open systems, and quantum thermodynamics. TODO update docstring examples and write some tests after writing some tutorials
Functions#
|
Calculates average excitation number \(\bar{n}(T) := 1/(e^{\hbar \omega / k_{b}T} - 1)\) of a bosonic field with frequeny \(\omega\) at a temperature T. |
|
Returns the polarisation \(\langle\hat{\sigma}_{z}\rangle := P_{1} - P_{0}\) of a qubit with frequency \(\omega\) in a thermal state of temperature T. |
|
Calculates the heat current \(\mathcal{J}:=Tr(\dot{\rho}\hat{H})\), where \(\dot{\rho} := \hat{\mathcal{L}}\rho\) is obtained using the given Lindbladian \(\hat{\mathcal{L}}\). |
Function Name |
Docstrings |
Examples |
Unit Tests |
Tutorials |
---|---|---|---|---|
nBarThermal |
✅ |
❌ |
❌ |
❌ |
qubitPolarisation |
✅ |
❌ |
❌ |
❌ |
HeatCurrent |
✅ |
❌ |
❌ |
❌ |
- nBarThermal(angFreq: float, temp: float, hbar: float = 1.0, kb: float = 1.0) float [source]#
Calculates average excitation number \(\bar{n}(T) := 1/(e^{\hbar \omega / k_{b}T} - 1)\) of a bosonic field with frequeny \(\omega\) at a temperature T. Boltzmann and reduced Planck constants are by default \(\hbar = k_{B} = 1\). TODO Physical constants’ default values should be connected to simUnits.
- Parameters:
angFreq (float) – (angular) frequency of the bosonic field
temp (float) – temperature
hbar (float) – reduced Planck’s constant
kb (float) – Boltzmann constant
- Returns:
Average excitation number
- Return type:
float
- Raises:
ValueError – If average number is infinite.
Examples
# TODO
- qubitPolarisation(freq: float, temp: float) float [source]#
Returns the polarisation \(\langle\hat{\sigma}_{z}\rangle := P_{1} - P_{0}\) of a qubit with frequency \(\omega\) in a thermal state of temperature T. \(P_{1}\) and \(P_{0}\) are excited and ground state populations satisfying \(P_{1} + P_{0} = 1\), and thermal state populations also satisfy \(\frac{P_{1}}{P_{0}} := e^{\omega/T}\).
- Parameters:
freq (float) – frequency of the qubit
temp (float) – temperature of the qubit
- Returns:
qubit polarisation, i.e. difference betwennn ground and excited state populations.
- Return type:
float
Examples
# TODO
- HeatCurrent(Lindbladian: spmatrix | ndarray, Hamiltonian: spmatrix | ndarray, denMat: spmatrix | ndarray) float [source]#
Calculates the heat current \(\mathcal{J}:=Tr(\dot{\rho}\hat{H})\), where \(\dot{\rho} := \hat{\mathcal{L}}\rho\) is obtained using the given Lindbladian \(\hat{\mathcal{L}}\). Here, \(\hat{H}\) is the system Hamiltonian, and the time derivative of density matrix is \(\dot{\rho}mathcal{L}\). It does not strictly speaking have to be a Lindbladian but any combination of terms from a Liouvillian. Disclaimer: physical meaning of those terms is not and cannot be interpreted by this function. TODO Write a bit of the theory here to better explain this function.
- Parameters:
Lindbladian (Matrix) – a Lindbladian or any combination of terms from a Liouvillian
Hamiltonian (Matrix) – Hamiltonian of the system
denMat (Matrix) – Density matrix (state) of the system
- Returns:
Heat current
- Return type:
float
Examples
# TODO