Topic: DMD0138

Help File Version: 2.10.0.636

INTEGRAT - Integrate Over Time


The Integrate Over Time (INTEGRAT) instruction is used accumulate the value of the specified input location (this is typically a rate value) at a specified time interval. A typical example where this instruction is used flow meters where the number of rotations of the rotor is counted by a pulse transmitter and converted to volume and flow rate.

 

 

The instruction always integrates at a per-second rate, regardless of the Sample Time. The Sample Time changes the interval at which it integrates, and adjusts the amount added accordingly. For example:

 

Assume Scale Factor is 1 and Input is fixed at 1.

 

If Sample Time is 10000, then every 10.000 seconds, Integrate Into will add 10 to Integrate Into.

If Sample Time is 1000, then every 1.000 second, Integrate Into will add 1 to Integrate Into.

If Sample Time is 100, every .0100 milliseconds, Integrate Into will add 0.1 to Integrate Into.

 

The calculation performed at each Sample Time is:

Integrate Into = Integrate Into + (Input * (current Sample Time in seconds) * Scale Factor).

 


Parameters:

Note: Use the F9 key or click the 'three dot box' at the right edge of the parameter field to open the Default Element Selection Tool (the Element Picker or the Element Browser) or use the Down-Arrow key (Auto-Complete) on any parameter field to see a complete list of the memory locations that are valid for that parameter of the instruction.

 

Input is the numeric memory location that contains the value to integrate. This can be any readable numeric location.

 


Sample Time is the amount of time over which the integral value will be calculated while the instruction is enabled. The sample time has a resolution of 1 millisecond. The maximum value is 2,147,483,647 milliseconds. The Sample Time value can be specified in one of two ways:

Constant means the Sample Time is a fixed amount of time and can only be changed by editing the instruction. The Sample Time value is specified using the Time format (HH : MM : SS : mmm). The maximum Time value in this form is 569 hours, 31 minutes, 23 seconds, and 647 milliseconds. If needed, the value entered will be normalized to its standard value. For example, if you entered a value of 97 Seconds, that value will be converted and displayed as 1 Minute and 37 Seconds. When editing the Constant Preset value the following keystrokes are available to make entering the value easier and faster: h, m, s, and mm move the edit cursor to the Hours, Minutes, Seconds or milliseconds fields respectively.

 

Variable allows the Sample Time to be changed while the PLC is running. The Sample Time is specified as a numeric memory location that will contain the total number of milliseconds desired (from 0 to 2,147,483,647). This can be any readable numeric location.

 


Scale Factor specifies a scale factor that will be applied during the integral calculation. This can be any constant value or any readable numeric location. Normally this value is calculated based on the time units of the Input, and the desired units of the Integrate Into parameter.

 

Integrate Into is a memory location to store the integral value. This can be any writable numeric location.

 


Status Display:

 

The yellow triangle in the upper left corner indicates this is a Multi-Scan instruction.

 

The first input leg (EN) enables and disables the integration process. If this input logic is ON, the instruction will begin integrating. When this input logic is OFF, the instruction will stop integrating, but the Integrate Into value will retain it's current value. If this input logic comes back ON, the instruction will resume the integration process.

 

The second input leg (RST) is the Reset. If this input logic is ON the instruction will reset the Integrate Into value to 0.0.

 


See Also:

CLAMP - Limit Range

 

DEADBAND - Set Outside Deadband

 

FILTER - First Order Filter

 

INTEGRAT - Integrate Over Time

 

PID - Closed Loop Controller

 

SLOPE- Calculate Slope

 

TIMEPROP - Time Proportional Control

 


Rung Example: