02/12/2016
Hello,
After exploring OPC UA Aggregates specification & samples given Time Average and Total, I have the following basic question.
Input data(quality=good)
12:00:00 – 10
12:00:02 – 12
12:00:05 – 15
Could you please explain me the formula to compute the time average for the above interval 12:00:00 to 12:00:05 ?
Thanks & Regards
Samba
Moderators-Specifications
Moderators-Companion
Moderators-Implementation
Moderators-Certification
Moderators-COM
02/24/2014
Samba,
TimeAverage is a slopped line between all of the points in the interval – in this case the line has the same slope – which makes it easy to calculate. (10 + (15-10)/2). Which would yield a result of 12.5. technically it should be calculated by {([10 + (12-10)/2] * 2 ) + ([12 + (15-12)/2] * 3)} / 5 -> 12.5
In English, find the average value for the first sub interval – multiply it by the number of seconds (well actually milli-seconds – but since the time in the example is even second boundary – the calculation is identical) + find the average value for the second interval multiply by the number of seconds. Add the two sub intervals together and then divide by the total time. Note technically the number might be slightly different since the time stamps, might have more accurrancy in the clocks (milli-second time stamps)
Paul
Paul Hunkar - DSInteroperability
1 Guest(s)