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 A273339 #28 Aug 15 2025 17:59:04 %S A273339 4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,6,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,6,4,4, %T A273339 4,4,4,4,4,4,4,4,4,4,4,4,4,6,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,6,4,4,4,4, %U A273339 4,4,4,4,4,4,4,4,4,4,4,6,4,4,4,4,4,4,4 %N A273339 Smallest composite c such that n^(c-1) != 1 (mod c^2), i.e., smallest composite c that is not a "Wieferich pseudoprime" to base n. %C A273339 Smallest composite c such that n does not occur in row c of the array in A244752. - _Felix Fröhlich_, Jan 07 2017 %C A273339 Conjecture: periodic with period = 16. - _Harvey P. Dale_, May 12 2025 %C A273339 For any set S of composite numbers, if n is a composite == 1 (mod lcm(S)^2) then n^(c-1) == 1 (mod c^2) for all c in S, so a(n) is not in S. Thus the sequence has infinitely many distinct members, and in particular the conjecture is false. - _Robert Israel_, Aug 15 2025 %H A273339 Felix Fröhlich, <a href="/A273339/b273339.txt">Table of n, a(n) for n = 2..10000</a> %p A273339 f:= proc(n) local c; %p A273339 for c from 4 do %p A273339 if not isprime(c) and n &^(c-1) mod (c^2) <> 1 then return c fi %p A273339 od %p A273339 end proc: %p A273339 map(f, [$2..100]); # _Robert Israel_, Aug 15 2025 %t A273339 A273339[n_] := NestWhile[#+1 &, 4, PrimeQ[#] || PowerMod[n, #-1, #^2] == 1 &]; %t A273339 Array[A273339, 100, 2] (* _Paolo Xausa_, Aug 15 2025 *) %o A273339 (PARI) a(n) = forcomposite(c=1, , if(Mod(n, c^2)^(c-1)!=1, return(c))) %Y A273339 Cf. A240719, A244752, A256517, A267288, A270776. %K A273339 nonn %O A273339 2,1 %A A273339 _Felix Fröhlich_, May 20 2016