Skip to main content
1-Visitor
March 5, 2013
Solved

Cumulative Function

  • March 5, 2013
  • 1 reply
  • 2908 views

I have a lengthy program that returns a row matrix (dN) as one of the results. What I need to do is to take the the value of the prior row and add it to the current row and iterate through the whole list. I get the result I need doing it manually, but the number of rows is variable (h) and large, +500.

Any help on a quick method to run this would be appreciated. My attempts at an i=0,1.. h soultion end up in a singular answer rather than the list of values I need.

Capture.PNG

Best answer by AndyWesterman

Is this what you need?

Regards

Andy

1 reply

25-Diamond I
March 5, 2013

Its not clear to me what you are trying to achieve.

Can you post a (short, manually derived) example and possible a worksheet (not necessarily that lengthy one you mentioned but soemthing stripped down to the point you are interested in).

What is given from the start and what is the supposed outcome?

mnesser1-VisitorAuthor
1-Visitor
March 5, 2013

Attached is an extract of the larger worksheet. (dN) is defined by a series of many other functions and variables.

The number of rows in (dN) is defined by the variable (h). I need a routine that takes the first row of dN then adds it to the next row, and repeats. Basically each new row should be the sum of all prior rows.

The result will be used to plot the accumulative damage (dN) as a function of (n) which is the number of rows.

12-Amethyst
March 5, 2013

Is this what you need?

Regards

Andy