## 3 Results and Discussions
In Figure 5, we observe the phase behavior generated by Hybrid Model 1, where the neural network predicts the \(K_{i}\) values followed by a single Rachford-Rice iteration to calculate the equilibrium compositions (\(x_{i}\) and \(y_{i}\)). The results show smooth and consistent \(K_{i}\) values across both near-critical (a) and regular (b) conditions, particularly for the heavier component, decane (nC10), which previously displayed unphysical fluctuations in the Direct Model. The tie-lines in both conditions are physically consistent and do not cross each other, confirming that the mass balance and phase behavior are properly maintained. This improved accuracy is due to the integration of the Rachford-Rice equation, which honors the underlying physical constraints of the system. By using a single Rachford-Rice iteration after the neural network generates the Ki values for the given pressure, temperature, and composition, Hybrid Model 1 successfully integrates machine learning with traditional thermodynamic principles, producing more reliable results in the compositional space. Figure 6 presents the results from Hybrid Model 2, where the neural network predicts the logarithmic mole fractions \(\log(x_{i})\) and \(\log(y_{i})\) and then calculates \(K_{i}\). As with Hybrid Model 1, a single Rachford-Rice iteration is then used to ensure that the phase compositions honor mass balance and phase equilibrium. The overall behavior of Hybrid Model 2 is similar to that of Hybrid Model 1, with smooth and consistent tie-lines and no unphysical behavior such as tie-line crossing. However, by using \(\log(x_{i})\) and \(\log(y_{i})\) in the process, in Hybrid Model 2 we are attempting to linearize the highly nonlinear Ki variable, potentially improving the accuracy of the predictions, particularly for challenging near-critical conditions. The logarithmic transformation helps the model handle the variability of \(K_{i}\) more effectively, ensuring that the final phase compositions are more physically consistent after the Rachford-Rice correction. This approach integrates machine learning with physical principles while addressing the inherent nonlinearity of the phase equilibrium variables. Figure 5: Ternary diagram generated using Hybrid Model 1—Ki \(\rightarrow\) RR \(\to x_{i}\), \(y_{i}\): (**a**) near-critical conditions of 80 atm and 60 \({}^{\circ}\)C; and (**b**) regular conditions of 75 atm and 60 \({}^{\circ}\)C.  
In Figure 7, we observe the phase behavior for the system under far-from-critical conditions (50 atm and 60 \({}^{\circ}\)C). The Peng-Robinson EoS (Figure 7a) serves as the reference case, providing physically consistent phase predictions. The Direct Model (Figure 7b), while still achieving a high accuracy during training, shows some unphysical fluctuations in the equilibrium constants, particularly for heavier components like decane, which highlights the limitations of this approach in capturing true physical behavior. In contrast, both Hybrid Model 1 (Figure 7c) and Hybrid Model 2 (Figure 7d) produce more consistent and physically accurate predictions. However, it is noticeable that Hybrid Model 2 offers even smoother predictions that are more closely aligned with the Peng-Robinson reference case. The use of logarithmic transformations in Hybrid Model 2 improves its ability to handle the nonlinear nature of equilibrium constants, providing an advantage in terms of both physical consistency and prediction smoothness, even in less challenging, far-from-critical conditions. This study evaluated the overall performance of machine learning algorithms to capture physical behavior in a controlled environment where we directly control the synthetic data, thus eliminating any potential quality data uncertainty and consistency. The implications of this study can be applicable for broader applications that heavily rely on phase behavior modelling, such as compositional reservoir simulations.