## 3 Genetic Algorithm and Fuzzy Logic for the FjSSP
In the proposed methodology, the fuzzy sets used have triangular membership functions such that \(\widetilde{C}_{j}=\left(C_{j}^{\mathit{inf}},C_{j}^{\mathit{mod}}C_{j}^{ \mathit{sup}}\right)\). The elements that make up the triangular fuzzy number are shown in Figure 5, and these can be calculated following Equations (20)-(22). \[\widetilde{C}_{j}=\max(\widetilde{C_{j}},\ \widehat{TM_{i}})+\widetilde{P_{ ju}}+\widetilde{S_{ilj}} \tag{19}\]  
\[C_{j}^{\mathit{inf}}=\max\ (C_{j}^{\mathit{inf}},\ TM_{i}^{\mathit{inf}})+P_{ ju}^{\mathit{inf}}+A_{ilj}^{\mathit{inf}} \tag{20}\]  
\[C_{j}^{\mathit{mod}}=\max\ (C_{j}^{\mathit{mod}},\ TM_{i}^{\mathit{mod}})+P_{ ju}^{\mathit{mod}}+A_{ilj}^{\mathit{mod}} \tag{21}\]  
\[C_{j}^{\mathit{sup}}=\max\ (C_{j}^{\mathit{sup}},\ TM_{i}^{\mathit{sup}})+P_{ ju}^{\mathit{sup}}+A_{ilj}^{\mathit{sup}} \tag{22}\]  
Likewise, it is necessary to calculate the fuzzy tardiness and earliness of each job to obtain the fitness of each chromosome. It requires comparing \(\widetilde{C}_{j}\) with the limits of the due window (\(d_{jA}\), \(d_{jB}\)). The fuzzy tardiness (\(\widetilde{T}_{j}\)) is determined by intercepting \(\widetilde{C}_{j}\) with the tardiness interval (\(IT_{j}\)) that starts at \(d_{jB}\) and is not bounded by an upper value \(\left( \begin{array}{c}d_{jB}\,,+\infty\end{array} \right)\). The fuzzy earliness of each job \(j\) (\(\widetilde{E}_{j}\)) is determined by the intercept of \(\widetilde{C}_{j}\) with the earliness  
Figure 4: Sequencing of jobs from the beta chromosome. Figure 5: Triangular membership function for the completion time of job \(j\). Figure 3: Illustration of a beta chromosome. interval (\(IE_{j}\)) that starts at zero and ends at \(d_{jA}\left(0\,,\;d_{jA}\right)\). Figure 6 illustrates the different cases in which fuzzy delay and fuzzy promptness can be configured. Figure 6a shows the first case where there is the possibility of completing job \(j\) early (earliness) or late (tardiness), but there is also the possibility of completing job \(j\) within the due window (on time and without penalties). Figure 6b shows the second case where job \(j\) cannot be delivered early (earliness) or late (tardiness), assuming a 100% possibility that job \(j\) will be completed within the due window despite considering uncertainty. Figure 6c shows the third case where job \(j\) cannot be completed late (tardiness), but there is a possibility that job \(j\) will be delivered early (earliness); however, when \(C_{j}^{sup}\leq d_{jA}\), there is a 100% possibility that job \(j\) will be completed early. Figure 6d shows the fourth case where job \(j\) cannot be delivered early (earliness), but there is a possibility that job \(j\) will be completed late (tardiness); however, when \(C_{j}^{inf}\geq d_{jB}\), there is a 100% possibility that job \(j\) will be completed late. Consequently, in some cases, it cannot be assured with certainty that a job \(j\) will be completed with earliness or tardiness, and in some cases, this possibility can be very high or low. Thus, when calculating the total weighted penalty of a job \(j\), the possibility of occurrence of an advance \(P_{j}^{E}\) or a delay \(P_{j}^{T}\) will be considered. For this, Equation (23) describes the membership function \(\mu_{Cj}(x)\) of the fuzzy completion time \(\widetilde{C}_{j}\), Equations (24)-(26) show the centroid method to defuzzify the fuzzy earliness, and Equations (27)-(29) show the centroid method to defuzzify the fuzzy tardiness and obtain a real number where \(E_{j}^{*}\) and \(T_{j}^{*}\) represent the defuzzification value of earliness and tardiness of job \(j\), \(x\mu_{Ej}(x)\) and \(x\mu_{Tj}(x)\) represent the membership function of the fuzzy earliness and tardiness. \[\mu_{Cj}(x)=\left\{ \begin{array}{cl}0&six\leq C_{j}^{inf}\\ \frac{x-c_{j}^{inf}}{c_{j}^{mod}-c_{j}^{inf}}&sic_{j}^{inf}<x\leq C_{j}^{mod} \\ \frac{c_{j}^{sup}-x}{c_{j}^{inf}-c_{j}^{mod}}&sic_{j}^{mod}<x<C_{j}^{sup}\\ 0&six\geq C_{j}^{sup}\end{array} \right.