I have a problem I want to solve, but I could not figure out how to approach it. And since I do not have formal maths training, I am not very familiar with the terminology so it is possible I may not know the correct keywords for search.
Below are a couple sample equations, which I want to find a way to solve them efficiently, when the numbers are big. So, no trial and error:
$$ k^2 + k + 5 \equiv 0 \, (mod \,\, 13-k) $$
Solution for this is k=2
$$ k^2 + 3028 \equiv 0 \, (mod \,\, 9011-k) $$
And solution for this is k=864
So the question is, how can I solve similar equations with a lot bigger coefficients without trial-error.
Thank you
EDIT: These equations also have negative solutions (k=-4
for the first one and k=-956
for the second one)
UPDATE:
As far as I see from the answers, the solution comes to factoring, which does not have an efficient solution when you have big numbers (more than hundreds of digits) as coefficients.
Thank you for your time and answers. Now I at least know this is really a difficult problem.
No comments:
Post a Comment