1 Introduction

The task of transmission expansion planning (TEP) is to determine when, where, and how many new transmission lines should be built to meet the projected load safely during a given horizon [1]. The principle of N-1 security in TEP requires the system to maintain a constant power supply with single component failure, e.g., a transmission line or a generator failure [2]. However, with the increase of the power system scale, the limitation of the N-1 security criterion becomes obvious. To cope with potential multiple component failures, an upgraded and tighter security criterion named N-2 becomes necessary for security considerations. In general, there are two types of methods for dealing with security in TEP, i.e. ① post-check: check whether the security criterion is satisfied after obtaining a transmission construction plan [3]; ② constraint embedded: integrate the security criterion as one constraint into the planning formulation and explicitly model all contingencies [4]. However, both methods have limitations. As for solution quality, the former has no guarantees whether the security criterion is satisfied. As for computational efficiency, the latter needs to add \({\text{C}}_{N}^{2}\) constraints for N components and the corresponding decision variables, which brings a heavy computational burden. Such a problem becomes more serious in networks with a large number of transmission lines and generators. It is necessary to propose a more efficient method to handle the N-2 security criterion.

The framework of adjustable robust optimization (ARO) [5, 6] offers a new way to tackle N-2 security in TEP. In ARO, uncertain variables representing uncertain events in power systems are constrained by an uncertainty set. Moreover, non-adjustable variables are determined before the realization of the uncertain variables, while adjustable variables can be chosen after their realization [5]. This mechanism enables planners to make transmission construction plans with the worst contingency and the optimal reaction. In this way, a transmission construction plan only needs to satisfy the worst N-2 contingency rather than all the contingencies. A bi-level “max–min” optimization model is capable of finding the worst contingency while avoiding the computational burden that would result from enumerating all possible N-2 contingencies. Motivated by this fact, we studied a novel ARO-based method to tackle the N-2 security-constrained TEP problem.

In the literature, ARO has mainly been used to handle the uncertainty of load and renewable energy in TEP [7,8,9,10,11]. Reference [7] employed ARO in TEP with load uncertainty. Reference [8] extended this work by considering the uncertainty of both load and renewable energy. Similar application examples can also be found in [9, 10]. In [11], apart from the uncertainty of load and renewable energy treated by ARO, the N-K contingency was further considered, but in a deterministic way. When applying ARO to TEP, a tricky problem is that the degree of conservativeness greatly depends on the uncertainty budget defined by users. In practical application, however, it is hard to determine the value of uncertainty budgets. An oversized uncertainty budget may lead to a conservative result, and an undersized uncertainty budget may underestimate the degree of uncertainty. Moreover, since the load and renewable energy vary with time continuously, the uncertainty should be represented by continuous variables and continuous uncertainty sets, e.g., polyhedron and ellipsoid uncertainty sets. Consequently, the reformulation of the max–min problem results in a bilinear problem involving the product of two continuous variables, which remains a challenge.

Compared with applications for uncertain load and renewable energy, ARO has several advantages in dealing with security problems through uncertain binary variables. It neither requires determination of uncertainty budgets (e.g., N-2) nor faces a bilinear problem involving the product of two continuous variables, e.g., the product of a continuous variable and a binary variable. Furthermore, the conservativeness of ARO well suits the cautiousness of planners when considering security problems.

Handling generalized N-K security with ARO begins with the research on security-constrained unit commitment (SCUC), which shares a similar problem structure with security-constrained TEP. Reference [12] incorporated the N-K security criterion into a single-bus unit commit problem based on ARO. Because only unit failures were considered earlier, extended work [13, 14] took both generator and line failures into consideration. In [15], the SCUC problem in AC-DC grids with generation and load uncertainty was studied. Reference [16] proposed a distributionally robust optimization (DRO) approach for SCUC, in which the probability distribution of contingencies was considered. Reference [17] proposed a SCUC formulation that includes dynamic gas constraints. Reference [18] integrated energy hub into a SCUC problem. When dealing with the security-constrained TEP problem, besides existing lines and generators, candidate lines that have been built may also fail. Therefore, not only the existing line failures, but also the candidate line failures have to be considered. The robust TEP model proposed by [19] managed the uncertainty of generator availability through generator capacity, while [20] used binary variables to represent the generator availability. However, the candidate line failures were still disregarded in those works. In [21], the N-K security criterion was incorporated in TEP using an ARO method. Moreover, [22] further considered the availability of candidate generators in planning for both composite generation and transmission expansion.

Mathematically, the ARO-based model is solved in a master-sub manner. Solution techniques include Benders decomposition (BD) [23], column-and-constraint generation (CCG) [24], and their modified versions such as the primal-dual algorithm developed in [21]. In the primal-dual algorithm, the lower-level problem is replaced by its dual form rather than by the Karush–Kuhn–Tucker (KKT) conditions. Because fewer iterations are needed compared to BD, and fewer constraints are introduced compared to CCG, the combined algorithm outperforms the individual BD and CCG algorithms [25]. Nevertheless, in [21], only one of the worst contingencies could be detected at each iteration. When the number of contingencies increases, it is inefficient to add the worse contingencies one by one.

Compared with current studies, the contributions of this paper are supported by the following specific aspects:

  1. 1)

    Different from the previous works that use robust optimization to manage the uncertainty of load and renewable energy, this paper applies robust optimization to the N-2 security-constrained TEP problem. In addition to existing line failures and generator failures, this paper also considers candidate line failures, which helps to make a better trade-off between transmission investment costs and operation costs.

  2. 2)

    In terms of modeling, the inherent bilinear problems that involve the product of two continuous variables are avoided, and the investigation of the uncertainty budget is not required, which are beneficial for the practical application of robust optimization. The bilinear problems in our model involve the product of a binary variable and a continuous variable, which are successfully handled in this paper.

  3. 3)

    The proposed contingency-aware method is an improvement of the ARO framework. The contingency-aware method uses a series of subproblems that detect not only the worst contingency, but also the potential contingencies. Multiple effective primal cuts are generated at one time, which significantly improves the computational efficiency. The computational speed of the proposed method is approximately 2000 times faster than the deterministic method. When compared to the ARO method, the proposed method considering potential contingencies can improve the computational efficiency by 25% to 38%.

