What are thermal energy distributions? I am trying to understand the photoelectric-effect deeply. My teacher used the Planck's law and integrated it to deduce the  Stefan-Boltzmann law. He somehow showed some quantum-physical characteristic -- something that intensity did not increase the energy of photon as expected classically but the stopping voltage.
Now let's take a step back. He started with Planck's law and I want to understand how it is connected to other thermal equilibriums such as Bose-Einstein distribution, Fermi-Dirac distribution and Maxwell-Boltzmann distribution.
What are the thermal energy distributions? How to remember them? Some mnemonics? Are they somehow connected? I know BE and FD are the quantum-physical descriptions while MB is a classical approximation but I don't how Planck's law is related to them, how?
Wikipedia about Planck's law

As an energy distribution, it is one of a family of thermal equilibrium distributions which include the Bose–Einstein distribution, the Fermi–Dirac distribution and the Maxwell–Boltzmann distribution.

 A: I just remember $$ \frac{1}{\exp(\beta (E-\mu)) \pm 1}$$
You can work out the sign from the fact that Bose-Einstein distributions can diverge (so they go with the - sign), whereas Fermi-Dirac is bounded (so they go with the + sign). Maxwell-Boltzmann applies to classical systems, so quantum statistics don't matter, so take the limit that the two distributions are the same (so drop the $\pm1$).
These expressions represent the average number of particles occupying a state with energy $E$. The chemical potential $\mu$ is just a knob that lets you adjust the overall density. You can also think of it as (roughly) the energy it takes to add a particle to the system. To find the total number of particles in the system you have to sum this over all of the energy levels. You can use this information to find all kinds of thermal averages. For example:
$$ \text{total energy} = \sum_{\text{all energies}} \left(\text{distribution function}\times\text{number of states with a given energy}\right)$$
This is essentially what is going on in Planck's law, only the sum is left off. Planck's law is the Bose-Einstein distribution (with $\mu=0$ because photons can be freely created and destroyed) multiplied by the number of states with an energy in a small range about $E$. This tells you how much energy there is in the photons with energies in that range.
A: The deduction of the thermal energy distributions are pretty much just Stirling approximation $\ln(x!)=x\ln(x)-x$, Lagrange-multipliers method and a lot of permutations/combinations. You can see it at the bottom.

Thermal energy distributions contain classical models such as Maxwell-Boltzmann statistics and quantum-physical models such as
  Bose-Einstein statistics and Fermi-Dirac statistics.
The "classical" term means models such as Maxwell equations, partial-derivations models, which do not contain the notion about discretization -- a big
  difference to QM models such as Planck's rule $E=hf$ where the energy
  of EM is quantified. 
Light is an example of EM radiation. Maxwell realized this by
  analyzing earlier studies of Weber and Kohlrausch
  here and
  concluded $c_0=\frac 1 {\sqrt{\mu_0 \epsilon_0}}$. A more realistic
  model of light is a non-classical model
here that cannot be
  described with classical mechanism but with quantified electromagnetic
  field and quantum mechanics. Photon is a boson so it obeys
  Bose-Einstein statistics, not the classical approximation ie
  Maxwell-Boltzmann statistics that is only realistic with extreme
  temperatures such as close to absolute zero or very high temperature. 
Facts such as photoelectric effect, X-emission (opposite to photoelectric effect) and Compton-scattering prove the discretization
  of the EM that QM describes. Wave-particle-dualism explains events
  where light acts like a wave and like a particle. This is impossible
  to explain with Maxwell equations. Examples of such events are
  double-slit-experiment and single slit expriment. 
Now the double-slit expriment lead into the realization of
  uncertainty. You cannot see the wave nature at the same time as the
  particle nature. An example of this is Heisenberg's uncertainty
  principle $\Delta p\Delta x \geq \frac{h}{4\pi}$ that means you cannot
  know the location of physical object and and its momentum at the same
  time -- if the $\Delta p$ is close to zero, you have a particle -- and
  if the $\Delta p$ is close to zero, you have a wave. Bohr
  generalized this concept of complementary events from mere waves and
  particles in his complementarity
here where
  he realized

"It is impossible to design a measuring device that demonstrates both phenomena simultaneously not because of lack of creativity on the
    part of the experimenter, but simply because such a device is
    literally inconceivable." (Sentence in the Wikipedia about
    complementarity)

which is actually quite thought-provoking statement. For example, I
  understand this so that you cannot have a camera that minimizes all
  types of noises. The QM models infer a new type of noises such as
  quantum noise aka shot noise that dominates low signal-to-noise-ratio
  noises in certain situations.
