Interpolation and calculation of consumption values
Interpolation is used to obtain consumption values as close to reality as possible, based on two meter readings. Suppose a reading is taken on March 1 showing 25,058 kWh, and a second reading on April 1 shows 25,158 kWh. The consumption for March is then 100 kWh, calculated as:
25,158 - 25,058 = 100 kWh
The example above assumes that the readings were taken exactly at the month turnover, i.e. March 1 at 00:00:00 and April 1 at 00:00:00. In this case, no interpolation is needed.
In practice, it is difficult to take a reading at the exact second. With manual readings, for example, it is common for the reading date to deviate several days from the month turnover. Automatic readings can also deviate due to technical problems.
If you were to calculate March’s consumption based on deviating readings taken on February 27 and March 3, the consumption would be higher compared to if both readings had been taken at the month turnover at 00:00:00. But with interpolation, you can calculate what the readings would have been if they had been taken at the month turnover.
Metry uses linear interpolation for all energy types - just like the highly regulated electricity industry. Metry also has separate calculation of hourly, daily, and monthly values for the best possible quality, and dynamic interpolation per metering point.
Linear interpolation
Interpolation means calculating a reading value for, for example, a month turnover based on two deviating readings taken before and after the month turnover. Linear means that the calculation assumes that consumption between the two deviating readings was completely even.
Interpolations are always estimates that are not the same as reality. But they are close to reality and linear interpolation is the method that the industry considers good enough.
Separate calculation of consumption values
Normally, consumption is calculated for the highest desired resolution (hourly) and the underlying hours are then summed to daily or monthly values. This works excellently as long as there are no gaps in the readings.
Example of problems with summation-based calculation
When (not if!) gaps occur, problems arise. The images below show the three most common problems with summation-based calculation.
![]() | The consumption within the gap ends up on the last hour. Hourly values are completely wrong, but the summed monthly value is correct (100 kWh) |
|---|---|
![]() | The consumption within the gap is distributed evenly. The monthly sum is correct, but the evenly distributed hourly values are misleading and far from reality. |
![]() | The gaps are marked as missing. All hourly values are correct, but the monthly sum is too low. |
Separate calculation
Metry instead uses separate calculation of consumption values, which means that all reported hourly, daily, and monthly values are correct.
![]() | The gaps are marked as missing. All hourly values are correct. The monthly value is also correct because it was calculated from 2 readings instead of the sum of the hourly values. |
|---|
Dynamic interpolation
Dynamic interpolation means that the rules for when an interpolation should be made depend on the circumstances. Without dynamic interpolation, a system set to hourly values, for example, would always interpolate hourly readings - even if there are only 2 readings during a month. This would mean the system would calculate 720 hourly readings where a calculation of hourly values would give exactly the same hourly value throughout the entire month.
With dynamic interpolation, you can set how large a deviation is allowed. If an interpolation falls outside the limit, a missing hourly value is created instead. By default, Metry allows deviations according to the table below - but this can be configured per metering point (contact support@metry.io ). It is also possible to force interpolation.
Default deviation times for automatic interpolation
- Hourly values: 20 minutes*
- Daily values: 8 hours*
- Monthly values: 7 days*
*The deviation time is the maximum allowed time distance to the nearest actual reading.