The remainder of this paper is organized as follows. Section 2 describes the ARO method for N-2 security-constrained TEP. Section 3 develops the contingency-aware method for N-2 security-constrained TEP. Section 4 presents solution techniques and the algorithm. Section 5 compares the performance of the proposed method with the ARO method in the case studies. Numerical results are also presented and analyzed. In Section 6, the relevant conclusions are drawn.

2 ARO method for N-2 security-constrained TEP

Because the contingency-aware method is based on the ARO framework, we first introduce the ARO framework in this section. The key idea is that when a transmission construction plan satisfies the worst N-2 contingency, it can satisfy all N-2 contingencies.

2.1 Framework of ARO method

We formulated the security-constrained TEP as a two-stage robust optimization model. The framework of this model is illustrated in Fig. 1. In the first stage (upper-level problem), the optimal transmission construction plan is made with the transmission expansion planning. In the second stage, the optimal power flow solution with the worst contingency is derived. Accordingly, the second stage problem is divided into a middle-level problem and a lower-level problem. The middle-level problem detects the worst N-2 contingency that maximizes the operation cost. By contrast, the lower-level problem obtains the optimal power flow solution that minimizes the operation cost with the realization of the worst contingency.

Fig. 1
figure 1

Framework of two-stage robust security-constrained TEP

2.2 Model formulation

A mathematical formulation of this problem is given below as a mixed integer trilevel programming problem. For the sake of brevity, formulations are presented in the form of vectors and matrices.

$$\text{min} \;{\varvec{C}}_{I}^{\text{T}} {\varvec{x}} + \mathop {\text{max} }\limits_{{{\varvec{w}},{\varvec{z}} \in\varvec{\varOmega}({\varvec{x}})}} \mathop {\text{min} }\limits_{{{\varvec{p}}_{g} ,{\varvec{p}}_{r} \in \varvec{\mathcal{F}}({\varvec{x}},{\varvec{w}},{\varvec{z}})}} \left( {{\varvec{C}}_{p}^{\text{T}} {\varvec{p}}_{g} + {\varvec{C}}_{r}^{\text{T}} {\varvec{p}}_{r} } \right)$$
(1)
$${\varvec{C}}_{I}^{\text{T}} {\varvec{x}} \le \varPi$$
(2)
$$x_{i} \in \{ 0,1\} \quad \forall i$$
(3)
$$\begin{aligned} \varvec{\mathcal{F}}({\varvec{x}},{\varvec{w}},{\varvec{z}}) & = \{ {\varvec{p}}_{g} \in {\varvec{R}}^{{n_{g} }} ,{\varvec{p}}_{r} \in {\varvec{R}}^{{n_{b} }} |{\varvec{C}}_{g} {\varvec{p}}_{g} + \\ & \quad {\varvec{p}}_{r} - {\varvec{C}}_{ft} {\varvec{p}}_{f1} - {\varvec{C}}_{ft} {\varvec{p}}_{f2} = {\varvec{p}}_{d} ,{\varvec{p}}_{f1} = [{\varvec{w}}]{\varvec{B}}_{f1}^{{}} \varvec{\theta} , \\ & \quad {\varvec{p}}_{f2} = [{\varvec{x}}]{\varvec{B}}_{f2} \varvec{\theta} ,{\varvec{P}}_{f1}^{\text{min} } \le {\varvec{p}}_{f1} \le {\varvec{P}}_{f1}^{\text{max} } ,{\varvec{P}}_{f2}^{\text{min} } \le \\ & \quad {\varvec{p}}_{f2} \le {\varvec{P}}_{f2}^{\text{max} } ,[{\varvec{z}}]{\varvec{P}}_{g}^{\text{min} } \le {\varvec{p}}_{g} \le [{\varvec{z}}]{\varvec{P}}_{g}^{\text{max} } ,{\varvec{P}}_{r}^{\text{min} } \le \\ & \quad {\varvec{p}}_{r} \le {\varvec{P}}_{r}^{\text{max} } ,\varvec{\theta}^{\text{min} } \le \varvec{\theta} \le \varvec{\theta}^{\text{max} } \} \\ \end{aligned}$$
(4)
$${\varvec{C}}_{g} {\varvec{p}}_{g} + {\varvec{p}}_{r} - {\varvec{C}}_{ft} {\varvec{p}}_{f1} - {\varvec{C}}_{ft} {\varvec{p}}_{f2} = {\varvec{p}}_{d} \quad {\varvec{u}}_{1}$$
(5)
$${\varvec{p}}_{f1}^{{}} = [{\varvec{w}}]{\varvec{B}}_{f1}^{{}} \varvec{\theta} \quad {\varvec{u}}_{2}$$
(6)
$${\varvec{p}}_{f2} = [{\varvec{x}}]{\varvec{B}}_{f2} \varvec{\theta} \quad {\varvec{u}}_{3}$$
(7)
$${\varvec{P}}_{f1}^{\text{min} } \le {\varvec{p}}_{f1} \le {\varvec{P}}_{f1}^{\text{max} } \quad {\varvec{u}}_{4} ,{\varvec{u}}_{5}$$
(8)
$${\varvec{P}}_{f2}^{\text{min} } \le {\varvec{p}}_{f2} \le {\varvec{P}}_{f2}^{\text{max} } \quad {\varvec{u}}_{6} ,{\varvec{u}}_{7}$$
(9)
$$[{\varvec{z}}]{\varvec{P}}_{g}^{\text{min} } \le {\varvec{p}}_{g} \le [{\varvec{z}}]{\varvec{P}}_{g}^{\text{max} } \quad {\varvec{u}}_{8} ,{\varvec{u}}_{9}$$
(10)
$${\varvec{P}}_{r}^{\text{min} } \le {\varvec{p}}_{r} \le {\varvec{P}}_{r}^{\text{max} } \quad {\varvec{u}}_{10} ,{\varvec{u}}_{11}$$
(11)
$$\varvec{\theta}_{{}}^{\text{min} } \le \varvec{\theta} \le \varvec{\theta}_{{}}^{\text{max} } \quad {\varvec{u}}_{12} ,{\varvec{u}}_{13}$$
(12)

