“…One of the most common partitional clustering algorithms used in energy system optimization is the k-means algorithm, which has been used in a variety of studies [14,15,24,37,57,58,63,69,74,78,[83][84][85][86][87]97,[137][138][139]141,142,[145][146][147][148][153][154][155][156][157][158][159][160][161]. The objective of the k-means algorithm is to minimize the sum of the squared distances between all cluster members of all clusters and the corresponding cluster centers, i.e., min…”