Playing around with the modulo operation

  • Thread starter Archosaur
  • Start date
In summary, the conversation discusses a pattern where if (a*b) mod c = 1, then the sequences a^n mod c and b^n mod c are reverse of each other. This is demonstrated with examples and partial proofs, with the conclusion that all modulo c, if ab = 1 then a^n = b^-n and the periodicity of the sequences ensures their opposite direction. The conversation ends with appreciation for the discussion and further thoughts on the topic.
  • #1
Archosaur
331
1
Hey guys,
I am by no means a mathematician, but I do have a decent eye for patterns, and I found a pretty cool one today. I was hoping one of you guys could tell me more about it.

As a general rule, I've found that if (a*b) mod c = 1, then the sequence a^n mod c is the reverse of the sequence b^n mod c.

For example, (7*8) mod 11 = 1
and 7^n mod 11= 7,5,2,3,10,4,6,9,8...
while 8^n mod 11= 8,9,6,4,10,3,2,5,7...

As another example, (56*24) mod 17 =1
and 56^n mod 17 = 5,8,6,13,14,2,10,16,12,9,11...
while 24^n mod 17= 11,9,12,16,10,2,14,13,6,8,5...

What do you all think about this? I'm willing to bet that all I've done is show a simple concept in a convoluted way, but I'm to fried to think critically about this any more.
 
Mathematics news on Phys.org
  • #2
This is very interesting. For your first example, it is significant that 7 and 11 are relatively prime (no factors in common other than 1), and the same is true for 8 and 11.
 
  • #3
Archosaur said:
Hey guys,
I am by no means a mathematician, but I do have a decent eye for patterns, and I found a pretty cool one today. I was hoping one of you guys could tell me more about it.

Hi Archosaur. Here's a partial proof that's very straight forward. (BTW, to save typing please take all equalities as " = modulo c" and all variables as positive integer in what follows).

1. Assume that we have some power of "a" that is equal to some power of "b", that is [itex] a^p = b^q = x [/itex] for some p,q. (I haven't shown under what conditions this is guaranteed to occur, so this is definitely only a partial proof).

2. Since [itex]ab = 1[/itex] then [itex]abx = x[/itex],

so [itex] ab b^p = a^p[/itex] and hence [itex]b^{p+1} = a^{q-1}[/itex], which proves the reversed nature of the two series.

Perhaps someone else will be able to provide a more complete proof.
 
  • #4
Wow, thank you very much, uart! That was just the kick-start I needed to think about this more.
 
  • #5
All modulo c: If ab = 1, then a= b^-1. So a^n=b^-n. The periodicity of the sequences assures that they are opposite. a^n = b^-n is going in the "opposite direction" to b^n.
 
  • #6
Awesome, yes, this is what I ended up with. Thanks for your help, everyone!
 

1. What is the modulo operation?

The modulo operation, denoted by the symbol "%", is a mathematical operation that finds the remainder after dividing one number by another. For example, 10 % 3 would result in a remainder of 1.

2. What is the purpose of using the modulo operation?

The modulo operation is commonly used in programming to check for divisibility or to perform cyclic operations. It can also be used to generate random numbers or to create patterns.

3. How does the modulo operation work with negative numbers?

The modulo operation works the same way with negative numbers as it does with positive numbers. The result will always be a positive number, and the sign of the remainder will depend on the sign of the dividend.

4. Can the modulo operation be used with non-integer numbers?

Yes, the modulo operation can be used with non-integer numbers. However, the result may not be accurate due to the precision of floating-point numbers. It is recommended to use a library or function specifically designed for calculating modulo with non-integer numbers.

5. Is there a relationship between the modulo operation and other mathematical operations?

Yes, there are several relationships between the modulo operation and other mathematical operations. For example, the remainder obtained from the modulo operation can also be obtained by subtracting the quotient of a division from the dividend. The modulo operation is also related to the concept of congruence in number theory.

Similar threads

Replies
6
Views
2K
  • Engineering and Comp Sci Homework Help
Replies
7
Views
1K
  • Engineering and Comp Sci Homework Help
Replies
1
Views
1K
  • Quantum Physics
Replies
3
Views
943
Replies
68
Views
9K
Replies
55
Views
3K
  • Precalculus Mathematics Homework Help
Replies
4
Views
729
  • Nuclear Engineering
Replies
7
Views
2K
  • Engineering and Comp Sci Homework Help
Replies
1
Views
1K
  • Calculus and Beyond Homework Help
Replies
2
Views
993
Back
Top