where \({\varvec{x}}\) is the \(n_{x}\) × 1 binary vector indicating whether candidate lines are built or not, \(n_{x}\) is the number of candidate lines; \(x_{i}\) is the element of \({\varvec{x}}\); \({\varvec{w}}\) is the \(n_{l}\) × 1 binary vector indicating the status of existing lines, \(n_{l}\) is the number of existing lines; \({\varvec{z}}\) is the \(n_{g}\) × 1 binary vector indicating the status of generators, \(n_{g}\) is the number of generators; \(\varvec{\mathcal{F}}( \cdot )\) is the feasibility region function; \(\varvec{\varOmega}( \cdot )\) is the uncertainty set; \({\varvec{p}}_{g}^{{}}\) is the \(n_{g}\) × 1 vector of generator outputs; \({\varvec{p}}_{r}^{{}}\) is the \(n_{b}\) × 1 vector of load shedding power, \(n_{b}\) is the number of buses; \(\varPi\) is the investment budget of transmission expansion; \({\varvec{C}}_{I}^{{}}\) is the \(n_{x}\) × 1 vector of investment cost; \({\varvec{C}}_{p}^{{}}\) is the \(n_{g}\) × 1 vector of generation cost; \({\varvec{C}}_{r}^{{}}\) is the \(n_{g}\) × 1 vector of load shedding cost; \({\varvec{u}}_{1}\) is the \(n_{b}\) × 1 vector of dual variables associated with power balance equation; \({\varvec{u}}_{2}\) is the \(n_{l}\) × 1 vector of dual variables associated with the power flow of existing lines; \({\varvec{u}}_{3}\) is the \(n_{x}\) × 1 vector of dual variables associated with the power flow of candidate lines; \({\varvec{u}}_{4} ,{\varvec{u}}_{5}\) are the \(n_{l}\) × 1 vectors of dual variables associated with lower and upper limits on power flow of existing lines; \({\varvec{u}}_{6} ,{\varvec{u}}_{7}\) are the \(n_{x}\) × 1 vectors of dual variables associated with lower and upper limits on power flow of candidate lines; \({\varvec{u}}_{8} ,{\varvec{u}}_{9}\) are the \(n_{g}\) × 1 vectors of dual variables associated with lower and upper limits on generator outputs; \({\varvec{u}}_{10} ,{\varvec{u}}_{11}\) are the \(n_{b}\) × 1 vectors of dual variables associated with lower and upper limits on load shedding power; \({\varvec{u}}_{12} ,{\varvec{u}}_{13}\) are the \(n_{b}\) × 1 vectors of dual variables associated with lower and upper limits on phase angles; \({\varvec{C}}_{g}^{{}}\) is the \(n_{b}\) × \(n_{g}\) generator connection matrix, its \((i,j)^{\text{th}}\) element is 1 if generator j is located at bus i and 0 otherwise; \({\varvec{C}}_{ft}^{{}}\) is the \(n_{b}\) × \(n_{l}\) line connection matrix, its \((i,j)^{\text{th}}\) element is 1 if line j starts at bus i; \({\varvec{p}}_{d}^{{}}\) is the \(n_{b} \times 1\) vector of loads; \({\varvec{p}}_{f1}^{{}}\) is the \(n_{l} \times 1\) vector of power flow of existing lines; \({\varvec{p}}_{f2}^{{}}\) is the \(n_{x} \times 1\) vector of power flow of candidate lines; \(\varvec{\theta}\) is the \(n_{b}\) × 1 vector of phase angles; \({\varvec{B}}_{f1}\) is the \(n_{l}\) × \(n_{b}\) susceptance matrix of existing lines such that \({\varvec{B}}_{f1} \varvec{\theta}\) is the vector of power injections at the “from” end; \({\varvec{B}}_{f2}\) is the \(n_{x}\) × \(n_{b}\) susceptance matrix of candidate lines such that \({\varvec{B}}_{f2} \varvec{\theta}\) is the vector of power injections at the “from” end; \({\varvec{P}}_{f1}^{\text{max} }\) is the \(n_{l}\) × 1 vector of the rating of existing lines; \({\varvec{P}}_{f2}^{\text{max} }\) is the \(n_{x}\) × 1 vector of the rating of candidate lines; \({\varvec{P}}_{f1}^{\text{min} } = - {\varvec{P}}_{f1}^{\text{max} }\); \({\varvec{P}}_{f2}^{\text{min} } = - {\varvec{P}}_{f2}^{\text{max} }\); \({\varvec{P}}_{g}^{\text{min} } ,{\varvec{P}}_{g}^{\text{max} }\) are the \(n_{g}\) × 1 vectors of lower and upper limits on generator outputs; \({\varvec{P}}_{r}^{\text{min} } ,{\varvec{P}}_{r}^{\text{max} }\) are the \(n_{b}\) × 1 vectors of lower and upper limits on load shedding power; \(\varvec{\theta}_{{}}^{\text{min} } ,\varvec{\theta}_{{}}^{\text{max} }\) are the \(n_{b}\) × 1 vectors of lower and upper limits on phase angles.

The objective function (1) includes the minimization of the investment cost and the operation cost with the worst contingency. Constraint (2) means the investment cost is within a specific budget, and the binary nature of investment variables is modeled in constraint (3). The term \(\varvec{\mathcal{F}}({\varvec{x}},{\varvec{w}},{\varvec{z}})\) denotes the feasibility region (4)–(12) with the worst contingency, which takes the transmission construction plan \({\varvec{x}}\) and the component status \({\varvec{w}}\), \({\varvec{z}}\) as input parameters. Concretely, constraint (5) represents the power balance equation. Constraints (6) and (7) represent the power flow of existing lines and candidate lines, respectively. Constraints (8) and (9) represent the branch power rating limit of existing lines and candidate lines, respectively. Constraint (10) requires generator outputs to be within the generator limits. In addition, the operator “[ ]” is used to generate a square diagonal matrix with the elements of the vector on the main diagonal. Constraint (11) limits the amount of load shedding. Constraint (12) limits the phase angles.

2.3 Uncertainty set

The uncertainty set \(\varvec{\varOmega}( \cdot )\) takes the transmission construction plan \({\varvec{x}}\) as input parameters and provides the worst contingency, as shown in (13). Binary variables \(w_{i}\) and \(z_{i}\) denote the status of existing lines and generators: 1 indicates that a component is available and 0 indicates that a component fails. The N-2 security criterion is modelled by the uncertainty set that comprises existing line failures and generator failures.

