Introduction

Oxygen is one of the most abundant elements in the universe, possessing fascinating properties. Under pressures exceeding 96 GPa1,2, molecular oxygen transitions into a metallic phase and transforms into the ζ phase at around 100 GPa3,4. Sun et al. thoroughly investigated oxygen at pressures up to 10 TPa5. They predicted a transition from the molecular phase to a tetragonal phase with polymerized helical chains at 1.9 TPa, followed by a layered monoclinic phase known as the chain-molecular phase (space group Fmmm) at 9.3 TPa. Moreover, they demonstrated that oxygen maintains a superconducting temperature of 0.6 K to 2.1 K at TPa pressures. Building upon the work of Sun et al., Cogollo-Olivo et al. re-examined the oxygen phase boundaries at finite temperatures within the 1–10 TPa pressure range6. These studies comprehensively demonstrate oxygen’s properties and states below 10 TPa. However, even under such extreme pressures, the lone pair electrons in oxygen structures persist, and the polymerization process of oxygen remains incompletely elucidated.

With increasing pressure, diatomic molecules such as oxygen, hydrogen, fluorine and nitrogen gradually aggregate from the molecular phase into the polymeric phase. Hydrogen may exhibit an alternately interlayered structure7,8,9, while nitrogen, due to its unique outer electron configuration, possesses highly stable nitrogen-nitrogen triple bonds. Beyond 100 GPa, nitrogen transforms into the cubic-gauche phase10,11, and there are many metastable polymeric nitrogen structures realized. Only fluorine and oxygen are known to remain undissociated and form polymeric phases under TPa pressure5,12. Fluorine undergoes multi-step dissociation under TPa pressures. Surprisingly, it is at 30 TPa that fluorine finally breaks down its molecular structure to form a polymeric phase12. Intermediate structures during this transition exhibit superconducting behaviour, affirming fluorine as a superconducting element despite its critical temperature (Tc) of only several Kelvin. This has sparked interest in the electronic properties of TPa pressure structure states.

However, current studies on the high-pressure polymerization of diatomic molecules have predominantly focused on static-pressure structure calculations and have not addressed finite-temperature dynamics. On the one hand, pressures exceeding the TPa regime require the use of pseudopotentials with small cutoff radius to achieve convergence, with the necessity for higher energy cutoffs further increasing computational costs; on the other hand, conventional force fields fail to accurately capture the finite-temperature dynamical behavior of dense oxygen. These limitations constrain our investigations into dense matter, particularly considering that dense astronomical objects, such as white dwarfs, experience pressures on the order of TPa or even higher. In this context, exploring the structural and property changes of materials under ultrahigh-pressure conditions provides novel insights into the extreme states of dense astronomical objects.

As a “cosmic clock”13,14,15, the white dwarf has its material state and cooling process that affect galaxy evolution and age. Carbon-oxygen white dwarf is the main form of white dwarfs. As compact objects marking the final stages of stellar evolution, white dwarfs exhibit extremely high pressures. However, the methods of studying such dense matter are very limited. Kritcher A. L. et al.16 measured the material state of the carbon envelope of white dwarfs through impact experiments, with pressures reaching up to 45 TPa. However, such shock experiments are extremely complex and challenging, and the finite-temperature dynamics of oxygen polymerization under TPa pressures and its implications for white dwarf cooling remain unexplored, which motivates our machine learning-assisted investigation. Inspired by above studies, we turned our attention to the state of oxygen. Unlike carbon, no research has yet been conducted on oxygen under extreme pressures exceeding 10 TPa. Nevertheless, earlier studies have indicated the existence of a white dwarf with an extremely high oxygen content. This indicate that the cooling process of this type of white dwarf may differ significantly from that of traditional hydrogen/helium envelope white dwarfs, which may lead to some yet-to-be-expected evolutionary results.

