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.

Previous Showing 61-70 of 103 results. Next

A217113 Greatest number (in decimal representation) with n nonprime substrings in base-3 representation (substrings with leading zeros are considered to be nonprime).

Original entry on oeis.org

2, 23, 71, 26, 77, 233, 239, 719, 701, 647, 725, 2159, 2177, 2158, 2157, 5822, 5741, 6551, 6476, 6532, 6531, 18944, 19436, 19655, 19601, 19673, 19653, 58310, 58309, 58316, 58967, 59021, 58964, 157211, 157217, 174950, 176408, 176407, 176903, 177065, 177064, 471653, 511511
Offset: 0

Views

Author

Hieronymus Fischer, Dec 20 2012

Keywords

Comments

The sequence is well-defined in that for each n the set of numbers with n nonprime substrings is not empty and finite. Proof of existence: Define m(n):=2*sum_{j=i..k} 3^j, where k:=floor((sqrt(8n+1)-1)/2), i:= n-(k(k+1)/2). For n=0,1,2,3,... the m(n) in base-3 representation are 2, 22, 20, 222, 220, 200, 2222, 2220, 2200, 2000, 22222, 22220, .... m(n) has k+1 digits and (k-i+1) 2’s. Thus, the number of nonprime substrings of m(n) is ((k+1)(k+2)/2)-k-1+i=(k(k+1)/2)+i=n. This proves the statement of existence. Proof of finiteness: Each 2-digit base-3 number has at least 1 nonprime substring. Hence, each 2(n+1)-digit number has at least n+1 nonprime substrings. Consequently, there is a boundary b < 3^(2n+1) such that all numbers > b have more than n nonprime substrings. It follows, that the set of numbers with n nonprime substrings is finite.

Examples

			a(0) = 2, since 2 = 2_3 (base-3) is the greatest number with zero nonprime substrings in base-3 representation.
a(1) = 23 = 212_3 has 1 substring in base-3 representation (= 1). All the other base-3 substrings (2, 2, 21, 12, 212) are prime substrings. 23 is the greatest number with 1 nonprime substring.
a(2) = 71 = 2122_3 has 10 substrings in base-3 representation (1, 2, 2, 2, 12, 21, 22, 122, 212, 2122), exactly 2 of them are nonprime substrings (1 and 22_3=8), and there is no greater number with 2 nonprime substrings in base-3 representation.
a(3) = 26 = 222_3 has 6 substrings in base-3 representation, only 3 of them are prime substrings (2, 2, 2) which implies that exactly 3 substrings must be nonprime, and there is no greater number with 3 nonprime substrings in base-3 representation.
		

Crossrefs

Formula

a(n) >= A217103(n).
a(n) >= A217303(A000217(A081604(a(n)))-n).
Example: a(12)=2177=2222122_3, A000217(A081604(2177))=28, hence a(12)>=A217303(28-12)=1934.
a(n) <= 3^min(n + 2, 5*floor((n+4)/5)).
a(n) <= 3^(n + 2).
a(n) <= 3^min((n + 11)/3, 11*floor((n+32)/33)).
a(n) <= 3^((1/3)*(n + 11)).
With m := floor(log_3(a(n))) + 1:
a(n+m+1) >= 3*a(n), if a(n)!=1 (mod 3).
a(n+m) >= 3*a(n), if a(n)=1 (mod 3).

A217118 Greatest number (in decimal representation) with n nonprime substrings in base-8 representation (substrings with leading zeros are considered to be nonprime).

Original entry on oeis.org

491, 3933, 24303, 32603, 188143, 253789, 261117, 1555423, 2030319, 2088797, 2088943, 16185163, 16710383, 16710381, 16768991, 99606365, 129884143, 133683069, 134150015, 134209503, 770611067, 1039073149, 1069408239, 1073209071, 1073209083, 1073676029, 5065578363
Offset: 0

Views

Author

Hieronymus Fischer, Dec 20 2012

Keywords

Comments