$$\begin{aligned}\varvec{\varOmega}({\varvec{x}}) & = \{ {\varvec{w}} \in {\varvec{Z}}^{{n_{l} }} ,{\varvec{z}} \in {\varvec{Z}}^{{n_{g} }} |\sum\limits_{i} {w_{i} } + \sum\limits_{i} {z_{i} } \\ & \quad \ge n_{l} + n_{g} - 2,\;w_{i} ,z_{i} \in \{ 0,1\} ,\;\forall i\} \\ \end{aligned}$$
(13)

3 Contingency-aware method for N-2 security-constrained TEP

In this section, we present a contingency-aware method for security-constrained TEP. Figure 2 provides the schematic diagram of this method. The key idea of this method is to detect both the worst contingency and the potential contingencies. MP represents the master problem that minimizes the investment cost of transmission network expansion and the operation cost under contingencies. SP0 to SP2 represent a series of the bi-level “max–min” subproblems that maximize the optimal operation cost with the worst contingency and the potential contingencies. The CUTS is the set of additional constraints formed by the worst contingency and the potential contingencies.

Fig. 2
figure 2

Schematic diagram for contingency-aware method

3.1 Uncertainty set considering candidate line failures

The N-2 security criterion is modelled by the uncertainty set \(\varvec{\varOmega}_{0} ( \cdot )\) which comprises all N-2 contingencies including candidate line failures.

$$\begin{aligned}\varvec{\varOmega}_{0} ({\varvec{x}}) & = \{ {\varvec{w}} \in {\varvec{Z}}^{{n_{l} }} ,{\varvec{y}} \in {\varvec{Z}}^{{n_{x} }} ,{\varvec{z}} \in {\varvec{Z}}^{{n_{g} }} | \\ & \quad \sum\limits_{i} {w_{i} } + \sum\limits_{i} {y_{i} } + \sum\limits_{i} {z_{i} } \ge n_{l} + n_{x} + n_{g} - 2 \\ & \quad x_{i} + y_{i} \ge 1,w_{i} ,y_{i} ,z_{i} \in \{ 0,1\} ,\;\forall i\} \\ \end{aligned}$$
(14)

where \({\varvec{y}}\) is the \(n_{x}\) × 1 binary vector indicating the status of candidate lines; and \(y_{i}\) is the element of \({\varvec{y}}\).

Different from the ARO method presented in Section 2, the failure of candidate lines is modelled in a constraint: \({\varvec{p}}_{f2} = [{\varvec{x}}][{\varvec{y}}]{\varvec{B}}_{f2} \varvec{\theta}\). The power flow of candidate lines is associated with the product of two binary variables: \(x_{i}\) indicates whether the candidate line \(i\) is built (\(x_{i} = 1\)) or not (\(x_{i} = 0\)), and \(y_{i}\) indicates whether the candidate line \(i\) is available (\(y_{i} = 1\)) or fails (\(y_{i} = 0\)). Moreover, because a candidate line that has not been built cannot fail, there exists a logical relationship between \(x_{i}\) and \(y_{i}\), which requires that the two binary variables cannot be 0 simultaneously. Therefore, we add a logical constraint \(x_{i} + y_{i} \ge 1\) into the uncertainty set. The main challenge for considering candidate line failures is that the constraint involves the product of two binary variables, which increases the complexity of the model. In Section 4, we will present techniques to solve this problem.

3.2 Master problem

The master problem is defined in (15). The worst contingency and the potential contingencies detected in the subproblems are iteratively added to the CUTS. Because DC power flow is used, constraints in CUTS are linear. Thus, the master problem is a mixed integer linear programming (MILP) problem.

