  Rosseland mean opacity plays an important role in theories of stellar
evolution and X-ray burst models. In the high-temperature regime, when most of
the gas is completely ionized, the opacity is dominated by Compton scattering.
Our aim here is to critically evaluate previous works on this subject and to
compute exact Rosseland mean opacity for Compton scattering in a broad range of
temperatures and electron degeneracy parameter. We use relativistic kinetic
equations for Compton scattering and compute the photon mean free path as a
function of photon energy by solving the corresponding integral equation in the
diffusion limit. As a byproduct we also demonstrate the way to compute photon
redistribution functions in case of degenerate electrons. We then compute the
Rosseland mean opacity as a function of temperature and electron degeneracy. We
compare our results to the previous calculations and find a significant
difference in the low-temperature regime and strong degeneracy. We find useful
analytical expressions that approximate well the numerical results. We then
proceed to compute the flux mean opacity and show that in diffusion
approximation it is nearly identical to the Rosseland mean opacity. We also
provide a simple way for accounting for the true absorption in evaluation of
the Rosseland and flux mean opacities.
