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!)
A242931 Largest number k such that k*n/(k+n) is prime or 0 if no such k exists. 2

%I #11 Feb 18 2023 08:09:12

%S 0,0,6,12,0,30,0,56,0,10,0,132,0,182,0,0,0,306,0,380,0,22,0,552,0,26,

%T 0,0,0,870,0,992,0,34,0,0,0,1406,0,0,0,1722,0,1892,0,46,0,2256,0,0,0,

%U 0,0,2862,0,8,0,58,0,3540,0,3782,0,0,0,0,0,4556,0,0,0,5112,0,5402

%N Largest number k such that k*n/(k+n) is prime or 0 if no such k exists.

%C Since the largest k that makes k*n/(k+n) an integer is n*(n-1), the zero terms are definite.

%C Apart from 0's, sequence contains a few duplicates. a(6) = a(870) = 30 is one. - _Antti Karttunen_, Feb 18 2023

%H Antti Karttunen, <a href="/A242931/b242931.txt">Table of n, a(n) for n = 1..10080</a>

%e (6*3)/(6+3) = 2 is prime. Since 6 = 3*(3-1), 6 is the largest number that makes k*n/(k+n) an integer. Thus a(3) = 6.

%o (PARI) a(n)=for(k=n*(1-n),0,s=(-k*n)/(-k+n);if(floor(s)==s,if(ispseudoprime(s),return(-k))))

%o n=1;while(n<100,print1(a(n),", ");n+=1)

%Y Cf. A242834, A002378.

%K nonn

%O 1,3

%A _Derek Orr_, May 27 2014

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 April 24 15:57 EDT 2024. Contains 371961 sequences. (Running on oeis4.)