$$\left\{ \begin{array}{c} \text{min} ({\varvec{C}}_{I}^{\text{T}} {\varvec{x}} + \alpha ) \hfill \\ {\text{s}} . {\text{t}} . \;{\varvec{C}}_{I}^{\text{T}} {\varvec{x}} \le \varPi \hfill \\ \,\, \,\,\,\, \,\,\,\, \,\,\,\, x_{i} \in \{ 0,1\} \hfill \\ C_{UTS} \hfill \\ \end{array} \right.$$
(15)

where \(\alpha\) is an auxiliary variable.

3.3 Subproblem

The subproblem SP0 is formulated below. It is a bi-level “max–min” optimization problem that can detect the worst contingency that maximizes the operation cost. The operation cost consists of the generation cost and the punishment cost of load shedding with the contingency.

$$\mathop {\text{max} }\limits_{{{\varvec{w}},{\varvec{y}},{\varvec{z}} \in\varvec{\varOmega}_{0} ({\varvec{x}})}} \mathop {\text{min} }\limits_{{{\varvec{p}}_{g} ,{\varvec{p}}_{r} \in \varvec{\mathcal{F}}({\varvec{x}},{\varvec{w}},{\varvec{y}},{\varvec{z}})}} ({\varvec{C}}_{p}^{\text{T}} {\varvec{p}}_{g} + {\varvec{C}}_{r}^{\text{T}} {\varvec{p}}_{r} )$$
(16)

For convenience, we introduce an aggregate variable \({\varvec{v}} = [{\varvec{w}}^{\text{T}} ,{\varvec{y}}^{\text{T}} ,{\varvec{z}}^{\text{T}} ]^{\text{T}}\), which comprises the status of existing lines, candidate lines and generators. Here, \({\bar{\varvec{v}}}^{(0)}\) denotes its value derived from the subproblem SP0.

$${\bar{\varvec{v}}}^{(0)} = \arg \;\mathop {\text{max} }\limits_{{{\varvec{w}},{\varvec{y}},{\varvec{z}} \in\varvec{\varOmega}_{0} ({\varvec{x}})}} \mathop {\text{min} }\limits_{{{\varvec{p}}_{g} ,{\varvec{p}}_{r} \in \varvec{\mathcal{F}}({\varvec{x}},{\varvec{w}},{\varvec{y}},{\varvec{z}})}} ({\varvec{C}}_{p}^{\text{T}} {\varvec{p}}_{g} + {\varvec{C}}_{r}^{\text{T}} {\varvec{p}}_{r} )$$
(17)

3.4 Potential contingency

By solving subproblem SP0, we can obtain the worst contingency \({\bar{\varvec{v}}}^{(0)}\) and the corresponding fault components. The set \({\mathcal{I}} = \{ i|\bar{v}_{i}^{(0)} = 0\}\) contains the index of the fault components. Note that the size of \({\mathcal{I}}\) equals the number of components that fail simultaneously. Assuming one of the component failures with the worst contingency can be avoided, i.e., forcing the status of the fault component to be 1, \(\bar{v}_{{{\mathcal{I}}(1)}}^{(0)} = 1\), \(\bar{v}_{{{\mathcal{I}}(2)}}^{(0)} = 1\), we can obtain the potential contingencies by solving subproblems SP1 and SP2 with the new uncertainty sets \(\varvec{\varOmega}_{1} =\varvec{\varOmega}_{0} \cup \{ \bar{v}_{{{\mathcal{I}}(1)}}^{(0)} = 1\}\) and \(\varvec{\varOmega}_{2} =\varvec{\varOmega}_{0} \cup \{ \bar{v}_{{{\mathcal{I}}(2)}}^{(0)} = 1\}\). SP1 and SP2 are expressed as (18) and (19), respectively. Because the worst contingency has been excluded from the uncertainty set, the secondary worst contingencies that maximize the operation cost can be obtained.

$$\mathop {\text{max} }\limits_{{{\varvec{w}},{\varvec{y}},{\varvec{z}} \in\varvec{\varOmega}_{1} ({\varvec{x}})}} \mathop {\text{min} }\limits_{{{\varvec{p}}_{g} ,{\varvec{p}}_{r} \in \varvec{\mathcal{F}}({\varvec{x}},{\varvec{w}},{\varvec{y}},{\varvec{z}})}} ({\varvec{C}}_{p}^{\text{T}} {\varvec{p}}_{g} + {\varvec{C}}_{r}^{\text{T}} {\varvec{p}}_{r} )$$
(18)
$$\mathop {\text{max} }\limits_{{{\varvec{w}},{\varvec{y}},{\varvec{z}} \in\varvec{\varOmega}_{2} ({\varvec{x}})}} \mathop {\text{min} }\limits_{{{\varvec{p}}_{g} ,{\varvec{p}}_{r} \in \varvec{\mathcal{F}}({\varvec{x}},{\varvec{w}},{\varvec{y}},{\varvec{z}})}} ({\varvec{C}}_{p}^{\text{T}} {\varvec{p}}_{g} + {\varvec{C}}_{r}^{\text{T}} {\varvec{p}}_{r} )$$
(19)

Similarly, \({\bar{\varvec{v}}}^{(1)}\) and \({\bar{\varvec{v}}}^{(2)}\) denote the potential contingencies, which are the optimal solutions of SP1 and SP2, respectively.

$${\bar{\varvec{v}}}^{(1)} = \arg \;\mathop {\text{max} }\limits_{{{\varvec{w}},{\varvec{y}},{\varvec{z}} \in\varvec{\varOmega}_{1} ({\varvec{x}})}} \mathop {\text{min} }\limits_{{{\varvec{p}}_{g} ,{\varvec{p}}_{r} \in \varvec{\mathcal{F}}({\varvec{x}},{\varvec{w}},{\varvec{y}},{\varvec{z}})}} ({\varvec{C}}_{p}^{\text{T}} {\varvec{p}}_{g} + {\varvec{C}}_{r}^{\text{T}} {\varvec{p}}_{r} )$$
(20)
$${\bar{\varvec{v}}}^{(2)} = \arg \;\mathop {\text{max} }\limits_{{{\varvec{w}},{\varvec{y}},{\varvec{z}} \in\varvec{\varOmega}_{2} ({\varvec{x}})}} \mathop {\text{min} }\limits_{{{\varvec{p}}_{g} ,{\varvec{p}}_{r} \in \varvec{\mathcal{F}}({\varvec{x}},{\varvec{w}},{\varvec{y}},{\varvec{z}})}} ({\varvec{C}}_{p}^{\text{T}} {\varvec{p}}_{g} + {\varvec{C}}_{r}^{\text{T}} {\varvec{p}}_{r} )$$
(21)

Once the worst contingency \({\bar{\varvec{v}}}^{(0)}\) and the potential contingencies \({\bar{\varvec{v}}}^{(1)}\) and \({\bar{\varvec{v}}}^{(2)}\) are obtained, the CUTS can be updated in the master problem as expressed below. Note that the variables with a symbol “-” above are fixed.

$$\alpha \ge {\varvec{C}}_{p}^{\text{T}} {\varvec{p}}_{g}^{(m)} + {\varvec{C}}_{r}^{\text{T}} {\varvec{p}}_{r}^{(m)}$$
(22)
$${\varvec{C}}_{g} {\varvec{p}}_{g}^{(m)} + {\varvec{p}}_{r}^{(m)} - {\varvec{C}}_{ft1} {\varvec{p}}_{f1}^{(m)} - {\varvec{C}}_{ft1} {\varvec{p}}_{f2}^{(m)} = {\varvec{p}}_{d}$$
(23)
$${\varvec{p}}_{f1}^{(m)} = [{\bar{\varvec{w}}}^{(m)} ]{\varvec{B}}_{f1}^{{}} \varvec{\theta}_{{}}^{(m)}$$
(24)
$${\varvec{p}}_{f2}^{(m)} = [{\varvec{x}}][{\bar{\varvec{y}}}^{(m)} ]{\varvec{B}}_{f2} \varvec{\theta}^{(m)}$$
(25)
$${\varvec{P}}_{f1}^{\text{min} } \le {\varvec{p}}_{f1}^{(m)} \le {\varvec{P}}_{f1}^{\text{max} }$$
(26)
$${\varvec{P}}_{f2}^{\text{min} } \le {\varvec{p}}_{f2}^{(m)} \le {\varvec{P}}_{f2}^{\text{max} }$$
(27)
$$[{\bar{\varvec{z}}}^{(m)} ]{\varvec{P}}_{g}^{\text{min} } \le {\varvec{p}}_{g}^{(m)} \le [{\bar{\varvec{z}}}^{(m)} ]{\varvec{P}}_{g}^{\text{max} }$$
(28)
$$\varvec{\theta}_{{}}^{\text{min} } \le \varvec{\theta}^{(m)} \le \varvec{\theta}_{{}}^{\text{max} }$$
(29)

where \({\varvec{p}}_{g}^{(m)}\), \({\varvec{p}}_{r}^{(m)}\), \({\varvec{p}}_{f1}^{(m)}\), \({\varvec{p}}_{f2}^{(m)}\), \(\varvec{\theta}^{(m)}\) are new variables generated corresponding to \({\bar{\varvec{v}}}^{(m)}\), \(m = 0,1,2\).

Constraint (25) involves a nonlinear problem that can be transformed to the following constraint by introducing a sufficiently large constant \(M\):

$$\left| {{\varvec{p}}_{f2}^{(m)} - [{\bar{\varvec{y}}}^{(m)} ]{\varvec{B}}_{f2} \varvec{\theta}_{{}}^{(m)} } \right| \le ({\bf{1}} - {\varvec{x}})M \quad m = 0,1,2$$
(30)

3.5 Discussion of differences in methods

Comparing the ARO method with the contingency-aware method proposed in this paper, the main differences between them are as follows: ① the candidate line failures are considered in the contingency-aware method; ② the subproblem of the ARO method is supposed to find the worst contingency, while the subproblem of the contingency-aware method is designed to acquire a series of potential contingencies as well as the worst contingency. It is worth mentioning that those potential contingencies play a key role in improving the computational efficiency of security-constrained TEP, which will be illustrated in the case study.

4 Solution techniques

Solving the proposed model involves some reformulation techniques. The master problem is a MILP problem, which can be solved through commercial software packages like CPLEX [26] or Gurobi [27]. The above subproblems share the same bi-level “max–min” structure and contain integer and continuous variables. The subproblem can be solved by the following techniques. For SP0, given a transmission plan \({\bar{\varvec{x}}}\) and a contingency scenario \({\bar{\varvec{v}}}\), the minimum problem in SP0 is a linear programming problem because all integer variables are fixed. By deriving the dual form of the minimum problem, the subproblem is equivalent to a single level maximum problem (31)–(40).

$$\begin{aligned} & \mathop {\text{max} }\limits_{{{\varvec{w}},{\varvec{y}},{\varvec{z}},{\varvec{u}}_{1} ,{\varvec{u}}_{2} , \ldots ,{\varvec{u}}_{13} }} ({\varvec{P}}_{d}^{\text{T}} {\varvec{u}}_{1} + ({\varvec{P}}_{f1}^{\text{min} } )^{\text{T}} {\varvec{u}}_{4} - ({\varvec{P}}_{f1}^{\text{max} } )^{\text{T}} {\varvec{u}}_{5} \\ & \quad \quad + ({\varvec{P}}_{f2}^{\text{min} } )^{\text{T}} {\varvec{u}}_{6} - ({\varvec{P}}_{f2}^{\text{max} } )^{\text{T}} {\varvec{u}}_{7} + ([{\varvec{z}}]{\varvec{P}}_{g}^{\text{min} } )^{\text{T}} {\varvec{u}}_{8} \\ & \quad \quad - ([{\varvec{z}}]{\varvec{P}}_{g}^{\text{max} } )^{\text{T}} {\varvec{u}}_{9} + ({\varvec{P}}_{r}^{\text{min} } )^{\text{T}} {\varvec{u}}_{10} - ({\varvec{P}}_{r}^{\text{max} } )^{\text{T}} {\varvec{u}}_{11} \\ & \quad \quad + (\varvec{\theta}^{\text{min} } )^{\text{T}} {\varvec{u}}_{12} - (\varvec{\theta}^{\text{max} } )^{\text{T}} {\varvec{u}}_{13} ) \\ \end{aligned}$$
(31)
$${\varvec{C}}_{g}^{\text{T}} {\varvec{u}}_{1} + {\varvec{u}}_{8} - {\varvec{u}}_{9} \le {\varvec{C}}_{p}^{{}}$$
(32)
$${\varvec{u}}_{1} + {\varvec{u}}_{10} - {\varvec{u}}_{11} \le {\varvec{C}}_{r}^{{}}$$
(33)
$$- {\varvec{C}}_{ft1}^{\text{T}} {\varvec{u}}_{1} + {\varvec{u}}_{2} + {\varvec{u}}_{4} - {\varvec{u}}_{5} = {\bf{0}}$$
(34)
$$- {\varvec{C}}_{ft2}^{\text{T}} {\varvec{u}}_{1} + {\varvec{u}}_{3} + {\varvec{u}}_{6} - {\varvec{u}}_{7} = {\bf{0}}$$
(35)
$$- {\varvec{B}}_{f1}^{\text{T}} [{\varvec{w}}]^{\text{T}} {\varvec{u}}_{2} - {\varvec{B}}_{f2}^{\text{T}} [{\varvec{y}}]^{\text{T}} [{\bar{\varvec{x}}}]^{\text{T}} {\varvec{u}}_{3} + {\varvec{u}}_{12} - {\varvec{u}}_{13} = {\bf{0}}$$
(36)
$${\varvec{u}}_{i} \ge {\bf{0}}\;\;\;i = 4,5, \cdots ,13$$
(37)
$$\sum\limits_{i} {w_{i} } + \sum\limits_{i} {y_{i} } + \sum\limits_{i} {z_{i} } \ge n_{l} + n_{x} + n_{g} - 2$$
(38)
$${\bar{\varvec{x}}} + {\varvec{y}} \ge {\bf{1}}$$
(39)
$$w_{i} ,y_{i} ,z_{i} \in \{ 0,1\}$$
(40)

Note that bilinear terms exist in both objective function (31) and constraint (36). The bilinear terms \(([{\varvec{z}}]{\varvec{P}}_{g}^{\text{min} } )^{\text{T}} {\varvec{u}}_{8}\) and \(([{\varvec{z}}]{\varvec{P}}_{g}^{\text{max} } )^{\text{T}} {\varvec{u}}_{9}\) in the objective function are the product of a binary variable and a continuous variable. The terms \([{\varvec{z}}]^{\text{T}} {\varvec{u}}_{8}\) and \([{\varvec{z}}]^{\text{T}} {\varvec{u}}_{9}\) can be linearized by introducing auxiliary variables \(\varvec{\beta}_{8}\) and \(\varvec{\beta}_{9}\), and the following constraints.

$$\varvec{\beta}_{8} \le {\varvec{u}}_{8}$$
(41)
$$\varvec{\beta}_{8} \le M{\varvec{z}}$$
(42)
$$\varvec{\beta}_{9} \ge {\varvec{u}}_{9} - M({\bf{1}} - {\varvec{z}})$$
(43)
$$\varvec{\beta}_{9} \ge \bf{0}$$
(44)

Constraint (36) contains the bilinear terms \({\varvec{B}}_{f}^{\text{T}} [{\varvec{w}}]^{\text{T}} {\varvec{u}}_{2}\), \({\varvec{B}}_{f}^{\text{T}} [{\bar{\varvec{x}}}]^{\text{T}} [{\varvec{y}}]^{\text{T}} {\varvec{u}}_{3}\). The terms \([{\varvec{w}}]^{\text{T}} {\varvec{u}}_{2}\) and \([{\varvec{y}}]^{\text{T}} {\varvec{u}}_{3}\) can be replaced by auxiliary variables \(\varvec{\beta}_{2}\) and \(\varvec{\beta}_{3}\), respectively, with the following constraints introduced.

$$\varvec{\beta}_{2} = {\varvec{u}}_{2} - {\varvec{h}}_{2}$$
(45)
$$- M{\varvec{w}} \le \varvec{\beta}_{2} \le M{\varvec{w}}$$
(46)
$$- M({\bf{1}} - {\varvec{w}}) \le {\varvec{h}}_{2} \le M({\bf{1}} - {\varvec{w}})$$
(47)
$$\varvec{\beta}_{3} = {\varvec{u}}_{3} - {\varvec{h}}_{3}$$
(48)
$$- M{\varvec{y}} \le \varvec{\beta}_{3} \le M{\varvec{y}}$$
(49)
$$- M({\bf{1}} - {\varvec{y}}) \le {\varvec{h}}_{3} \le M({\bf{1}} - {\varvec{y}})$$
(50)

Finally, because all the bilinear terms are linearized, the subproblem SP0 (16) is equivalent to a MILP problem, whose objective function is shown in (51), and its constraints include (32)–(35), (37)–(50) and (52). Constraint (36) is replaced by constraint (52). SP1 and SP2 can also be solved by the same techniques. The algorithm is summarized in Fig. 3. ε denotes the convergence threshold.

Fig. 3
figure 3

Flow chart of the proposed algorithm

$$\begin{aligned} & \mathop {\text{max} }\limits_{{{\varvec{w}},{\varvec{y}},{\varvec{z}},{\varvec{u}}_{1} ,{\varvec{u}}_{2} , \cdots ,{\varvec{u}}_{13} ,\varvec{\beta}_{2} ,\varvec{\beta}_{3} ,\varvec{\beta}_{8} ,\varvec{\beta}_{9} }} ({\varvec{P}}_{d}^{\text{T}} {\varvec{u}}_{1} + ({\varvec{P}}_{f1}^{\text{min} } )^{\text{T}} {\varvec{u}}_{4} - \\ & \quad \quad ({\varvec{P}}_{f1}^{\text{max} } )^{\text{T}} {\varvec{u}}_{5} + ({\varvec{P}}_{f2}^{\text{min} } )^{\text{T}} {\varvec{u}}_{6} - ({\varvec{P}}_{f2}^{\text{max} } )^{\text{T}} {\varvec{u}}_{7} + \\ & \quad \quad ({\varvec{P}}_{g}^{\text{min} } )^{\text{T}} \varvec{\beta}_{8} \; - ({\varvec{P}}_{g}^{\text{max} } )^{\text{T}} \varvec{\beta}_{9} + ({\varvec{P}}_{r}^{\text{min} } )^{\text{T}} {\varvec{u}}_{10} - \\ & \quad \quad ({\varvec{P}}_{r}^{\text{max} } )^{\text{T}} {\varvec{u}}_{11} + (\varvec{\theta}^{\text{min} } )^{\text{T}} {\varvec{u}}_{12} - (\varvec{\theta}^{\text{max} } )^{\text{T}} {\varvec{u}}_{13} ) \\ \end{aligned}$$
(51)
$$- {\varvec{B}}_{f1}^{\text{T}} \varvec{\beta}_{2} - {\varvec{B}}_{f2}^{\text{T}} [{\bar{\varvec{x}}}]^{\text{T}} \varvec{\beta}_{3} + {\varvec{u}}_{12} - {\varvec{u}}_{13} = {\bf{0}}$$
(52)

5 Case study

In this section, the proposed approach is conducted on the IEEE RTS 24-bus [28] and the IEEE 118-bus test systems [29]. The computation is carried out on a PC with Intel 2.5 GHz CPU and 8 GB RAM. The algorithm uses the YALMIP platform [30] and the Gurobi solver 7.5.2 [27]. The termination tolerance of the algorithm is set to 0.01%.

5.1 IEEE RTS 24-bus test system

The first case study was based on the IEEE RTS 24-bus test system [28], as shown in Fig. 4, which has 24 buses, 33 generators, 38 existing lines and 38 candidate lines, i.e., each existing line corresponds to one candidate line. The construction cost of transmission lines is set to $0.2 million per mile [31]. The total generation capacity is 3405 MW, and the total load is 2850 MW. All data are from MATPOWER [32]. The 23rd, 24th, and 33rd generators have 400, 400, and 350 MW capacities, respectively. The failure of any two of them simultaneously would lead to a total load larger than the total generation capacity. To make sure that at least two large capacity generators are available, we added an additional constraint \(z_{23} + z_{24} + z_{33} \ge 2\) to the uncertainty set. For comparison, we implemented the following three methods to tackle the N-2 security-constrained TEP problem: ① M1, the deterministic planning method that takes N-2 contingencies as constraints; ② M2, the ARO method presented in [21]; ③ M3, the proposed contingency-aware method.

Fig. 4
figure 4

Diagram of IEEE RTS 24-bus test system

  1. 1)

    Comparison of planning results

