Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

I have a file which contains watt readings for various times throughout the day. A reading is stored roughly every 6 seconds.

206,2012/04/24 00:00:05
400,2012/04/24 00:00:21
300,2012/04/24 00:00:23
90,2012/04/24 00:00:29

I have two methods of working out a total kilowatt-hour figure from the above readings.

Method 1:-

I take an average of the watt reading, so 206+400+300+90 = 790 / 4 = 197.5

Then i work out the total range of the file, so 29 - 5 = 24 seconds.

Then i work out the kWh by converting the avg. watts to kW 197.5 / 1000 = 0.1975 Convert the seconds to hours, 24/3600 = 0.006666666 Then 0.1975 * 0.00666666666666667 = 0.00131666 kwh.

The other method i have is to work out the kwH per line and keep a running total:-

I do this by working out how long the first reading lasted by subtracting the second readings time value from the first. We assume the last line lasted 6 seconds as we havent got a reading after it to distinguish its length.

206,2012/04/24 00:00:05    lasted 16 seconds             so 206 for 16 seconds = ? kwh
400,2012/04/24 00:00:21    lasted 2 seconds              so 400 for 2 seconds = ? kwh
300,2012/04/24 00:00:23    lasted 6 seconds              and so on....
90,2012/04/24 00:00:29     assume last record lasted 6 seconds

I then work out the kwh per line and keep a running total of the kwh reading.

Question is, which is more accurate, and would there be a massive difference in the accuracy of the two methods.

share|improve this question
add comment

1 Answer 1

up vote 1 down vote accepted

If the readings were taken at consistent intervals, the two methods would yield the same answer (with a slight perturbation for the endpoints of the interval) because you would always be multiplying by the the same amount of time in the second. If the time spacing is not regular, the second will weight the readings in proportion to the time spacing until the next reading is taken.

If your readings are truly a measurement at a point in time, perhaps with some noise added, I don't think you can tell the difference between the two. If your readings are bouncing around a lot and you wait a longer time before the next one (16 seconds in your example) do you think it is close to 206 watts for all those 16 seconds?

The high-tech approach would be to install a low-pass filter to smooth out the data. You would want the time constant to be twice the time spacing between readings. Then it would take out noise and you could use FFT or polynomial fitting techniques. But if you are taking 1440 readings per day, any reasonable way of averaging is probably quite good.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.