*5.2. Market Clearing*

Based on the above data, we used two schemes to verify the impact of the flexible load on market clearing.

Case One: The market clearing model does not consider the flexible load, and the power consumption behavior of the flexible load does not change.

Case Two: 4.97% of the transferable load participates in the market clearing, and the transferable load can change the power usage behavior according to the cost of the electricity.

The marginal electricity price of a node is defined as the increase of the 1 MW load at the node. Under the premise of ensuring safety, the minimum production cost of the system can be obtained through the optimization model of market bidding [32]. The node's marginal price can be obtained by solving the Lagrange function, and the definition of the node's marginal electricity price can be applied in the market clearing model [33,34].

By comparing the two schemes, the impact of the flexible load on the market clearing model can be analyzed.

From Figures 9 and 10, we can know the marginal node electricity price of the market clearing. The di fference is that Figure 9 does not consider flexible loads, and Figure 10 considers flexible loads. The results show that the node electricity price can be obtained successfully, and it is very close to the actual electricity price, which has grea<sup>t</sup> engineering application value.

**Figure 9.** Marginal node price without considering the flexible load.

**Figure 10.** Marginal node price considering the flexible load.

When the convertible load is not considered, the highest price of the node is 0.832 yuan/kWh, and the lowest price is 0.704 yuan/kWh. Considering the participation of the convertible loads, the highest electricity price in all aspects is 0.813 yuan/kWh, and the lowest electricity price is 0.712 yuan/kWh. Therefore, the participation of the convertible loads in the market can clearly reduce the electricity price and reduce the peak-to-valley electricity price difference in the market. This result is in line with expectations, because the flexible load itself is economical.

During the market clearing process, the users of convertible loads are shifted and allocated to the time when the cost of electricity is lower. Because of this, the load curve will change, and the convertible load during the peak period of power consumption will shift to the lower period.

The load curve after the market clearing is shown in Figure 11. The peak-to-valley difference of the initial load is 33.71%. Compared with the initial load, the peak-to-valley difference of the load curve is reduced by 11.40%. This article is aimed at a specific urban power grid, which has a high proportion of load density. In other high-density load cities, the load characteristics have similar properties to the

urban power grid. The research in this paper can be extended to similar urban power grids, which can effectively alleviate the challenges to the supply of electricity and improve the load curve.

**Figure 11.** Load curve after the market clearing.
