5.2.4. Constraints

*Constraint 1:* The constraint that indicating the number of personnel assigned to each grade in accordance with their seniority:

$$\text{a. Number of Shift Supervisors needed for shift } k. \sum\_{i=1}^{4} X\_{ijk} \ge 1\\j = 1, 2, \dots, mk = 1, 2, \dots, n \qquad \text{(24)}$$

$$\text{b. Number of Foremen needed for shift } k. \sum\_{i=5}^{16} X\_{i\bar{j}k} \ge 3j = 1, 2, \dots, mk = 1, 2, \dots, n \tag{25}$$

$$\text{3. Number of Experiment needed for shift } k. \sum\_{i=17}^{40} X\_{i\bar{j}k} \ge 6j = 1, 2, \dots, mk = 1, 2, \dots, n \tag{26}$$

$$\text{nd. Number of Assistant needed for shift } k. \sum\_{i=41}^{80} X\_{ijk} \ge 10j = 1, 2, \dots, mk = 1, 2, \dots, n \tag{27}$$

*Constraint 2:* The constraint that indicating if a staff working any day at night shift should not work in the morning and evening shifts the next day:

$$X\_{i\backslash 3} + X\_{i(j+1)1} + X\_{i(j+1)2} \le 1i = 1, 2, 3, \dots, l\\j = 1, 2, \dots, m - 1\tag{28}$$

*Constraint 3:* The constraint that indicating if a person working on any day of the evening should not work the next day in the morning:

$$X\_{i\backslash 2} + X\_{i(j+1)1} \le 1\\i = 1, 2, 3, \dots, l\\j = 1, 2, \dots, m - 1\tag{29}$$

*Constraint 4:* This constraint indicates that every staff member should take one day day-off (at least) in a week. In other words, every staff member should not work more than 6 days in a week:

$$h\_{ij} + h\_{i(j+1)} + h\_{i(j+2)} + h\_{i(j+3)} + h\_{i(j+4)} + h\_{i(j+5)} + h\_{i(j+6)} \geq 1\\i = 1,2,\dots,l\\j = 1,2,\dots,24\qquad(30)$$

*Constraint 5:* The constraint that indicating every staff member should not work on his/her the day off:

$$\sum\_{k=1}^{3} X\_{ijk} + h\_{ij} = 1i = 1, 2, 3, \dots, l \mathbf{j} = 1, 2, \dots, m \tag{31}$$

*Constraint 6:* The constraint that indicating in the night shift, the staff cannot be operated more than 9 days:

$$\begin{array}{c} X\_{l|3} + X\_{l(j+1)3} + X\_{l(j+2)3} + X\_{l(j+3)3} + X\_{l(j+4)3} + X\_{l(j+5)3} + X\_{l(j+6)3} + X\_{l(j+7)3} + X\_{l(j+8)3} \leq 9 \\\ i = 1, 2, 3, \dots, l \end{array} \tag{32}$$
