Integrator

B113_INTEGRATOR

PROGRAM TEST B113
  VAR
  BOOL1,BOOL2 :BOOL;
  REAL1,REAL2,REAL3: REAL;;
  FB: LIB.CORE.V1_0.B113_INTEGRATOR; 
 END_VAR
 FB(IN:=REAL1, ENABLED:=BOOL1,RESET:=BOOL2,OUT=>REAL2,LASTY=>REAL3);
END_PROGRAM

LIB\CORE

V1.0

The block integrates the input signal in in time.

Input TypeDescription Default value
IN REALInput value 0
ENABLEDBOOLEnable of integrationFalse
RESET BOOLInput value reset False
OutputTypeDescription
OUT REALActual integrated value
LASTY REALResult before last reset

The function reads input value in and adds it to the output every second. This gives, for example, wattseconds if there are watts on the input. The integrated value is reset after a rising edge at the reset input, and integrates if Enabled=true. Reset copies the last integrated value to the lasty output.

The block is used for calculation of cummulated values, such as total amount of water (m3) from flow value (m3/s), energy (Ws or kWh) from power (W), solar energy from sun (kWh/m2/day) from instant irradiation (W/m2) etc.

  • © Energocentrum Plus, s.r.o. 2017 - 2024