login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A269253 Smallest prime in the sequence s(k) = n*s(k-1) - s(k-2), with s(0) = 1, s(1) = n + 1 (or -1 if no such prime exists). 15

%I #57 Apr 03 2023 10:36:13

%S 2,3,11,5,29,7,-1,71,89,11,131,13,181,-1,239,17,5167,19,379,419,461,

%T 23,-1,599,251894449,701,20357,29,25171,31,991,36002209323169,

%U 47468744103199,-1,1259,37,2625505273,1481,1559,41,1721,43,150103799,1979,2069,47,-1,2351,287762399

%N Smallest prime in the sequence s(k) = n*s(k-1) - s(k-2), with s(0) = 1, s(1) = n + 1 (or -1 if no such prime exists).

%C For n >= 3, smallest prime of the form (x^y - 1/x^y)/(x - 1/x), where x = (sqrt(n+2) +/- sqrt(n-2))/2 and y is an odd positive integer, or -1 if no such prime exists.

%C When n=7, the sequence {s(k)} is A033890, which is Fibonacci(4i+2), and since x|y <=> F_x|F_y, and 2i+1|4i+2, A033890 is never prime, and so a(7) = -1. What is the proof for the other entries that are -1? Answer: See the Comments in A269254. - _N. J. A. Sloane_, Oct 22 2017

%C For detailed theory, see [Hone]. - _L. Edson Jeffery_, Feb 09 2018

%H Hans Havermann, <a href="/A269253/b269253.txt">Table of n, a(n) for n = 1..300</a>

%H C. K. Caldwell, Top Twenty page, <a href="https://t5k.org/top20/page.php?id=47">Lehmer number</a>

%H Andrew N. W. Hone, et al., <a href="https://arxiv.org/abs/1802.01793">On a family of sequences related to Chebyshev polynomials</a>, arXiv:1802.01793 [math.NT], 2018.

%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Lehmer_number">Lehmer number</a>

%F If n is prime then a(n-1) = n.

%t terms = 172;

%t kmax = 120;

%t a[n_] := Module[{s, k}, s[k_] := s[k] = n s[k-1] - s[k-2]; s[0] = 1; s[1] = n+1; For[k = 1, k <= kmax, k++, If[PrimeQ[s[k]], Return[s[k]]]]];

%t Array[a, terms] /. Null -> -1 (* _Jean-François Alcover_, Aug 30 2018 *)

%o (Magma) lst:=[]; for n in [1..49] do if n gt 2 and IsSquare(n+2) then Append(~lst, -1); else a:=n+1; c:=1; if IsPrime(a) then Append(~lst, a); else repeat b:=n*a-c; c:=a; a:=b; until IsPrime(a); Append(~lst, a); end if; end if; end for; lst;

%Y Cf. A117522, A269251, A269252, A269254.

%Y Cf. A294099, A298675, A298677, A298878, A299045, A299071, A285992, A299107, A299109, A088165, A299100, A299101, A113501.

%K sign

%O 1,1

%A _Arkadiusz Wesolowski_, Jul 09 2016

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 3 22:58 EDT 2024. Contains 372225 sequences. (Running on oeis4.)