A simple method is proposed to overcome the difficulties of the Thomas
-Fermi model caused by the inadequacy of the semiclassical approach ne
ar nuclei. As a result the divergences of the quantum corrections to t
he energy and free energy in the origin vanish, the Scott correction a
ppears, and agreement between the statistical model and perturbation t
heory is restored for superhigh pressures and/or temperatures. A compa
rison of the refined statistical results with those of band-structure
calculations in the high-compression limit and those of the Saha model
in the high-temperature limit demonstrates good quantitative agreemen
t.