In this study, refractive indices in the visible, near-infrared, and extreme ultraviolet (XUV) regions are calculated based on Mathematica software. Atomic scattering factors are simulated for a high photon energy range (20-60 eV). By using the atomic scattering factors, the real and imaginary part of the index of refraction values are plotted as a function of photon energy. This work aims to present a computational program, which calculates the index of refraction of the inert gases at different wavelength regions. The refractive indices of gases, namely helium (He), neon (Ne), argon (Ar), and xenon (Xe) in the near-infrared and XUV region are computed by using Mathematica software. The applications of the index of refraction are discussed in the paper. The Mathematica program calculating the refractive indices is presented in the Appendix.