## 2 Modeling of Offshore Oil and Gas Platform Cluster System
### Prediction of Typical Output of Wind/Sunlight  
LightGBM was first proposed in 2017. It inherits the practice of the XGBoost integration model and continuously performs residual fitting on multiple regression trees to integrate strong regression trees. Because of its fast running speed and high accuracy, it is becoming widely used.  
To predict the typical daily output power of an offshore WT/PV system, based on the local wind meteorologically typical day, the PV meteorologically typical day, the historical meteorological data of the existing wind-farm solar field, and the corresponding power generation data, this study trained the WT and PV meteorologically typical daily-output power-prediction model based on the LightGBM network and, then, used the trained prediction model to predict the typical daily power generation according to the meteorologically typical days. The meteorological data of wind-power generation prediction included wind speed at different heights and wind direction corresponding to each wind speed, temperature, and humidity. Meteorological data for PV power generation prediction included short-wave radiation intensity, long-wave radiation intensity, cloud cover, temperature, and humidity.  
The LightGBM prediction model can be expressed as follows:  
\[\hat{P}_{i}=f_{w/pv}(X_{i}), \tag{7}\]  
where \(f_{w/pv}\) refers to the prediction model of wind-power or PV-power generation based on LightGBM, and \(X_{i}\) is the \(i\)-th meteorological sample point for wind-power or PV-power generation. \(\hat{P}_{i}\) is the predicted generation power corresponding to the \(i\)-th sample point.  
The objective function of the training was to minimize the mean square value (MSE) of prediction, as follows:  
\[\text{min}\sum_{i=1}^{N}\frac{\left(\hat{P}_{i}-P_{i}\right)^{2}}{N}, \tag{8}\]  
where \(P_{i}\) is the real power generation corresponding to sample \(i\) and \(N\) is the number of samples.  
Finally, the trained wind-power-generation prediction model \(f_{w}\) and the PV-power-generation prediction model \(f_{pv}\) were used, respectively, to predict the wind-power generation and the PV-power generation on a typical day.  
\(X_{wind}\) and \(X_{pv}\) denote the meteorological weather forecasting data used to predict the wind- and solar-power generation of a typical day, respectively, and their corresponding power predictions are determined by the following equations:  
\[\hat{P}_{w,i}=f_{w}(X_{w,i}), \tag{9}\]  
\[\hat{P}_{pv,i}=f_{pv}(X_{pv,i}), \tag{10}\]  
where \(X_{w,i}\) and \(X_{pv,i}\) are the \(i\)-th sample points of meteorological wind power and meteorological solar power of a typical day, respectively.  
The reasonable prediction of local wind/solar sequential-power generation can provide a reasonable basis for the connected capacity of WT and PV cells. It can also guide the siting and sizing of ES to effectively reduce the system's power fluctuation and line loss, stabilize the voltage, achieve the dispatching balance relationship (as shown in Equation (11)), improve the timing matching of each power supply in the system, and reduce the impact of the randomness of wind and solar energy, while improving the penetration of new energy:  
\[\sum_{i=1}^{n_{pv}}\hat{P}_{pv,i}+\sum_{i=1}^{n_{wind}}\hat{P}_{w,i}+\sum_{i=1}^{ n_{e}}P_{e,i}+P_{G}+P_{P}=P_{L}, \tag{11}\]  
where \(P_{G}\) and \(P_{P}\) are the dispatching output power of the gas-turbine and power grids, respectively, \(P_{e,i}\) is the ES dispatching output power, \(P_{L}\) is the load-power forecasting, and \(n_{pv}/n_{pe}/n_{e}\) are the total numbers of PV/WT ES, respectively. The ideal planning operation results are shown in Figure 2.