I would like to know, how to input and solve following equation in Matlab:
$2^x \equiv 456 \ (\text{mod}\ 582)$
Is there a way to find $x$ in Matlab?
I would like to know, how to input and solve following equation in Matlab:
$2^x \equiv 456 \ (\text{mod}\ 582)$
Is there a way to find $x$ in Matlab?
This equation has no solution: indeed, as $582=6\times 97$, a solution would imply $$2^x\equiv 456\equiv 68\mod 97.$$ However, as $2$ has order $48\bmod 97$, this would imply $68^{48}\equiv 1\mod 97$. However the fast exponentiation algorithm shows $68^{48}\equiv -1\mod 97$.
Added:
@Mike observed, it's much simpler to consider congruences mod. $3$: $456\equiv 0\mod 3$, and $2$ is a unit mod $3$, so none of its powers can be congruent to $456 \bmod 3$.