In order to explore the above issues efficiently, in this work, we employed the machine learning accelerated crystal structure prediction method MAGUS17,18,19 combined with NEP20 potential to predict oxygen structures under pressures up to 1 PPa; these new structures were cross-validated using ab initio random structure search (AIRSS)21,22. We have summarized the multi-step complete polymerization process of oxygen. By calculating the electron localization function (ELF), we identified two-dimensional bonding in the bct phase persisting up to 248 TPa and observed that, as pressure increases, oxygen’s lone pair electrons gradually vanish while the bonding softens. To further explore the impact of this electronic structure on finite-temperature dynamical behavior, we utilized the GPUMD molecular dynamics package23,24 to compute the melting curve of oxygen up to 200 TPa via the two-phase method, and constructed the oxygen phase diagram by determining the phase boundaries between the bct and hcp phases using the stochastic self-consistent harmonic approximation (SSCHA)25,26,27. Compared with the melting point predicted by the Coulomb coupling parameter Γ, our computational approach successfully revealed abnormal melting of the bct phase beyond 100 TPa. On this basis, to elucidate the influence of such an oxygen envelope on the thermal evolution at white dwarf conditions, we calculated the thermal conductivity and isochoric heat capacity of oxygen and helium at 200 TPa using the Kubo-Greenwood method, and found that the oxygen envelope can release heat more efficiently than the helium envelope.

Results and discussion

Figure 1(a) illustrates the oxygen polymerization pathway we constructed, in which the bct and hcp phases were observed for the first time. Further calculations indicate that oxygen transforms from the Fmmm phase to the bct phase after 20 TPa, and then the bct phase aggregates into the hcp phase after 248 TPa. As shown in Fig. 1(b), the two short lattice axes of the orthorhombic Fmmm phase gradually become equal in the bct phase, with no abrupt changes in bond lengths; additionally, the enthalpy of the Fmmm phase converges to that of the bct phase after 20 TPa, and the recognition result of the space group also becomes the bct phase. Then, with increasing pressure, oxygen aggregates into the hcp phase after 248 TPa and exhibits various bonding modes—from molecular, to chain, to layered, and finally to polymeric structures. This behavior is primarily attributed to the involvement of lone pair electrons; their strong repulsion increases the pressure required for oxygen to form a three-dimensional, densely packed polymeric structure and also affects charge transfer and chemical bond reconstruction.

Fig. 1: Complete polymerization process of oxygen and continuous transformation of Fmmm-bct phase.
figure 1

a The first bond length of oxygen varies from 1 TPa to 1 PPa (red line). b The relative enthalpy of Fmmm and bct (EFmmm-Ebct) varies with pressure (orange line), and the lengths of both short axes b (lb) and c(lc) of the Fmmm phase converge with pressure increase (red dash line). The blue shading area indicates that the difference in enthalpy between the structures is within ±10 meV, which is generally considered to be degenerate. The inset is a schematic diagram of the transition from Fmmm phase to bct phase. Source data are provided as a Source Data file.

After elucidating the high-pressure phase transition pathway of oxygen, we further investigated the electronic properties of these new structures. As shown in Fig. 2(a), the ELF indicates that bonding in the body-centered tetragonal (bct) phase is predominantly established within a two-dimensional plane, while the charge distribution outside this plane exhibits an interlocking pattern due to the mutual repulsion among lone pair electrons. This two-dimensional concave–convex interlocking arrangement of charge effectively fills the interlayer gaps with electrons, thereby enhancing the structural stability under high-pressure conditions. As the pressure increases (see Figs. 2(c) and 2(d)), the charge density along the bond directions in the bct phase decreases, indicating bond softening, and the population of lone pair electrons gradually decreases. Upon transforming into the hexagonal close-packed (hcp) phase, weak interstitial anionic electrons (IAEs) emerge at the lattice interstices. These IAEs not only alleviate the interlayer repulsion but also facilitate the formation of three-dimensional bonding, thus driving the phase transition from the bct to the hcp structure.

Fig. 2: The electron localization function (ELF) of bct phase and hcp phase.
figure 2

a, b The ELF of the bct structure at 50 TPa with isosurface level 0.75 and the hcp structure at 300 TPa with isosurface level 0.65. c, d The ELF of the bct structure at 50 TPa and 250 TPa with isosurface level 0.83.

