MeanToInstantaneous


disaggregates data

Input
  • inputVariable
Output
  • outputVariable
Description

This transformation takes a mean input time series as input and transforms it to an instantaneous time series. Because it is not possible to calculate exactly how the instantaneous values were which resulted in this mean time series, the transformation will make a best estimate of the instantaneous time series.

The first step in this procedure is analysing the previous mean value, the current mean value and the next mean value.

No change  

If there is no significant rise in these values, which is the case when the current mean value is the same as the previous mean value and the next mean value within an error tolerance of 0.1% the current mean value is considered to be the best estimate for the instantaneous values.

If this is not the case, the procedure checks if there is a continuous rise or fall or if the mean values are in a peak or valley.

Rise or Fall

If the mean values are in a continous rise (currentMeanValue >= previousMeanValue && currentMeanValue <= nextMeanValue) then the estimation procedure is as follows.

First the instantaneous value at the end of the disaggregation period is estimated by

Fall: endValue = currentMeanValue - 0.75f * (currentMeanValue - nextMeanValue)

Rise: endValue = currentMeanValue + 0.25f * (nextMeanValue - currentMeanValue)

The values between the value at the end of the previous disaggregation period and the estimated end value are estimated by creating a small rise or fall from the end value.

Peak or Valley

First the value of the peak or valley is estimated

peak = currentMeanValue + 0.25f * (difma + difmb) / 2

difma = |previousMeanValue - currentMeanValue|

difmb = |nextMeanValue - currentMeanValue|

Secondly the place of the peak is estimated. This will be done analysing the ratio between difma and difmb.

When the value and the place of the peak are estimated the values between the peak and the end value and the last value of the previous period are added

by adding a small rise or fall to/from the peak.

After this procedure the estimated instantaneous values are corrected by using the AdjustQMeanDailyDischarge-transformation (a volume correction). This transformation will ensure that the mean values of the estimated instantaneous time series are equal to the orignal mean values.  

Configuration example

	<transformation id="disaggregation imeanToInstantaneous">
		<disaggregation>
			<meanToInstantaneous>
				<inputVariable>
					<timeSeriesSet>
						<moduleInstanceId>ImportTelemetry</moduleInstanceId>
						<valueType>scalar</valueType>
						<parameterId>Q.obs</parameterId>
						<locationSetId>hydgauges</locationSetId>
						<timeSeriesType>external historical</timeSeriesType>
						<timeStep unit="minute" multiplier="15"/>
						<relativeViewPeriod unit="day" startOverrulable="true" start="-7" end="0"/>
						<readWriteMode>read only</readWriteMode>
					</timeSeriesSet>
				</inputVariable>
				<outputVariable>
					<timeSeriesSet>
						<moduleInstanceId>Aggregate_Historic</moduleInstanceId>
						<valueType>scalar</valueType>
						<parameterId>Q.obs_disaggregated</parameterId>
						<locationSetId>hydgauges</locationSetId>
						<timeSeriesType>external historical</timeSeriesType>
						<timeStep unit="minute" multiplier="5"/>
						<relativeViewPeriod unit="day" startOverrulable="true" start="-7" end="0"/>
						<readWriteMode>add originals</readWriteMode>
					</timeSeriesSet>
				</outputVariable>
			</meanToInstantaneous>
		</disaggregation>
	</transformation>
  • No labels