Require: hyperparameters for inner and outerloop convergence criteria
Require: hyperparameters for update of relevant coupling parameters
Require: initial relevant coupling parameters in interface storage
\(k \leftarrow 0\)
repeat
\(l \leftarrow 0\)
repeat
for every \(i \in M\) do
Copy relevant coupling parameters of \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\) from interface storage
Prepare optimization problem formulation
\[\begin{aligned} {}^{i}d^{(k,\,l+1)} \leftarrow{} & \argmin_{{}^{i}d \;\in\; {}^{i}\mathcal{D}} \;\; {}^{i}v_f\!\left({}^{i}r\right) + {}^{i}P\!\left({}^{i}d,\; \left\{{}^{i}_{j}u,\; {}^{j}_{i}u\right\}_{j \in {}^{i}N},\; {}^{i}_{C}u,\; {}^{C}_{i}u\right) \\ & \text{s.t.} \;\; {}^{i}v_g\!\left({}^{i}r\right) \leq 0, \\ & \phantom{\text{s.t.}} \;\; {}^{i}v_h\!\left({}^{i}r\right) = 0, \\ & \phantom{\text{s.t.}} \;\; {}^{i}Q^{\leq}\!\left({}^{i}d,\; \left\{{}^{i}_{j}u,\; {}^{j}_{i}u\right\}_{j \in {}^{i}N},\; {}^{i}_{C}u,\; {}^{C}_{i}u\right) \leq 0, \\ & \phantom{\text{s.t.}} \;\; {}^{i}Q^{=}\!\left({}^{i}d,\; \left\{{}^{i}_{j}u,\; {}^{j}_{i}u\right\}_{j \in {}^{i}N},\; {}^{i}_{C}u,\; {}^{C}_{i}u\right) = 0. \end{aligned}\]
Post-process the optimization
Copy relevant coupling parameters of \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\) to interface storage
end for
for Controller do
Copy relevant coupling parameters of \({}^{C}_{i}u,\; {}^{i}_{C}u \;\forall\; i \in M\) from interface storage
Prepare optimization problem formulation
\[\begin{aligned} \Box \leftarrow{} & \argmin_{\Box} \;\; {}^{C}P\!\left(\Box,\; \left\{{}^{C}_{i}u,\; {}^{i}_{C}u\right\}_{i \in M}\right) \\ & \text{s.t.} \;\; {}^{C}Q^{\leq}\!\left(\Box,\; \left\{{}^{C}_{i}u,\; {}^{i}_{C}u\right\}_{i \in M}\right) \leq 0, \\ & \phantom{\text{s.t.}} \;\; {}^{C}Q^{=}\!\left(\Box,\; \left\{{}^{C}_{i}u,\; {}^{i}_{C}u\right\}_{i \in M}\right) = 0. \end{aligned}\]
Post-process the optimization
Copy relevant coupling parameters of \({}^{C}_{i}u,\; {}^{i}_{C}u \;\forall\; i \in M\) to interface storage
end for
for every \(i \in M\) and Controller in parallel do
Copy relevant coupling parameters of \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\) from interface storage
Update relevant coupling parameters \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\)
Copy relevant coupling parameters of \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\) to interface storage
end for
Compute innerloop convergence criterion
\(l \leftarrow l + 1\)
until innerloop convergence criterion is met
\({}^{i}d^{(k+1)} \leftarrow {}^{i}d^{(k,\,l)} \;\forall\; i \in M\)
for every \(i \in M\) and Controller in parallel do
Copy relevant coupling parameters of \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\) from interface storage
Prepare update of relevant coupling parameters \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\)
Copy relevant coupling parameters of \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\) to interface storage
end for
for every \(i \in M\) and Controller in parallel do
Copy relevant coupling parameters of \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\) from interface storage
Update relevant coupling parameters \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\)
Copy relevant coupling parameters of \({}^{i}_{j}u,\; {}^{j}_{i}u \;\forall\; j \in {}^{i}N\) and \({}^{i}_{C}u,\; {}^{C}_{i}u\) to interface storage
end for
Compute outerloop convergence criterion
\(k \leftarrow k + 1\)
until outerloop convergence criterion is met
return \(\left\{{}^{i}d^{(k)}\right\}_{i \in M}\)