This fundamental change in the electronic structure and bonding mode is likely to have a significant impact on the thermodynamic behavior at finite temperatures. So far, the melting curve of oxygen has been roughly estimated using the Lindemann criterion28. However, a more reliable approach is to use large-scale molecular dynamics simulations. In order to avoid the latent heat of the phase transition in molecular dynamics calculations, we employed the two-phase method to determine the melting point. The two-phase method assumes that the solid and liquid phases coexist at the melting point and are in thermodynamic equilibrium. In this case, the latent heat of the phase transition is eliminated because of the equality of the chemical potentials of these two phases, which has been well validated in previous studies29,30. Since the two-phase method for calculating the melting point is subject to significant size effects, we used systems containing more than 105 atoms for the melting point calculations.

As shown in Fig. 3(a), our results align closely with the melting point estimated by Montoya, J. A. et al.28 using the Lindemann coefficient L = 0.11. However, the Lindemann criterion yields significantly divergent results when different L-values are adopted, providing only a rough range and trend for the melting curve. In contrast, the melting curve derived from molecular dynamics calculation is more reliable, as it incorporates explicit molecular-scale processes such as pre-melting defect accumulation and the evolution of solid-liquid interfaces. Additionally, we employed the SSCHA method to calculate the Gibbs free energy and calibrate the phase boundaries between Fmmm-bct and bct-hcp, as illustrated in Fig. 3(b). The SSCHA effectively captures significant high-order anharmonic effects at elevated temperatures, circumventing the limitations of the quasi-harmonic approximation (QHA) in addressing high-temperature systems. The results indicate that the Fmmm-bct phase boundary is minimally influenced by temperature, while higher temperatures reduce the pressure required for the bct-to-hcp phase transition.

Fig. 3: Phase boundary and melting curve of oxygen, calculated by other researchers and inferred from Coulomb coupling parameters and the melting point of He.
figure 3

a The melting curve of oxygen in the pressure range of 1–10 TPa (red line), compared with DFT results (light bule line) by Montoya, J. A. et al.28, the black line is the phase boundary calculated by Cogollo-Olivo, B. H. et al.6. b The melting curve of oxygen in the pressure range of 10–200 TPa (red line). The melting curve determined according to the Coulomb coupling parameters (cyan line). We calculated the melting point of helium (red symbol) and Fmmm-bct phase boundary (brown line). The inset shows the phase boundary of bct-hcp (The error bars in the figure represent the upper and lower limits of the melting point, with the center being the average value). Source data are provided as a Source Data file.

One of the most important parameters for white dwarf cooling models is the Coulomb coupling parameter \(\Gamma={\left({{\rm{Ze}}}\right)}^{2}/{{\rm{a}}}{{{\rm{k}}}}_{{{\rm{B}}}}{{\rm{T}}}\), where a is the distance between ions. For large \(\Gamma\) values (\(\simeq 175\))31, the transition occurs with the release of corresponding latent heat. The melting temperatures are also derived from the Coulomb coupling parameters 169 < \(\Gamma\)< 183. As shown in Fig. 3(b), the melting points deduced from \(\Gamma=175\) are very close to those calculated by molecular dynamics within the range of 100TPa. However, such a straightforward method cannot capture the abnormal melting behaviour of oxygen and shows higher melting temperatures for high pressures of > 100 TPa. The bond softening in the bct phase reduces the energy barrier for atomic motion, thereby lowering the melting temperature and explaining the anomalous melting behavior observed beyond 100 TPa. At 200 TPa, the density of bct-phase oxygen increases upon entering the liquid state (see Fig. S2). According to the Clausius-Clapeyron relation, this density behavior implies a negative slope in the melting curve of bct-phase oxygen, which aligns with our computational predictions.

