## 2 Load Profiling Mathematical Background
### Clustering Evaluation  
The validity indicators are measures of similarity of patterns. The term \"compactness\" refers to the similarities between the patterns of the same cluster and between the patterns and the centroids. The term \"separation\" refers to the similarities between the centroid of the different clusters. Let \(y_{n}^{s}\) and \(y_{n}^{t}\) be 2 patterns \(y_{n}^{s},y_{n}^{t}\in Y\). The following metrics are defined:  
* The Euclidean distance between \(y_{n}^{s}\) and \(y_{n}^{t}\) : \[d_{encl}(y_{n}^{s},y_{n}^{t})=\sqrt{\frac{1}{D}\sum_{d=1}^{D}\left(y_{nd}^{s}- y_{nd}^{t}\right)^{2}}\] (18)
* The subset of \(Y\) that belongs to the cluster \(C_{k}\) is denoted as \(S_{k}\). The Euclidean distance between the centroid \(c_{k}\) of the \(k\)th cluster and the subset \(S_{k}\) is the mean of the Euclidean distances \(d_{encl}(c_{k},S_{k})\) between \(c_{k}\) and each member \(y_{n}^{k}\) of \(S_{k}\): \[d_{encl}(c_{k},S_{k})=\sqrt{\frac{\sum_{n=1}^{N_{k}}d_{encl}^{2}\left(c_{k},y_{ n}^{k}\right)}{N_{k}}}\] (19)
* The mean of the inner-distances between the patterns \(y_{n}^{k}\) and \(y_{n}^{t}\) members of the subset \(S_{k}\) is: \[d_{encl}(S_{k})=\sqrt{\frac{1}{2N_{k}}\sum_{d=1}^{D}d_{encl}^{2}\left(y_{nd}^{ k},y_{nd}^{t}\right)}\] (20) The following validity indicators are considered [17]:
* The Mean Square Error \(J\), which refers to the sum of distances between the patterns and the clusters that belong to: \[J=\frac{1}{N}\sum_{ \begin{array}{c}n=1\\ y_{n}\in S_{k}\end{array} }^{N}d_{encl}^{2}(y_{n},c_{k})\] (21)* The Mean Index Adequacy (MIA), which refers to the average of the distances of the clusters: \[\text{MIA}=\sqrt{\frac{1}{K}\sum\limits_{k=1}^{K}d_{eucl}^{2}(c_{k},S_{k})}\] (22)
* The Clustering Dispersion Indicator (CDI), which refers to the ratio of the mean intra-set distance between the patterns in the same cluster and the inter-set distance between the clusters centroids: \[\text{CDI}=\frac{\sqrt{\frac{1}{K}\sum\limits_{k=1}^{K}d_{eucl}^{2}(S_{k})}}{ \sqrt{\frac{1}{2K}\sum\limits_{K=1}^{K}d_{eucl}^{2}(c_{k},C_{k})}}\] (23)
* The ratio of Within Cluster Sum of Squares to Between Cluster Variation (WCBCR), which corresponds to the ratio of the distance of each pattern from its cluster centroid and the sum of distances of the set \(C_{k}\): \[\text{WCBCR}=\frac{\sum\limits_{k=1}^{K}\sum\limits_{n=1}^{N}d_{eucl}^{2}(c_{ k},y_{n})}{\sum\limits_{1\leq s<t}^{N}d_{eucl}^{2}(y_{s},y_{t})}\] (24)
* The Similarity Matrix Indicator (SMI), which takes into account the maximum of the centroid distances: \[\text{SMI}=\underset{s>t}{\text{max}}\Bigg{\{}\left(1-\frac{1}{\ln[d_{eucl}(c _{s},c_{t}]}\right)^{-1}\Bigg{\}}:s,t=1,...,K\] (25)
* The Similarity Matrix Indicator 2 (SMI2), which takes into account the root of maximum of the centroid distances: \[\text{SMI2}=\sqrt{\underset{s>t}{\text{max}}\Bigg{\{}\left(1-\frac{1}{\ln[d_{ eucl}(c_{s},c_{t}]}\right)^{-1}\Bigg{\}}}:s,t=1,...,K\] (26)
* The Davies-Bouldin Index (DBI), which relates the mean distance of each cluster with the distance to the closest cluster: \[\text{DBI}=\frac{1}{K}\sum\limits_{s,t=1}^{K}\underset{s\
eq t}{\text{max}} \Bigg{\{}\frac{\hat{d}_{eucl}(C_{s})+\hat{d}_{eucl}(C_{t})}{d_{eucl}(c_{s},c_{ t})}\Bigg{\}}\] (27)
* The Modified Dunn Index (MDI), which takes into the minimum of the centroid distances: \[\text{MDI}=\underset{1\leq q\leq K}{\text{max}}\{\hat{d}(C_{q})\}(\underset{s \
eq t}{\text{min}}\{d(c_{s},c_{t})\}^{-1}\] (28)
* The Intra Cluster Index (IAI), which corresponds to the overall sum of the distances between patterns and centroids: \[\text{IAI}=\underset{n=1}{\text{max}}\,d_{eucl}^{2}(y_{n},c_{k})\] (29)* The Inter Cluster Index (IEI), which corresponds to the sum of distances between the cluster centroids and the arithmetic mean: \[\text{IEI}=\sum\limits_{k=1}^{K}N_{k}\cdot d_{eucl}(c_{k},p)\] (30) where \(p\) is the arithmetic mean of set \(X\).