My lecture documents
  here
  at the end are confusing in this point. It mentions "You cannot force
  wave nature into particle nature without losing interference." after
  mentioning "You will lose interference pattern on the left if you try
  to find out from which hole the photon went by filling the other hole
  one-by-one" (not word-to-word translation) but the meaning should be
  the same. 

Now back to the statistics 'why are the statistics called "thermal"
  or "energy"?'

QM models such as Bose-Einstein and Fermi-Dirac describe bosons and fermions, respectively. Classical models (ambiguous term but meaning
    now Maxwell equations) are energy equations in a way: you need energy
    to see their working. Thermal prepending is a bit odd but perhaps it
    wants to stress the association of energy and temperature. The word
    "distribution" stresses the statistical connotation.
I hope someone more experienced can explain what the "thermal energy distributions" really are! I feel my explanation is not
    thorough.


Mathematical formalism

Bose-Einstein
We have particles with states $N_i$ and walls $M$ where particles can have the same quantum state, a big difference to fermions where $(n,s,l,m_l)$ cannot be the same. So horizontal alignment 
$$W_h^i=\frac{(N_i+M-1)!}{N_i!(M-1)!}$$
where the total alignment is the product of all horizontal alignment so the probability function $P=\Pi_i w_h^i=\Pi_i\frac{(N_i+M_i-1)!}{N_i!(M_i-1)!}$ so 
$$\ln(P)=\sum_i \ln\left[(N_i+M-1)!-\ln(N_i!)-\ln((M-1)!)\right]$$
Now we use Lagrange-multiplier method so the F-function is
$$F=\ln(P)+\alpha (N-\sum_i n_i)  + \beta (MU-\sum_i n_i u_i)$$
where the first $\alpha$ restriction means the amount of particles is the sum of all particles in the states $N=\sum_i n_i$ and the second $\beta$ condition means the system energy is the sum of all energies in states.
Now we derivative this one with respect to the states variable $n_i$ where we need to use the Stirling approximation $\ln(x!)\approx x\ln(x)-x$ because of large number of particles (small amount of particles requires an extra term here). So 
$$\ln(M)-\ln(N_i)-\alpha-\beta E_i=0$$
$$N_i=Me^{-\alpha-\beta E_i}$$
Fermi-Dirac
Pauli's exclusion principle is the key difference. It is otherwise the same deduction as with Bose-Einstein but $W_h^i=\frac{M!}{N!(M-N_i)!}$ where $N!$ is for "miehitetty" manned states and $(M-N_i)!$ for un-manned states due to Pauli's exclusion principle -- you cannot have same two Q-states with fermions! 
Maxwell Boltzmann
I use now lectures 2061 here pages 63-65. I am not sure of this because the two teachers use a slightly different notations but I understand it this way
$$W_h^i =\frac{g_i^{n_i}}{n_i!}$$
where $g_i$ is the degenerazy, $n_i$ is the amount of state so the probability $P_{MB}=\Pi_i W_h^i.$ And we will get the statistics but taking the logarithm and using Lagrange multipliers. Our conditions are $N=\sum_i n_i$ and $E=\sum_i n_i E_i$.

SUMMARY

Most states are with Maxwell-Boltzman then Bose-Eistein and least states with Fermi-Dirac because of Walls and Pauli's exclusion principle. Please, note that there are no "walls" with Maxwell-Boltzmann where systems such as ideal-gas particles can occupy the same quantum state -- perhaps related to superfluidity phenomenon. Horizontal occupation formulae for Bose-Einstein, Fermi-Dirac and Maxwell-Boltzman:
$$W_h^i(BE)=\frac{(N_i+M-1)!}{N_i!(M-1)!}$$ 
$$W_h^i(FD)=\frac{M!}{N_i!(M-N_i)!}$$
$$W_h^i(MB) =\frac{G_i^{N_i}}{N_i!}$$ 

Study Questions

  
*
  
*Do Fermions and Bosons have degenerazy like a Maxwell-Boltzmann system? 
  
*In other words, why no $G_i$ with BE and FD formulae?

A: There is an interesting view on how to relate the statistical physics distributions and the problem to arrange balls on boxes
Here is the link: http://tominology.blogspot.com.br/2014/11/counting-problems-and-statistical.html
Basically you can think that:


*

*Maxwell-Boltzmann: arrange distinguishable particles inside cells where the cells can contain multiple particles.

*Bose-Einstein: arrange indistinguishable particles inside cells where the cells can contain multiple particle.

*Fermi-Dirac:arrange indistinguishable particles inside cells where each cell can contain only one particle.

