# Proactive Scheduling and Routing of MRP-Based Production with Constrained Resources
## 4 Mathematical Model for Proactive Scheduling and Routing
Second, the model's structure, including its set of constraints and multi-objective function, allows us to answer individual questions Q1-Q4 by appropriately selecting constraints and elements of the objective function, thereby enabling dynamic model construction for each specific question. Table 2 presents the model's parameters and decision variables. Table 3 outlines the individual components of the objective function, while Table 4 provides a brief description of constraints (1)-(18). The objective function primarily relates to cost (two components) and also includes one time-related component. \begin{table}
\begin{tabular}{l l} \hline \hline \multicolumn{1}{c}{**Symbol**} & \multicolumn{1}{c}{**Description**} \\ \hline \multicolumn{3}{c}{Indices} \\ \hline T & Set of execution periods (t-execution period index t \(\in\) T) \\ W & Set of machines/workstations (w-machine/workstation index w \(\in\) W) \\ R & Set of additional resources (r-resource index r \(\in\) R) \\ F & Set of variants of equipping machines/workstations with additional \\  & resources (f-variant index f \(\in\) F) \\ O & Set of customer orders (o-order index o \(\in\) O) \\ E & Set of tasks to be performed (e-task index e \(\in\) E) \\ U & Set of predicted resource unavailability states (u-state index u \(\in\) U) \\ \hline \multicolumn{3}{c}{Parameters} \\ \hline pw\_r\({}_{\text{o}}\) & Agreed end date of the customer order o. If pw\_r\({}_{0}\) = 0, the date is arbitrary. \\  & If task e is part of the customer order o, then pw\_2o,e = 1; otherwise, \\  & pw\_2o,e = 0. \\  & If task e is the last task in the customer order o, then pw\_g\_o,e = 1; otherwise, \\  & pw\_g\_o,e = 0. \\  & If in a variant of equipping f task e can be executed on machine w, then \\  & pt\_w\_t\_e,w = 1; otherwise, pt\_w\_t\_e,w = 0. \\  & Number of quanta/time segments required to execute task e on machine w \\  & in equipment configuration f. \\ pt\_gt\_e,w,r & Quantity of additional resource r required to execute task e on machine w in \\  & equipment configuration f. If pt\_gt\_e,w,r = 0, then the resource is not needed. \\  & If pw\_k\_e1,e2 = 1, then task e2 must be performed before task e1. If pw\_k\_e1,e2 = 0, then there is no direct sequence relation between tasks e1 and e2. \\  & Minimum technological break between the start of task e1 and the end of e2. \\  & Valid only if pw\_k\_e1,e2 = 1. \\  & Maximum technological break between the start of task e1 and the end of e2. \\  & Valid only if pw\_k\_e1,e2 = 1. \\  & If task e1 and e2 must be executed on the same machine, then pw\_r\_e1,e2 = 1; \\  & otherwise, pw\_r\_e1,e2 = 0. \\ pt\_m\_r & Available quantity of additional resource r. \\  & If in the state of resource unavailability, u machine w is available, then \\  & pd\_a\_u,w = 1; otherwise, pd\_a\_u,w = 0. \\ pd\_b\_u,r & Amount by which the availability of additional resource r is reduced in the state of unavailability u? \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Decision variables, indices, and parameters of the mathematical model.