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.

Showing 1-2 of 2 results.

A217407 Numbers of the form 3^r * 5^s whose decimal representation has a prime number of each digit 0-9.

Original entry on oeis.org

38171039656829610443115234375, 129892841018736362457275390625, 1766298261467341813095601383375, 83480063729486358039093017578125, 715350795894273434303718560266875, 172661884789704345166683197021484375, 65186341275865666700926353804318984375, 5280093643345119002775034658149837734375
Offset: 1

Views

Author

James G. Merickel, Oct 02 2012

Keywords

Comments

This sequence in particular is motivated by the coincidence that both (2^41)*(3^43) and (3^43)*(5^47) have prime numbers of each digit.

Examples

			The first term here is (3^35)*(5^17), corresponding to A217408(1)=35 and A217409(1)=17. Its decimal representation has two each of 0's, 2's, 7's, 8's and 9's; three each of 4's, 5's and 6's; and 5 each of 1's and 3's.
		

Crossrefs

Programs

  • Maple
    N:= 10^100: # to get all terms <= N
    filter:= proc(n) local L,P,d;
      L:= convert(n,base,10);
      P:= Vector(10);
      for d in L do P[d+1]:= P[d+1]+1 od:
      andmap(isprime,P);
    end proc:
    sort(select(filter, [seq(seq(3^r*5^s, r=0..floor(log[3](N/5^s))),s=0..floor(log[5](N)))])); # Robert Israel, May 08 2017
  • PARI
    prDigits(n)=my(d=digits(n), v=vector(10)); for(i=1, #d, v[d[i]+1]++); for(i=1, 10, if(!isprime(v[i]), return(0))); 1
    list(lim)=my(v=List(), t); for(a=0, log(lim+.5)\log(5), t=5^a; while(t<=lim, if(prDigits(t), listput(v, t)); t*=3)); vecsort(Vec(v)) \\ Charles R Greathouse IV, Sep 19 2013

Formula

a(n) = 3^A217408(n) * 5^A217409(n).

Extensions

More terms from Robert Israel, May 08 2017

A217408 3-adic valuation of A217407.

Original entry on oeis.org

35, 20, 59, 42, 63, 5, 69, 73, 21, 43, 71, 1149
Offset: 1

Views

Author

James G. Merickel, Oct 02 2012

Keywords

Comments

See main sequence for rationale.

Examples

			The first number that has only 3 and 5 as prime factors and has prime counts of each digit 0-9 in its decimal representation is (3^35)*(5^17), so, corresponding to that being A217407(1), this sequence's first term is 35.
		

Crossrefs

Programs

  • PARI
    prDigits(n)=my(d=digits(n), v=vector(10)); for(i=1, #d, v[d[i]+1]++); for(i=1, 10, if(!isprime(v[i]), return(0))); 1
    list(lim)=my(v=List(), t); for(a=0, log(lim+.5)\log(5), t=5^a; while(t<=lim, if(prDigits(t), listput(v, t)); t*=3)); apply(k -> valuation(k,3), vecsort(Vec(v))) \\ Charles R Greathouse IV, Sep 19 2013
Showing 1-2 of 2 results.