I was studying the derivation of Planck's Law. But I found confusing texts in different books.
In the book "Quantum Physics of Atoms" by Eisberg and Resnick, it states that Planck considered the cavity radiation to be composed of electromagnetic standing waves and then calculated the number density of those standing waves. He then found the average total energy of all those standing waves by multiplying the possible discrete energies by the weights, using Boltzmann probabilty distribution $P(\epsilon)=\frac{\exp(-\frac{\epsilon}{kT})}{kT}$ and computing the summation to get the Planck's Blackbody distribution. It is written below.
In the book "A Treatise on Heat" by Saha and Srivastava and also in my professor's lecture notes, it states that Planck considered the cavity radiation to be composed of simple harmonic hertzian oscillators and then calculated the number density of those oscillators. He then found the average total energy of all those standing waves by multiplying the possible discrete energies by the weights, using Maxwell probabilty distribution $P(\epsilon)=\exp(-\frac{\epsilon}{kT})$ and computing the same summation to get the Planck's Blackbody distribution. $$N=\sum_{i=1}^\infty N_i$$ $$\bar E=\frac{1}{N}(N_1\cdot\epsilon+N_2\cdot2\epsilon+\ldots)=\frac{\epsilon}{N}\sum_{r=1}^\infty rN_r$$ $$N_r=N_1\exp(-\frac{\epsilon}{kT})$$ In Kenneth Krane's book on Modern Physics, it states the radiation is composed of resonators and that Planck used the Maxwell-Boltzmann probabilty distribution $P(\epsilon)=\frac{N\exp(-\frac{\epsilon}{kT})}{kT}$ for his corresponding calculations.
QUESTION:
All these however correctly yield the same result. So which is the correct assumption regarding the form of radiation in the cavity? Which one did Planck use? And which probability distribution did he use? Are any of the books wrong?
I am eagerly waiting for an answer. Thanks!