## 2 Problem Description
### Lower-Level Planning
#### 2.3.1 Lower-Level Planning when the Operating Room Is the Bottleneck Resource (R*)  
When the operating room becomes the bottleneck, the lower-level planning model for the operating room is triggered. The objective function of operating room planning at the lower level is given by Equation (36).  
\[\left(obj\right)_{od\tau}=\text{minimize}\left(makespnt\right)_{od\tau}\forall o \in O_{d\tau}\;\forall 0<d\leq D,\;\forall\tau \tag{36}\]  
\[\left(makespnt\right)_{od\tau}=\sum_{p=1}^{P}t_{p}^{compp}\times X_{po}^{d\tau} \;\forall o\in O\;\forall 0<d\leq D\;\forall\tau \tag{37}\]  
\[t_{p}^{comp}\geq(t_{sp}^{arr}+t_{p}^{set}+t_{p}^{sur}+t_{p}^{cl})\times W_{pod \tau}\;\forall p\in P \tag{38}\]  
\[t_{p}^{comp}\geq(t_{sp}^{arr}+t_{pp^{\prime}}^{sds}+t_{p}^{sur}+t_{p}^{cl}) \times S_{pp^{\prime}od\tau}\;\forall p\in P \tag{39}\]  
\[\sum_{p=1}^{P}S_{pp^{\prime}od\tau}=1-V_{pod}\;\forall o\in O\;0<d\leq D\;\forall\tau \tag{40}\]  
\[\sum_{p=1}^{P}S_{pp^{\prime}od\tau}=1-W_{pod}\;\forall o\in O\;0<d\leq D\;\forall\tau \tag{41}\]  
\[\sum_{p=1}^{O}V_{pod\tau}=1\;\forall o\in O,0<d\leq D\;\forall\tau \tag{42}\]  
\[\sum_{p=1}^{P}W_{pod\tau}=1\;\forall o\in O\;\forall 0<d\leq D\;\forall\tau \tag{43}\]  
\[t_{p^{\prime}}^{comp}\geq t_{p}^{comp}+t_{pp^{\prime}}^{sds}+t_{p}^{sur}+t_{p}^ {cl}-M\Big{(}1-S_{pp^{\prime}od\tau}\Big{)}\;\forall p,p^{\prime}\in P\; \forall 0<d\leq D\;\forall\tau \tag{44}\]  
\[\left(makespnt\right)_{od\tau}\geq 0\;\forall o\in O\;\forall 0<d\leq D,\;\forall\tau \tag{45}\]  
\[St_{p}^{t}\geq Dt_{p}^{op}\;\forall p\in P^{o\to i} \tag{46}\]  
\[St_{p}^{up}\geq Dt_{p}^{up}\;\forall p\in P^{o\to w} \tag{47}\]  
The objective function given by Equation (36) aims to minimize the makespan of the operating room. Equation (37) represents the method of calculating the makespan of an operating room. The objective function considered at lower-level planning is significant to minimize the completion time of all surgeries in the allocated operating rooms. The minimum makespan leaves time to accommodate more surgeries, thus leading to increased utilization of operating rooms and cost savings. Equation (38) represents the method of calculating the completion time of the surgery of a patient if they were operated on at the first position in the operating room \(o\). Equation (39) represents the method of calculating the completion time of the surgery of patient \(p^{\prime}\) if they were operated on immediately after patient \(p\) in the operating room \(o\). Equations (38) and (39) also state that each patient can be operated on after the arrival of the surgeon for the patient \(p\). Equation (40) states that each patient must precede another patient unless they are operated on last. Equation (41) states that each patient must be preceded by another patient unless they are operated on first. Equations (42) and (43) impose the constraint that only one patient can be operated on as first and last in the operating room \(o\). Equation (44) imposes that each patient's surgery must be started before the surgery of the previous patient is completed. Equation (45) statesthat the makespan of an operating room must be non-negative. Equations (46) and (47) provide constraints for the ICU and ward, respectively, when the operating room is the bottleneck resource (R*). These constraints limit the starting time of surgery patients in the ICU and ward. The output of the lower-level plan is the optimal schedule of patients in the allocated operating rooms. The optimal schedule is released to the upstream units of the operating room as well as to the ICU and ward to accommodate the patients as per the capacity of the operating room, which is bottleneck resource (R*) on day \(d\) of the planning horizon \(\tau\).