Hello,
I have a worksheet containing monthly well production data. There are columns for the well number, month (date), barrels produced that month, and number of days the well was actively producing that month.
I am trying to write a formula that will give the total number of barrels produced for a given well over the first 240 days of production.
So basically I think I need to add the numbers in the third column until the numbers in the fourth column exceed 240, then multiply the difference between the sum of days producing up to that point and 240, and multiply this difference by the average daily production for the final month. The product of this last step would then be added to the sum of third column numbers up to that point.
Seems straightforward enough, but I am having a difficult time figuring this one out.
Here is a sample of the data:
[TABLE="width: 260"]
<tbody>[TR]
[TD]Well Number[/TD]
[TD]Date[/TD]
[TD]Barrels Produced[/TD]
[TD]Days Producing[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]7/1/1961[/TD]
[TD="align: right"]887[/TD]
[TD="align: right"]30[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]8/1/1961[/TD]
[TD="align: right"]3479[/TD]
[TD="align: right"]30[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]9/1/1961[/TD]
[TD="align: right"]3320[/TD]
[TD="align: right"]23[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]10/1/1961[/TD]
[TD="align: right"]3362[/TD]
[TD="align: right"]31[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]11/1/1961[/TD]
[TD="align: right"]3275[/TD]
[TD="align: right"]29[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]12/1/1961[/TD]
[TD="align: right"]1834[/TD]
[TD="align: right"]18[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]1/1/1962[/TD]
[TD="align: right"]1372[/TD]
[TD="align: right"]19[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]2/1/1962[/TD]
[TD="align: right"]2020[/TD]
[TD="align: right"]24[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]3/1/1962[/TD]
[TD="align: right"]1706[/TD]
[TD="align: right"]22[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]4/1/1962[/TD]
[TD="align: right"]1280[/TD]
[TD="align: right"]14[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]5/1/1962[/TD]
[TD="align: right"]1525[/TD]
[TD="align: right"]14[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]6/1/1962[/TD]
[TD="align: right"]1334[/TD]
[TD="align: right"]17[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]7/1/1962[/TD]
[TD="align: right"]2093[/TD]
[TD="align: right"]31[/TD]
[/TR]
</tbody>[/TABLE]
Thanks!
I have a worksheet containing monthly well production data. There are columns for the well number, month (date), barrels produced that month, and number of days the well was actively producing that month.
I am trying to write a formula that will give the total number of barrels produced for a given well over the first 240 days of production.
So basically I think I need to add the numbers in the third column until the numbers in the fourth column exceed 240, then multiply the difference between the sum of days producing up to that point and 240, and multiply this difference by the average daily production for the final month. The product of this last step would then be added to the sum of third column numbers up to that point.
Seems straightforward enough, but I am having a difficult time figuring this one out.
Here is a sample of the data:
[TABLE="width: 260"]
<tbody>[TR]
[TD]Well Number[/TD]
[TD]Date[/TD]
[TD]Barrels Produced[/TD]
[TD]Days Producing[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]7/1/1961[/TD]
[TD="align: right"]887[/TD]
[TD="align: right"]30[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]8/1/1961[/TD]
[TD="align: right"]3479[/TD]
[TD="align: right"]30[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]9/1/1961[/TD]
[TD="align: right"]3320[/TD]
[TD="align: right"]23[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]10/1/1961[/TD]
[TD="align: right"]3362[/TD]
[TD="align: right"]31[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]11/1/1961[/TD]
[TD="align: right"]3275[/TD]
[TD="align: right"]29[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]12/1/1961[/TD]
[TD="align: right"]1834[/TD]
[TD="align: right"]18[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]1/1/1962[/TD]
[TD="align: right"]1372[/TD]
[TD="align: right"]19[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]2/1/1962[/TD]
[TD="align: right"]2020[/TD]
[TD="align: right"]24[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]3/1/1962[/TD]
[TD="align: right"]1706[/TD]
[TD="align: right"]22[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]4/1/1962[/TD]
[TD="align: right"]1280[/TD]
[TD="align: right"]14[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]5/1/1962[/TD]
[TD="align: right"]1525[/TD]
[TD="align: right"]14[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]6/1/1962[/TD]
[TD="align: right"]1334[/TD]
[TD="align: right"]17[/TD]
[/TR]
[TR]
[TD="align: right"]2853[/TD]
[TD="align: right"]7/1/1962[/TD]
[TD="align: right"]2093[/TD]
[TD="align: right"]31[/TD]
[/TR]
</tbody>[/TABLE]
Thanks!