Sorry for what is probably a naive question...
I can map a polynomial to an exponential function
In[940]:= ClearAll [a, b, c , x, \[Theta]]
a x + b x^2 + c /. x -> Exp[\[Theta] I Pi]
Out[941]= c + a E^(I \[Pi] \[Theta]) + b E^(2 I \[Pi] \[Theta])
But how do I do the reverse and take a function which is powers of an exponential and substitute to get a polynomial in x? The example below substitutes the first order power, but fails for higher powers.
In[942]:= ClearAll [a, b, c , x, \[Theta]]
a Exp[\[Theta] I Pi] + b Exp[2 \[Theta] I Pi] + c /.
Exp[\[Theta] I Pi] -> x
Out[943]= c + b E^(2 I \[Pi] \[Theta]) + a x
Thanks!