Determining Expected Value

The Archive Compression algorithm calculates the expected value from the slope, time, and offset (a combination of previous values and its timestamp):

ExpectedValue = m_CompSlope * Time + m_CompOffset;

Where

m_CompSlope = deltaValue / deltaT
m_CompOffset = lastValue - (m_CompSlope * LastTimeSecs)

Determining Expected Value

Values arriving into the archiver for tag1 are

Time Value
t0 2
t0+5 10
t0+10 20
The expected value at time stamp t0+15 is calculated based on the samples at t0+5 and t0+10:
m_CompSlope = deltaValue / deltaTime m_CompSlope = (20-10) / 5
m_CompSlope = 2
m_CompOffset = lastValue - (m_CompSlope * LastTimeSecs)
m_CompOffset = 20 - (2 * 10)
m_CompOffset = 0
ExpectedValue = m_CompSlope * Time + m_CompOffset; 
ExpectedValue = 2 * 15 + 0;
ExpectedValue = 30

The expected value at t0+15 is 30.

Archive Compression of a Ramping Tag

An iFIX tag is associated with an RA register. This value ramps up to 100 then drops immediately to 0.

Assume a 5-second poll time in Historian. How much archive compression can be performed to still "store" the same information?

With an archive compression of 75%, 25% or 5%, only the change in direction is logged:
11-Mar-2003 19:31:40.000 0.17 Good NonSpecific
11-Mar-2003 19:32:35.000 90.17 Good NonSpecific 
11-Mar-2003 19:32:40.000 0.17 Good NonSpecific
11-Mar-2003 19:33:35.000 91.83 Good NonSpecific 
11-Mar-2003 19:33:40.000 0.17 Good NonSpecific 
An archive compression of 1% stores the most samples.

An archive compression of 0% logs every incoming sample. Even on a perfectly ramping signal with no deviations, 0% compression conserves no storage space and essentially disables archive compression.

Archive Compression of a Drifting Tag

A drifting tag is one that ramps up, but for which the value barely falls within the deadband each time. Even though a new held sample is created and the current one discarded, the slope is not updated unless the current slope exceeded. With a properly chosen deadband value, this is irrelevant: by specifying a certain deadband, the user is saying that the process is tolerant of changes within that deadband value and that they do not need to be logged.

Archive Compression of a Filling Tank

In the case of a filling tank, the value (representing the fill level) ramps up, then stops. In this case, the system also uses collector compression, so when the value stops ramping, no more data is sent to the archiver. At some point in the future, the value will begin increasing again.

As long as nothing is sent to the archiver, no raw samples are stored. During this flat time (or plateau), it will appear flat in an interpolated retrieval because the last point is stretched. This illustrates that you should use interpolated retrieval methods on archived compressed data.