# Factoring $2^b-1$ out from $(1+2^a+...+2^{(b-1)a})$

It is well known that $2^{ab}-1=(2^a-1)(1+2^a+...+2^{(b-1)a})=(2^b-1)(1+2^b+...+2^{(a-1)b})$. Assuming $gcd(2^a-1,2^b-1)=1$, we see $2^b-1|(1+2^a+...+2^{(b-1)a})$. My question is simply how to factor out the factor $2^b-1$ from this expression.

• Try a few concrete cases first, like $a=2,b=3$, and $a=2,b=5$, and $a=3,b=4$, and $a=3,b=5$. See if you can spot some immediate pattern. If you swap $2$ with $x$, then this wikipedia article might help you identify the factors which appear. Aug 18 '18 at 4:34

Since the primitive part of a term in a sequence is defined as the term divided by the algebraic part, and because here the algebraic part is $$(2^a-1)(2^b-1)$$, we know the expression we are trying to find is the primitive part of $$2^{ab}-1$$. This is calculable via $$\Phi_{ab}(2)$$, using roots of unity as shown in the link provided in the comment.