Nec
- 50
- 0
I have an integer A and a possitive odd integer B, can you tell me how to find a nonnegative integer C such that C<2^A and 1+BC=0(mod 2^A) ?
?
?
This discussion centers on finding a non-negative integer C such that C < 2A and 1 + BC ≡ 0 (mod 2A) for a given integer A and a positive odd integer B. Participants confirm that a solution exists for every odd B, specifically by choosing C as the complementary odd integer. The Euclidean algorithm is highlighted as a method to derive C, with an example provided where A = 6 and B = 17, resulting in C = 15. The discussion also touches on the lack of an analytic form for C in terms of A and B.
PREREQUISITESMathematicians, computer scientists, and students interested in number theory, particularly those working with modular arithmetic and Diophantine equations.
Sorry, I don't remember how to solve Diophantine equations off the top of my head. Anyways, where's the brain teaser?Nec said:I have an integer A and a possitive odd integer B, can you tell me how to find a nonnegative integer C such that C<2^A and 1+BC=0(mod 2^A)
As C is bounded, I would use a loopNec said:I have an integer A and a possitive odd integer B, can you tell me how to find a nonnegative integer C such that C<2^A and 1+BC=0(mod 2^A) ?
?
CLOCK-->---------(E)->COUNTER(C) REGISTER(B)
E | | |
^ | | |
| | v v
| ----(E)------------>MULTIPLiER
| |
| |
-----------<-----------------------(AND)
I already put you into my list of top 10 ! --smile--Gokul43201 said:If you have A = 4, 2^A = 16.
Any odd B is 4k+1 or 4k-1. Choose C to be the other of the pair.
So, 1+BC = 1+ (4k+1)(4k-1) = 16k^2 == 0 (mod 16)
Looking for a general solution for all A.