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.

A210959 Triangle read by rows in which row n lists the divisors of n starting with 1, n, the second smallest divisor of n, the second largest divisor of n, the third smallest divisor of n, the third largest divisor of n, and so on.

Original entry on oeis.org

1, 1, 2, 1, 3, 1, 4, 2, 1, 5, 1, 6, 2, 3, 1, 7, 1, 8, 2, 4, 1, 9, 3, 1, 10, 2, 5, 1, 11, 1, 12, 2, 6, 3, 4, 1, 13, 1, 14, 2, 7, 1, 15, 3, 5, 1, 16, 2, 8, 4, 1, 17, 1, 18, 2, 9, 3, 6, 1, 19, 1, 20, 2, 10, 4, 5, 1, 21, 3, 7, 1, 22, 2, 11, 1, 23, 1, 24
Offset: 1

Views

Author

Omar E. Pol, Jul 29 2012

Keywords

Comments

A two-dimensional arrangement of squares has the property that the number of vertices in row n equals the number of divisors of n. So T(n,k) is represented in the structure as the k-th vertex of row n (see the illustration of initial terms).

Examples

			Written as an irregular triangle the sequence begins:
1;
1, 2;
1, 3;
1, 4, 2;
1, 5;
1, 6, 2, 3;
1, 7;
1, 8, 2, 4;
1, 9, 3;
1, 10, 2, 5;
1, 11;
1, 12, 2, 6, 3, 4;
		

Crossrefs

Row n has length A000005(n). Row sums give A000203. Right border gives A033677.

Programs

  • PARI
    row(n) = my(d=divisors(n)); vector(#d, k, if (k % 2, d[(k+1)/2], d[#d-k/2+1])); \\ Michel Marcus, Jun 20 2019