## 1 Introduction
The EFC in MESs can be divided into two categories based on solution formats: the decomposition format and the unified format. In the former, each subsystem is treated as a decoupled independent unit, and the model of each subnetwork is solved sequentially until the state variables at the decoupling points meet the convergence conditions of the iteration. Relying on the decomposition solution format, numerous solution algorithms, such as the Newton-Raphson (NR) method [21], holomorphic embedded method [22], graph method [22], and topological decomposition method [23], have been successfully applied to solve the EFC problem. In contrast, the unified format considers the components of MESs as a tightly coupled whole, avoiding the potential issues of insufficient computational accuracy or indivisibility that may arise in the decomposition format. The NR-based method is the primary solution technique under this format, with studies [9; 15; 24] providing typical cases of using it to assess the operating state of MESs. However, the NR-based method is sensitive to the selection of initial values, and improper initial values can lead to a singular Jacobian matrix, which, in turn, causes iteration divergence. Furthermore, as the coupling degree of the MES increases or the system scale expands, the solvable domain of the EFC problem shrinks, making it harder to generate appropriate initial guesses. To address these issues, an initial value guessing strategy for MESs was proposed in [25] from the perspective of the convergence theorem. In [26], a fast decoupled EFC solution algorithm was proposed, in which the Jacobian matrix was replaced with a diagonal constant matrix to enhance the convergence of the NR iteration. In [27], a damping technique was incorporated to regulate the iteration step size and convergence direction of the NR-based EFC solution process. Additionally, some studies applied data-driven methods to handle EFC in MESs [28,29]. Despite the satisfactory performance in case studies, these methods are constrained by the quality of sample data, which limits their solution stability and applicability. Therefore, the NR method is still the mainstream solution algorithm for EFC in MESs. The above studies indicate that the development bottleneck of the NR-based EFC solution method lies in its fragile convergence. In MESs, the initial values for the DEN and DHN are typically set using a flat start approach [12], which is the most widely adopted method and yields satisfactory results. For the DGN, determining appropriate initial gas pressure values has always been a challenging task. To avoid singularity in the Jacobian matrix caused by the flat start approach, the most common method for gas pressure initialization is to set the balance node pressure as a reference value and apply a 5-10% pressure difference along the gas flow direction between the starting and ending points of the pipeline [8]. However, in most MES scenarios, the direction of gas flow in the DGN cannot be determined in advance, and when loops exist in the DGN topology, the gas flow direction becomes even more complex. Moreover, considering that the model scale of the DGN further increases when alternative gas injections are accounted for, the convergence of the NR method becomes even harder to guarantee. In view of this, this paper aims to develop a matrix-based MES energy flow model with strong universality that is applicable to most scenarios. Unlike previous studies that primarily focus on enhancing EFC solution algorithms, this paper begins from the physical meaning inherent in the model itself and improves the parts of the MES model involving gas composition tracking, thereby expanding its solvable domain. The main contributions of this paper are as follows:  
* A matrix-based MES energy flow model is constructed, which considers the diversity of compressor operating modes and gas compositions in the DGN. In addition, the impact of the gas compressibility factor under non-ideal gas conditions on the MES operating state is also quantified.