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.

Showing 1-5 of 5 results.

A293482 The number of 5th powers in the multiplicative group modulo n.

Original entry on oeis.org

1, 1, 2, 2, 4, 2, 6, 4, 6, 4, 2, 4, 12, 6, 8, 8, 16, 6, 18, 8, 12, 2, 22, 8, 4, 12, 18, 12, 28, 8, 6, 16, 4, 16, 24, 12, 36, 18, 24, 16, 8, 12, 42, 4, 24, 22, 46, 16, 42, 4, 32, 24, 52, 18, 8, 24, 36, 28, 58, 16, 12, 6, 36, 32, 48, 4, 66, 32, 44, 24, 14, 24, 72, 36, 8, 36, 12, 24, 78, 32, 54, 8, 82, 24
Offset: 1

Views

Author

R. J. Mathar, Oct 10 2017

Keywords

Comments

The size of the set of numbers j^5 mod n, gcd(j,n)=1, 1 <= j <= n.
A000010(n) / a(n) is another multiplicative integer sequence.

Crossrefs

The number of k-th powers in the multiplicative group modulo n: A046073 (k=2), A087692 (k=3), A250207 (k=4), this sequence (k=5), A293483 (k=6), A293484 (k=7), A293485 (k=8).

Programs

  • Maple
    A293482 := proc(n)
        local r,j;
        r := {} ;
        for j from 1 to n do
            if igcd(j,n)= 1 then
                r := r union { modp(j &^ 5,n) } ;
            end if;
        end do:
        nops(r) ;
    end proc:
    seq(A293482(n),n=1..120) ;
  • Mathematica
    a[n_] := Module[{r, j}, r = {}; For[j = 1, j <= n, j++, If[GCD[j, n] == 1, r = r ~Union~ {PowerMod[j, 5, n]}] ]; Length[r]];
    Table[a[n], {n, 1, 120}] (* Jean-François Alcover, Feb 14 2023, after R. J. Mathar *)
    f[p_, e_] := (p - 1)*p^(e - 1)/If[Mod[p, 5] == 1, 5, 1]; f[2, e_] := 2^(e - 1); f[2, 1] = 1; f[5, e_] := 4*5^(e-2); f[5, 1] = 4; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Aug 10 2023 *)

Formula

Conjecture: a(2^e) = 1 for e <= 1; a(2^e) = 2^(e-1) for e >= 1; a(5)=4; a(5^e) = 4*5^(e-2) for e > 1; a(p^e) = (p-1)*p^(e-1) for p == {2,3,4} (mod 5); a(p^e) = (p-1)*p^(e-1)/5 for p == 1 (mod 5). - R. J. Mathar, Oct 13 2017
a(n) = A000010(n)/A319099(n). This implies that the conjecture above is true. - Jianing Song, Nov 10 2019

A087692 Number of cubes in multiplicative group modulo n.

Original entry on oeis.org

1, 1, 2, 2, 4, 2, 2, 4, 2, 4, 10, 4, 4, 2, 8, 8, 16, 2, 6, 8, 4, 10, 22, 8, 20, 4, 6, 4, 28, 8, 10, 16, 20, 16, 8, 4, 12, 6, 8, 16, 40, 4, 14, 20, 8, 22, 46, 16, 14, 20, 32, 8, 52, 6, 40, 8, 12, 28, 58, 16, 20, 10, 4, 32, 16, 20, 22, 32, 44, 8, 70, 8, 24, 12, 40, 12, 20, 8, 26, 32, 18, 40
Offset: 1

Views

Author

Yuval Dekel (dekelyuval(AT)hotmail.com), Sep 27 2003

Keywords

Comments

Cubic analog of A046073. - Steven Finch, Mar 01 2006

Crossrefs

Cf. A000010, A060839, A046073 (squares), A250207 (4th powers).

