Electronic structure of UO2; contributions to the excess enthalpy at 3000 k and in the liquid