login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Product of the nonzero digital products of all the prime numbers prime(1) to prime(n).
1

%I #23 Sep 20 2024 03:04:57

%S 2,6,30,210,210,630,4410,39690,238140,4286520,12859560,270050760,

%T 1080203040,12962436480,362948221440,5444223321600,244990049472000,

%U 1469940296832000,61737492466944000,432162447268608000,9075411392640768000,571750917736368384000

%N Product of the nonzero digital products of all the prime numbers prime(1) to prime(n).

%H Harvey P. Dale, <a href="/A127482/b127482.txt">Table of n, a(n) for n = 1..547</a>

%F a(n) = Product_{k=1..n} dp_p(prime(k)) where prime(k)=A000040(k) and dp_p(m)=product of the nonzero digits of m in base p (p=10 for this sequence). - _Hieronymus Fischer_, Sep 29 2007

%F From _Michel Marcus_, Mar 11 2022: (Start)

%F a(n) = Product_{k=1..n} A051801(prime(k)).

%F a(n) = Product_{k=1..n} A101987(k). (End)

%e a(7) = dp_10(2)*dp_10(3)*dp_10(5)*dp_10(7)*dp_10(11)*dp_10(13)*dp_10(17) = 2*3*5*7*(1*1)*(1*3)*(1*7) = 4410.

%p a:= proc(n) option remember; `if`(n<1, 1, a(n-1)*mul(

%p `if`(i=0, 1, i), i=convert(ithprime(n), base, 10)))

%p end:

%p seq(a(n), n=1..30); # _Alois P. Heinz_, Mar 11 2022

%t Rest[FoldList[Times,1,Times@@Cases[IntegerDigits[#],Except[0]]&/@ Prime[ Range[ 20]]]] (* _Harvey P. Dale_, Mar 19 2013 *)

%o (PARI) f(n) = vecprod(select(x->(x>1), digits(prime(n)))); \\ A101987

%o a(n) = prod(k=1, n, f(k)); \\ _Michel Marcus_, Mar 11 2022

%o (Python)

%o from math import prod

%o from sympy import sieve

%o def pod(s): return prod(int(d) for d in s if d != '0')

%o def a(n): return pod("".join(str(sieve[i+1]) for i in range(n)))

%o print([a(n) for n in range(1, 23)]) # _Michael S. Branicky_, Mar 11 2022

%Y Cf. A000040, A007953, A007954, A051801, A101987, A131385, A131387, A131451.

%K base,easy,nonn

%O 1,1

%A Alain Van Kerckhoven (alain(AT)avk.org), Sep 12 2007

%E Corrected and extended by _Hieronymus Fischer_, Sep 29 2007