Programs

  • Maple
    b:= proc(p,i)
      if p = 3 then if i=1 then 2 else 2*3^(i-2) fi
      elif p mod 6 = 1 then (p-1)*p^(i-1)/3
      else (p-1)*p^(i-1)
      fi
    end proc:
    seq(mul(b(f[1],f[2]), f = ifactors(n)[2]), n = 1 .. 1000); # Robert Israel, Jan 04 2015
  • Mathematica
    Map[Length,Table[Select[Range[n],CoprimeQ[#, n] && IntegerQ[PowerMod[#, 1/3, n]] &], {n, 1, 82}]] (* Geoffrey Critzer, Jan 07 2015 *)
    f[p_, e_] := (p - 1)*p^(e - 1)/If[Mod[p, 6] == 1, 3, 1]; f[3, e_] := 2*3^(e-2); f[3, 1] = 2; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Aug 10 2023 *)
  • PARI
    a(n) = my(f = factor(n)); prod(j=1, #f~, p=f[j,1]; k=f[j,2]; if (p == 3, if (k==1, 2, 2*3^(k-2)), if ((p % 6) == 1, ((p-1)*p^(k-1))/3, (p-1)*p^(k-1)))); \\ Michel Marcus, Jan 05 2015

Formula

a(n) = phi(n) / A060839(n).
Multiplicative with a(3) = 2, a(3^k) = 2*3^(k-2) otherwise;
a(p^k) = (p-1)*p^(k-1)/3 if prime p == 1 mod 6; a(p^k) = (p-1)*p^(k-1) for all other primes p. - Robert Israel, Jan 04 2015
Sum_{k=1..n} a(k) ~ c * n^2/log(n)^(1/3), where c = (17/(36*Gamma(2/3))) * Product_{p = 3 or p prime == 2 (mod 3)} (1+1/*p)*(1-1/p)^(2/3) * Product_{p prime == 1 (mod 3)} (1+1/(3*p))*(1-1/p)^(2/3) = 0.33051128776333262024... (Finch and Sebah, 2006). - Amiram Eldar, Oct 18 2022

Extensions

More terms from Steven Finch, Mar 01 2006

A293483 The number of 6th powers in the multiplicative group modulo n.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 1, 1, 2, 5, 1, 2, 1, 2, 2, 8, 1, 3, 2, 1, 5, 11, 1, 10, 2, 3, 1, 14, 2, 5, 4, 5, 8, 2, 1, 6, 3, 2, 2, 20, 1, 7, 5, 2, 11, 23, 2, 7, 10, 8, 2, 26, 3, 10, 1, 3, 14, 29, 2, 10, 5, 1, 8, 4, 5, 11, 8, 11, 2, 35, 1, 12, 6, 10, 3, 5, 2, 13, 4, 9, 20
Offset: 1

Views

Author

R. J. Mathar, Oct 10 2017

Keywords

Comments

The size of the set of numbers j^6 mod n, gcd(j,n)=1, 1 <= j <= n.
A000010(n) / a(n) is another multiplicative integer sequence.

Crossrefs

The number of k-th powers in the multiplicative group modulo n: A046073 (k=2), A087692 (k=3), A250207 (k=4), A293482 (k=5), this sequence (k=6), A293484 (k=7), A293485 (k=8).

Programs

  • Maple
    A293483 := proc(n)
        local r,j;
        r := {} ;
        for j from 1 to n do
            if igcd(j,n)= 1 then
                r := r union { modp(j &^ 6,n) } ;
            end if;
        end do:
        nops(r) ;
    end proc:
    seq(A293483(n),n=1..120) ;
  • Mathematica
    a[n_] := EulerPhi[n]/Count[Range[0, n - 1]^6 - 1, k_ /; Divisible[k, n]];
    Array[a, 100] (* Jean-François Alcover, May 24 2023 *)
    f[p_, e_] := (p - 1)*p^(e - 1)/If[Mod[p, 6] == 1, 6, 2]; f[2, e_] := If[e <= 3, 1, 2^(e - 3)]; f[3, e_] := If[e <= 2, 1, 3^(e - 2)]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Aug 10 2023 *)

Formula

Conjecture: a(2^e) = 1 for e <= 3; a(2^e) = 2^(e-3) for e >= 3; a(3^e) = 1 for e <= 2; a(3^e) = 3^(e-2) for e >= 2; a(p^e) = (p-1)*p^(e-1)/2 for p == 5 (mod 6); a(p^e) = (p-1)*p^(e-1)/6 for p == 1 (mod 6). - R. J. Mathar, Oct 13 2017
a(n) = A000010(n)/A319100(n). This implies that the conjecture above is true. - Jianing Song, Nov 10 2019

A293484 The number of 7th powers in the multiplicative group modulo n.

Original entry on oeis.org

1, 1, 2, 2, 4, 2, 6, 4, 6, 4, 10, 4, 12, 6, 8, 8, 16, 6, 18, 8, 12, 10, 22, 8, 20, 12, 18, 12, 4, 8, 30, 16, 20, 16, 24, 12, 36, 18, 24, 16, 40, 12, 6, 20, 24, 22, 46, 16, 6, 20, 32, 24, 52, 18, 40, 24, 36, 4, 58, 16, 60, 30, 36, 32, 48, 20, 66, 32, 44, 24, 10, 24, 72, 36, 40, 36
Offset: 1

Views

Author

R. J. Mathar, Oct 10 2017

Keywords

Comments

The size of the set of numbers j^7 mod n, gcd(j,n)=1, 1 <= j <= n.
A000010(n) / a(n) is another multiplicative integer sequence (size of the kernel of the isomorphism of the multiplicative group modulo n to the multiplicative group of 7th powers modulo n).

Crossrefs

The number of k-th powers in the multiplicative group modulo n: A046073 (k=2), A087692 (k=3), A250207 (k=4), A293482 (k=5), A293483 (k=6), this sequence (k=7), A293485 (k=8).

Programs

  • Maple
    A293484 := proc(n)
        local r,j;
        r := {} ;
        for j from 1 to n do
            if igcd(j,n)= 1 then
                r := r union { modp(j &^ 7,n) } ;
            end if;
        end do:
        nops(r) ;
    end proc:
    seq(A293484(n),n=1..120) ;
  • Mathematica
    a[n_] := EulerPhi[n]/Count[Range[0, n - 1]^7 - 1, k_ /; Divisible[k, n]];
    Array[a, 100] (* Jean-François Alcover, May 24 2023 *)
    f[p_, e_] := (p-1)*p^(e-1)/If[Mod[p, 7] == 1, 7, 1]; f[2, e_] := 2^(e-1); f[7, 1] = 6; f[7, e_] := 6*7^(e-2); a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Aug 10 2023 *)

Formula

Conjecture: a(2^e) = 1 for e <= 1; a(2^e) = 2^(e-1) for e >= 1; a(7^e) = 6 for e=1; a(7^e) = 6*7^(e-2) for e >= 2; a(p^e) = (p-1)*p^(e-1) for p == {2,3,4,5,6} (mod 7); a(p^e) = (p-1)*p^(e-1)/7 for p == 1 (mod 7). - R. J. Mathar, Oct 13 2017
a(n) = A000010(n)/A319101(n). This implies that the conjecture above is true. - Jianing Song, Nov 10 2019

A293485 The number of 8th powers in the multiplicative group modulo n.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 3, 1, 3, 1, 5, 1, 3, 3, 1, 1, 2, 3, 9, 1, 3, 5, 11, 1, 5, 3, 9, 3, 7, 1, 15, 1, 5, 2, 3, 3, 9, 9, 3, 1, 5, 3, 21, 5, 3, 11, 23, 1, 21, 5, 2, 3, 13, 9, 5, 3, 9, 7, 29, 1, 15, 15, 9, 2, 3, 5, 33, 2, 11, 3, 35, 3, 9, 9, 5, 9, 15, 3, 39, 1, 27, 5, 41, 3, 2
Offset: 1

Views

Author

R. J. Mathar, Oct 10 2017

Keywords

Comments

The size of the set of numbers j^8 mod n, gcd(j,n)=1, 1<=j<=n.

Crossrefs

The number of k-th powers in the multiplicative group modulo n: A046073 (k=2), A087692 (k=3), A250207 (k=4), A293482 (k=5), A293483 (k=6), A293484 (k=7), this sequence (k=8).
Cf. A085311, A247257 (order of the kernel isomorphism of Z/nZ to this group), A000010.

Programs

  • Maple
    A293485 := proc(n)
        local r,j;
        r := {} ;
        for j from 1 to n do
            if igcd(j,n)= 1 then
                r := r union { modp(j &^ 8,n) } ;
            end if;
        end do:
        nops(r) ;
    end proc:
    seq(A293485(n),n=1..120) ;
  • Mathematica
    a[n_] := EulerPhi[n]/Count[Range[0, n - 1]^8 - 1, k_ /; Divisible[k, n]];
    Array[a, 100] (* Jean-François Alcover, May 24 2023 *)
    f[p_, e_] := (p - 1)*p^(e - 1)/Switch[Mod[p, 8], 1, 8, 5, 4, , 2]; f[2, e] := If[e <= 4, 1, 2^(e - 5)]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Aug 10 2023 *)
  • PARI
    \\ The following two functions by Charles R Greathouse IV, from A247257:
    g(p, e) = if(p==2, 2^min(e-1, 4), if(p%4==3, 2, if(p%8==5, 4, 8)));
    A247257(n) = my(f=factor(n)); prod(i=1, #f~, g(f[i, 1], f[i, 2]));
    A293485(n) = (eulerphi(n)/A247257(n)); \\ Antti Karttunen, Dec 05 2017

Formula

A000010(n) / a(n) = A247257(n).
Multiplicative with a(2^e) = 1 for e<=4, a(2^e) = 2^(e-5) for e>=5; a(p^e) = (p-1)*p^(e-1)/8 for p == 1 (mod 8); a(p^e) = (p-1)*p^(e-1)/4 for p == 5 (mod 8); a(p^e) = (p-1)*p^(e-1)/2 for p == {3,7} (mod 8). - R. J. Mathar, Oct 15 2017 [corrected by Georg Fischer, Jul 21 2022]
Showing 1-5 of 5 results.