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.

A082458 Multiply by 1, add 1, multiply by 2, add 2, etc., starting with 0.

Original entry on oeis.org

0, 0, 1, 2, 4, 12, 15, 60, 64, 320, 325, 1950, 1956, 13692, 13699, 109592, 109600, 986400, 986409, 9864090, 9864100, 108505100, 108505111, 1302061332, 1302061344, 16926797472, 16926797485, 236975164790, 236975164804, 3554627472060, 3554627472075, 56874039553200, 56874039553216
Offset: 0

Views

Author

Vladeta Jovovic, Apr 25 2003

Keywords

Comments

Bisections: A007526 and A038154.

Crossrefs

Cf. A019464 (same, but start with 1), A019465 (start with 2), A019466 (start with 3).
Cf. A019460 .. A019463 & A082448 (similar, but first add, then multiply).

Programs

  • Mathematica
    Module[{a = 0}, Join[{a}, Flatten[Array[{a *= #, a += #} &, 20]]]] (* Paolo Xausa, Oct 24 2024 *)
  • PARI
    a(n)=if(n<2,0,if(n%2,(n+1)/2*(floor(exp(1)*((n-1)/2)!)-1),floor(exp(1)*(n/2)!)-1))
    
  • PARI
    A082458(n,a=0)={for(i=2,n+1,if(bittest(i,0),a+=i\2,a*=i\2));a} \\ M. F. Hasler, Feb 25 2018

Formula

For n>=2, a(2n)=floor(e*n!)-1, a(2*n+1)=(n+1)*(floor(e*n!)-1). - Benoit Cloitre, Apr 28 2003

Extensions

Edited by M. F. Hasler, Feb 25 2018