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 21-24 of 24 results.

A244609 Least prime divisor of 659*2^n-1.

Original entry on oeis.org

2, 3, 5, 3, 13, 3, 5, 3, 73, 3, 5, 3, 7, 3, 5, 3, 13, 3, 5, 3, 977, 3, 5, 3, 7, 3, 5, 3, 13, 3, 5, 3, 31, 3, 5, 3, 7, 3, 5, 3, 13, 3, 5, 3, 73, 3, 5, 3, 7, 3, 5, 3, 13, 3, 5, 3, 13477, 3, 5, 3, 7, 3, 5, 3, 13, 3, 5, 3, 48430237, 3, 5, 3, 7, 3, 5, 3, 13
Offset: 0

Views

Author

Robert Israel, Jul 01 2014

Keywords

Comments

a(n) = 3 if n is odd.
a(n) = 5 if n == 2 (mod 4).
From Bruno Berselli, Jul 02 2014: (Start)
a(n) = 7 if n == 0 (mod 12) for n>0.
a(n) = 13 if n == 4 (mod 12).
a(n) == 3 or 7 (mod 12) for n>1. (End)
A040081(659) = 800516, so 800516 is the first n for which a(n) = 659*2^n-1 (found by David W Linton in 2004). - Jens Kruse Andersen, Jul 02 2014

Examples

			For n=4, 659*2^4-1 = 10543 = 13 * 811 so a(4) = 13.
		

Crossrefs

Programs

  • Magma
    [PrimeDivisors(659*2^n-1)[1]: n in [0..100]]; // Bruno Berselli, Jul 02 2014
  • Maple
    f:= proc(m) local F;
       F:= map(t -> t[1],ifactors(659*2^m-1,easy)[2]);
       F:= select(type,F,integer);
       if nops(F) = 0 then
         F:= map(t -> t[1],ifactors(659*2^m-1)[2]);
         min(F);
       else min(F)
       fi
    end proc;
    seq(f(n), n= 0 .. 100);

A253176 Least k>=0 such that both 3n*2^k+1 and 3n*2^k-1 are primes, or -1 if no such k exists.

Original entry on oeis.org

1, 0, 1, 0, 1, 0, 1, 3, 2, 0, 6, 1, 3, 0, 2, 2, 1, 1, 2, 0, 14, 5, 1, 0, 1, 2, 5, 5, 2, 1, 4, 1, 1, 0, 2, 0
Offset: 1

Views

Author

Eric Chen, Mar 16 2015

Keywords

Comments

If n*2^k+1 and n*2^k-1 are both primes, then n must be divisible by 3.
a(79) = -1, since 237*2^k+1 or 237*2^k-1 must divisible by 5, 7, 13, 17, or 241. Similarly, a(269) = -1 (cover: {5, 7, 13, 19, 37, 73}), a(1527) = -1 (cover: {5, 7, 13, 17, 241}).
Conjecture: if n < 79, then a(n) >= 0.
a(38) - a(40) = {1, 4, 1}, a(42) - a(50) = {13, 3, 4, 1, 0, 1, 3, 44, 0}, a(52) = 1, a(54) - a(56) = {4, 2, 4}, a(58) - a(60) = {1, 12, 0}, a(n) is currently unknown for n = {37, 41, 51, 53, 57, ...}
a(37), if it exists, is > 160000.

Examples

			a(11) = 6 since 33*2^n+1 and 33*2^n-1 are not both primes for all 0 <= n <= 5, but they are both primes for n = 6.
		

Crossrefs

Programs

  • Mathematica
    Table[k = 0; While[! PrimeQ[3*n*2^k + 1] || ! PrimeQ[3*n*2^k - 1], k++]; k, {n, 60}]
  • PARI
    a(n) = for(k=0, 2^24, if(ispseudoprime(3*n*2^k+1) && ispseudoprime(3*n*2^k-1), return(k)))

Formula

If a(n) > 0, then a(2n) = a(n) - 1.

A343914 Riesel problem in base 3: a(n) is the smallest k >= 0 such that (2*n)*3^k-1 is prime, or -1 if no such k exists.

Original entry on oeis.org

1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 2, 0, 2, 1, 0, 0, 1, 1, 0, 2, 0, 0, 1, 0, 1, 2, 0, 1, 1, 0, 0, 1, 1, 0, 3, 0, 0, 1, 1, 0, 3, 0, 1, 1, 0, 2, 1, 2, 0, 3, 0, 0, 1, 0, 0, 3, 0, 1, 1, 1, 2, 3, 9, 0, 1, 0, 1, 2, 0, 0, 2, 1, 6, 1, 0, 0, 1, 1, 0, 1, 3, 0, 2, 0, 1, 3, 0
Offset: 1

Views

Author

Felix Fröhlich, May 04 2021

Keywords

Comments

31532322469 (A273987(3)/2) is the smallest n such that a(n) = -1.

Examples

			For n = 11: (2*11)*3^k-1 is prime for k = 2, with 2 being the smallest such k, so a(11) = 2.
		

Crossrefs

Cf. A040081 (base 2), A273987.

Programs

  • PARI
    a(n) = for(k=0, oo, if(ispseudoprime((2*n)*3^k-1), return(k)))

A345403 Riesel problem in base 5: a(n) is the smallest k >= 0 such that (2*n)*5^k - 1 is prime, or -1 if no such k exists.

Original entry on oeis.org

4, 0, 0, 0, 3, 0, 0, 1, 0, 0, 1, 0, 4, 1, 0, 0, 163, 1, 0, 1, 0, 0, 1, 0, 2, 5, 0, 2, 7, 0, 0, 5, 5, 0, 1, 0, 0, 1, 1, 0, 1, 0, 2058, 1, 0, 26, 5, 1, 0, 1, 0, 0, 3, 0, 0, 3, 0, 32, 17, 1, 2, 1, 3, 0, 3, 0, 8, 21, 0, 0, 1, 1, 4, 1, 0, 0, 1, 4, 0, 7, 1, 0, 1, 0
Offset: 1

Views

Author

Felix Fröhlich, Jun 18 2021

Keywords

Comments

a(346802/2) = a(173401) = -1 (see A273987).

Examples

			For n = 5: 10*5^k - 1 is composite for k = 0, 1, 2 and prime for k = 3. Since 3 is the smallest such k, a(5) = 3.
		

Crossrefs

Cf. A040081 (base 2), A343914 (base 3), A250205 (base 6).
Cf. A273987.

Programs

  • PARI
    a(n) = for(k=0, oo, if(ispseudoprime((2*n)*5^k-1), return(k)))
Previous Showing 21-24 of 24 results.