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.

A227154 Product of digits+1 of n in factorial base.

This page as a plain text file.
%I A227154 #31 Feb 27 2025 13:34:17
%S A227154 1,2,2,4,3,6,2,4,4,8,6,12,3,6,6,12,9,18,4,8,8,16,12,24,2,4,4,8,6,12,4,
%T A227154 8,8,16,12,24,6,12,12,24,18,36,8,16,16,32,24,48,3,6,6,12,9,18,6,12,12,
%U A227154 24,18,36,9,18,18,36,27,54,12,24,24,48,36,72,4,8,8
%N A227154 Product of digits+1 of n in factorial base.
%H A227154 Antti Karttunen, <a href="/A227154/b227154.txt">Table of n, a(n) for n = 0..5040</a> (corrected by Ray Chandler, Jan 19 2019)
%H A227154 Tyler Ball, Joanne Beckford, Paul Dalenberg, Tom Edgar, and Tina Rajabi, <a href="https://cs.uwaterloo.ca/journals/JIS/VOL23/Edgar/edgar3.html">Some Combinatorics of Factorial Base Representations</a>, J. Int. Seq., Vol. 23 (2020), Article 20.3.3.
%H A227154 <a href="/index/Fa#facbase">Index entries for sequences related to factorial base representation</a>.
%e A227154 5 has factorial base representation A007623(5) = "21" (as 2*2 + 1*1 = 5). Adding one to these digits and multiplying, we get 3*2 = 6, thus a(5)=6.
%t A227154 a[n_] := Module[{k = n, m = 2, r, p = 1}, While[{k, r} = QuotientRemainder[k, m]; k != 0|| r != 0, p *= (r+1); m++]; p]; Array[a, 100, 0] (* _Amiram Eldar_, Feb 13 2024 *)
%o A227154 (MIT/GNU Scheme)
%o A227154 (define (A227154 n) (apply * (map 1+ (n->factbase n))))
%o A227154 (define (n->factbase n) (let loop ((n n) (fex (if (zero? n) (list 0) (list))) (i 2)) (cond ((zero? n) fex) (else (loop (floor->exact (/ n i)) (cons (modulo n i) fex) (1+ i))))))
%o A227154 (PARI) a(n)=my(b=2,t=1); while(n, t *= n%b + 1; n \= b; b++); t \\ _Charles R Greathouse IV_, Jun 06 2017
%Y A227154 Cf. A007623, A208575, A227153.
%K A227154 nonn,base
%O A227154 0,2
%A A227154 _Antti Karttunen_, Jul 04 2013
%E A227154 a(0)=1 added by _Tom Edgar_, Jun 05 2017