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.

A191664 Dispersion of A014601 (numbers >2, congruent to 0 or 3 mod 4), by antidiagonals.

Original entry on oeis.org

1, 3, 2, 7, 4, 5, 15, 8, 11, 6, 31, 16, 23, 12, 9, 63, 32, 47, 24, 19, 10, 127, 64, 95, 48, 39, 20, 13, 255, 128, 191, 96, 79, 40, 27, 14, 511, 256, 383, 192, 159, 80, 55, 28, 17, 1023, 512, 767, 384, 319, 160, 111, 56, 35, 18, 2047, 1024, 1535, 768, 639
Offset: 1

Views

Author

Clark Kimberling, Jun 11 2011

Keywords

Comments

Row 1: A000225 (-1+2^n)
Row 2: A000079 (2^n)
Row 3: A055010
Row 4: 3*A000079
Row 5: A153894
Row 6: 5*A000079
Row 7: A086224
Row 8: A005009
Row 9: A052996
For a background discussion of dispersions, see A191426.
...
Each of the sequences (4n, n>2), (4n+1, n>0), (3n+2, n>=0), generates a dispersion. Each complement (beginning with its first term >1) also generates a dispersion. The six sequences and dispersions are listed here:
...
A191663=dispersion of A042948 (0 or 1 mod 4 and >1)
A054582=dispersion of A005843 (0 or 2 mod 4 and >1; evens)
A191664=dispersion of A014601 (0 or 3 mod 4 and >1)
A191665=dispersion of A042963 (1 or 2 mod 4 and >1)
A191448=dispersion of A005408 (1 or 3 mod 4 and >1, odds)
A191666=dispersion of A042964 (2 or 3 mod 4)
...
EXCEPT for at most 2 initial terms (so that column 1 always starts with 1):
A191663 has 1st col A042964, all else A042948
A054582 has 1st col A005408, all else A005843
A191664 has 1st col A042963, all else A014601
A191665 has 1st col A014601, all else A042963
A191448 has 1st col A005843, all else A005408
A191666 has 1st col A042948, all else A042964
...
There is a formula for sequences of the type "(a or b mod m)", (as in the Mathematica program below):
If f(n)=(n mod 2), then (a,b,a,b,a,b,...) is given by
a*f(n+1)+b*f(n), so that "(a or b mod m)" is given by
a*f(n+1)+b*f(n)+m*floor((n-1)/2)), for n>=1.
This sequence is a permutation of the natural numbers. - L. Edson Jeffery, Aug 13 2014

Examples

			Northwest corner:
1...3...7....15...31
2...4...8....16...32
5...11..23...47...95
6...12..24...48...96
9...19..39...79...159
		

Crossrefs

Programs

  • Mathematica
    (* Program generates the dispersion array T of the increasing sequence f[n] *)
    r = 40; r1 = 12;  c = 40; c1 = 12;
    a = 3; b = 4; m[n_] := If[Mod[n, 2] == 0, 1, 0];
    f[n_] := a*m[n + 1] + b*m[n] + 4*Floor[(n - 1)/2]
    Table[f[n], {n, 1, 30}]  (* A014601(n+2): (4+4k,5+4k) *)
    mex[list_] := NestWhile[#1 + 1 &, 1, Union[list][[#1]] <= #1 &, 1, Length[Union[list]]]
    rows = {NestList[f, 1, c]};
    Do[rows = Append[rows, NestList[f, mex[Flatten[rows]], r]], {r}];
    t[i_, j_] := rows[[i, j]];
    TableForm[Table[t[i, j], {i, 1, 10}, {j, 1, 10}]] (* A191664 *)
    Flatten[Table[t[k, n - k + 1], {n, 1, c1}, {k, 1, n}]] (* A191664  *)
    (* Clark Kimberling, Jun 11 2011 *)
    Grid[Table[2^k*(2*Floor[(n + 1)/2] - 1) - Mod[n, 2], {n, 12}, {k, 12}]] (* L. Edson Jeffery, Aug 13 2014 *)