Forum Discussion

treg2020's avatar
treg2020
Copper Contributor
Jun 26, 2020

rolling sum with specified start and end row

Hi all, 

 

I want to calculate the surface under a segment of line BF: y = x  (see image below)

via pythagoras the following can be deduced:

0.5(d-c)(b-a)+c(b-a)

When substituting: b-a = n

0.5n(d-c)+cn

In Excel column BF specifies the y(x)

surface under BF in excel: SUMIF(INDIRECT(“BF"&a & ":BF"&b),"<>#N/A")

when putting the first formula in excel, it only mimics the indirect function when adding +1 for segment n:  0.5(n+1)(d-c)+c(n+1)

Why do I have to do that, how does excel approach the indirect function exactly?!!!

1 Reply

  • treg2020 hello there,

     

    Are you just asking how the INDIRECT function works? If so, it returns a range reference from a static parameter. There are a few functions which do this. You can watch https://youtu.be/-wnqlQB_j3k to see that and others. 

Resources