Coprime

Coprime (or Relatively Prime or Mutually Prime) numbers
have no common factors other than 1

And no fractions! Just integers, and positive factors.

Example: 21 and 22 are coprime

  • The positive factors of 21 are 1, 3, 7 and 21
  • The positive factors of 22 are 1, 2, 11 and 22

The only common factor is 1, so they are coprime.

Example: 21 and 24 are NOT coprime

  • The factors of 21 are 1, 3, 7 and 21
  • The factors of 24 are 1, 2, 3, 4, 6, 8, 12 and 24

The common factors are 1 AND 3, so they are NOT coprime.

With no common factors other than 1 their greatest common factor is also 1

And 1 is not prime, so coprimes don't share any prime factors either.

coprime table
Coprime Table 1 to 12

Consecutive (following each other) numbers like 3,4 or 126,127 are always coprime: imagine the first number n has a prime factor p, then n+1 cannot have the factor p as n+1 divided by p will have a remainder of 1.

Useful for Fractions

35

When we simplify a fraction as much as possible, then the top and bottom numbers (the numerator and denominator) are coprime.

610 = 35

If the top and bottom numbers of a fraction are not coprime (like 6 and 10 that share the factor 2), then we can simplify the fraction.

Useful in Cryptography

Coprime numbers are needed in the field of cryptography, such as for RSA Cryptography that helps ensure secure communication and data protection.

𝄞 Music

In music, when two notes have coprime ratios such as 1:2, 2:3, 3:4, etc, they create a harmony that is pleasing to the ear.

piano keys

Example: the ratios between the pitches of the scale (C, D, E, F, G, A, B, C) all have coprime ratios.

By using coprime intervals within a chord or melody composers can achieve a sense of complexity and interest in the music.

And just like musical harmony, coprimes have a special relationship that makes them mathematically "harmonious".

Testing

We can test if two numbers are coprime by using the Euclidean Algorithm.

Grid

When two numbers are coprime (like 7 and 5) they can "see" each other through the grid (no other grid points get in the way):

coprime 7 and 5 grid

 

2237, 7969, 7970, 7973, 25349, 25350, 25351, 25352, 25353, 25354