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.

A126017 Smallest prime of the form k^n + k^(n-1) - 1.

This page as a plain text file.
%I A126017 #11 Jan 08 2025 11:33:54
%S A126017 2,5,11,23,47,971,191,383,22136835839,1310719,2259801991,6143,
%T A126017 353563778431304822783,91424858111,5425784582791,57395627,21474836479,
%U A126017 1099999999999999999,786431,13508517176729920889,1818426107493966837974532393806148403199,153558654482644991
%N A126017 Smallest prime of the form k^n + k^(n-1) - 1.
%C A126017 Primes arising in A125973.
%e A126017 Consider n = 10. k^n + k^(n-1) - 1 evaluates to 1, 1535, 78731, 1310719 for k = 1, ..., 4. Only the last of these numbers, 4^10+4^9-1 = 1310719, is prime, hence a(10) = 1310719.
%t A126017 Table[k=0;Until[PrimeQ[p=k^n+k^(n-1)-1],k++];p,{n,22}] (* _James C. McMahon_, Dec 23 2024 *)
%o A126017 (PARI) {for(n=1,20,k=1;while(!isprime(a=k^n+k^(n-1)-1),k++);print1(a,","))} \\ _Klaus Brockhaus_, Dec 17 2006
%Y A126017 Cf. A000040, A045546, A125881-A125885, A125965-A125973.
%K A126017 nonn
%O A126017 1,1
%A A126017 _Artur Jasinski_, Dec 14 2006
%E A126017 Edited and extended by _Klaus Brockhaus_, Dec 17 2006
%E A126017 a(21)-a(22) from _James C. McMahon_, Dec 23 2024