First of all, you always must include the description of what you have tried so far and what error you encountered while doing so. It is not nice to ask a question directly without showing your efforts in it.
Now coming back to your question, it is actually quite very easy, what you can do is this:
temp = 1
geom_prog = []
while temp<n+1:
geom_prog.append(temp)
temp = temp*ratio
2
solved Python math issue [closed]