I have to go.. Don't time to finnish...

Here is start.. Your data is in rows =POWER(2;ROW(A1)-1)-1

And you need to use them in index function...

Hope someone else can continue