I recently came across the following summation in the definition of the Gini impurity in a machine learning lecture on decision trees:
$$\sum_{i \ne j}{P(\omega_i)P(\omega_j)} \space\space\space i,j \in c$$
Based on the formulas used in the lecture, the above summation involves only combinations. In other words, if $(i,j)=(1,2)$ is included then $(2,1)$ is not. This is intuitively how I would interpret the notation, and how my professor did as well.
However, based on the formulas in Wikipedia, the above summation should be over all permutations. Indeed, if I were to write it more explicitly as shown below, then this way makes sense too:
$$\sum_i\sum_j{P(\omega_i)P(\omega_j)} \space\mid\space i \ne j$$
So is either of these correct or accepted? And regardless, how would one explicitly write the double summation over all combinations as I did for permutations?