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.

Showing 1-2 of 2 results.

A331105 T(n,k) = -k*(k+1)/2 mod 2^n; triangle T(n,k), n>=0, 0<=k<=2^n-1, read by rows.

Original entry on oeis.org

0, 0, 1, 0, 3, 1, 2, 0, 7, 5, 2, 6, 1, 3, 4, 0, 15, 13, 10, 6, 1, 11, 4, 12, 3, 9, 14, 2, 5, 7, 8, 0, 31, 29, 26, 22, 17, 11, 4, 28, 19, 9, 30, 18, 5, 23, 8, 24, 7, 21, 2, 14, 25, 3, 12, 20, 27, 1, 6, 10, 13, 15, 16, 0, 63, 61, 58, 54, 49, 43, 36, 28, 19, 9
Offset: 0

Views

Author

Alois P. Heinz, Jan 09 2020

Keywords

Comments

Row n is a permutation of {0, 1, ..., A000225(n)}.

Examples

			Triangle T(n,k) begins:
  0;
  0,  1;
  0,  3,  1,  2;
  0,  7,  5,  2, 6, 1,  3, 4;
  0, 15, 13, 10, 6, 1, 11, 4, 12, 3, 9, 14, 2, 5, 7, 8;
  ...
		

Crossrefs

Columns k=0-2 give: A000004, A000225, A036563 (for n>1).
Row sums give A006516.
Row lengths give A000079.
T(n,n) gives A014833 (for n>0).
T(n,2^n-1) gives A131577.

Programs

  • Maple
    T:= n-> (p-> seq(modp(-k*(k+1)/2, p), k=0..p-1))(2^n):
    seq(T(n), n=0..6);
    # second Maple program:
    T:= proc(n, k) option remember;
          `if`(k=0, 0, T(n, k-1)-k mod 2^n)
        end:
    seq(seq(T(n, k), k=0..2^n-1), n=0..6);
  • Mathematica
    T[n_, k_] := T[n, k] = If[k == 0, 0, Mod[T[n, k - 1] - k, 2^n]];
    Table[Table[T[n, k], {k, 0, 2^n - 1}], {n, 0, 6}] // Flatten (* Jean-François Alcover, Mar 28 2022, after Alois P. Heinz *)

A130104 Expansion of x(1-3x+5x^2-2x^3)/((1-x)^3*(1-2x)).

Original entry on oeis.org

0, 1, 2, 6, 17, 43, 100, 220, 467, 969, 1982, 4018, 8101, 16279, 32648, 65400, 130919, 261973, 524098, 1048366, 2096921, 4194051, 8388332, 16776916, 33554107, 67108513, 134217350, 268435050, 536870477, 1073741359
Offset: 0

Views

Author

Paul Barry, May 07 2007

Keywords

Comments

a(n+1)=A014833(n+2).
Partial sums of A130103.

Crossrefs

Programs

  • Mathematica
    Accumulate[Join[{0,1},LinearRecurrence[{4,-5,2},{1,4,11},40]]] (* Harvey P. Dale, May 16 2014 *)
    Join[{0},LinearRecurrence[{5, -9, 7, -2},{1, 2, 6, 17},29]] (* Ray Chandler, Aug 03 2015 *)

Formula

a(n)=2^(n+1)-C(n+2,2)-0^n.
Showing 1-2 of 2 results.