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 A227334 #47 Dec 06 2024 10:24:42 %S A227334 1,2,8,4,4,8,48,4,24,4,120,8,12,48,8,8,16,24,360,4,48,120,528,8,20,12, %T A227334 72,48,28,8,960,16,120,16,48,24,36,360,24,4,40,48,1848,120,24,528, %U A227334 2208,8,336,20,16,12,52,72,120,48,360,28,3480,8,60,960,48,32 %N A227334 Exponent of the group of the Gaussian integers in a reduced system modulo n. %C A227334 a(n) is the exponent of the multiplicative group of Gaussian integers modulo n, i.e., (Z[i]/nZ[i])* = {a + b*i: a, b in Z/nZ and gcd(a^2 + b^2, n) = 1}. The number of elements in (Z[i]/nZ[i])* is A079458(n). %C A227334 For n > 2, a(n) is divisible by 4. - _Jianing Song_, Aug 29 2018 %C A227334 From _Jianing Song_, Sep 23 2018: (Start) %C A227334 Equivalent of psi (A002322) in the ring of Gaussian integers. %C A227334 a(n) is the smallest positive e such that for any Gaussian integer z coprime to n we have z^e == 1 (mod n). %C A227334 By definition, A079458(n)/a(n) is always an integer, and is 1 iff (Z[i]/nZ[i])* is cyclic, that is, rank((Z[i]/nZ[i])*) = A316506(n) = 0 or 1, and n has a primitive root in (Z[i]/nZ[i])*. A079458(n)/a(n) = 1 iff n = 1, 2 or a prime congruent to 3 modulo 4. (End) %H A227334 Jianing Song, <a href="/A227334/b227334.txt">Table of n, a(n) for n = 1..10000</a> %H A227334 Wikipedia, <a href="https://en.wikipedia.org/wiki/Gaussian_integer">Gaussian integer</a> %H A227334 Wikipedia, <a href="https://en.wikipedia.org/wiki/Torsion_group">Torsion group</a> %F A227334 a(2^e) = 2^e if e <= 2 and 2^(e-1) if e >= 3, a(p^e) = (p - 1)*p^(e-1) if p == 1 (mod 4) and (p^2 - 1)*p^(e-1) if p == 3 (mod 4). If gcd(m, n) = 1 then a(mn) = lcm(a(m), a(n)). - _Jianing Song_, Aug 29 2018 [See the group structure of (Z[i]/(pi^e)Z[i])* in A316506, where pi is a prime element in Z[i]. - _Jianing Song_, Oct 03 2022] %e A227334 Let G = (Z[i]/4Z[i])* = {i, 3i, 1, 1 + 2i, 2 + i, 2 + 3i, 3, 3 + 2i}. The possibilities for the exponent of G are 8, 4, 2 and 1. G^4 = {x^4 mod 4 : x belongs to G} = {1} and i^2 !== 1 (mod 4). Therefore, the exponent of G is greater than 2, accordingly the exponent of G is 4 and a(4) = 4. %t A227334 fa = FactorInteger;lamas[1] = 1;lamas[p_, s_]:= Which[Mod[p, 4]==3,p^(s-1)(p^2 - 1), Mod[p, 4] == 1, p^(s - 1)(p - 1), s ≥ 4, 2^(s - 1), s > 1, 4, s == 1, 2]; lamas[n_] := {aux = 1; Do[aux = LCM[aux, lamas[fa[n][[i, 1]], fa[n][[i, 2]]]], {i, 1, Length@fa[n]}]; aux}[[1]]; Table[lamas[n], {n, 100}] %o A227334 (PARI) a(n)= %o A227334 { %o A227334 my(r=1, f=factor(n)); %o A227334 for(j=1, #f[, 1], my(p=f[j, 1], e=f[j, 2]); %o A227334 if(p==2&&e<=2, r=lcm(r,2^e)); %o A227334 if(p==2&&e>=3, r=lcm(r,2^(e-1))); %o A227334 if(p%4==1, r=lcm(r,(p-1)*p^(e-1))); %o A227334 if(p%4==3, r=lcm(r,(p^2-1)*p^(e-1))); %o A227334 ); %o A227334 return(r); %o A227334 } \\ _Jianing Song_, Aug 29 2018 %Y A227334 Equivalent of arithmetic functions in the ring of Gaussian integers (the corresponding functions in the ring of integers are in the parentheses): A062327 ("d", A000005), A317797 ("sigma", A000203), A079458 ("phi", A000010), this sequence ("psi", A002322), A086275 ("omega", A001221), A078458 ("Omega", A001222), A318608 ("mu", A008683). %Y A227334 Equivalent in the ring of Eisenstein integers: A319446. %K A227334 nonn %O A227334 1,2 %A A227334 _José María Grau Ribas_, Jul 07 2013