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.

A127591 Numbers k such that 64k+21 is prime.

Original entry on oeis.org

2, 4, 10, 13, 17, 19, 20, 22, 23, 25, 29, 32, 37, 44, 50, 53, 55, 58, 59, 62, 68, 79, 83, 88, 89, 94, 95, 97, 100, 107, 109, 113, 118, 122, 134, 142, 143, 152, 155, 157, 158, 163, 167, 169, 173, 193, 194, 199, 200
Offset: 1

Views

Author

Artur Jasinski, Jan 19 2007

Keywords

Crossrefs

Programs

  • Mathematica
    a = {}; Do[If[PrimeQ[21 + 64 n], AppendTo[a, n]], {n, 0, 200}]; a
    Select[Range[200],PrimeQ[64#+21]&] (* Harvey P. Dale, Jan 15 2016 *)

A127592 Primes of the form 64k+21.

Original entry on oeis.org

149, 277, 661, 853, 1109, 1237, 1301, 1429, 1493, 1621, 1877, 2069, 2389, 2837, 3221, 3413, 3541, 3733, 3797, 3989, 4373, 5077, 5333, 5653, 5717, 6037, 6101, 6229, 6421, 6869, 6997, 7253, 7573, 7829, 8597, 9109, 9173, 9749, 9941, 10069, 10133, 10453
Offset: 1

Views

Author

Artur Jasinski, Jan 19 2007, Nov 12 2007

Keywords

Comments

All these primes are sums of two squares, also all indices are sums of two squares since we have the identity 64k+21 = 4(4(4k+1)+1)+1.

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(11000) | p mod 64 eq 21 ]; // Vincenzo Librandi, Sep 06 2012
  • Mathematica
    a = {}; Do[If[PrimeQ[21 + 64 n], AppendTo[a, 21 + 64 n]], {n, 0, 200}]; a
    Select[Prime[Range[1700]], MemberQ[{21}, Mod[#, 64]] &] (* Vincenzo Librandi, Sep 06 2012 *)

A127579 Primes of the form 64n+63.

Original entry on oeis.org

127, 191, 383, 1087, 1151, 1279, 1471, 1663, 2111, 2239, 2687, 2879, 3391, 3583, 3967, 4159, 4799, 5119, 5503, 6079, 6143, 6271, 6719, 6911, 7039, 7103, 7487, 8191, 8447, 8831, 9151, 9343, 9791, 10111, 10303, 10559, 10687, 11071, 11519, 11839
Offset: 1

Views

Author

Artur Jasinski, Jan 19 2007

Keywords

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(12000) | p mod 64 eq 63]; // Vincenzo Librandi, Aug 25 2012
    
  • Mathematica
    a = {}; Do[If[PrimeQ[64n + 63], AppendTo[a, 64n + 63]], {n, 1, 200}]; a
    Select[Prime[Range[4000]], MemberQ[{63}, Mod[#, 64]] &] (* Vincenzo Librandi, Aug 25 2012 *)
    Select[Range[63,12000,64],PrimeQ] (* Harvey P. Dale, Mar 01 2015 *)
  • PARI
    forprime(p=2,1e6,if(bitand(p,63)==63,print1(p", "))) \\ Charles R Greathouse IV, May 15 2013

A127593 Primes of the form 256 k + 85.

Original entry on oeis.org

853, 1109, 1621, 1877, 2389, 3413, 5717, 6229, 6997, 7253, 10069, 10837, 11093, 12373, 13397, 16981, 17749, 18517, 18773, 19541, 21589, 22613, 23893, 24917, 27733, 29269, 30293, 31573, 32341, 37717, 39509, 40277, 41813, 43093, 46933
Offset: 1

Views

Author

Artur Jasinski, Jan 19 2007

Keywords

Crossrefs

Programs

  • Mathematica
    a = {}; Do[If[PrimeQ[85 + 256 n], AppendTo[a, 85 + 256 n]], {n, 0, 200}]; a
    Select[256*Range[200]+85,PrimeQ] (* Harvey P. Dale, Oct 09 2020 *)

A127594 Numbers k such that 256 k + 85 is prime.

Original entry on oeis.org

3, 4, 6, 7, 9, 13, 22, 24, 27, 28, 39, 42, 43, 48, 52, 66, 69, 72, 73, 76, 84, 88, 93, 97, 108, 114, 118, 123, 126, 147, 154, 157, 163, 168, 183, 184, 186, 196, 198
Offset: 1

Views

Author

Artur Jasinski, Jan 19 2007

Keywords

Crossrefs

Programs

  • Mathematica
    a = {}; Do[If[PrimeQ[85 + 256 n], AppendTo[a, n]], {n, 0, 200}]; a

A127597 Least number k such that k 4^n + (4^n-1)/3 is prime.

Original entry on oeis.org

2, 1, 0, 2, 3, 2, 4, 4, 3, 10, 3, 3, 2, 7, 2, 25, 6, 17, 4, 13, 3, 20, 36, 20, 11, 27, 66, 23, 39, 24, 19, 13, 3, 10, 6, 122, 71, 58, 24, 13, 3, 2, 41, 10, 6, 32, 58, 17, 4, 79, 26, 55, 36, 48, 31, 28, 9, 2, 76, 24, 32, 28, 63, 20, 37, 9, 2, 7, 39, 10, 91, 47
Offset: 0

Views

Author

Artur Jasinski, Jan 19 2007

Keywords

Crossrefs

Programs

  • Mathematica
    a = {}; Do[k = 0; While[ !PrimeQ[k 4^n + (4^n - 1)/3], k++ ]; AppendTo[a, k], {n, 0, 50}]; a (*Artur Jasinski*)
    lnk[n_]:=Module[{k=0,n4=4^n},While[!PrimeQ[k*n4+(n4-1)/3],k++];k]; Array[ lnk,60,0] (* Harvey P. Dale, May 28 2018 *)
  • Python
    from sympy import isprime
    def a(n):
        k, fourn = 0, 4**n
        while not isprime(k*fourn + (fourn-1)//3): k += 1
        return k
    print([a(n) for n in range(72)]) # Michael S. Branicky, May 18 2022

Extensions

Offset corrected and a(51) and beyond from Michael S. Branicky, May 18 2022

A127598 Least primes of the form k 4^n + (4^n-1)/3.

Original entry on oeis.org

2, 5, 5, 149, 853, 2389, 17749, 70997, 218453, 2708821, 3495253, 13981013, 39146837, 492131669, 626349397, 27201459541, 27201459541, 297784399189, 297784399189, 3665038759253, 3665038759253, 89426945725781
Offset: 1

Views

Author

Artur Jasinski, Jan 19 2007

Keywords

Crossrefs

Programs

  • Mathematica
    a = {}; Do[k = 0; While[ !PrimeQ[k 4^n + (4^n - 1)/3], k++ ]; AppendTo[a, k 4^n + (4^n - 1)/3], {n, 0, 50}]; a (*Artur Jasinski*)

A306431 Least number x > 1 such that n*x divides 1 + Sum_{k=1..x-1} k^(x-1).

Original entry on oeis.org

2, 3, 13, 7, 19, 31, 41, 31, 13, 19, 43, 31, 23, 83, 139, 31, 61, 67, 113, 79, 251, 43, 19, 31, 199, 23, 13, 167, 53, 139, 83, 127, 157, 67, 293, 431, 443, 151, 103, 79, 61, 251, 113, 47, 337, 19, 179, 31, 41, 199, 67, 23, 19, 499, 181, 367, 607, 139, 257, 359
Offset: 1

Views

Author

Paolo P. Lava, Apr 05 2019

Keywords

Comments

If n = 1, all the solutions of x | 1 + Sum_{k=1..x-1} k^(x-1) should be prime numbers, according to Giuga's conjecture.
If n*x | 1 + Sum_{k=1..x-1} k^(x-1), then certainly x does, so Giuga's conjecture would say x must be prime. Similarly if x^n divides it, so does x, so again Giuga would say x is prime. - Robert Israel, Apr 26 2019
E.g., the first solution for x^2 | 1 + Sum_{k=1..x-1} k^(x-1) is x = 1277, that is prime.

Examples

			a(4) = 7 because (1 + 1^6 + 2^6 + 3^6 + 4^6 + 5^6 + 6^6) / (4*7) = 67172 / 28 = 2399 and it is the least prime to have this property.
		

Crossrefs

Cf. A191677. All the solutions for n = m: A000040 (m=1), A002145 (m=2), A007522 (m=4), A127576 (m=8), A141887 (m=10), A127578 (m=16), A142198 (m=20), A127579 (m=32), A095995 (m=50).

Programs

  • Maple
    P:=proc(j) local k,n; for n from 2 to 10^6 do
    if frac((add(k^(n-1),k=1..n-1)+1)/(j*n))=0
    then RETURN(n); break; fi; od; end: seq(P(i),i=1..60);
  • Mathematica
    a[n_] := For[x = 2, True, x++, If[Divisible[1+Sum[k^(x-1), {k, x-1}], n x], Return[x]]];
    Array[a, 60] (* Jean-François Alcover, Oct 16 2020 *)
  • PARI
    a(n) = my(x=2); while (((1 + sum(k=1, x-1, k^(x-1))) % (n*x)), x++); x; \\ Michel Marcus, Apr 27 2019

Formula

Least solution of n*x | 1 + Sum_{k=1..x-1} k^(x-1), for n = 1, 2, 3, ...
Previous Showing 11-18 of 18 results.