## 5 Analysis of Impact of Resource Failures on CPS  
Consider a perturbation vector \(\delta\) and the associated uncertainty model \(\Delta(m)=(m,\delta,\omega)\) due to resource failures. To study the influence of \(\delta\), we construct a residual spatial-temporal network \(RSTN_{j}(V_{j},A_{j})\) based on \(STN_{j}(V_{j},A_{j})\) for \(j\in\boldsymbol{J}\) and the nominal solution \(f\). The nominal solution \(f\) for the Feasibility Problem (FP) can be decomposed into several components, \(f_{1}\), \(f_{2}\), \(f_{3}\), \(\ldots\), \(f_{I}\), with \(f=f_{1}+f_{2}+f_{3}+\ldots+f_{I}=\sum\limits_{j\in J}f_{j}\), where \(f_{j}\) is the component of the solution in spatial-temporal network \(STN_{j}(V_{j},A_{j})\) for type \(j\) task, \(j\in\boldsymbol{J}\). Note that \(f_{j}\) can be divided into two parts, \(f_{j1}\) and \(f_{j2}\), where \(f_{j1}\) denotes the flows in \(STN_{j}(V_{j},A_{j})\) not influenced by the resource failures \(\Delta(m)\) and \(f_{j2}\) represents the flows in \(STN_{j}(V_{j},A_{j})\) influenced by the resource failures \(\Delta(m)\). Before constructing \(RSTN_{j}(V_{j},A_{j})\), we compute the residual capacity \(\widetilde{C}_{rt}\) based on the nominal solution in \(STN_{j}(V_{j},A_{j})\) and resource failures first. The procedure to compute the residual capacity and construct \(RSTN_{j}(V_{j},A_{j})\) is shown as follows. ```
Input: \(STN_{j}(V,A)\), \(f_{j},j\in J\), \(\Pi,\theta,\delta\), \(\Delta(m)=(m,\delta,\omega)\), \(C_{rt},r\in\mathbf{R},\ t\in\{1,2,\ldots,\Pi\}\) Output: \(\widetilde{C}_{rt}\), \(RSTN_{j}(V_{j},A_{j})\), \(Q_{j}^{\delta}\) Step 1: Apply the Algorithm to Construct spatial-temporal network \(STN_{j}(V_{j},A_{j})\) Step 2: \(RSTN_{j}(V_{j},A_{j})\gets STN_{j}(V_{j},A_{j})\) Step 3: Find the flows \(f_{j1}\) not influenced by resource failures \(\delta\) in the solution \(f_{j}\) of \(RSTN_{j}(V_{j},A_{j})\) for \(j\in J\) Find the flows \(f_{j2}\) influenced by resource failures \(\delta\) in the solution \(f_{j}\) of \(RSTN_{j}(V_{j},A_{j})\) for \(j\in J\) Step 4: Remove all the flows \(f_{j1}\) not influenced by the resource failures \(\Delta(m)\) from \(RSTN_{j}(V_{j},A_{j})\) for \(j\in\boldsymbol{J}\) Step 5: Remove the flows influenced \(f_{j2}\) by the resource failures \(\Delta(m)\) from \(RSTN_{j}(V_{j},A_{j})\) for \(j\in J\). Find \(Q_{j}^{\delta}\) denote the quantity of products associated with \(f_{j2}\) influenced by resource failures \(\Delta(m)\). Step 6: \(\widetilde{C}_{rt}\leftarrow C_{rt}\) for each \(r\in\mathbf{R}\) for each period \(t\in\{1,2,\ldots,\Pi\}\) Update the residual resource capacity \(\widetilde{C}_{rt}\) for each \(r\in\mathbf{R}\) for each period \(t\): Update the residual capacity \(\widetilde{C}_{rt}\) by removing the associated resource capacities originally allocated to \(f_{j1}\) from \(C_{rt}\) for \(r\in\mathbf{R}\) for \(j\in\boldsymbol{J}\) Update the residual capacity \(\widetilde{C}_{rt}\) by removing the associated resource capacities due to resource failures \(\delta\) in \(\Delta(m)\) from \(C_{rt}\) for \(r\in\mathbf{R}\) for \(j\in J\): \(\widetilde{C}_{rt}=C_{rt}-\sum\limits_{j\in J}\sum\limits_{a=(u,w)\in A_{rt}}f_{ j1}(u,w)-C_{rt}^{\delta}\forall r\in\mathbf{R}\ \forall t\in\{1,2,\ldots,\Pi\}\), where \(C_{rt}^{\delta}\) is the capacity loss due to resource failures \(\delta\). Feasibility Problem of Residual Spatial-Temporal Network (FPRSTN) \(RSTN_{j}(V,A)\)

\[\min_{f_{j}}\sum\limits_{a=(u,v)\in A_{jrt}}w_{a}f_{j}(u,v)\]

\[\sum\limits_{a=(u,w)\in A_{jrt}}f_{j}(u,w)\leq\widetilde{C}_{rt}\forall r\in \textbf{R}\ \forall t\in\{1,2,\ldots,\Pi\} \tag{6}\]

\[\sum\limits_{w\in V}f_{j}(u,w)=0\ \forall u\
otin\{s,e\} \tag{7}\]

\[\sum\limits_{w\in V}f_{j}(s,w)=Q_{j} \tag{8}\]

\[\sum\limits_{w\in V}f_{j}(w,e)=Q_{j} \tag{9}\]

\[f_{j}(u,v)\in Z\ \forall(u,v)\in A_{j},\ \text{where is the set of nonnegative integers} \tag{10}\]

Consider a perturbation vector \(\delta\) and \(\Delta(m)=(m,\,\delta,\,\omega)\) due to resource failures.