A051250
Numbers whose reduced residue system consists of 1 and prime powers only.
Original entry on oeis.org
1, 2, 3, 4, 5, 6, 8, 9, 10, 12, 14, 18, 20, 24, 30, 42, 60
Offset: 1
RRS[ 60 ] = {1,7,11,13,17,19,23,29,31,37,41,43,47,49,53,59}.
- M. Dalezman, From 30 to 60 Is Not Twice as Hard, Mathematics Magazine, Vol. 73, No. 2 (Apr. 2000), pp. 151-153.
- O. Ore and N. J. Fine, Reduced Residue Systems, American Mathematical Monthly Vol. 66, No. 10 (Dec., 1959), pp. 926-927.
-
a051250 n = a051250_list !! (n-1)
a051250_list = filter (all ((== 1) . a010055) . a038566_row) [1..]
-- Reinhard Zumkeller, May 27 2015, Dec 18 2011, Oct 27 2010
-
fQ[n_] := Union[# == 1 || Mod[#, # - EulerPhi[#]] == 0 & /@ Select[ Range@ n, GCD[#, n] == 1 &]] == {True}; Select[ Range@ 100, fQ] (* Robert G. Wilson v, Jul 11 2011 *)
-
isprimepower(n)=ispower(n,,&n);isprime(n)
is(n)=for(k=2,n-1,if(gcd(n,k)==1&&!isprimepower(k),return(0)));1 \\ Charles R Greathouse IV, Jul 14 2011
A048863
Number of nonprimes (1 and composites) in the reduced residue system of n-th primorial number (A002110).
Original entry on oeis.org
1, 1, 1, 1, 6, 142, 2518, 49836, 1012859, 24211838, 721500294, 22627459401, 844130935668, 34729870646918, 1491483322755274, 69890000837179157, 3692723747920861125, 217158823263305180123, 13182405032836651359192, 879055475442725460400606
Offset: 0
For n = 3, the 3rd primorial is 30, phi(30) = 8, a(3) = 1 since 1 is nonprime. See A048597.
For n = 4, the 4th primorial is 210, the size of its reduced residue system (RRS) is 48 of which 6 are either composite numbers or 1: {1, 121, 143, 169, 187, 209}.
-
Table[Function[P, EulerPhi@ P - # &[PrimePi@ P - n]]@ Product[Prime@ i, {i, n}], {n, 0, 12}] (* Michael De Vlieger, May 08 2017 *)
a(18)-a(19) calculated using Kim Walisch's primecount and added by
Amiram Eldar, Sep 03 2024
A286941
Irregular triangle read by rows: the n-th row corresponds to the totatives of the n-th primorial, A002110(n).
Original entry on oeis.org
1, 1, 5, 1, 7, 11, 13, 17, 19, 23, 29, 1, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 121, 127, 131, 137, 139, 143, 149, 151, 157, 163, 167, 169, 173, 179, 181, 187, 191, 193, 197, 199, 209
Offset: 1
The triangle starts
1;
1, 5;
1, 7, 11, 13, 17, 19, 23, 29;
1, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 121, 127, 131, 137, 139, 143, 149, 151, 157, 163, 167, 169, 173, 179, 181, 187, 191, 193, 197, 199, 209;
Cf.
A002110,
A005867,
A048862,
A057588,
A279864,
A286941,
A286942,
A309497,
A038110,
A058250,
A329815.
-
Table[Function[P, Select[Range@ P, CoprimeQ[#, P] &]]@ Product[Prime@ i, {i, n}], {n, 4}] // Flatten (* Michael De Vlieger, May 18 2017 *)
-
row(n) = my(P=factorback(primes(n))); select(x->(gcd(x, P) == 1), [1..P]); \\ Michel Marcus, Jun 02 2020
Original entry on oeis.org
0, 0, 5, 26, 124, 852, 7550, 86125, 1250924, 23748764
Offset: 1
a(3) = 5 since there are 5 ways to express A002110(3) = 30 as (prime(i) + prime(j))/2 with (prime(i) - prime(j))/2 also prime:
(53 + 7)/2 = 30, (53 - 7)/2 = 46/2 = 23
(47 + 13)/2 = 30, (47 - 13)/2 = 34/2 = 17
(43 + 17)/2 = 30, (43 - 17)/2 = 26/2 = 13
(41 + 19)/2 = 30, (41 - 19)/2 = 22/2 = 11
(37 + 23)/2 = 30, (37 - 23)/2 = 14/2 = 7.
- Eric Weisstein's World of Mathematics, Primorial
- Eric Weisstein's World of Mathematics, Totative
-
With[{j = 10^3}, Do[Module[{P = Times @@ Prime@ Range@ n, m}, m = PrimePi@ P; Print@ Total@ Reap[Do[Sow@ Count[Map[{2 P - #, #} &, Prime@ Range[Max[n, k], Min[k + j - 1, m]]], w_ /; And[PrimeQ@ First@ w, PrimeQ[(Subtract @@ w)/2]]], {k, 1, m, j}]][[-1, 1]]], {n, 9}]] (* or *)
Table[Function[P, Count[Map[{2 P - #, #} &, #], w_ /; And[PrimeQ@ First@ w, PrimeQ[(Subtract @@ w)/2]]] &@ Flatten@ Select[Prime@ Range[n + 1, PrimePi[P]], Times @@ Boole@ Map[PrimeQ, {#, P - #}] == 1 &]]@ Product[Prime@ i, {i, n}], {n, 9}] (* Michael De Vlieger, May 03 2017 *)
countOfPrimes = 0
countOfPrimes2 = 0
countOfPrimes3 = 0
Pn10 = 2*3*5*7*11*13*17*19*23*29
PnToUse = Pn10
distanceToCheck = PnToUse
For[i=0,iJamie Morken, May 05 2017 *)
A048980
Difference between number of nonprimes and primes in reduced residue system of primorial numbers.
Original entry on oeis.org
1, 1, 0, -6, -36, -196, -724, 7512, 366838, 11928316, 421130508, 14598816402, 584642184936, 25314953837836, 1128885572358548, 54492272309366314, 2950485568862138250, 213151926413154110951
Offset: 0
n=4, Q(4)=2*3*5*7=210, reduced residue system includes 48 terms:42 primes and 6 composites and 1: a(4)=6-42=-36.
-
Table[Function[P, EulerPhi@ P - 2 # &[PrimePi@ P - n]]@ Product[Prime@ i, {i, n}], {n, 0, 12}] (* Michael De Vlieger, May 08 2017 *)
A048982
Number of numbers which have a "prime-rich" reduced residue system (RRS) and binary order n.
Original entry on oeis.org
0, 0, 0, 1, 3, 8, 15, 22, 32, 50, 85, 80, 98, 84, 59, 37, 10, 2, 0, 0, 0
Offset: 0
In binary order (A029837) zone of 7, i.e., in [65,128], 22 numbers belong to A048868: 66, 68, 70, 72, 74, 76, 78, 80, 84, 88, 90, 96, 98, 100, 102, 104, 108, 110, 112, 114, 120, and 126. The largest term is 90090. The largest 4 are divisible by 2310, the largest 28 by 210, and the largest 103 by 30.
A276497
Number of noncomposites in the reduced residue system of n-th primorial number, A002110(n).
Original entry on oeis.org
1, 2, 8, 43, 339, 3243, 42325, 646022, 12283523, 300369787, 8028643000, 25948875073, 9414916809083, 362597750396727, 15397728527812844, 742238179058722876, 40068968501510691878
Offset: 1
-
Primorial[n_] := Product[Prime[j], {j, 1, n}];
Table[PrimePi[Primorial[n]] - n + 1, {n, 1, 12}]
-
a(n) = primepi(prod(k=1,n,prime(k))) - n + 1; \\ Michel Marcus, Oct 03 2016
Definition aligned with formulas and data by
Peter Munn, Sep 06 2023
A286424
Number of partitions of p_n# into parts (q, k) both coprime to p_n#, with q prime and k nonprime, where p_n# = A002110(n).
Original entry on oeis.org
0, 0, 1, 1, 4, 110, 1432, 23338, 397661, 8193828, 212858328, 5941706227
Offset: 0
a(0) = 0 by definition. A002110(0) = 1; 1 is coprime to all numbers; the only possible totative pair is (1,1) and this does not include both a prime and a nonprime.
a(1) = 0 since, of the floor(A005867(1)/2) = 1 totative pair (1,1) of A002110(1) = 2, none include a both a prime and a nonprime.
a(2) = 1 since, the only totative pair (1,5) of A002110(1) = 6 includes both a prime and a nonprime.
a(3) = 1 since only (1,29) includes both a prime and a nonprime.
a(4) = 4 since (23,187), (41,169), (67,143), (89,121) include a both a prime and a nonprime.
- C. K. Caldwell, The Prime Glossary, Primorial.
- Eric Weisstein's World of Mathematics, Totative.
-
Table[Function[P, Count[Prime@ Range[n + 1, PrimePi[P]], q_ /; ! PrimeQ[P - q]]]@ Product[Prime@ i, {i, n}], {n, 0, 9}] (* Michael De Vlieger, May 08 2017 *)
Showing 1-8 of 8 results.
Comments