Can someone explain modulo with fractions?

  • Context: Undergrad 
  • Thread starter Thread starter maxfails
  • Start date Start date
  • Tags Tags
    Explain Fractions
Click For Summary

Discussion Overview

The discussion centers around the concept of modulo operations involving fractions, specifically the interpretation of the modular inverse and its application in modular arithmetic. Participants seek clarification on how to understand expressions like \(3^{-1} \mod 5\) and \((1/3) \mod 5\).

Discussion Character

  • Exploratory, Technical explanation, Conceptual clarification

Main Points Raised

  • One participant states that \(3^{-1} \mod 5 = 2\) and questions how this relates to \((1/3) \mod 5\).
  • Another participant explains that in rational numbers, \(1/3\) is the solution to \(3 \cdot x = 1\), and in modular arithmetic, this translates to finding \(x\) such that \(3 \cdot x \equiv 1 \mod 5\), identifying \(x = 2\) as the solution.
  • A different participant introduces the condition that if \(\text{gcd}(a,m) = 1\) and \(ab \equiv 1 \mod m\), then \(b\) can be interpreted as \(1/a \mod m\), suggesting the use of the Euclidean algorithm to find \(b\).
  • Another participant suggests looking up "modular inverse" for further information and references existing resources.

Areas of Agreement / Disagreement

The discussion does not reach a consensus, as participants present different aspects of the topic without resolving the initial question about the interpretation of modulo with fractions.

Contextual Notes

Participants assume familiarity with concepts like modular inverses and the Euclidean algorithm, but the discussion does not clarify the specific steps or definitions needed to fully understand the relationship between fractions and modulo operations.

maxfails
Messages
10
Reaction score
0
so apparently 3^-1 mod 5 = 2 so (1/3) mod 5 = 2
I don't get how this works, can someone explain?
 
Mathematics news on Phys.org
maxfails said:
so apparently 3^-1 mod 5 = 2 so (1/3) mod 5 = 2
I don't get how this works, can someone explain?

Sure.

In the rational numbers, 1/3 represents the solution to 3 * x = 1. For integers mod 5, we mean the same thing: 3 * x = 1 mod 5. But you can see that 3 * 2 = 1 mod 5, so 3^-1 is just 2.
 
If gcd(a,m) = 1 and ab = 1 (mod m) then b = 1/a (mod m). If you want to find what integer b is congruent to modulo m and you only know a, then you can first use the euclidean algorithm to find it.
 
Last edited:

Similar threads

  • · Replies 6 ·
Replies
6
Views
1K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 11 ·
Replies
11
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 10 ·
Replies
10
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K
Replies
5
Views
2K
  • · Replies 5 ·
Replies
5
Views
2K