Update/error: I had a small error in the $(2a+1)$-term in the formula which should have been $(a+1)$ . Because I added now my derivations in long and broad at the end of the question I also rewrite a bit the unknowns $a$ by a shift of $a+1$ to $a$ now reading as $a_1$ and $M_1=M-1$ instead of $M$
I'm looking at whether the rhs in the following equation $$2^W = (2a_1+1)^2 \cdot 2^{M_1}-(a_1)$$ can ever be a perfect power of $2$ for integer $W>0$, $M_1 \ge 0$ and integer (positive or negative) $a_1$.
I know that for $a_1=1$ and $M_1=0$ we have one solution: $$2^W = (3)^2 \cdot 2^0-(+1) = 9 - 1 = 2^3 $$
Q : Is there another or no other solution?
Q : how to do a proof?
I fiddled with this today and didn't get it. Maybe this is easy and I'm only dense at the moment...
Motivation: I'm considering the possibility of 2-step-cycles in the generalized Collatz-problem $ b={m \cdot a +1 \over 2^A} \to a={m \cdot b +1 \over 2^B}$ for odd $m$ and $a,b$ (note: both $a,m$ in the positive and negative).
Letting $a,b$ both be unknown I first checked numerically up to very large positive $m$ and verified the sparseness of known cycles up to some $m \approx 10^{1400}$. But a proof of the nonexistence of further 2-step-cycles seemed out of reach for me.
So I tried with a simplified version, where $b=1$ and only $a$ and $m$ is unknown.
This is what I found so far:
A useful ansatz for the analysis of cycles is to write the equality of products
$$ b \cdot a ={m \cdot a +1 \over 2^A} \cdot {m \cdot b +1 \over 2^B}$$ and reorder to arrive at
$$ 2^{A+B} = (m+{1 \over a}) \cdot (m+{1 \over b})$$
For convenience I always write $S$ for the sum $A+B$ and to simplify the problem we set here $b=1$ and get the
Main formula: $$ 2^S = (m+1)\cdot(m+1/a) \tag 1$$ Because the second parenthese has a denominator $a$ it follows by the first parenthese, that $m$ must have the structure with some integer $m_1$
$$m=m_1 \cdot a - 1 \tag {1.1}$$ The equation changes to $$ 2^S = (a\cdot m_1)\cdot(a\cdot m_1-1+1/a) \\ = m_1\cdot(a^2\cdot m_1-a+1) \tag 2$$ Because both factors must be perfect powers of $2$ it follows $m_1$ must be a perfect power of $2$ (possibly $2^0=1$), say $m_1=2^M$ so $ m=2^M \cdot a-1$ and then $$ 2^S = 2^M\cdot(a^2\cdot 2^M-a+1) \tag {2.1}$$ Because by definition all $a,b$ in the generalized Collatz-problem with $b={m \cdot a +1\over 2^A} $ are odd we can write the structure of $a$ by some integer $a_1$ as $a=2a_1+1$.
Beforehand, we exclude $a=1$ by the problem definition (we want discuss the existence of a two-step-cycle $1 \to a \to 1$) so a solution $a_1=0$ is not wanted - it would be the trivial one-step-cycle which is existent for many $m$ repeated two times).
What we have now is $$ 2^S = 2^M\cdot((2a_1+1)^2\cdot 2^M-2a_1-1+1)\\ 2^{S-M-1} = (2a_1+1)^2\cdot 2^{M-1}-a_1 \tag 3$$ or simplified for the actual original question $$ 2^W = (2a_1+1)^2\cdot 2^{M_1}-a_1 \tag {3.1 for OP} $$ Small solutions are
a_1 a (2a_1+1)^2 rhs M m S comment
------------------------------------------------------------------------
1 3 9 9* 2^{M-1}-1 1 5 5 (well known) solution 1
0 1 1 2^{M-1} any -1 2M trivial, not wanted
-1 -1 1 2^{M-1}+1 1 -3 3 new (?)
-23 -45 2025 2025*2^{M-1}+23 1 -91 13 new (?)
??? ??? ??? .
The likely full set of 2-step-cycles with $b$ varying over the odd integers and $a \ne b$ seems to be
S m: a b a ...
------:-----------------
3, 3: -7, -5, -7
3, -3: -1, 1, -1
5, 5: 1, 3, 1
7, -11: -1, 3, -1
13, -91: -45, 1, -45
15, 181: 27, 611, 27
15, 181: 35, 99, 35
But this was taken using brute force up to $m \approx 10^{300}$, no analytical evaluation about the possibility of 2-step-cycles with $m$ of larger absolute values has been done.