Solving a discrete logarithm problem returns a 0x1 sym or Unable to find explicit solution

6 views (last 30 days)
syms x
solve(2 == (6^x) - (11 * ((6^x)/11)),x)
Returns:
ans =
Empty sym: 0-by-1
I tried using:
syms x
solve(2==mod((6^x),11),x)
but i recieve:
Warning: Unable to find explicit solution. For options, see help.
> In solve (line 317)
ans =
Empty sym: 0-by-1
I just want to solve:

Answers (1)

Torsten
Torsten on 9 Jan 2022
Edited: Torsten on 9 Jan 2022
Brute force:
x = 0:24;
y = uint64(6.^x);
d = mod(y,11);
x = x(d==2)

Products


Release

R2019b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!