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 11-18 of 18 results.

A255401 Numbers n with the property that its k-th smallest divisor, for all 1 <= k <= tau(n), contains exactly k "1" digits in its binary representation.

Original entry on oeis.org

1, 3, 5, 17, 25, 39, 57, 201, 257, 289, 291, 323, 393, 579, 1083, 2307, 7955, 8815, 9399, 12297, 12909, 13737, 36867, 40521, 43797, 50349, 65537, 66049, 66291, 66531, 68457, 80457, 98313, 160329, 196617, 197633, 230691, 299559, 599079, 786441, 922179, 1278537
Offset: 1

Views

Author

Jaroslav Krizek, Feb 22 2015

Keywords

Comments

For n>1; a(n) is a multiple of a Fermat prime (A019434). Subsequence of A071593.
For all divisors d_k of a(n) we have A000120(d_k) = k.
Subsequence of known numbers with k divisors:
for k = 2: 3, 5, 17, 257, 65537, ... - Fermat primes (A019434);
for k = 3: 25, 289, 66049, 4295098369, ... - some square of Fermat prime;
for k = 4: 39, 57, 201, 291, 323, 393, 579, 2307, 12297, 36867, 98313, 196617, 197633, 786441, 2359299, 805306377, 3221225481, 4295229443, 9663676419, 618475290627, 19791209299971, ... - some products of two distinct primes p*q, where p is a Fermat prime (A019434) and q is a term of sequence A081091, see (Magma) - Set(Sort([n*m: n in [A019434(n)], m in [A081091(m)] | n lt m and &+Intseq(n, 2) eq 2 and &+Intseq(m, 2) eq 3 and &+Intseq(n*m, 2) eq 4]));
for k = 6: 1083 - the only number with this property < 10^7;
for k = 8: 7955, 8815, 9399, 12909, 13737, 40521, 43797, 50349, 66291, 66531, 68457, 80457, 160329, 230691, 299559, 599079, 922179, 1278537, 2396199, 2556489, ...; see (Magma) - Set(Sort([n: n in [1..1000000] | [&+Intseq(d, 2): d in Divisors(n)] eq [1,2,3,4,5,6,7,8]])).
Conjectures: 1) Sequence is infinite. 2) 8 is the maximal value of k for numbers with this property.
Numbers 805306377, 3221225481, 4295098369, 4295229443, 9663676419, 618475290627 and 19791209299971 are also terms of this sequence.
Sequence of the smallest numbers n with k divisors having these properties for k >= 1 or 0 if no solution exists or has been found: 1, 3, 25, 39, 0, 1083, 0, 7955, ...; a(5) = a(7) = 0 if there are only 5 Fermat primes. Conjecture: a(k) = 0 for k > 8.

Examples

			The divisors of 1083, expressed in base 2 and listed in ascending order as 1, 11, 10011, 111001, 101101001, 10000111011, contain 1, 2, 3, 4, 5 and 6 "1" digits, respectively.
		

Crossrefs

