Chapter 15 The PID function of K200S MASTER-K
15-13
15.3 Realization of PID control on the PLC
In this chapter, it will described that how to get the discrete formula of the P, I, and D terms.
Then, the pseudo code of PIF control will be introduced.
15.3.1 P control
The discrete formula of P control is as following;
)()()( nPVnSVbKnP −×= n : sampling number
K : proportional gain constant
b : reference value
SV : set value
PV : present value
15.3.2 I control
The continuous formula of I control is as following;
∫
=
t
dsse
K
tI
0
)()( I(t) : integral term
K : proportional gain constant
Ti : integral time
e(s) : deviation value
By deviation about t, we can obtain;
e
K
dI
= e = (SV – PV) : deviation value
The digitized formula is as following;
)(
)()1(
ne
K
nInI
=
h : sampling period
)()()1( ne
Kh
nInI +=+