I did this, maybe it will help:
In cells C1:C43 I put the consecutive number 1-43.
In cells B1:B43 I put a formula -- the one in B2 is: =SIN(C2)*(C2)^-(1/5)
This was to get a decaying series.
In cells A2:A43 I put a formula -- the one in A2 is:
=IF(AND(B2>B1,B2>B3),1+A1,A1)
This finds the maximums
The number in A go from 0 to 6. I put the number 1-6 in E2:E7
The formula in F2 is: =VLOOKUP(E2,$A$2:$B$43,2,FALSE)
With similar formulas in F3:F7
G2 has =VLOOKUP(E2,$A$2:$C$43,3,FALSE)
With similar formulas in G3:G7
Highlight F9:G9 and type the following array formula:
=LOGEST(F2:F7,G2:G7)
You have to hit Shift-Ctrl-Enter to make this an array formula.
Then in D1 I put: =$G$9*$F$9^C1
With similar formulas in D2
43.
I hope this is helpful.
Art.