1
Textbooks treat black body radiation as radiation in thermal equilibrium with its environment (more specifically - with a black body): Planck's formula is essentially derived from the partition function $$ \hat{\rho}=Z^{-1}e^{-\beta H_{ph}}, Z=tr[e^{-\beta H_{ph}}]\\ H_{ph}=\sum_{\mathbf{k},\lamb...