First, to verify the effectiveness and the correctness of M3, we compared the planning results of M3 to that of M1 and M2 with the same conditions. Note that the candidate line failures are not considered in all three methods.

We found that the transmission construction plan of M3 (i.e., lines 3, 6, 8, 10, 11, 23) is the same as that of M1 and M2. The investment cost is $27.8 million, the generation cost is $633.2 million, and the load shedding punishment cost is 0. In the post-check, it was found that the construction plan remains robust to the N-2 contingencies that consist of the failures of existing lines and generators.

On the other hand, the effectiveness of M3 can be verified in Table 1, which demonstrates the solving process of M3. At iteration 3, the combined failure of a line and a generator (e.g., line 11 and unit 23) is observed. At iteration 4, the combined failure of two generators (e.g., unit 22 and unit 23) is observed. These observations validate the effectiveness of joint transmission and generation consideration by the contingence-aware method. At the last iteration, there is no contingency that causes load shedding, which also confirms that the planning result can satisfy the N-2 security criterion.

Table 1 Results of each iteration of M3 implemented on IEEE RTS 24-bus test system
  1. 2)

    Comparison of computational efficiency

Second, to demonstrate the computational efficiency of M3, we compared the computational time and the number of iterations of each method, as shown in Table 2.

Table 2 Computational efficiency of methods implemented in IEEE RTS 24-bus test system

