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 A254352 #25 Apr 29 2019 20:49:00 %S A254352 385,21,93,235,2899,903,1771,3619,651,11935,2667,48895,11811,27559, %T A254352 415555,848995,172011,3153535,761763,1777447,2752491,7281799,11010027, %U A254352 28442407,48758691,113770279,199753347,466091143,677207307,2064117919,3220807683,7515217927 %N A254352 a(n) is the least composite x such that sigma(x) divides (x-1)^n but not (x-1)^(n-1), for n >= 2. %e A254352 sigma(385) = 576; (385 - 1)^2 = 21743271936 and 21743271936 / 576 = 37748736. %e A254352 sigma(21) = 32; (21 - 1)^3 = 8000 and 8000 / 32 = 250. %e A254352 sigma(93) = 128; (93 - 1)^4 = 71639296 and 71639296 / 128 = 559682. %p A254352 with(numtheory):P:=proc(q) local a,j,k,n; for k from 2 to q do %p A254352 for n from 1 to q do if not isprime(n) then %p A254352 if type((n-1)^k/sigma(n),integer) then %p A254352 if not type((n-1)^(k-1)/sigma(n),integer) then lprint(k,n); %p A254352 break; fi; fi; fi; od; od;end: P(10^9); %t A254352 a[n_] := Module[{k=4, s=7}, While[PrimeQ[k] || !(PowerMod[k-1, n, s] == 0 && PowerMod[k-1, n-1, s] > 0), k++; s=DivisorSigma[1, k]]; k]; Array[a, 11, 2] (* _Amiram Eldar_, Apr 08 2019 *) %o A254352 (PARI) a(n) = {x = 4; sx = sigma(x); while(! (((x-1)^(n-1) % sx) && !((x-1)^n % sx)), x++; while (isprime(x), x++); sx = sigma(x)); x;} \\ _Michel Marcus_, Jan 30 2015 %o A254352 (PARI) isok(x, n) = my(sx=sigma(x)); (((x-1)^(n-1) % sx) && !((x-1)^n % sx)); %o A254352 a(n) = forcomposite(x=4, , if (isok(x, n), return(x))); \\ _Michel Marcus_, Apr 08 2019 %Y A254352 Cf. A000203, A234936, A254409. %K A254352 nonn %O A254352 2,1 %A A254352 _Paolo P. Lava_, Jan 30 2015 %E A254352 a(22)-a(33) from _Amiram Eldar_, Apr 08 2019