This site is supported by donations to The OEIS Foundation.

# Coprimality triangle

Note, among others, the patterns highlighted in blue and green (symmetric about multiples of
 6
) of the noncoprime numbers.
The equilateral version of the coprimality triangle
(Coprime numbers triangle)
 n
${\displaystyle \varphi (n)=\,}$

${\displaystyle \sum _{i=1}^{n-1}=T(n,i)\,}$

2   1   1
3   1 1   2
4   1 0 1   2
5   1 1 1 1   4
6   1 0 0 0 1   2
7   1 1 1 1 1 1   6
8   1 0 1 0 1 0 1   4
9   1 1 0 1 1 0 1 1   6
10   1 0 1 0 0 0 1 0 1   4
11   1 1 1 1 1 1 1 1 1 1   10
12   1 0 0 0 1 0 1 0 0 0 1   4
13   1 1 1 1 1 1 1 1 1 1 1 1   12
14   1 0 1 0 1 0 0 0 1 0 1 0 1   6
15   1 1 0 1 0 0 1 1 0 0 1 0 1 1   8
16   1 0 1 0 1 0 1 0 1 0 1 0 1 0 1   8
17   1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1   16
18   1 0 0 0 1 0 1 0 0 0 1 0 1 0 0 0 1   6
19   1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1   18
20   1 0 1 0 0 0 1 0 1 0 1 0 1 0 0 0 1 0 1   8
21   1 1 0 1 1 0 0 1 0 1 1 0 1 0 0 1 1 0 1 1   12
22   1 0 1 0 1 0 1 0 1 0 0 0 1 0 1 0 1 0 1 0 1   10
23   1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1   22
24   1 0 0 0 1 0 1 0 0 0 1 0 1 0 0 0 1 0 1 0 0 0 1   8
25   1 1 1 1 0 1 1 1 1 0 1 1 1 1 0 1 1 1 1 0 1 1 1 1   20
26   1 0 1 0 1 0 1 0 1 0 1 0 0 0 1 0 1 0 1 0 1 0 1 0 1   12
27   1 1 0 1 1 0 1 1 0 1 1 0 1 1 0 1 1 0 1 1 0 1 1 0 1 1   18
28   1 0 1 0 1 0 0 0 1 0 1 0 1 0 1 0 1 0 1 0 0 0 1 0 1 0 1   12
29   1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1   28
30   1 0 0 0 0 0 1 0 0 0 1 0 1 0 0 0 1 0 1 0 0 0 1 0 0 0 0 0 1   8
31   1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1   30
32   1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1   16

 i
= 1
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31

## Definition

The entries of the coprimality triangle are defined as

${\displaystyle T(n,i)\equiv [(n,i)=1],\ 1\leq i\leq n-1,\,}$

where ${\displaystyle \scriptstyle (n,i)\,}$ is the greatest common divisor and ${\displaystyle \scriptstyle [\cdot ]\,}$ is the Iverson bracket.

## Properties

### Symmetry

The coprimality triangle is symmetric with respect to a central vertical line, i.e.

${\displaystyle T(n,i)=T(n,n-i)\,}$

since

${\displaystyle (n,i)=(n,n-i).\,}$

Note, among others, the patterns highlighted in blue, purple and green (symmetric about multiples of 6) of the noncoprime numbers.

### Connectivity of noncoprimes?

It seems that if we form a graph where each node corresponds to a triangle cell with value 1 and each edge links nodes corresponding to adjacent cells with value 1 that the resulting graph is connected, i.e. has the connectivity property. Is that true and if so is there a proof?

### Row sums

The row sums give Euler's totient function of
 n
(count of numbers less than
 n
and coprime to
 n
), i.e.
${\displaystyle \sum _{i=1}^{n-1}T(n,i)=\varphi (n).\,}$

## Sequences

The rows give an infinite sequence of finite sequences

 {{1}, {1, 1}, {1, 0, 1}, {1, 1, 1, 1}, {1, 0, 0, 0, 1}, {1, 1, 1, 1, 1, 1}, {1, 0, 1, 0, 1, 0, 1}, {1, 1, 0, 1, 1, 0, 1, 1}, {1, 0, 1, 0, 0, 0, 1, 0, 1}, {1, 1, 1, 1, 1, 1, 1, 1, 1, 1}, {1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1}, ...}
where the row sums give the sequence for Euler's totient function (A000010
 (n), n   ≥   2
)
 {1, 2, 2, 4, 2, 6, 4, 6, 4, 10, 4, 12, 6, 8, 8, 16, 6, 18, 8, 12, 10, 22, 8, 20, 12, 18, 12, 28, 8, 30, 16, 20, 16, 24, 12, 36, 18, 24, 16, 40, 12, 42, 20, 24, 22, 46, 16, 42, 20, 32, 24, 52, 18, 40, 24, 36, 28, 58, 16, 60, 30, ...}
whose partial sums plus one give the summatory function of Euler's totient function (A002088
 (n), n   ≥   2
)
 {2, 4, 6, 10, 12, 18, 22, 28, 32, 42, 46, 58, 64, 72, 80, 96, 102, 120, 128, 140, 150, 172, 180, 200, 212, 230, 242, 270, 278, 308, 324, 344, 360, 384, 396, 432, 450, 474, 490, }

and the concatenation of the rows gives the sequence (A054431)

 {1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, ...}
whose partial sums plus one give (A??????
 (n), n   ≥   2
)
 {2, 3, 4, 5, 5, 6, 7, 8, 9, 10, 11, 11, 11, 11, 12, 13, 14, 15, 16, 17, 18, 19, 19, 20, 20, 21, 21, 22, 23, 24, 24, 25, 26, 26, 27, 28, 29, 29, 30, 30, 30, 30, 31, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 43, ...}

Relative prime triangle, ${\displaystyle \scriptstyle T(n,i)\,\equiv \,i\cdot [(n,i)\,=\,1],\ 1\,\leq \,i\,\leq \,n,\,}$

 1; 1, 0; 1, 2, 0; 1, 0, 3, 0; 1, 2, 3, 4, 0; 1, 0, 0, 0, 5, 0; 1, 2, 3, 4, 5, 6, 0; ...