login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo

Thanks to everyone who made a donation during our annual appeal!
To see the list of donors, or make a donation, see the OEIS Foundation home page.

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A327823 Odd integers m such that every odd integer k with 1 < k < m and gcd(k,m) = 1 is prime. 0
1, 3, 5, 7, 9, 15, 21, 45, 105 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

Solomon W. Golomb and Kee-Wai Lau prove in AMM (see link) that the greatest odd integer with this property is 105.

This sequence is inspirated by the other one: integers q such that every integer k with 1 < k < q and gcd(k,q) = 1 is prime, with 2, 3, 4, 6, 8, 12, 18, 24, 30 in A048597 \ {1}.

The terms 1 and 3 are added after recommendations of Amiram Eldar and Michel Marcus.

REFERENCES

David Wells, The Penguin Dictionary of Curious and Interesting Numbers, Revised Edition, Penguin Books, London, England, 1997, number 105, page 118.

LINKS

Table of n, a(n) for n=1..9.

Solomon W. Golomb and Kee-Wai Lau, Problem E3137, American Mathematical Monthly, Vol. 94, No. 9, Nov. 1987, pp. 883-884.

EXAMPLE

For m = 15 and 1 < k odd < 15, we have gcd(3,15) = 3, gcd(5,15) = 5, gcd(7,15) = 1, gcd(9,15) = 3, gcd(11,15) = 1, gcd(13,15) = 1. So, gcd(k,15) = 1 only if k is prime and 15 is a term.

For m = 63, we have gcd(25,63) = 1 with 25 no prime, so 63 is not a term.

MATHEMATICA

aQ[n_] := OddQ[n] && AllTrue[Select[Range[3, n, 2], CoprimeQ[n, #] &], PrimeQ]; Select[Range[10^3], aQ] (* Amiram Eldar, Sep 27 2019 *)

PROG

(PARI) isok(m) = {if (m % 2, forstep (k=3, m-1, 2, if ((gcd(k, m) == 1) && !isprime(k), return(0)); ); return(1); ); } \\ Michel Marcus, Sep 27 2019

CROSSREFS

Cf. A048597.

Sequence in context: A201643 A018388 A100866 * A102633 A052942 A240944

Adjacent sequences:  A327820 A327821 A327822 * A327824 A327825 A327826

KEYWORD

nonn,full,fini

AUTHOR

Bernard Schott, Sep 26 2019

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified January 21 16:47 EST 2020. Contains 331114 sequences. (Running on oeis4.)