MathGroup Archive 1999

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Finding a relative prime

  • To: mathgroup at
  • Subject: [mg19698] Re: [mg19682] Finding a relative prime
  • From: "Arnold Knopfmacher" <arnoldk at>
  • Date: Sat, 11 Sep 1999 16:36:04 -0400
  • Organization: MS, University of the Witwatersrand
  • Sender: owner-wri-mathgroup at


Arnold Knopfmacher

I'm using Mathematica 3.0 for the Mac, and I'm trying to figure out how
to get it to pick a random number that is relatively prime to another
number, p-1, where p is prime.  In other words, pick a random number k
such that 1) k is between 2 and p-1, and 2) k is relatively prime to p-1.
How can I do that in Mathematica 3.0?


Sent via
Share what you know. Learn what you don't.

The Centre for Applicable Analysis and Number Theory:
Arnold Knopfmacher:
Fax: 2711-4039317
email: arnoldk at

  • Prev by Date: nonlinear differential equations
  • Next by Date: Re: NonlinearFit
  • Previous by thread: Re: Re: Finding a relative prime
  • Next by thread: Re: RE: Finding a relative prime