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.

A270360 Least positive integer k such that 5^n-1 and k^n-1 are relatively prime.

This page as a plain text file.
%I A270360 #24 Jul 29 2024 12:56:17
%S A270360 2,6,2,6,2,42,2,6,2,132,2,546,2,12,6,102,2,798,2,198,2,138,2,546,2,6,
%T A270360 2,348,2,85932,2,102,2,12,22,383838,2,12,6,2706,2,1806,2,414,22,282,2,
%U A270360 9282,2,264,2,318,2,1596,2,348,2,354,2,34072038
%N A270360 Least positive integer k such that 5^n-1 and k^n-1 are relatively prime.
%C A270360 Note that (5^n-1)^n-1 is always relatively prime to 5^n-1.
%C A270360 Based on conjecture given in A270390, a(n) = 2 infinitely often.
%C A270360 Are all terms even? - _Harvey P. Dale_, Jul 29 2024
%e A270360 Since 5^2-1 = 24 and 6^2-1 = 35 are relatively prime while 2^2-1, 3^2-1, 4^2-1, and 5^2-1 are not relatively prime to 24, a(5) = 3.
%t A270360 lpi[n_]:=Module[{k=1,c=5^n-1},While[!CoprimeQ[c,k^n-1],k++];k]; Array[lpi,60] (* _Harvey P. Dale_, Jul 29 2024 *)
%o A270360 (Sage)
%o A270360 def min_k(n):
%o A270360     g, k=2, 0
%o A270360     while g!=1:
%o A270360         k=k+1
%o A270360         g=gcd(5^n-1, k^n-1)
%o A270360     return k
%o A270360 print([min_k(n) for n in [1..60]])
%o A270360 (PARI) a(n) = {k=1; while( gcd(5^n-1, k^n-1)!=1, k++); k; }
%Y A270360 Cf. A260119, A268081.
%K A270360 nonn
%O A270360 1,1
%A A270360 _Tom Edgar_, Mar 16 2016
%E A270360 a(60) from _Harvey P. Dale_, Jul 29 2024