The sequence is well-defined in that for each n the set of numbers with n nonprime substrings is not empty and finite. Proof of existence: Define m(n):=2*sum_{j=i..k} 8^j, where k:=floor((sqrt(8n+1)-1)/2), i:= n-(k(k+1)/2). For n=0,1,2,3,... the m(n) in base-8 representation are 2, 22, 20, 222, 220, 200, 2222, 2220, 2200, 2000, 22222, 22220, .... m(n) has k+1 digits and (k-i+1) 2’s. Thus, the number of nonprime substrings of m(n) is ((k+1)(k+2)/2)-k-1+i=(k(k+1)/2)+i=n. This proves the statement of existence. Proof of finiteness: Each 4-digit base-8 number has at least 1 nonprime substring. Hence, each 4(n+1)-digit number has at least n+1 nonprime substrings. Consequently, there is a boundary b < 8^(4n+3) such that all numbers > b have more than n nonprime substrings. It follows, that the set of numbers with n nonprime substrings is finite.

Examples

			a(0) = 491, since 491 = 753_8 (base-8) is the greatest number with zero nonprime substrings in base-8 representation.
a(1) = 3933 = 7535_8 has 1 nonprime substring in base-8 representation (=7535_8). All the other base-8 substrings are prime substrings. 3933 is the greatest such number with 1 nonprime substring.
a(2) = 24303 = 57357_8 has 15 substrings in base-8 representation, exactly 2 of them are nonprime substrings (57357_8 and 735_8), and there is no greater number with 2 nonprime substrings in base-3 representation.
a(3) = 32603 = 77533_8 has 15 substrings in base-8 representation, only 3 of them are nonprime substrings (33_8, 77_8, and 7753_8), and there is no greater number with 3 nonprime substrings in base-8 representation.
		

Crossrefs

Formula

a(n) >= A217108(n).
a(n) >= A217308(A000217(num_digits_8(a(n)))-n), where num_digits_8(x) is the number of digits of the base-8 representation of x.
a(n) <= 8^min(n+3, 7*floor((n+6)/7)).
a(n) <= 512*8^n.
a(n+m+1) >= 8*a(n), where m := floor(log_8(a(n))) + 1.

A217304 Minimal natural number (in decimal representation) with n prime substrings in base-4 representation (substrings with leading zeros are considered to be nonprime).

Original entry on oeis.org

1, 2, 7, 11, 23, 43, 93, 151, 239, 373, 479, 727, 1495, 2015, 2775, 5591, 6133, 7919, 12271, 22367, 24303, 30431, 48991, 89527, 95607, 98143, 129887, 357883, 358111, 382431, 744797, 519551, 1431007, 1432447, 1556319, 2457439
Offset: 0

Views

Author

Hieronymus Fischer, Nov 22 2012

Keywords

Comments

The sequence is well-defined in that for each n the set of numbers with n prime substrings is not empty. Proof: Define m(0):=1, m(1):=2 and m(n+1):=4*m(n)+2 for n>0. This results in m(n)=2*sum_{j=0..n-1} 4^j = 2*(4^n - 1)/3 or m(n)=1, 2, 22, 222, 2222, 22222, …,for n=0,1,2,3,…. Evidently, for n>0 m(n) has n 2’s and these are the only prime substrings in base-4 representation. This is why every substring of m(n) with more than one digit is a product of two integers > 1 (by definition) and can therefore not be prime number.
No term is divisible by 4. a(1) = 2 is the only even term.

Examples

			a(1) = 2 = 2_4, since 2 is the least number with 1 prime substring in base-4 representation.
a(2) = 7 = 13_4, since 7 is the least number with 2 prime substrings in base-4 representation (3_4=3 and 13_4=7).
a(3) = 11 = 23_4, since 11 is the least number with 3 prime substrings in base-4 representation (2_4, 3_4, and 23_4).
a(5) = 43 = 223_4, since 43 is the least number with 5 prime substrings in base-4 representation (2 times 2_4, 3_4, 23_4=11, and 223_4=43).
a(7) = 151 = 2113_4, since 151 is the least number with 7 prime substrings in base-4 representation (2 times 2_4, 3_4, 11_4=5, 13_4=7, 113_4=23, and 2113_4=151).
		

Crossrefs

Formula

a(n) > 4^floor(sqrt(8*n-7)-1)/2), for n>0.
a(n) <= 2*(4^n - 1)/3, n>0.
a(n+1) <= 4*a(n) + 2.

A217305 Minimal natural number (in decimal representation) with n prime substrings in base-5 representation (substrings with leading zeros are considered to be nonprime).

Original entry on oeis.org

1, 2, 7, 13, 37, 88, 67, 192, 317, 932, 942, 1567, 4663, 4692, 8442, 23317, 23442, 36067, 102217, 114192, 180337, 192317, 511087, 901682, 582942, 2495443, 2555436, 2536067, 5289942, 12321061, 12680337, 12301692, 26461592, 61508461, 61508462, 63885918
Offset: 0

