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.

A106264 Diagonal sums of number triangle A106262.

Original entry on oeis.org

1, 0, 1, 2, 2, 4, 2, 4, 6, 7, 7, 8, 14, 10, 13, 12, 15, 19, 22, 22, 23, 25, 25, 44, 44, 40, 28, 50, 44, 54, 52, 55, 50, 66, 53, 72, 83, 80, 58, 73, 82, 110, 114, 123, 127, 113, 91, 112, 158, 137, 117, 122, 152, 135, 166, 160, 211, 206, 171, 219, 240, 201, 188, 194, 236
Offset: 0

Views

Author

Paul Barry, Apr 28 2005

Keywords

Crossrefs

Cf. A106262.

Programs

  • Magma
    [(&+[2^(n-2*k) mod (k+2): k in [0..Floor(n/2)]]): n in [0..80]]; // G. C. Greubel, Jan 10 2023
    
  • Mathematica
    Table[Sum[Mod[2^(n-2*k), k+2], {k,0,Floor[n/2]}], {n,0,80}] (* G. C. Greubel, Jan 10 2023 *)
  • SageMath
    def A106264(n): return sum( (2^(n-2*k)%(k+2)) for k in range(n//2+1) )
    [A106264(n) for n in range(81)] # G. C. Greubel, Jan 10 2023

Formula

a(n) = Sum_{k=0..floor(n/2)} ( 2^(n-2*k) mod (k+2) ).