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.

A126018 Smallest prime of the form 1 + Sum{j=1..n} k^(2*j-1).

This page as a plain text file.
%I A126018 #11 Jan 08 2025 11:13:13
%S A126018 2,3,43,5,683,7,10101010101011,43691,174763,11,2796203,13,
%T A126018 1074532291189456211731158116986854092943409,
%U A126018 10518179715343122711873674826619717982095485405484801996888751,715827883,17,47765234780450752737667634787440955821061405946096137816061
%N A126018 Smallest prime of the form 1 + Sum{j=1..n} k^(2*j-1).
%C A126018 Primes arising in A124151.
%C A126018 If n=(prime number-1) then a(n) = prime(n). - _Artur Jasinski_, Dec 23 2006
%e A126018 Consider n = 8. 1 + Sum{j=1...8} k^(2*j-1) evaluates to 9 for k = 1 and to 43691 for k = 2. 9 is composite but 43691 is prime, hence a(8) = 1+2+2^3+2^5+2^7+2^9+2^11+2^13+2^15 = 43691.
%t A126018 Table[k=0; Until[PrimeQ[p=1+Sum[k^(2j-1),{j,n}]], k++]; p, {n, 17}] (* _James C. McMahon_, Dec 23 2024 *)
%o A126018 (PARI) {for(n=1,14,k=1;while(!isprime(s=1+sum(j=1,n,k^(2*j-1))),k++);print1(s,","))} \\ _Klaus Brockhaus_, Dec 16 2006
%Y A126018 Cf. A006093, A124151, A124205-A124209, A124164, A124178, A124181, A124185-A124187, A124189, A124200, A124154, A124163.
%K A126018 nonn
%O A126018 1,1
%A A126018 _Artur Jasinski_, Dec 14 2006
%E A126018 Edited and extended by _Klaus Brockhaus_, Dec 16 2006
%E A126018 a(15)-a(17) from _James C. McMahon_, Dec 23 2024