# Genetic Algorithm for the Retailers' Shelf Space Allocation Profit Maximization Problem
## 6 Computational Experimental Results
### Genetic Algorithm vs. Cplex
In 7 cases, CPLEX found the same solution as GA\({}^{+}\) with Two Rankings, in 6 cases, CPLEX found the same solution as GA\({}^{+}\) with Roulette Wheel and GA\({}^{+}\) with Tournament. For the case with 15 products and 100 cm shelves, the CPLEX solution was better by 1.24% for all GA\({}^{+}\) tests; when we extend the time for the CPLEX, it also found a 0.22% better solution for 15 products set and 500 cm shelves than GA\({}^{+}\) with Tournament. Both GA\({}^{+}\) with Two Rankings and GA\({}^{+}\) with Tournament found the solution better than CPLEX by an average of 1.33%, with its minimum and maximum values 0.03% and 7.03%. GA\({}^{+}\) with Roulette Wheel found the solution slightly higher, on average 1.74% better than CPLEX with minimum and maximum values 0.05% and 7.05%. Figure 9 demonstrates the average time for GA\({}^{+}\). All GAs\({}^{+}\) found the solution on average approximately 2-3 min. The fastest solution was found in 0.01-0.02 min and the slowest one in 27.15 min by GA\({}^{+}\) with Two Rankings, 40.63 min by GA\({}^{+}\) with Roulette Wheel and 42.74 by GA\({}^{+}\) with Tournament. Table 5 shows the quality of the best and average solutions of GA\({}^{-}\) compared to the best and average solutions of GA\({}^{+}\). In the case of the best solutions for the set of 10 products, GA\({}^{-}\) and GA\({}^{+}\) found the same solution almost in all cases, except GA\({}^{+}\) with Tournament which was better on 500 cm shelves. For all other cases, GA\({}^{+}\) with Roulette Wheel and GA\({}^{+}\) with Tournament were better than GA\({}^{-}\) on average 0.30% (0.03-1.58%). GA\({}^{+}\) with Two Rankings slightly differs, finding the better solution on average by 0.28% (0.04-1.58%). In the case of average solutions in all cases, GA\({}^{+}\) was better than GA\({}^{-}\). GA\({}^{+}\) with Two Rankings and GA\({}^{+}\) with Tournament were better than the corresponding GA\({}^{-}\) on average 1.89%, but GA\({}^{+}\) with Roulette Wheel gives the slightly higher average result 5.16%. The minimum value for GA\({}^{+}\) with Two Rankings and GA\({}^{+}\) with Roulette Wheel is 0.19%, and 0.28% for GA\({}^{+}\) with Tournament. GA\({}^{+}\) with Roulette Wheel found the highest value compared to GA\({}^{-}\) of 65.80%. Other GA\({}^{+}\) with Two Rankings and GA\({}^{+}\) with Tournament give 28.10% and 24.98% their maximum values. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline \multirow{2}{*}{**Products**} & \multirow{2}{*}{**Sheff Width**} & \multicolumn{2}{c}{**Two Rankings**} & \multicolumn{2}{c}{**Roulette Wheel**} & \multicolumn{2}{c}{**Tournament**} \\  & & **CPLEX Is Better** & **GA Is Better** & **CPLEX Is Better** & **GA Is Better** & **GA Is Better** \\ \hline \multirow{4}{*}{10} & 100 & & 1.57\% & & 1.57\% & 1.57\% \\  & 200 & & 7.03\% & & 7.03\% & 7.03\% \\  & 250 & & 5.98\% & & 7.05\% & 6.31\% \\  & 375 & & & 6.15\% & & \\  & 500 & & & 0.26\% & & \\ \hline \multirow{4}{*}{15} & 100 & 1.24\% & & 1.24\% & 1.24\% & \\  & 200 & & 0.92\% & & 1.02\% & 1.02\% \\  & 250 & & 0.09\% & & 0.13\% & 0.13\% \\  & 375 & & 0.83\% & & 0.83\% & 0.83\% \\  & 500 & & & & 0.22\% & \\ \hline \multirow{4}{*}{20} & 100 & & & & & \\  & 200 & & & & & \\  & 250 & & 0.45\% & & 0.40\% & 0.22\% \\  & 375 & & 0.49\% & & 0.46\% \\  & 500 & & 0.26\% & & 0.26\% & 0.16\% \\ \hline \multirow{4}{*}{25} & 200 & & 0.05\% & & 0.05\% & 0.05\% \\  & 250 & & 0.13\% & & 0.13\% & 0.17\% \\  & 500 & & 0.49\% & & 0.41\% \\ \hline \multirow{4}{*}{50} & 250 & & & & & \\  & 375 & & 0.03\% & & 0.03\% \\  & 500 & & 0.30\% & & 0.21\% & 0.21\% \\ \hline \multirow{4}{*}{
\begin{tabular}{c} Min \\ Avg \\ Max \\ \end{tabular} } & 0.03\% & & 0.05\% & & 0.03\% \\  & 1.33\% & & 1.74\% & & 1.33\% \\ \cline{1-1}  & 7.03\% & & 7.05\% & & 7.03\% \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Quality of the best solution of GA\({}^{+}\) compared to the CPLEX solution (Time_CPLEX = max_Time_GA). Figure 10 shows the computational time for the best solution of GA\({}^{-}\).