Compared with M1, which takes 18639.00 s, M3 only takes 7.94 s. The computational speed of the proposed method is approximately 2000 times faster than the deterministic method. This is because the scale of M3 is much smaller than that of M1 and only the worst contingency is required. Moreover, in the subproblem, the worst contingency can be quickly detected among \(\text{C}_{38 + 33}^{2} = 2485\) contingencies (within 1 s), while several minutes are needed by emulation.

Figure 5 shows the upper and lower bounds of M2 and M3. As seen in Fig. 5, M2 converges in 8 iterations and takes 12.95 s while M3 converges in 5 iterations and only takes 7.94 s. Compared with M2, M3 saves approximately 38.7% of computational time. The results prove the high computational efficiency of the proposed method in dealing with security-constrained TEP.

Fig. 5
figure 5

Upper and lower bounds of M2 and M3 for IEEE RTS 24-bus test system

  1. 3)

    Analysis of computational efficiency

To explain the high efficiency of the proposed method, we have the following observations and analyses. From the comparison between Table 1 and Table 3, M3 can obtain a better first-stage decision in each iteration because more valid information is provided by the subproblem. In contrast, M2 takes the worst contingencies into consideration one by one and needs more iterations. It is important to note that the part of the potential contingencies derived by M3 become the worst contingency in M2, e.g., line contingencies (5, 10), (3, 9), and (6, 7). It is equivalent to considering them in advance in M3. On the other hand, the subproblems of M3 can be solved by parallel computing, and the major computational burden has been significantly alleviated by reducing the number of iterations. The above observations prove the effectiveness of the potential contingencies and explain why the method proposed in this paper has higher computational efficiency.

