login
Search: a077723 -id:a077723
     Sort: relevance | references | number | modified | created      Format: long | short | data
Primes which can be expressed as sums of distinct powers of 8.
+10
13
73, 521, 577, 4673, 32833, 33289, 33353, 36929, 37441, 262153, 262217, 262657, 295433, 299017, 299521, 2097673, 2101249, 2101313, 2134529, 2359369, 2359873, 2363393, 2363401, 2392073, 16777289, 16777729, 16810049, 16810561, 16814089
OFFSET
1,1
COMMENTS
Primes whose base 8 representations contain only 0's and 1's.
Intersection of A000040 and A033045. - Michel Marcus, Sep 14 2013
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
PROG
(PARI) isok(n) = {digs = digits(n, 8); for (i = 1, #digs, if (digs[i] > 1, return (0)); ); return (1); }
lista(nn) = {forprime (p=1, nn, if (isok(p), print1(p, ", "); ); ); } \\ Michel Marcus, Sep 14 2013
(PARI) forstep(n=7, 999, 2, t=fromdigits(binary(n), 8); if(isprime(t), print1(t", "))) \\ Charles R Greathouse IV, Jun 08 2015
KEYWORD
nonn
AUTHOR
Amarnath Murthy, Nov 19 2002
EXTENSIONS
More terms from Francois Jooste (phukraut(AT)hotmail.com), Dec 23 2002
STATUS
approved
Primes which can be expressed as sum of distinct powers of 7.
+10
10
7, 2801, 17207, 19559, 120401, 134513, 134807, 137201, 840743, 842759, 842801, 941249, 943601, 958007, 958049, 958343, 960793, 5782001, 5784409, 5899307, 5899601, 5899657, 5901659, 6591089, 6607903, 6706393, 6708787, 6722801, 6722857, 6723193
OFFSET
1,1
COMMENTS
Primes whose base 7 representation contains only zeros and 1's.
LINKS
MAPLE
pos := 0:for i from 1 to 4000 do b := convert(i, base, 2); s := sum(b[j]*7^(j-1), j=1..nops(b)): if(isprime(s)) then pos := pos+1:a[pos] := s:fi: od:seq(a[j], j=1..pos);
MATHEMATICA
Select[Prime[Range[10^6]], Max[IntegerDigits[#, 7]]<=1 &] (* Vincenzo Librandi, Sep 07 2018 *)
KEYWORD
nonn
AUTHOR
Amarnath Murthy, Nov 19 2002
EXTENSIONS
More terms from Sascha Kurz, Jan 03 2003
STATUS
approved
Primes whose base-2 representation also is the base-9 representation of a prime.
+10
6
11, 13, 19, 41, 79, 109, 137, 151, 167, 191, 193, 199, 227, 239, 271, 307, 313, 421, 431, 433, 457, 487, 491, 521, 563, 613, 617, 659, 677, 709, 727, 757, 929, 947, 1009, 1033, 1051, 1249, 1483, 1693, 1697, 1709, 1721, 1831, 1951, 1979, 1987, 1993
OFFSET
1,1
COMMENTS
This sequence is part of a two-dimensional array of sequences, given in the LINK, based on this same idea for any two different bases b, c > 1. Sequence A235265 and A235266 are the most elementary ones in this list. Sequences A089971, A089981 and A090707 through A090721, and sequences A065720 - A065727, follow the same idea with one base equal to 10.
For further motivation and cross-references, see sequence A235265 which is the main entry for this whole family of sequences.
A subsequence of A027697, A050150, A062090 and A176620.
EXAMPLE
11 = 1011_2 and 1011_9 = 6571 are both prime, so 11 is a term.
PROG
(PARI) is(p, b=9)=isprime(vector(#d=binary(p), i, b^(#d-i))*d~)&&isprime(p)
CROSSREFS
Cf. A235466A077723, A235266, A152079, A235475 - A235478, A065720A036952, A065721 - A065727, A089971A020449, A089981, A090707 - A091924, A235394, A235395, A235461 - A235482. See the LINK for further cross-references.
KEYWORD
nonn,base
AUTHOR
M. F. Hasler, Jan 12 2014
STATUS
approved
a(n) = smallest prime which can be expressed as a sum of distinct powers of n.
+10
3
2, 3, 5, 5, 7, 7, 73, 739, 11, 11, 13, 13, 197, 241, 17, 17, 19, 19, 401, 463, 23, 23, 577, 10171901, 677, 757, 29, 29, 31, 31, 32801, 1123, 1336337, 44101, 37, 37, 1483, 59359, 41, 41, 43, 43, 85229, 93151, 47, 47, 110641, 13847169701, 2551, 345157903, 53, 53
OFFSET
2,1
COMMENTS
a(n) = smallest prime whose base n representation contains only zeros and 1's.
Values of n at which a(n) reach record values are: 2, 3, 4, 6, 8, 9, 25, 49, 91, 121, 187, 201, 301, 721, 799, 841... Notably, many of them are squares of primes. - Ivan Neretin, Sep 20 2017
LINKS
MATHEMATICA
Table[i = p = 1; While[! PrimeQ[p], p = FromDigits[IntegerDigits[i++, 2], n]]; p, {n, 2, 53}] (* Ivan Neretin, Sep 20 2017 *)
KEYWORD
nonn
AUTHOR
Amarnath Murthy, Nov 19 2002
EXTENSIONS
More terms from Sascha Kurz, Jan 03 2003
STATUS
approved
Primes whose base-9 representation also is the base-2 representation of a prime.
+10
2
739, 811, 6571, 59779, 532261, 591301, 4783699, 4789621, 4842109, 4849399, 5314411, 5314501, 5373469, 5374279, 43047541, 43112341, 43113061, 47888821, 47889559, 47895301, 48361861, 48420271, 48420919, 387421219, 387486109, 388011061, 388011709, 392210029, 392262589, 392734981
OFFSET
1,1
COMMENTS
This sequence is part of the two-dimensional array of sequences based on this same idea for any two different bases b, c > 1. Sequence A235265 and A235266 are the most elementary ones in this list. Sequences A089971, A089981 and A090707 through A090721, and sequences A065720 - A065727, follow the same idea with one base equal to 10.
For further motivation and cross-references, see sequence A235265 which is the main entry for this whole family of sequences.
When the smaller base is b=2 such that only digits 0 and 1 are allowed, these are primes that are the sum of distinct powers of the larger base, here c=9, thus a subsequence of A077723.
EXAMPLE
739 = 1011_9 and 1011_2 = 11 are both prime, so 739 is a term.
MATHEMATICA
fQ[n_, j_, k_] := Block[{id = IntegerDigits[n, j]}, Max[id] < k && PrimeQ[ FromDigits[ id, k]]]; lst = {}; p = 2; While[p < 4*10^9, If[ fQ[p, 9, 2], AppendTo[lst, p]; Print[p]]; p = NextPrime@ p] (* Robert G. Wilson v, Oct 09 2014 *)
pr9Q[n_]:=Module[{idn9=IntegerDigits[n, 9]}, Max[idn9]<2&&PrimeQ[ FromDigits[ idn9, 2]]]; Select[Prime[Range[21*10^6]], pr9Q] (* Harvey P. Dale, Aug 25 2015 *)
PROG
(PARI) is(p, b=2, c=9)=vecmax(d=digits(p, c))<b&&isprime(vector(#d, i, b^(#d-i))*d~)&&isprime(p)
(PARI) forprime(p=1, 1e3, is(p, 9, 2)&&print1(vector(#d=digits(p, 2), i, 9^(#d-i))*d~, ", ")) \\ To produce the terms, this is much more efficient than to select them using straightforwardly is(.)=is(., 2, 9)
CROSSREFS
Cf. A065720A036952, A065721 - A065727, A235394, A235395, A089971A020449, A089981, A090707 - A091924, A235461 - A235482. See the LINK for further cross-references.
KEYWORD
nonn,base
AUTHOR
M. F. Hasler, Jan 11 2014
STATUS
approved

Search completed in 0.005 seconds