OFFSET
1,3
COMMENTS
For n >= 3, 3^x == y (mod 2^n) has solutions x if and only if y is in A047471.
LINKS
Robert Israel, Table of n, a(n) for n = 1..831
FORMULA
a((3^k - (-1)^k)/4 + 1) = k.
EXAMPLE
a(4) = 39 because A047471(4) = 11 and 3^39 == 11 (mod 2^11).
MAPLE
f:= proc(n) local k, v;
v:= subs(msolve(3^k=n, 2^n), k);
subs(op(indets(v))=0, v)
end proc:
seq(seq(f(8*i+j), j=[1, 3]), i=0..10);
CROSSREFS
KEYWORD
nonn
AUTHOR
J. M. Bergot and Robert Israel, Dec 16 2020
STATUS
approved