Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #38 Apr 23 2020 12:11:58
%S 1,1,4,29,1,3,4,43,3,1,5,37,2,5,9,19,1,267,22,23,4,3,43,57,2,1,46,19,
%T 20,5,4,23,440,3,5,162,1,7,20,499,2,74,4,128,29,9,927,215,156,1,96,91,
%U 7,1058,73,162,3,763,5
%N Least integer k > 0 such that k*n - prime(k) is a square.
%C Conjecture: a(n) exists for any n > 1.
%C Note that k*n - prime(k) < 0 if k > e^(n + 1).
%H Zhi-Wei Sun, <a href="/A247278/b247278.txt">Table of n, a(n) for n = 2..10000</a>
%H Zhi-Wei Sun, <a href="http://arxiv.org/abs/1409.5685">A new theorem on the prime-counting function</a>, arXiv:1409.5685, 2014.
%H Zhi-Wei Sun, <a href="http://dx.doi.org/doi:10.1007/s11139-015-9702-z">A new theorem on the prime-counting function</a>, Ramanujan J. 42 (2017), no.1, 59-67. (Cf. Conjecture 4.1.)
%F a(A059100(n)) = 1. - _Michel Marcus_, Sep 28 2014
%e a(5) = 29 since 29 * 5 - prime(29) = 145 - 109 = 6^2.
%t SQ[n_] := IntegerQ[Sqrt[n]]
%t Do[k = 1; Label[aa]; If[SQ[k * n - Prime[k]], Print[n, " ", k]; Goto[bb]]; k = k + 1; Goto[aa]; Label[bb]; Continue,{n, 2, 60}]
%Y Cf. A000040, A000290, A247893, A247895.
%K nonn
%O 2,3
%A _Zhi-Wei Sun_, Sep 27 2014