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.

A357905 a(n) = log_3(A060839(n)).

This page as a plain text file.
%I A357905 #21 Oct 05 2023 04:11:03
%S A357905 0,0,0,0,0,0,1,0,1,0,0,0,1,1,0,0,0,1,1,0,1,0,0,0,0,1,1,1,0,0,1,0,0,0,
%T A357905 1,1,1,1,1,0,0,1,1,0,1,0,0,0,1,0,0,1,0,1,0,1,1,0,0,0,1,1,2,0,1,0,1,0,
%U A357905 0,1,0,1,1,1,0,1,1,1,1,0,1,0,0,1,0,1,0,0,0,1,2,0,1,0,1,0,1,1,1,0,0,0,1,1,1
%N A357905 a(n) = log_3(A060839(n)).
%C A357905 3-rank of the multiplicative group of integers modulo n.
%H A357905 Jianing Song, <a href="/A357905/b357905.txt">Table of n, a(n) for n = 1..10000</a>
%F A357905 Additive with a(3) = 0, a(3^e) = 1, e >= 2; a(p^e) = 1 for p == 1 (mod 3), 0 for p == 2 (mod 3).
%e A357905 a(63) = 2 since (Z/63Z)* = C_6 X C_6 has 3-rank 2.
%t A357905 f[p_, e_] := If[Mod[p, 3] == 1, 1, 0]; f[3, e_] := 1; f[3, 1] = 0; a[1] = 0; a[n_] := Plus @@ f @@@ FactorInteger[n]; Array[a, 100] (* _Amiram Eldar_, Oct 05 2023 *)
%o A357905 (PARI) a(n)=my(f=factor(n)); sum(i=1, #f~, if(f[i, 1]==3, min(f[i, 2]-1, 1), if(f[i, 1]%3==1, 1, 0)))
%o A357905 (Python)
%o A357905 from sympy import factorint
%o A357905 def A357905(n): return sum(1 for p, e in factorint(n).items() if (p!=3 or e!=1) and p%3!=2) # _Chai Wah Wu_, Oct 19 2022
%Y A357905 Cf. A060839, A072273, A357906.
%K A357905 nonn,easy
%O A357905 1,63
%A A357905 _Jianing Song_, Oct 19 2022