After accurately constructing the phase diagram, we calculated the transport properties and potential influence on the thermal evolution of the oxygen envelope at white dwarfs32. The recent asteroseismology analysis has demonstrated that the total oxygen content of white dwarfs is much higher than expected in typical stellar evolution calculations33. It is of great interest to compare the distinct thermal effects of helium and oxygen at white dwarfs’ conditions by calculating their thermal conductivity and specific heat capacity. In Fig. 4, we use the Kubo-Greenwood formula to calculate thermal conductivity. It is based on linear response theory and can describe the behaviour of free electrons in metals. It is a good approximation for calculating the transport properties of warm dense matter34,35,36,37,38. Compared with helium, oxygen has a higher thermal conductivity at the same pressure, which may lead to premature cooling of oxygen-rich envelopes. On the other hand, we calculated the isochoric heat capacity, where the ionic part obtained through the NVT ensemble on average (\({{{\rm{C}}}}_{{{\rm{vi}}}}=\frac{ < {{{\rm{E}}}}^{2} > -{ < {{\rm{E}}} > }^{2}}{{{{\rm{K}}}}_{{{\rm{B}}}}{ < {{\rm{T}}} > }^{2}}\)), and the electron part obtained by Sommerfeld expansion (\({{{\rm{C}}}}_{{{\rm{ve}}}}=\frac{{{{\rm{\pi }}}}^{2}{{\rm{N}}}{{{{\rm{K}}}}_{{{\rm{B}}}}}^{2}{{\rm{T}}}}{2{{{\rm{\varepsilon }}}}_{{{\rm{F}}}}}\)). The ion and electron parts of oxygen are lower than that of helium. The energy loss of cold white dwarfs mainly comes from the thermal energy stored by ions because of their higher specific heat for electrons. Therefore, oxygen with lower specific heats can release energy more effectively, thereby possibly affecting the cooling process at white dwarfs conditions14.

In summary, we explored the polymerization, phase transitions, and thermal transport properties of oxygen under extreme pressures using machine learning-assisted structure prediction and molecular dynamics simulations. We identified a novel high-pressure phase transition pathway of oxygen, from the Fmmm phase to a body-centered tetragonal (bct) phase at 20 TPa, which remains stable up to 248 TPa before transforming into a hexagonal close-packed (hcp) phase. Electronic structure analysis revealed significant bond softening in the bct phase, impacting its thermodynamic behavior. Using molecular dynamics and the two-phase method, we constructed the melting curve of oxygen up to 200 TPa and observed an anomalous melting behavior beyond 100 TPa that is not captured by classical white dwarf models. Furthermore, our calculations of the thermal conductivity and isochoric heat capacity indicate that oxygen-rich envelopes at white dwarf conditions can release energy more efficiently than those with helium envelopes. This enhanced thermal transport capability may lead to a faster cooling process for oxygen-dominated white dwarfs, impacting their evolution and lifespan. Our findings provide new insights into the extreme states of matter in compact astrophysical objects and suggest a new research pathway for understanding the cooling process of white dwarfs.

Methods

The geometry optimizations calculations are realized through the density functional theory package QUANTUM ESPRESSO39,40. We use the ultra-soft pseudopotential based on the Perdew-Burke-Ernzerhof (PBE) functional41,42. We use the CASTEP code43,44 to generate similar pseudopotentials as used in QUANTUM ESPRESSO for structure prediction and verification. This method has been successfully applied in studying a series of substances at TPa pressure45,46,47,48,49. The structure prediction results are cross-checked by MAGUS17,18,19 and AIRSS21,22. Thermal conductivity calculations are performed using Kubo Greenwood formula, implemented through KGEC code50,51,52. Machine learning force field NEP20,53 and GPU accelerated molecular dynamics package GPUMD23,24 are employed for the molecular dynamic calculation. Please refer to the supplementary information for more details.

DFT calculation details

The pseudopotential of the entire valence electron case is generated using the ld1.x module. For the structures under 25 TPa, we use the pseudopotential with a core cutoff radius of 0.7 Bohr, and the energy cutoff is 1600 eV. For the structures under pressures ranging from 25 TPa to 300 TPa, we use the pseudopotential with a core cutoff radius of 0.56 Bohr. An energy cutoff of 2500 eV. For the structure of 300 TPa-1 PPa, a pseudopotential with a core cutoff radius of 0.42 Bohr is used. The energy cutoff is 2800 eV. The pseudopotential with an internal cutoff smaller than half the distance between atoms is generally considered a reliable pseudopotential. In all calculations, the kinetic energy cutoff energy of the charge density and potential is eight times that of the kinetic energy of the wave function. A high-precision k-point grid of 2π × 0.03 Å has been used. We examined the influence of multiple exchange-correlation functionals on the Equation of State (EOS) in the Supplementary Materials (Fig. S5). The PBE functional exhibits close agreement with both the metaGGA functional R2SCAN and the hybrid Hartree-Fock functional B3LYP over the studied pressure range, indicating that PBE delivers reasonably high accuracy while maintaining significantly higher computational efficiency.

Structural prediction method