Views

Author

Hieronymus Fischer, Nov 22 2012

Keywords

Comments

The sequence is well-defined in that for each n the set of numbers with n prime substrings is not empty. Proof: Define m(0):=1, m(1):=2 and m(n+1):=5*m(n)+2 for n>0. This results in m(n)=2*sum_{j=0..n-1} 5^j = (5^n - 1)/2 or m(n)=1, 2, 22, 222, 2222, 22222,…, (in base-5) for n=0,1,2,3,…. Evidently, for n>0 m(n) has n 2’s and these are the only prime substrings in base-5 representation. This is why every substring of m(n) with more than one digit is a product of two integers > 1 (by definition) and can therefore not be a prime number.
No term is divisible by 5.

Examples

			a(1) = 2 = 2_5, since 2 is the least number with 1 prime substring in base-5 representation.
a(2) = 7 = 12_5, since 7 is the least number with 2 prime substrings in base-5 representation (2_5 and 12_5=7).
a(3) = 13 = 23_5, since 13 is the least number with 3 prime substrings in base-5 representation (2_5, 3_5, and 23_5).
a(4) = 37 = 122_5, since 37 is the least number with 4 prime substrings in base-5 representation (2 times 2_5, 12_5=7, and 122_5=37).
a(7) = 192 = 1232_5, since 192 is the least number with 7 prime substrings in base-5 representation (2 times 2_5, 3_5, 12_5=7, 23_5=13, 32_5=17, and 232_5=67).
		

Crossrefs

Formula

a(n) > 5^floor(sqrt(8*n-7)-1)/2), for n>0.
a(n) <= (5^n - 1)/2, n>0.

A217306 Minimal natural number (in decimal representation) with n prime substrings in base-6 representation (substrings with leading zeros are considered to be nonprime).

Original entry on oeis.org

1, 2, 11, 17, 47, 83, 269, 263, 479, 839, 1559, 1579, 2999, 5039, 9355, 9479, 14759, 56131, 56135, 61343, 56879, 336791, 341351, 336815, 341279, 341275, 2020727, 2020895, 2047651, 2020891, 4055159, 12098587, 12125347, 12285907, 15737755, 19128523, 39190247
Offset: 0

Views

Author

Hieronymus Fischer, Nov 22 2012

Keywords

Comments

The sequence is well-defined in that for each n the set of numbers with n prime substrings is not empty. Proof: Define m(0):=1, m(1):=2 and m(n+1):=6*m(n)+2 for n>0. This results in m(n)=2*sum_{j=0..n-1} 6^j = 2*(6^n - 1)/5 or m(n)=1, 2, 22, 222, 2222, 22222, …, (in base-6) for n=0,1,2,3,…. Evidently, for n>0 m(n) has n 2’s and these are the only prime substrings in base-6 representation. This is why every substring of m(n) with more than one digit is a product of two integers > 1 (by definition) and can therefore not be prime number.
No term is divisible by 6.

Examples

			a(1) = 2 = 2_6, since 2 is the least number with 1 prime substring in base-6 representation.
a(2) = 11 = 15_6, since 11 is the least number with 2 prime substrings in base-6 representation (5_6=5 and 15_6=11).
a(3) = 17 = 25_6, since 17 is the least number with 3 prime substrings in base-6 representation (2_6, 5_6, and 25_6).
a(4) = 47 = 115_6, since 47 is the least number with 4 prime substrings in base-6 representation (5_6, 11_6=7, 15_6=11, and 115_6=47).
a(8) = 479 = 2115_6, since 479 is the least number with 8 prime substrings in base-6 representation (2_6, 5_6, 11_6=7, 15_6=11, 21_6=13, 115_6=47, 211_6=79, and 2115_6=479).
		

Crossrefs

Formula

a(n) > 6^floor(sqrt(8*n-7)-1)/2), for n>0.
a(n) <= 2*(6^n - 1)/5, n>0.
a(n+1) <= 6*a(n)+2.

A217307 Minimal natural number (in decimal representation) with n prime substrings in base-7 representation (substrings with leading zeros are considered to be nonprime).

Original entry on oeis.org

