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 A347946 #34 Oct 01 2021 21:58:51 %S A347946 0,0,1,2,4,24,48,0,4032,17280,5400,0,518400,415134720,0,0,1797120, %T A347946 6467044147200,39086530560,0,0,1738201006080000,10247897088,0, %U A347946 9632530575360000,706822057112371200000,569299069913333760000,0,54538738974720000,0 %N A347946 Products of nonprimitive roots of n, or 0 if n = 2 or has no primitive roots. %C A347946 If n is a prime p, a(n) == -1 (mod p) for n > 3; if n is a composite c, a(n) == 0 (mod c) for n > 4. %e A347946 a(11) = 5400 because the primitive roots of 11 are {2,6,7,8} and therefore the nonprimitive roots of 11 are {1,3,4,5,9,10} and 1*3*4*5*9*10 = 5400. %t A347946 a[n_] := If[n == 2 || (p = PrimitiveRootList[n]) == {}, 0, (n - 1)!/Times @@ p]; Array[a, 30] (* _Amiram Eldar_, Sep 26 2021 *) %Y A347946 Cf. A123475, A219027, A219028. %K A347946 nonn %O A347946 1,4 %A A347946 _Davide Rotondo_, Sep 26 2021