Solution (source code)

= Solution

The <luminosity distance> is defined operationally by the bolometric relation $F=L/(4\pi d_L^2)$ for an isotropic source. It incorporates geometric spreading, reduced photon energy and dilated photon arrival times. If $D_M$ is the transverse comoving distance with the present scale factor included, then $d_L=(1+z)D_M$ in a spacetime with an <FLRW metric> with photon number conserved.

Let $\nu_e=(1+z)\nu_o$ be the emitted frequency. A narrow emitted band carries energy $P(\nu_e)\,d\nu_e\,dt_e\,d\Omega$. At the observer the energy is smaller by $1+z$, the time interval is $dt_o=(1+z)dt_e$, the frequency interval is $d\nu_o=d\nu_e/(1+z)$, and the illuminated area is $D_M^2d\Omega$. Hence the spectral <spectral flux density> per unit observed frequency is
$$
S(\nu_o)=\frac{P((1+z)\nu_o)}{(1+z)D_M^2}
=\frac{(1+z)P((1+z)\nu_o)}{d_L^2}.
$$
For the specified power law, $P((1+z)\nu_o)=(1+z)^{-\alpha}P(\nu_o)$, so the <power-law spectral K correction> is
$$
\boxed{S(\nu_o)=P(\nu_o)(1+z)^{1-\alpha}d_L^{-2}.}
$$
There is no extra $4\pi$ because $P$ is power per steradian. For total spectral luminosity $L_\nu=4\pi P_\nu$, that factor would instead appear in the denominator. The frequency-band factor is essential: bolometric flux has two redshift-dimming factors, but spectral flux has one of them compensated by the bandwidth change.