Using the crystal structure search method accelerated by machine learning17,18, we have predicted a series of planetary materials54,55,56,57,58,59. In this work, each search uses 1000 entirely random structures, with a total search structure approaching 20,000. The structure searches were employed at 1 TPa, 5 TPa, 10 TPa, 50 TPa, 100 TPa, 200 TPa, 400 TPa, and 1000 TPa, respectively. The energy cutoff used during the search process is 0.7 times that of high-precision DFT calculations.

Machine learning force field details

In this study, we employed a machine learning force field to overcome the size effect on describing the melting curve. Moreover, we used the NEP to perform molecular dynamics simulations.

The characteristics of NEP machine learning force field include GPU computation capability, enabling long-time simulations of large systems. Its descriptors consist of radial and angular components, with radial part adopting radial distribution functions, while angular part utilizes ACE-like method, the loss function of NEP is the root mean square error of forces, energies, and virials. For more information, please refer to https://github.com/brucefan1983/GPUMD.

The initial dynamic trajectory set was obtained through AIMD. The AIMD uses NPT ensemble and supercells with over 50 atoms, including sufficient solid and liquid configurations. We train the force field at different pressures to maintain accuracy, including 1 TPa, 3 TPa, 5 TPa, 7.5 TPa, 10 TPa, 50 TPa, 100 TPa, and 200 TPa (as shown in Fig. S10).

Firstly, we generated a rough force field through equal interval sampling. Subsequently, we obtained the most representative configuration in the total data through farthest point sampling and retrained it to obtain a more accurate force field, each force field consists of at least 2000 structures, at least 40% of which are liquid structures. At very high temperatures, it becomes necessary to account for the influence of electronic entropy on the dynamics processes. Therefore, we describe high-temperature molecular dynamics more accurately by introducing electron temperature into the NEP force field60. The melting point is calculated by the two-phase method, and each phase uses a supercell with more than 60,000 atoms, the total number of atoms is over 120,000. To obtain a solid-liquid interface, we immobilized one set of atoms while melting the other, thus avoiding the introduction of a vacuum layer and its impact on the melting point. We conduct all dynamic calculations for at least 50 ps, by which time a good equilibrium has been reached.

KGEC details

We performed molecular dynamics simulations on 36-atom supercells containing oxygen and helium. After achieving structural stabilization, we selected 10 configurations at 50 ps intervals to calculate the electronic thermal conductivity and isochoric heat capacity (constant-volume heat capacity). This sampling strategy aimed to mitigate the influence of thermal fluctuations in the atomic configurations. The final results were statistically analyzed, including the average value along with the maximum and minimum values observed at each temperature point Fig. 4.

Fig. 4: Comparisons of the thermal properties of oxygen and helium at white dwarf conditions.
figure 4

a The thermal conductivity of oxygen (bct phase) and helium (hcp phase) at 200 TPa (red line for Oxygen, blue line for Helium, the error bars in the figure represent the upper and lower limits of the thermal conductivity, with the center being the average value). b The isochoric specific heat capacity of oxygen (red) and helium (blue), the solid and dashed lines represent ionic and electronic contributions, respectively. c, d Schematic diagram of the potential distinct cooling strength of oxygen-rich or helium-rich envelops of white dwarf, due to the more efficient transfer of heat by oxygen, white dwarfs in the oxygen envelope cool faster. Source data are provided as a Source Data file.

SSCHA method

We used the stochastic self-consistent harmonic approximation (SSCHA) method to calculate the anharmonic effects. The convergence of SSCHA minimization has been verified through 200 supercells. The SSCHA calculations were performed using a 3 × 3 × 3 supercell with 54 atoms. The trial harmonic dynamical matrices were obtained from the QUANTUM ESPRESSO (QE) code combined with the Density Functional Perturbation Theory (DFPT) method, and the SSCHA iteration was used to minimize the free energy corresponding to the crystal structure (lattice and atomic coordinates).

Lindemann criterion

The Lindemann criterion is a purely phenomenological vibrational approach, which posits that as temperature increases, the vibrational amplitude of atoms within a crystal lattice also increases. When the amplitude reaches a certain critical value, the atoms deviate from their equilibrium positions, leading to the disruption of the lattice structure and the onset of melting in the solid. Furthermore, this critical amplitude is considered to be related to the interatomic distance.