I have a set of paired numbers as follows:
{
{{1,2},{1,3},{1,4},{1,5}},
{{2,3},{2,4},{2,5}},
{{3,4},{3,5}},
{4,5}
}
(a) How can I calculate the number of unique triads, such that only 3 digits appear in each triad? In the example above, one triad would be:
{{1,2},{1,3},{2,3}}. So in the set above, we would have 10 such sets.(b) What is the general formula, given $n$ number of items (or numbers, if you like) for the number of triads?
(c) What is the correct mathematical language to describe this problem?
The number of unique pairs is given by the shifted triangular series: $k = n(n-1)/2$ = 10.
It can also be obtained through the ${n \choose m} = {5 \choose 2} = 10$
Possibly related questions:
Clarification:
The answer for the 10 triads I am looking to calculate are:
{
{12,13,23}, {12,14,24}, {12,15,25}, {13,14,34}, {13,15,35}, {14,15,45},
{23,24,34}, {23,25,35},
{34,35,45}
}
Thanks to André Porto's comment, I learned something about triangular numbers and complete graphs. The complete graph on $n$ vertices is denoted by $K_n$. In our case $n=5$ so that the $K_5$ graph look like this:
The number of triads are equivalent to the number of connected edges, given by:
$r = {n \choose k} = {5 \choose 3} = 10$
Coincidentally, this is also equivalent to ${5 \choose 2}$, as was the case for the number of pairs. Also, notice how each vertex is connected to the other four.