Programs

  • Magma
    Set(Sort([n: n in [1..1000000] | [&+Intseq(d, 2): d in Divisors(n)] eq [1..NumberOfDivisors(n)]]))
    
  • Mathematica
    Select[Range[10^6], Total @ IntegerDigits[#, 2] & /@ (d = Divisors[#]) == Range @ Length[d] &] (* Amiram Eldar, Dec 29 2019 *)
  • PARI
    isok(n) = {my(d = divisors(n)); for (i=1, #d, if (hammingweight(d[i]) != i, return (0));); return (1);} \\ Michel Marcus, Feb 22 2015

A070739 Primes of form 2^x + 2^y + 1.

Original entry on oeis.org

3, 5, 7, 11, 13, 17, 19, 37, 41, 67, 73, 97, 131, 137, 193, 257, 521, 577, 641, 769, 1033, 1153, 2053, 2081, 2113, 4099, 4129, 8209, 12289, 16417, 18433, 32771, 32801, 32833, 40961, 65537, 65539, 133121, 147457, 163841, 262147, 262153, 262657
Offset: 1

Views

Author

Benoit Cloitre, May 14 2002

Keywords

Comments

This sequence is the union of A081091 and the Fermat primes, A000215. - T. D. Noe, Jun 22 2007
Odd primes with Hamming weight (A000120) at most three. - Jeppe Stig Nielsen, Dec 09 2020

Examples

			41 = 2^5 + 2^3 + 1, hence 41 is in the sequence.
		

Crossrefs

Programs

  • Maple
    k := 0:for i from 1 to 140 do for j from i to 140 do if isprime(2^i+2^j+1) then k := k+1:c[k] := 2^i+2^j+1:fi:od:od:sort([3,seq(c[i],i=1..k)]);# gives all terms up to 2^140
  • Mathematica
    f[x_,y_]:=2^x+2^y+1; imax=20; lst={}; Do[p=f[x,y]; If[p<2^imax+3 && PrimeQ[p], AppendTo[lst,p]], {y, 0, imax}, {x, 0, y}]; Union[lst] (* Vladimir Joseph Stephan Orlovsky, Apr 08 2011 *)
    Union[Select[Total/@(2^#&/@Union[Sort[Tuples[Range[0,20],2]]])+1,PrimeQ]] (* Harvey P. Dale, Jun 06 2020 *)
  • PARI
    for(n=1,300,if(sum(i=0,n,sum(j=0,i,if(2^i+2^j+1-prime(n),0,1)))>0,print1(prime(n),",")))

Extensions

More terms from Sascha Kurz, Aug 15 2002

A133830 Least positive number k < n such that the binary trinomial 1 + 2^n + 2^k is prime, or 0 if there is no such k.

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 0, 3, 3, 2, 1, 4, 5, 1, 1, 11, 1, 6, 5, 4, 7, 3, 9, 0, 17, 15, 1, 15, 1, 6, 0, 4, 9, 14, 13, 3, 11, 25, 0, 6, 7, 0, 17, 7, 15, 2, 0, 30, 23, 6, 21, 2, 33, 1, 0, 3, 0, 14, 5, 6, 21, 19, 0, 30, 3, 1, 5, 34, 19, 26, 17, 19, 17, 5, 33, 15, 23, 27, 33, 4, 3, 26, 1, 39, 35, 19, 9, 18
Offset: 2

Views

Author

T. D. Noe, Sep 26 2007

Keywords

Comments

Sequence A081504 gives the n such that a(n) = 0. For those n, A133831(n) gives the least k > n for which the binary trinomial is prime.

Crossrefs

Cf. A057732, A059242, A057196, A057200, A081091 (various forms of prime binary trinomials).
Cf. A095056, A133831, A133832 (k > n equivalent).

Programs

  • Mathematica
    Table[s=1+2^n; k=1; While[k
    				

Extensions

Edited by Peter Munn, Sep 30 2024

A133831 Least positive number k != n such that the binary trinomial 1 + 2^n + 2^k is prime, or 0 if there is no such k.

Original entry on oeis.org

2, 1, 1, 1, 2, 1, 1, 9, 3, 3, 2, 1, 4, 5, 1, 1, 11, 1, 6, 5, 4, 7, 3, 9, 27, 17, 15, 1, 15, 1, 6, 458465, 4, 9, 14, 13, 3, 11, 25, 57, 6, 7, 46, 17, 7, 15, 2, 1009, 30, 23, 6, 21, 2, 33, 1, 1265, 3, 69, 14, 5, 6, 21, 19, 2241, 30, 3, 1, 5, 34, 19, 26, 17, 19, 17, 5, 33, 15, 23, 27
Offset: 1

Views

Author

T. D. Noe, Sep 26 2007

Keywords

Comments

Does such k exist (so that a(n) is nonzero) for all n? These binary trinomials can also be written as f*2^n+1, where f=2^m+1 for some m, which is reminiscent of the Sierpinski problem (see A076336). Hence if there are no Sierpinski numbers of the form 2^m+1, then a(n) is nonzero for all n.
The PFGW program was used to find a(32), which produces a 138012-digit probable prime. If a(256) is nonzero, it is greater than 10^6.

Crossrefs

Cf. A057732, A059242, A057196, A057200, A081091 (various forms of prime binary trinomials).
Closely related problems: A040076 (see also A076336), A067760, A133830 (k < n), A133832 (k > n).
Cf. A095056.

Programs

  • Mathematica
    mx=4000; Table[s=1+2^n; k=1; While[k==n || (k
    				

Extensions

Edited by Peter Munn, Sep 29 2024

A133832 Least number k > n such that the binary trinomial 1 + 2^n + 2^k is prime, or 0 if there is no such k.

Original entry on oeis.org

2, 3, 5, 13, 6, 7, 9, 9, 18, 19, 14, 13, 15, 17, 17, 81, 20, 19, 30, 33, 26, 27, 38, 81, 27, 35, 31, 33, 35, 31, 42, 458465, 36, 45, 47, 37, 67, 53, 41, 57, 42, 45, 46, 69, 54, 57, 53, 1009, 100, 119, 55, 73, 83, 67, 57, 1265, 74, 69, 66, 113, 75, 101, 66, 2241, 68, 67, 70
Offset: 1

Views

Author

T. D. Noe, Sep 26 2007

Keywords

Comments

Conjecture: a(n) is nonzero for all n. These binary trinomials can also be written as f*2^n+1, where f=2^m+1 for some m, which is reminiscent of the Sierpinski problem (see A076336). The conjecture is equivalent to no Sierpinski numbers of the form 2^m+1 existing.
The PFGW program was used to find a(32), which produces a 138012-digit probable prime.

Crossrefs

Cf. A057732, A059242, A057196, A057200, A081091 (various forms of prime binary trinomials).
Cf. A095056, A133830 (k < n equivalent), A133831.

Programs

  • Mathematica
    mx=4000; Table[s=1+2^n; k=n+1; While[k
    				

Extensions

Edited by Peter Munn, Sep 29 2024

A197918 Pythagorean primes p such that for all primes q < p, p XOR q is not equal to p - q.

Original entry on oeis.org

2, 5, 17, 41, 73, 97, 137, 193, 257, 521, 577, 641, 1033, 1153, 2081, 2113, 4129, 7681, 8353, 8737, 9281, 10369, 10753, 12289, 16417, 17921, 18433, 21569, 25601, 32801, 32833, 36353, 37889, 38921, 39041, 40961, 50177, 53377, 65537, 131617, 133121, 136193, 139273, 139297, 139393, 147457, 163841
Offset: 1

Views

Author

Brad Clardy, Oct 24 2011

Keywords

Comments

It is conjectured that with the exception of the first three terms (2,5,17) all of the terms are a subset of all primes p such that p XOR 22 = p + 22.
If the inequality in the definition is replaced with equality the result are the Mersenne primes A000668, which is equivalent to for all primes q

This sequence is apparently a subset of A081091 Primes of the form 2^i + 2^j + 1, i>j>0, with the added conditions that j <> 1 or 2, and if j can be written as 2n then i cannot be 2n+1. This removes A123250 Primes of form 2^n + 5 (or 2^n + 2^2 +1) for n>0, primes from A140660 3*4^n + 1 (or 2^(2n+1) + 2^(2n) + 1) for n>0, and A057733 Primes of form 2^n + 3 (2^n + 2^1 + 1) for n>1.

Examples

			5 is a Pythagorean prime (1^2 + 2^2) and a member since ((5 XOR 2) <> (5 - 2)) and ((5 XOR 3) <> (5 - 3)).
13 is a Pythagorean prime (2^2 + 3^2) however it is not a member because 5, a prime less than 13, (13 XOR 5) = (13 - 5).
		

Programs

  • Magma
    XOR := func;
    i:=0; k:=0; pn:=0;
    for n:= 5 to 10000 by 4 do
           if IsPrime(n)  then  pn:=n;  end if;
           if (pn eq n) then k:=0;
               for j in [2 .. n-2] do
                    if IsPrime(j)  then pj:=j;
                         if (XOR(pn,pj) ne pn-pj) then i+:=1;
                             else k+:=1;
                         end if;
                    end if;
               end for;
           end if;
           if ((i ne 0) and (k eq 0))  then pn; end if;
           i:=0; k:=0;
    end for;
    
  • PARI
    forprime(p=2,1e6,if(p%4-3==0,next);forprime(q=2,p-1,if(bitxor(p,q)==p-q, next(2)));print1(p", ")) \\ Charles R Greathouse IV, Jul 31 2012

A128898 Primes of form 2^j + 2^k - 1 or 2^j + 2^k + 1.

Original entry on oeis.org

2, 3, 5, 7, 11, 13, 17, 19, 23, 31, 37, 41, 47, 67, 71, 73, 79, 97, 127, 131, 137, 191, 193, 257, 263, 271, 383, 521, 577, 641, 769, 1031, 1033, 1039, 1087, 1151, 1153, 1279, 2053, 2063, 2081, 2111, 2113, 4099, 4111, 4127, 4129, 4159, 5119, 6143, 8191, 8209
Offset: 1

Author

J. M. Bergot, Apr 21 2007

Keywords

Comments

Union of A000668, A081091 and A239712. - Robert Israel, Jun 13 2018

Examples

			2^2 + 2^5 + 1 = 4 + 32 + 1 = 37 is prime, hence 37 is a term.
2^4 + 2^5 - 1 = 16 + 32 - 1 = 47 is prime, hence 47 is a term.
2^3 + 2^6 + 1 = 8 + 64 + 1 = 73 is prime, hence 73 is a term.
		

Crossrefs

Cf. A000668 (Mersenne primes), A092506 (primes of form 2^n + 1), A070739 (primes of form 2^x+2^y+1), A081091, A239712.

Programs

  • Maple
    sort(convert(select(isprime, {2,seq(seq(seq(2^i+2^j+k,k=[-1,1]),j=1..i),i=1..15)}),list)); # Robert Israel, Jun 13 2018
  • Mathematica
    lst = {}; Do[p = 2^a + 2^b; If[PrimeQ[p - 1], AppendTo[lst, p - 1]]; If[PrimeQ[p + 1], AppendTo[lst, p + 1]], {a, 0, 14}, {b, 0, a}]; Union@ lst (* Robert G. Wilson v *)
  • PARI
    {m=13; v=[]; for(j=0, m, for(k=j, m, if(isprime(p=2^j+2^k-1), v=concat(v, p)); if(isprime(p=2^j+2^k+1), v=concat(v,p)))); w=Vec(listsort(List(v), 1)); w} /* Klaus Brockhaus, Apr 22 2007 */

Extensions

Edited, corrected and extended by Klaus Brockhaus and Robert G. Wilson v, Apr 22 2007

A362979 Square array, read by descending antidiagonals: row n lists the primes whose base-2 representation has exactly n ones, starting from n=3.

Original entry on oeis.org

7, 11, 23, 13, 29, 31, 19, 43, 47, 311
Offset: 3

Author

Clark Kimberling, May 11 2023

Keywords

Examples

			Corner:
  n=3:    7    11    13    19    37   41     67    73    97
  n=4:   23    29    43    53    71   83     89   101   113
  n=5:   31    47    59    61    79   103   107   109   151
  n=6:  311   317   347   349   359   373   461   467   571
The first four primes in row n=3 have these base-2 representations, respectively: 111, 1011, 1101, 10011.
		

Crossrefs

Cf. A019434 (row 2), A061712 (column 1), A081091 (row 3), A095077 (row 4).

Programs

  • Mathematica
    t[n_] := Count[IntegerDigits[Prime[n], 2], 1]  (* A014499 *)
    u = Table[t[n], {n, 1, 200}];
    p[n_] := Flatten[Position[u, n]]
    w = TableForm[Table[Prime[p[n]], {n, 3, 16}]]

Extensions

New offset and edited by Michel Marcus, Jan 19 2024
Previous Showing 11-18 of 18 results.