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.

A089898 Product of (digits of n each incremented by 1).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 6, 12, 18, 24, 30, 36, 42, 48, 54, 60, 7, 14, 21, 28, 35, 42, 49, 56, 63, 70, 8, 16, 24, 32, 40, 48, 56, 64
Offset: 0

Views

Author

Marc LeBrun, Nov 13 2003

Keywords

Comments

Sum of products of all subsets of digits of n (with the empty subset contributing 1).
Number of nonnegative values k such that the lunar sum of k and n is n.
First 100 values are 10 X 10 multiplication table, read by rows/columns.

Examples

			a(12)=6 since (1+1)*(2+1)=2*3=6 and since (1*2)+(1)+(2)+(1)=2+1+2+1=6 and since the lunar sum of 12 with any of the six values {0,1,2,10,11,12} is 12.
		

Crossrefs

Programs

  • Haskell
    a089898 n = if n < 10 then n + 1 else (d + 1) * a089898 n'
                where (n', d) = divMod n 10
    -- Reinhard Zumkeller, Jul 06 2014
  • Maple
    seq(convert(map(`+`,convert(n,base,10),1),`*`), n = 0 .. 1000); # Robert Israel, Nov 17 2014
  • Mathematica
    a089898[n_Integer] :=
    Prepend[Array[Times @@ (IntegerDigits[#] + 1) &, n], 1]; a089898[77] (* Michael De Vlieger, Dec 22 2014 *)
  • PARI
    a(n) = my(d=digits(n)); prod(i=1, #d, d[i]+1); \\ Michel Marcus, Apr 06 2014
    
  • PARI
    a(n) = vecprod(apply(x->x+1, digits(n))); \\ Michel Marcus, Feb 01 2023
    

Formula

a(n) = a(floor(n/10))*(1+(n mod 10)). - Robert Israel, Nov 17 2014
G.f. g(x) satisfies g(x) = (10*x^11 - 11*x^10 + 1)*g(x^10)/(x-1)^2. - Robert Israel, Nov 17 2014