1, 2, 16, 17, 115, 121, 509, 821, 3251, 4721, 5749, 22760, 25301, 41673, 142950, 173819, 291714, 920561, 1222716, 2041709, 4450031, 8559017, 9350687, 14295199, 31150219, 50568439, 71502954, 100066398, 218051538, 353979075, 500526787, 702815371, 1512442643
Offset: 0

Views

Author

Hieronymus Fischer, Nov 22 2012

Keywords

Comments

The sequence is well-defined in that for each n the set of numbers with n prime substrings is not empty. Proof: Define m(0):=1, m(1):=2 and m(n+1):=7*m(n)+2 for n>0. This results in m(n)=2*sum_{j=0..n-1} 7^j = (7^n - 1)/3 or m(n)=1, 2, 22, 222, 2222, 22222,…, (in base-7) for n=0,1,2,3,…. Evidently, for n>0 m(n) has n 2’s and these are the only prime substrings in base-7 representation. This is why every substring of m(n) with more than one digit is a product of two integers > 1 (by definition) and can therefore not be prime number.
No term is divisible by 7.

Examples

			a(1) = 2 = 2_7, since 2 is the least number with 1 prime substring in base-7 representation.
a(2) = 16 = 22_7, since 16 is the least number with 2 prime substrings in base-7 representation (2 times 2_7=2).
a(3) = 17 = 23_7, since 17 is the least number with 3 prime substrings in base-7 representation (2_7, 3_7, and 23_7).
a(5) = 121 = 232_7, since 121 is the least number with 5 prime substrings in base-7 representation (2 times 2_7, 3_7, 23_7=17, and 32_7=23).
a(6) = 509 = 1325_7, since 509 is the least number with 6 prime substrings in base-7 representation (2_7, 3_7, 5_7, 25_7=19, 32_7=23, and 1325_7=509).
		

Crossrefs

Formula

a(n) > 7^floor(sqrt(8*n-7)-1)/2), for n>0.
a(n) <= (7^n - 1)/3, n>0.
a(n+1) <= 7*a(n) + 2.

A227922 Numbers whose digits are prime and which retain this property when multiplied by some 1-digit prime (i.e., one of 2, 3, 5 or 7).

Original entry on oeis.org

5, 7, 25, 55, 75, 325, 555, 755, 775, 2525, 2575, 3225, 3325, 5325, 5555, 7525, 7555, 7575, 7775, 25775, 32225, 33225, 33325, 53225, 53325, 55555, 75325, 75555, 75775, 77525, 77575, 77775
Offset: 1

Views

Author

M. F. Hasler, Oct 12 2013

Keywords

Comments

Motivated by Gardner's puzzle, which reads: In the following calculation,
| PPP
| x PP
|------
| PPPP
| PPPP
|------
| PPPPP
replace each P by some prime digit, to produce a correct calculation.

Examples

			a(1)=5 is in the sequence because 5x5=25 which has only prime digits.
a(2)=7 is in the sequence because 7x5=35 has only prime digits.
a(3)=25 is in the sequence because 25x3=75 has only prime digits.
		

References

  • Martin Gardner, "The Unexpected Hanging and Other Mathematical Diversions", University of Chicago Press (November 1991), ISBN: 978-0226282565.

Crossrefs

A subsequence of A046034.