Table 3 Results of each iteration of M2 implemented on IEEE RTS 24-bus test system

5.2 IEEE 118-bus test system

The second case study is based on the IEEE 118-bus test system, as shown in Fig. 6, which consists of 118 buses, 54 generators, 186 existing lines, and 188 candidate lines, i.e., each existing line has 1 candidate line, except that lines 183 and 184 have 2 candidate lines. The total generation capacity is 9966 MW, and the total load is 4242 MW. All data can be found in [29]. Three methods (M1, M2, and M3) were implemented. Different from Section 5.1, the candidate line failures are considered by M3. Hence the worst contingency should be detected among \(\text{C}_{{186{ + }188 + 54}}^{2} = 91738\) contingencies.

Fig. 6
figure 6

Diagram of IEEE 118-bus test system

  1. 1)

    Comparison of planning results

Table 4 shows the planning results of each method. M1 is unsolvable because it contains too many variables and constraints and runs out of memory. M3 constructs two more lines than M2 and has a higher investment cost. The difference between M2 and M3 lies in that M2 constructs one line of corridor 12–117 and one line of corridor 68–116 while M3 constructs two lines of corridor 12–117 and two lines of corridor 68–116. When candidate line failures are included in N-2 contingencies, the construction plan of M2 cannot satisfy the N-2 security criterion. For example, when the candidate line 68–116 and the existing line 68–118 fail simultaneously, there will be an 84 MW of load shedding in the system of M2. In contrast, the construction plan of M3 has no load shedding with all N-2 contingencies, therefore it can satisfy the N-2 security criterion. Although the construction plan of M2 has a lower investment cost ($125.81 million) than that of M3 ($131.14 million), M2 involves higher operation cost ($754.16 million) incurred by the penalty cost of load shedding ($10.4 million) and hence a higher total cost ($879.97 million). In summary, when candidate line failures are considered, the construction plan given by the proposed method can satisfy the N-2 security criterion while other methods cannot. Moreover, the proposed method saves $5.63 million of total cost compared to the ARO method.

Table 4 Planning results of methods implemented in IEEE 118-bus test system
  1. 2)

    Comparison of computational efficiency

To demonstrate further the computational efficiency of the proposed method in a larger system, Table 5 shows the computational time and the number of iterations of each method, and Fig. 7 presents the upper bounds and the lower bounds of M2 and M3. As seen, M1 is too large to be solved. M2 converges in 57 iterations and takes 2164 s, while M3 converges in only 30 iterations and takes 1619 s. Compared with M2, M3 takes almost half of the number of iterations of M2 to converge and saves approximately 25.2% of computational time. The results validate the improved computational efficiency of the proposed method in dealing with the security-constrained TEP.

Table 5 Computational efficiency of methods implemented in IEEE 118-bus test system
Fig. 7
figure 7

Upper and lower bounds of M2 and M3 for IEEE 118-bus test system

6 Conclusion

To make the transmission construction plan satisfy the N-2 security criterion, we propose a contingency-aware method for the security-constrained TEP problem in this paper. From the comparison of three different methods implemented on two test systems, we have verified the effectiveness and superiority of the proposed contingency-aware method. The main findings are as follows:

  1. 1)

    Robust optimization techniques (the ARO method and the proposed method) handle the security-constrained TEP problem efficiently. The sensitivity analysis of the uncertainty budget is not required, and a bilinear problem involving the product of two continuous variables is avoided. Computational efficiency can be significantly improved compared to the deterministic method. In a small-scale system, the computational speed of the proposed method is approximately 2000 times faster than the deterministic method; in a large-scale system, the deterministic method is unsolvable while the proposed method can obtain an optimal solution efficiently.

  2. 2)

    When candidate line failures are considered, the construction plan given by the proposed method can satisfy the N-2 security criterion while other methods cannot. Considering that candidate line failures can make the transmission construction plan more robust against contingency uncertainties, this plan achieves a better trade-off between investment costs and operation costs.

  3. 3)

    The proposed method is capable of detecting potential contingencies in addition to the worst contingency. When potential contingencies are taken into account, the computational efficiency can be improved by 25% to 38% compared to the ARO method.

Several possible extensions are worth investigating for future research, e.g., an improved model allowing a certain amount of load curtailment, and applications on multi-regional power grids with different security criteria. Moreover, the proposed method could be extended to N-K security-constrained problems in the future work.