Equal masses of gases have equal amount of internal K.E. at same temperature. In rarefied gas, molecules are at more distance from each other than in compressed gas. These molecules possess more interned P.E. It makes total internal energy of the rarefied gas more than that of the compressed gas.