cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A133994 Irregular array read by rows: n-th row contains (in numerical order) both the positive integers <= n that are divisors of n and those that are coprime to n.

Original entry on oeis.org

1, 1, 2, 1, 2, 3, 1, 2, 3, 4, 1, 2, 3, 4, 5, 1, 2, 3, 5, 6, 1, 2, 3, 4, 5, 6, 7, 1, 2, 3, 4, 5, 7, 8, 1, 2, 3, 4, 5, 7, 8, 9, 1, 2, 3, 5, 7, 9, 10, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 1, 2, 3, 4, 5, 6, 7, 11, 12, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 1, 2, 3, 5, 7, 9, 11, 13, 14
Offset: 1

Views

Author

Leroy Quet, Oct 01 2007

Keywords

Comments

Row n contains A073757(n) terms.
The number 1 would appear twice for each n >= 1 if one takes the union of the divisor list of n and the list of the smallest positive reduced residue system modulo n. - Wolfdieter Lang, Jan 16 2016

Examples

			The divisors of 12 are: 1,2,3,4,6,12. The positive integers which are <= 12 and are coprime to 12 are: 1,5,7,11. So row 12 is the union of these two sets: 1,2,3,4,5,6,7,11,12.
The irregular triangle T(n, k) starts:
n\k 1 2 3 4 5 6  7  8  9 10 11 12 13 14 15 16 17
1:  1
2:  1 2
3:  1 2 3
4:  1 2 3 4
5:  1 2 3 4 5
6:  1 2 3 5 6
7:  1 2 3 4 5 6  7
8:  1 2 3 4 5 7  8
9:  1 2 3 4 5 7  8  9
10: 1 2 3 5 7 9 10
11: 1 2 3 4 5 6  7  8  9 10 11
12: 1 2 3 4 5 6  7 11 12
13: 1 2 3 4 5 6  7  8  9 10 11 12 13
14: 1 2 3 5 7 9 11 13 14
15: 1 2 3 4 5 7  8 11 13 14 15
16: 1 2 3 4 5 7  8  9 11 13 15 16
17: 1 2 3 4 5 6  7  8  9 10 11 12 13 14 15 16 17
18: 1 2 3 5 6 7  9 11 13 17 18 19
... Formatted by _Wolfdieter Lang_, Jan 16 2016
		

Crossrefs

Programs

  • Maple
    row:= n -> op(select(t -> member(igcd(t,n), [1,t]), [$1..n])):
    seq(row(n), n=1..30); # Robert Israel, Jan 18 2016
  • Mathematica
    row[n_] := Divisors[n] ~Union~ Select[Range[n], CoprimeQ[n, #]&]; Array[ row, 15] // Flatten (* Jean-François Alcover, Jan 18 2016 *)