Programs

  • PARI
    {(p(x)=Set(isprime(digits(x)))==[1]);for(x=2,1e5,p(x)&&forprime(q=2,9,p(x*q)&&!print1(x",")&&break))}
    
  • PARI
    conv(v)=subst(Pol(apply(k->[2,3,5,7][k+1],v)),'x,10)
    isA046034(n)=!#setminus(Set(digits(n)),[2,3,5,7])
    for(d=1,7,forstep(k=4^d+2,2*4^d-1,[1,3],n=conv(digits(k,4)[2..d+1]); if(vecmax(apply(isA046034, [2,3,5,7]*n)), print1(n", ")))) \\ Charles R Greathouse IV, Jan 05 2014

A300289 a(n) is the smallest prime p such that the product of p and prime(n) contains only prime digits, or -1 if no such prime p exists.

Original entry on oeis.org

11, 11, 5, 5, 2, 29, 19, 3, 11, 13, 17, 61, 13, 59, 5, 61, 43, 37, 5, 5, 101, 3, 31, 307, 59, 23, 541, 5, 3, 29, 179, 17, 1721, 257, 17, 5, 239, 229, 199, 149, 3, 13, 3, 1439, 281, 127, 107, 101, 9791, 163, 31, 107, 3, 3, 139, 199, 83, 13, 929, 83, 19, 11, 11, 107, 71, 181, 167, 661, 1031
Offset: 1

Views

Author

Ivan N. Ianakiev, Mar 02 2018

Keywords

Comments

If a(i) = prime(j), then a(j) <= prime(i). - Rémy Sigrist, Mar 03 2018. [Note that this does not imply that a prime p always exists! In fact if r and s are large primes, r*s will surely contain a nonprime digit, although this kind of question is beyond the reach of present-day mathematics. - N. J. A. Sloane, Mar 03 2018]

Examples

			11 is the smallest prime such that 11*prime(1)=22 consists of only prime digits. Therefore a(1) = 11.
		

Crossrefs

Cf. A046034.

Programs

  • Mathematica
    p[n_] := Module[{k = 1},  While[Union[PrimeQ /@ IntegerDigits[n*Prime[k]]] != {True}, k++]; Prime[k]]; p /@ Prime[Range[100]]
    spp[p_]:=Module[{k=2},While[AnyTrue[IntegerDigits[p*k],!PrimeQ[#]&],k=NextPrime[k]];k]; Table[spp[p],{p,Prime[Range[70]]}] (* Harvey P. Dale, Jun 20 2023 *)
  • PARI
    a(n) = {forprime(p=2, , if (#select(x->(! isprime(x)), digits(p*prime(n))) == 0, return (p)););} \\ Michel Marcus, Mar 02 2018

Extensions

Escape clause added to definition by N. J. A. Sloane, Mar 03 2018

A062087 Squarefree numbers with all prime digits.

Original entry on oeis.org

2, 3, 5, 7, 22, 23, 33, 35, 37, 53, 55, 57, 73, 77, 222, 223, 227, 233, 235, 237, 253, 255, 257, 273, 277, 322, 323, 327, 335, 337, 353, 355, 357, 373, 377, 523, 527, 533, 535, 537, 553, 555, 557, 573, 577, 723, 727, 733, 737, 753, 755, 757, 773, 777, 2222, 2227
Offset: 1

Views

Author

Amarnath Murthy, Jun 16 2001

Keywords

Comments

Heuristically, there are about 4^n * 275/(48*Pi^2) n-digit terms of this sequence. - Charles R Greathouse IV, Oct 18 2011

Examples

			a(6) = 23, 2 and 3 are both primes.
		

Crossrefs

Intersection of A046034 and A005117.

Programs

  • Mathematica
    Select[Range[3000], Abs[MoebiusMu[#]] == 1 && Union[PrimeQ[IntegerDigits[#]]] == {True} &] (* Alonso del Arte, Oct 18 2011 *)

Extensions

Corrected and extended by Larry Reeves (larryr(AT)acm.org), Jun 18 2001
Offset corrected by Arkadiusz Wesolowski, Oct 18 2011

A084983 Palindromes made of only prime digits.

Original entry on oeis.org

2, 3, 5, 7, 22, 33, 55, 77, 222, 232, 252, 272, 323, 333, 353, 373, 525, 535, 555, 575, 727, 737, 757, 777, 2222, 2332, 2552, 2772, 3223, 3333, 3553, 3773, 5225, 5335, 5555, 5775, 7227, 7337, 7557, 7777, 22222, 22322, 22522, 22722, 23232, 23332, 23532, 23732, 25252, 25352
Offset: 1

Views

Author

Meenakshi Srikanth (menakan_s(AT)yahoo.com), Jun 27 2003

Keywords

Crossrefs

Intersection of A002113 and A046034.

Programs

  • Mathematica
    With[{p = Prime@ Range@ PrimePi@ 9}, Array[If[OddQ@ #1, Map[FromDigits@ Join[#, Reverse@ Most@ #] &, #2], Map[FromDigits@ Join[#, Reverse@ #] &, #2]] & @@ {#, Tuples[p, {Ceiling[#/2]}]} &, 5]] // Flatten (* Michael De Vlieger, Jan 28 2020 *)
  • PARI
    a(n)={my(k=4); while(n>2*k, n-=2*k; k*=4); my(v=[d*2+1+(!d)|d<-digits(k+n-1,4)]); fromdigits(concat(v[2..#v-(n<=k)], Vecrev(v[2..#v])))} \\ Andrew Howroyd, Jan 27 2020

Extensions

Terms a(33) and beyond from Andrew Howroyd, Jan 27 2020
Previous Showing 61-70 of 103 results. Next