# The Porcupine Measure for Comparing the Performance of Multi-Objective Optimization Algorithms
## 5 Weighted 2-Dimensional Attainment-Surface-Shaped Intersection Lines
```
1:Input: The optimal OPF, \(Q=\{\vec{q}_{i}:i\in\{1,\ldots,I\}\}\) with \(I\) solutions and \(\vec{q}_{i}=(q_{i1},q_{i2})\)
2:Output: An attainment surface
3:for each attainment line segment \(s_{l}\)do
4: Let \(w_{l}=length(s_{l})\)
5: Let \(\mathbf{c}\) be the center of \(s_{l}\)
6: Let \(\theta=\frac{\pi(c_{1}+(\max(q_{l2}-c_{2}))}{2d}\), for \(i=1,\ldots,I\)
7: Let \(\mathbf{p}=(\sin\theta,\cos\theta)\)
8: //Draw the generated intersection line
9: drawIntersectionLineWithWeight(from=\(\mathbf{c}-\mathbf{p}\),\(\mathbf{t}\)=\(\mathbf{c}+\mathbf{p}\),weight=\(w_{l}\))
10:endfor
```  
**Algorithm 3** Weighted attainment-surface-shaped intersection line (WASSIL) generation. For POF test cases 1 through 3, only 2 of the 15 measurements using the random intersection line generation approach had a deviation from the true KC of less than 5%. Overall, 50% of the measurements using the random intersection line generation abroad had a deviation greater than 5%. This confirms that the random intersection line generation approach is not well suited for the KC calculation. The rotation-based intersection line generation approach presented by [PERSON] and [PERSON] fared better than the random intersection line generation approach. Only 7 of the 30 measurements using the rotation-based intersection line generation approach had a deviation greater than 5%. Case 1 with a convex POF fared worse with a deviation of almost 15% for both algorithms. Four of the five case 2 measurements using the rotation-based intersection line generation approach had a deviation greater than 5%. For the remaining case 2 measurement, a deviation of at least 3% is noted. The results indicate the rotation-based intersection line generation approach outperformed the random intersection line generation approach with respect to accuracy. However, the results also indicate that the rotation-based intersection line generation approach is not well suited for the KC calculation and that the results vary based on the POF shape and the spread of the solutions. As expected, the WASSIL generation approach produced results much closer to the true KC: the closer the approximated POFs being compared are to the true POF, the more accurate the comparison using the WASSIL generation approach becomes. Figure 9: Convex POF and attainment surface with WASSILs. ```
1:Input: Intersection lines for algorithms A and B to be compared
2:Output: The weighted KC measure
3: Let \(w_{total}=0\)
4: Let \(wins_{A}=0\)
5: Let \(wins_{B}=0\)
6:for each intersection line \(l\)do
7: Let \(w_{l}\) be the weight associated with \(l\)
8: Let \(O\) be the strict ordering of the intersection points for algorithms \(A\) and \(B\) on intersection line \(l\)
9: Let \(O_{A}\subset O\) be the ordering of the intersection points for algorithm \(A\) on intersection line \(l\)
10: Let \(O_{B}\subset O\) be the ordering of the intersection points for algorithm \(B\) on intersection line \(l\)
11:if\(O_{A}\) is statistically significantly less than \(O_{B}\)then
12:\(wins_{A}=wins_{A}+w_{l}\)
13:elseif\(O_{B}\) is statistically significantly less than \(O_{A}\)then
14:\(wins_{B}=wins_{B}+w_{l}\)
15:endif
16:\(w_{total}=w_{total}+w_{l}\)
17:endfor
18:Return \([\frac{100 wins_{A}}{w_{total}},\frac{100 wins_{B}}{w_{total}}]\)
```  
**Algorithm 4** Weighted KC measure algorithm  
\begin{table}
\begin{tabular}{l l l c c c} \hline \hline \multirow{2}{*}{**Case**} & \multirow{2}{*}{**Geometry**} & \multirow{2}{*}{**True**} & \multicolumn{4}{c}{**Intersection Line Generation Approach**} \\  & & & **Rotation-Based** & **Random** & **ASSIL** & **WASSIL** \\ \hline \multirow{4}{*}{Case 1} & Concave & (73.27, 26.73) & (71.00, 29.00) & (79.90, 20.10) & (73.20, 26.80) & (73.27, 26.73) \\  & Convex & (70.37, 29.63) & (85.10, 14.90) & (87.40, 12.60) & (70.30, 29.7