I am looking to write a formula for an ‘actual’ (Column C) that is equal to the ‘potential’ (Column A) but not exceed the ‘capacity’ (Column B).
In case the potential is greater than the capacity the excess (potential-capacity) is carried over into in next row until the capacity becomes available and fill the gap at that point. Ultimately, the entire of potential will be realized as actual over time as capacity becomes available.
ColumnA ColumnB ColumnC
(Potential) (Capacity) (Actual)
40 50 40
60 50 50
70 80 80 (actual now includes excess from the row above)
100 80 80
100 90 90
90 100 100 (actual includes some of the excess within the capacity constraint)
80 100 90 (actual includes remainder of the excess as capacity is now available)
Bookmarks