We are currently using the AB power monitoring system, and we are having problems, basically, the graph we have for our projected power demand for any current interval is not accurate at all. This is the reason for my desire to create my own code to reflect what our energy usage is. The pulses I am referring to are coming from our meter, and into the power monitoring system. If the pulses mean kW or KWH, matters none to me. I simply want an instantaneous graph of what our consumption is, no matter what the units are. I also do not want just an average calculation. This would be ineffective as a tool for us to use to get below our designated limit. What I really need to project is based on the average of our samples taken this period, what is the amount we will be billed for. The system AB setup for us really doesn't give us that. I cannot wait for a 15 minute period to be over before I get a final amount, as it will be too late at that point. I'll try get what is in my head out here so people can bang away at it.
1st pulse hits. = 1.44, 1 second into interval.
Average projected usage = 1.44 * 900 seconds(15 min.)= 1296
2nd pulse hits. = 2.88, 3 seconds into interval
Average projected usage = 2.88* 300 periods(15 min) = 864
And so on. Now, the only thing wrong with just displaying the 1296 and the 864 is that I only really need to pay attention to the 864. What I really want is to see the trend between the two, and exptrapolate that out over the rest of the 15 minute interval. This way, I can see that after 5 minutes into a period, we're shutting down power at a rate fast enough to get under our "limit" or not. For the data given, I'm at a slope of -216 per second. This would be a piece of cake to extrapolate. What I am confused about is how I handle say 285 of these points to create a accurate projection of where we are going to finish. Obviously, if we run steady at say 3000 for 12 minutes, then slope off at this -216, my projection should not say that I'll hit zero. Instead, it should be time weighted to show that even as I fall off at the end, I still ran high for the majority of the interval, hence my projection should say something like 2500 or something. Hopefully this is a little clearer now, and my apologies for being so long winded.
Russ