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.

A274913 Square array read by antidiagonals upwards in which each new term is the least positive integer distinct from its neighbors.

Original entry on oeis.org

1, 2, 3, 1, 4, 1, 2, 3, 2, 3, 1, 4, 1, 4, 1, 2, 3, 2, 3, 2, 3, 1, 4, 1, 4, 1, 4, 1, 2, 3, 2, 3, 2, 3, 2, 3, 1, 4, 1, 4, 1, 4, 1, 4, 1, 2, 3, 2, 3, 2, 3, 2, 3, 2, 3, 1, 4, 1, 4, 1, 4, 1, 4, 1, 4, 1, 2, 3, 2, 3, 2, 3, 2, 3, 2, 3, 2, 3, 1, 4, 1, 4, 1, 4, 1, 4, 1, 4, 1, 4, 1, 2, 3, 2, 3, 2, 3, 2, 3, 2, 3, 2, 3, 2, 3
Offset: 1

Views

Author

Omar E. Pol, Jul 11 2016

Keywords

Comments

This is also a triangle read by rows in which each new term is the least positive integer distinct from its neighbors.
In the square array we have that:
Antidiagonal sums give the positive terms of A008851.
Odd-indexed rows give A010684.
Even-indexed rows give A010694.
Odd-indexed columns give A000034.
Even-indexed columns give A010702.
Odd-indexed antidiagonals give the initial terms of A010685.
Even-indexed antidiagonals give the initial terms of A010693.
Main diagonal gives A010685.
This is also a triangle read by rows in which each new term is the least positive integer distinct from its neighbors.
In the triangle we have that:
Row sums give the positive terms of A008851.
Odd-indexed columns give A000034.
Even-indexed columns give A010702.
Odd-indexed diagonals give A010684.
Even-indexed diagonals give A010694.
Odd-indexed rows give the initial terms of A010685.
Even-indexed rows give the initial terms of A010693.
Odd-indexed antidiagonals give the initial terms of A010684.
Even-indexed antidiagonals give the initial terms of A010694.

Examples

			The corner of the square array begins:
1, 3, 1, 3, 1, 3, 1, 3, 1, 3, ...
2, 4, 2, 4, 2, 4, 2, 4, 2, ...
1, 3, 1, 3, 1, 3, 1, 3, ...
2, 4, 2, 4, 2, 4, 2, ...
1, 3, 1, 3, 1, 3, ...
2, 4, 2, 4, 2, ...
1, 3, 1, 3, ...
2, 4, 2, ...
1, 3, ...
2, ...
...
The sequence written as a triangle begins:
1;
2, 3;
1, 4, 1;
2, 3, 2, 3;
1, 4, 1, 4, 1;
2, 3, 2, 3, 2, 3;
1, 4, 1, 4, 1, 4, 1;
2, 3, 2, 3, 2, 3, 2, 3;
1, 4, 1, 4, 1, 4, 1, 4, 1;
2, 3, 2, 3, 2, 3, 2, 3, 2, 3;
...
		

Crossrefs

Programs

  • Mathematica
    Table[1 + Boole@ EvenQ@ # + 2 Boole@ EvenQ@ k &[n - k + 1], {n, 14}, {k, n}] // Flatten (* Michael De Vlieger, Nov 14 2016 *)

Formula

a(n) = A274912(n) + 1.