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.

A161415 First differences of A160414.

Original entry on oeis.org

1, 8, 12, 28, 12, 36, 36, 92, 12, 36, 36, 108, 36, 108, 108, 292, 12, 36, 36, 108, 36, 108, 108, 324, 36, 108, 108, 324, 108, 324, 324, 908, 12, 36, 36, 108, 36, 108, 108, 324, 36, 108, 108, 324, 108, 324, 324, 972, 36, 108, 108, 324, 108, 324, 324, 972, 108, 324, 324
Offset: 1

Views

Author

Omar E. Pol, May 20 2009, Jun 13 2009

Keywords

Crossrefs

Programs

  • Maple
    Contribution from R. J. Mathar, Oct 16 2010: (Start)
    isA000079 := proc(n) if type(n,'even') then nops(numtheory[factorset](n)) = 1 ; else false ; fi ; end proc:
    A048883 := proc(n) 3^wt(n) ; end proc:
    A161415 := proc(n) if n = 1 then 1; elif isA000079(n) then 4*A048883(n-1)-2*n ; else 4*A048883(n-1) ; end if; end proc: seq(A161415(n),n=1..90) ; (End)
  • Mathematica
    a[1] = 1; a[n_] := 4*3^DigitCount[n-1, 2, 1] - If[IntegerQ[Log[2, n]], 2n, 0];
    Array[a, 60] (* Jean-François Alcover, Nov 17 2017, after N. J. A. Sloane *)

Formula

For n > 1, a(n) = 4*A048883(n-1), except a(n) = 4*A048883(n-1) - 2n if n is a power of 2. - N. J. A. Sloane, Jul 13 2009

Extensions

More terms from R. J. Mathar, Oct 16 2010