In this paragraph, the optimization problem is defined. Equation
6 represents all 22 objectives to be minimized. As previously mentioned, all variables presented reach their optimum in the minimum value. Equations
7a–u are precisely the 21 empirical regression models obtained by the statistical analysis of the 21 performances presented in the previous chapter. Equation
7v represents the kg of CO
2eq emitted in the atmosphere to produce the parts. This equation is derived from the general one presented before. In particular, in this mathematical function, it is inserted the binary variable
\({RE}_{y}\), equal to 1 if recycled PLA is used, 0 otherwise, and the parameters are specified:
\(ke\) is the CO
2eq emitted to produce a kg/VAh (in this analysis, we approximate this value as 0.06 CO
2eq kg/kWh, considering equal the CO
2eq released to generate a kWh or a kVAh),
\({EE}_{NRE}\) is the embedded energy in non-recycled PLA (15.28 kWh/kg), while
\({EE}_{RE}\) is the embedded energy in recycled PLA (5 kWh/kg).
\({C}_{NRE}\) is the CO
2eq released to produce 1 kg of non-recycled PLA (2.8 CO
2eq kg/kg) and
\({C}_{RE}\) for recycled one (0.95 CO
2eq kg/kg). Finally, Eqs.
8a–i represent the decisional variables' lower and upper bound. The range is the same as the experimental plan. Since we have studied only this space, we can infer only inside it.
$$ \begin{aligned} & {\text{min }}PT, PE, w,totC,\overline{A}_{B} ,\overline{Q}_{B} ,\overline{A}_{A} ,\overline{A}_{Sp} ,\overline{Q}_{Sp} ,\\ & \qquad \overline{A}_{P} ,\overline{Q}_{P} ,\overline{Q}_{Sd} , \overline{R}_{Sd} ,\\ & \quad \quad \overline{A}_{H} ,\overline{Q}_{H} ,\overline{A}_{Sl} ,\overline{Q}_{Sl} ,\overline{A}_{R} ,\overline{R}_{R} ,\overline{A}_{S} ,\overline{A}_{F} ,\overline{A}_{T} \end{aligned} $$
(6)
$$ \begin{aligned} PT & = k_{PT} - \hat{\beta }_{1 PT} \cdot WS + \hat{\beta }_{2 PT} \cdot S_{y} + \hat{\beta }_{3 PT} \cdot BAS_{y} + \hat{\beta }_{4 PT} \cdot LH \\ & \quad + \hat{\beta }_{5 PT} \cdot IR + \hat{\beta }_{6 PT} \cdot SN + \hat{\beta }_{7 PT} \cdot LH \cdot SN \\ & \quad + \hat{\beta }_{8 PT} \cdot LH \cdot IR + \hat{\beta }_{9 PT} \cdot IR \cdot SN \\ \end{aligned} $$
(7a)
$$ \begin{aligned} PE & = k_{PE} + \hat{\beta }_{1 PE} \cdot PT + \hat{\beta }_{2 PE} \cdot WS + \hat{\beta }_{3 PE} \cdot S_{y} + \hat{\beta }_{4 PE} \cdot LH \\ & \quad + \hat{\beta }_{5 PE} \cdot IR - \hat{\beta }_{6 PE} \cdot LH \cdot IR \\ \end{aligned} $$
(7b)
$$ w = k_{w} + \hat{\beta }_{1 w} \cdot S_{y} + \hat{\beta }_{2 w} \cdot BAS_{y} + \hat{\beta }_{3 w} \cdot LH + \hat{\beta }_{4 w} \cdot IR + \hat{\beta }_{5 w} \cdot SN $$
(7c)
$$ \overline{A}_{B} = k_{{\overline{A}_{B} }} + \hat{\beta }_{{1 \overline{A}_{B} }} \cdot S_{y } + \hat{\beta }_{{2 \overline{A}_{B} }} \cdot LH + \hat{\beta }_{{3 \overline{A}_{B} }} \cdot SN + \hat{\beta }_{{4 \overline{A}_{B} }} \cdot S_{y} \cdot SN $$
(7d)
$$ \overline{Q}_{B} = k_{{\overline{Q}_{B} }} + \hat{\beta }_{{1 \overline{Q}_{B} }} \cdot RE_{y} + \hat{\beta }_{{2 \overline{Q}_{B} }} \cdot WS + \hat{\beta }_{{3 \overline{Q}_{B} }} \cdot S_{y} + \hat{\beta }_{{4 \overline{Q}_{B} }} \cdot LH $$
(7e)
$$ \begin{aligned} \overline{A}_{A} & = k_{{\overline{A}_{A} }} + \hat{\beta }_{{1 \overline{A}_{A} }} \cdot RE_{y} + \hat{\beta }_{{2 \overline{A}_{A} }} \cdot WS + \hat{\beta }_{{3 \overline{A}_{A} }} \cdot S_{y} + \hat{\beta }_{{4 \overline{A}_{A} }} \cdot IR \\ & \quad + \hat{\beta }_{{5 \overline{A}_{A} }} \cdot BAS_{y } \cdot WS + \hat{\beta }_{{6 \overline{A}_{A} }} \cdot BAS_{y } \cdot S_{y} + \hat{\beta }_{{7 \overline{A}_{A} }} \cdot BAS_{y } \cdot RE_{y} \\ \end{aligned} $$
(7f)
$$ \begin{aligned} \overline{A}_{Sp} & = k_{{\overline{A}_{Sp} }} + \hat{\beta }_{{1 \overline{A}_{Sp} }} \cdot WT + \hat{\beta }_{{2 \overline{A}_{Sp} }} \cdot PT + \hat{\beta }_{{3 \overline{A}_{Sp} }} \cdot WS - \hat{\beta }_{{4 \overline{A}_{Sp} }} \cdot S_{y} \\ & \quad + \hat{\beta }_{{5 \overline{A}_{Sp} }}\! \cdot\! LH \!+\! \hat{\beta }_{{6 \overline{A}_{Sp} }} \!\cdot\! LH \!\cdot\! PT \!+\! \hat{\beta }_{{7 \overline{A}_{Sp} }} \!\cdot\! LH \cdot S_{y} + \hat{\beta }_{{8 \overline{A}_{Sp} }} \cdot PT \cdot S_{y} \\ \end{aligned} $$
(7g)
$$ \overline{Q}_{Sp} = k_{{\overline{Q}_{Sp} }} + \hat{\beta }_{{1 \overline{Q}_{Sp} }} \cdot WT + \hat{\beta }_{{2 \overline{Q}_{Sp} }} \cdot SN + \hat{\beta }_{{3 \overline{Q}_{Sp} }} \cdot LH \cdot WS $$
(7h)
$$ \overline{A}_{P} = k_{{\overline{A}_{P} }} + \hat{\beta }_{{1 \overline{A}_{P} }} \cdot PT + \hat{\beta }_{{2 \overline{A}_{P} }} \cdot WS + \hat{\beta }_{{3 \overline{A}_{P} }} \cdot LH + \hat{\beta }_{{4 \overline{A}_{P} }} \cdot IR $$
(7i)
$$ \begin{aligned} \overline{Q}_{P} & = k_{{\overline{Q}_{P} }} + \hat{\beta }_{{1 \overline{Q}_{P} }} \cdot RE_{y} + \hat{\beta }_{{2 \overline{Q}_{P} }} \cdot WT + \hat{\beta }_{{3 \overline{Q}_{P} }} \cdot WS \\ & \quad + \hat{\beta }_{{4 \overline{Q}_{P} }} \cdot SN + \hat{\beta }_{{5 \overline{Q}_{P} }} \cdot RE_{y} \cdot WT + \hat{\beta }_{{6 \overline{Q}_{P} }} \cdot LH \cdot PT \\ \end{aligned} $$
(7j)
$$ \begin{aligned} \overline{Q}_{Sd} & = k_{{\overline{Q}_{Sd} }} + \hat{\beta }_{{1 \overline{Q}_{Sd} }} \cdot WS + \hat{\beta }_{{2 \overline{Q}_{Sd} }} \cdot LH + \hat{\beta }_{{3 \overline{Q}_{Sd} }} \cdot SN \\ & \quad + \hat{\beta }_{{4 \overline{Q}_{Sd} }} \cdot SN \cdot LH + \hat{\beta }_{{5 \overline{Q}_{Sd} }} \cdot RE_{y} \cdot LH \\ \end{aligned} $$
(7k)
$$ \overline{R}_{Sd} = k_{{\overline{R}_{Sd} }} + \hat{\beta }_{{1 \overline{R}_{Sd} }} \cdot LH + \hat{\beta }_{{2 \overline{R}_{Sd} }} \cdot LH \cdot WS $$
(7l)
$$ \overline{A}_{H} = k_{{\overline{A}_{H} }} + \hat{\beta }_{{1 \overline{A}_{H} }} \cdot WS + \hat{\beta }_{{2 \overline{A}_{H} }} \cdot LH \cdot WT + \hat{\beta }_{{3 \overline{A}_{H} }} \cdot WS \cdot WT $$
(7m)
$$ \overline{Q}_{H} = k_{{\overline{Q}_{H} }} + \hat{\beta }_{{1 \overline{Q}_{H} }} \cdot LH + \hat{\beta }_{{2 \overline{Q}_{H} }} \cdot SN $$
(7n)
$$ \begin{aligned} \overline{A}_{Sl} & = k_{{\overline{A}_{Sl} }} + \hat{\beta }_{{1 \overline{A}_{Sl} }} \cdot LH + \hat{\beta }_{{1 \overline{A}_{Sl} }} \cdot LH \cdot SN \\ & \quad + \hat{\beta }_{{1 \overline{A}_{Sl} }} \cdot RE_{y} \cdot SN + \hat{\beta }_{{1 \overline{A}_{Sl} }} \cdot RE_{y} \cdot LH \\ \end{aligned} $$
(7o)
$$ \overline{Q}_{Sl} = k_{{\overline{Q}_{Sl} }} + \hat{\beta }_{{1 \overline{Q}_{Sl} }} \cdot BAS_{y} + \hat{\beta }_{{2 \overline{Q}_{Sl} }} \cdot LH $$
(7p)
$$ \overline{A}_{R} = k_{{\overline{A}_{R} }} + \hat{\beta }_{{1 \overline{A}_{R} }} \cdot BAS_{y } + \hat{\beta }_{{2 \overline{A}_{R} }} \cdot LH + \hat{\beta }_{{3 \overline{A}_{R} }} \cdot BAS_{y } \cdot LH $$
(7q)
$$ \overline{R}_{R} = k_{{\overline{R}_{R} }} + \hat{\beta }_{{1 \overline{R}_{R} }} \cdot LH \cdot BAS_{y } + \hat{\beta }_{{2 \overline{R}_{R} }} \cdot LH \cdot WS + \hat{\beta }_{{3 \overline{R}_{R} }} \cdot RE_{y } \cdot LH $$
(7r)
$$ \overline{A}_{S} = k_{{\overline{A}_{S} }} + \hat{\beta }_{{1 \overline{A}_{S} }} \cdot RE_{y } + \hat{\beta }_{{2 \overline{A}_{S} }} \cdot WT + \hat{\beta }_{{2 \overline{A}_{S} }} \cdot RE_{y } \cdot WT $$
(7s)
$$ \overline{A}_{F} = k_{{\overline{A}_{F} }} + \hat{\beta }_{{1 \overline{A}_{F} }} \cdot S_{y} + \hat{\beta }_{{2 \overline{A}_{F} }} \cdot PT \cdot SN $$
(7t)
$$\begin{aligned} & \overline{A}_{T} = k_{{\overline{A}_{T} }} + \hat{\beta }_{{1 \overline{A}_{T} }} \cdot BAS_{y } + \hat{\beta }_{{2 \overline{A}_{T} }} \cdot LH\\ & \quad + \hat{\beta }_{{3 \overline{A}_{T} }} \cdot S_{y} \cdot SN + \hat{\beta }_{{4 \overline{A}_{T} }} \cdot SN \cdot LH \end{aligned} $$
(7u)
$$ \begin{aligned} totC & = ke \cdot EE_{RE} \cdot w \cdot RE_{y} + C_{RE} \cdot w \cdot RE_{y }\\ & \quad + ke \cdot EE_{NRE} \cdot w \cdot \left( {1 - RE_{y } } \right) \\ & \quad + C_{NRE} \cdot w \cdot \left( {1 - RE_{y } } \right) + ke \cdot PE \\ \end{aligned} $$
(7v)
\(s.t.\)$$ \{ RE_{y } \in {\mathbb{N}}|0 \le RE_{y} \le 1\} $$
(8a)
$$ \{ WT \in {\mathbb{R}}|200 \le WT \le 215\} $$
(8b)
$$ \{ PT \in {\mathbb{R}}|25 \le PT \le 50\} $$
(8c)
$$ \{ WS \in {\mathbb{R}}|40 \le WS \le 80\} $$
(8d)
$$ \{ BAS_{y } \in {\mathbb{N}}|0 \le BAS_{y } \le 1\} $$
(8e)
$$ \{ S_{y } \in {\mathbb{N}}|0 \le S_{y } \le 1\} $$
(8f)
$$ \{ LH \in {\mathbb{R}}|0.1 \le LH \le 0.3\} $$
(8g)
$$ \{ IR \in {\mathbb{R}}|10 \le IR \le 60\} $$
(8h)
$$ \{ SN \in {\mathbb{N}}|1 \le SN \le 3\} $$
(8i)
In order to find the best solution, we implemented the problem in Python using the pymoo library [
45]. In particular, we used the NSGA-II algorithm [
46]. In the literature, it is possible to find some recent applications of NSGA-II on additive manufacturing optimization. E.g., in [
47], the authors used the same algorithm to find a frontier of solutions that minimize the time and material consumption while keeping a sufficient level of ultimate tensile strength and surface roughness. Matos et al. [
48] studied the best manufacturing positioning while optimizing the support area, the manufacturing time, the surface roughness and the surface quality using an NSGA-II algorithm.
The new offspring
\({O}_{t}\), depends on two operators: the crossover probability
\(X\) and the mutation probability
\(M\). Finally, to find the best solutions, four different factors have to be set: the population (
\(N\)), the crossover (
\(X\)) and the mutation (
\(M\)) and the number of generations to be tested (
\(G\)). In the literature, it is possible to find different suggestions and methods for choosing these parameters. According to Schaffer et Al. [
49], a mutation probability higher than 0.05 never drives good results, and
\(M\) of 0.005 and a
\(X\) between 0.95 and 0.65, even with a small population, is suggested. For these reasons, we decided to set a
\(M\) = 0.005 and a
\(X\) equal to 0.95. Finally in order to increase the probability to reach te convergence we set a number of generation
\(G\) equal to 1000.
According to the literature, the larger the initial population, the more efficiently the algorithm finds the optimal front [
50]. For this reason, we tested the difference between the optimal frontier obtained with a
\(N\) equal to 1000, 35, 30 and 20. The difference between the first (
\(N\) =1000) and the second (
\(N\) = 35) is meagre: looking for the best solution in each performance, these were practical all the same, and only one deviated by less than 2%. While testing the first with the third, all values were identical except for one value that differed by about 10%. Finally, as expected, we got the worst results with a population of only 20 solutions. The average deviation from the first run was 20%, with peaks at 117%. For this reason, we can assume that the best value for
\(N\) would be between 30 and 35. So, for this reason, we fixed
\(N\) equal to 35, testing 35,000 solutions. The results have been obtained with a computer HP Elitebook 830 G6 with CPU Intel core i5-8265U 1.60 GHz and RAM 16 GB. The algorithm evaluates 1000 generations made of a population of 1000 in about 9 min and 2 s. In contrast, it tests 1000 generations of 35 solutions on average in 37 s.