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.
%I A378898 #24 Dec 12 2024 09:28:08 %S A378898 1,1,5,1,1,5,1,5,1,3,3,1,7,1,7,3,1,5,1,3,5,1,7,1,1,5,5,5,1,1,13,1,7,1, %T A378898 1,13,3,7,1,3,3,1,5,5,7,3,1,5,25,1,5,5,5,5,3,5,11,5,5,1,3,3,17,7,1,5, %U A378898 13,27,1,1,13,1,27,5,19,9,3,5,1,9,19,1,5,1,1,9,1,15,7,1,3,3,5,5,7 %N A378898 a(n) is the least k > 0 such that (n+k)^2 + n^2 is prime. %H A378898 Robert Israel, <a href="/A378898/b378898.txt">Table of n, a(n) for n = 1..10000</a> %F A378898 a(n) = A089489(n) - n. %e A378898 a(3) = 5 because (3+5)^2 + 3^2 = 73 is prime, and no smaller number works. %p A378898 f:= proc(n) local k; %p A378898 for k from n+1 by 2 do %p A378898 if igcd(k,n) = 1 and isprime(k^2 + n^2) then return k-n fi %p A378898 od %p A378898 end proc; %p A378898 map(f, [$1..100]); %o A378898 (PARI) a(n) = my(k=1); while (!isprime((n+k)^2 + n^2), k++); k; \\ _Michel Marcus_, Dec 11 2024 %Y A378898 Cf. A027861 (a(n) = 1), A089489, A378945, A378946. %K A378898 nonn %O A378898 1,3 %A A378898 _Robert Israel_, Dec 11 2024