Professional Documents
Culture Documents
&
(1)
- 11 -
Figure 5 Nonlinear Function Track
Where e, e
and e& represent the error, the integration of the error, and the
derivative of the error, respectively. Kp is the proportional gain, Ki is the integral gain
and Kd is the derivative gain. u is the controller output. ( , , ) fal e is a nonlinear
function illustrated in Figure 5, which is defined as:
1
( ) , when
( , , )
, when
sign e e e
y fal e
e e
>
= =
(2)
Where e is the error input and y is the output. The and terms are two
*parameters of the nonlinear function. Usually, is choosing between 0 and 1 (0<1).
When = 1, it is exactly the linear function of y = e. is a small positive number applied
(*?)to create a small linear area in this nonlinear function when e is approaching 0. This
is to avoid infinite high gain in the neighborhood of the set point, which could lead to
*numerical problems, cause system easily unstable.
The idea of the NPID controller is to use a nonlinear combination of e,
e
and
e&
in place of the linear one in the classical PID controller. The fal (e, , ) function is an
exponential function and is the exponent. The fal function can achieve small error with
- 12 -
limited high gain (in small area ), big error with low gain. This algorithm makes it easy
to remove overshoot in the transient stage (with high error and low gain) and get strong
*disturbance rejection after settling (with small error and high gain)
In practice, most of the objectives have nonlinear features. Classical PID
(*?)controller wont quite qualify to handle the control requirement efficiently. One
*approach is to linearize the system dynamically, i.e., to approximate the nonlinear model
by a serial of linear ones. Based on the dynamically linearized models, several
*linearization-based PID controller can be designed at many operating conditions and
*then interpolate the local designs to yield an overall nonlinear controller. This procedure
*is known as gain scheduling [12]. It is an intuitively appealing but heuristic practice,
*which is used in a wide variety of control applications on nonlinear objectives. The
main goal that gain scheduling wants to achieve is to give high gain for small errors and
*small gain for large errors thought the whole nonlinear region. The novel NPID
controller just uses an exponential function to implement this idea simply and
*systematically. The tuning of a NPID controller is similar to tuning a PID controller,
which can be done on-site to achieve better performance based on test results. The
*simulation results in next chapter show that a NPID controller for a PWM DC-DC
power converter (an exact nonlinear system) achieves better performance than a classical
PID controller, and has strong robustness dealing with the large variations of line and
load change.
A fuzzy controller also can achieve the above requirement, but it is much more
complicated than the fal function algorithm.
*A normal NPID configuration is as below [8]:
- 13 -
Figure 6 NPID configuration
Where r(t) and ( ) r t & are the desired trajectories for y(t) and ( ) y t & respectively. The
*Reference Generator idea comes from motion profile, which is popular applied in
(*?)motion industrial. Such a method is not only practical to provide better control on the
position, but also to its velocity and acceleration. The reference is generated outside the
control loop and therefore, has no impact on the dynamic response and the system
stability [12].
2.2 NPID Control Design
*Based on the novel NPID method that we discuss at the last section, we can
*design a NPID controller for a PWM DC-DC Power Converter. In this case, we use a
*2nd order linear model to approximate the nonlinear power converter as below:
() yt
&
%
Reference
Generator
Plant
Differentiator
+_
+_
Nonlinear
Combination
dt
setpoint
() rt
() yt
%
() rt
&
() yt
() et
&
() et
edt
()
d
yt
- 14 -
2
( )
* * 1
p
l
G s
m s n s
=
+ +
(3)
*We will derive our NPID controller from classical PID controller.
2.2.1 PID initial tuning parameter setting
Using a simplified 2
nd
order model, the PID controller parameters can be obtained
by a direct calculation using pole placement. There are 3 parameters in the model
Equation (3). By using a PID controller, which also has three parameters, it is possible to
arbitrarily place the three poles of the closed-loop system.
The approximate derivative term is implemented using a /( / 1) s s N + transfer
function block. Making N large can create a "stiff" system.
We can assume to design a controller, and its transfer function is described as:
2
*
( )
/ 1
( * / / ) * ( * / 1)*
*
*
i d
c p
d i p i p i
i
K K s
G s K
s s N
N K K K K s N K K s N
K N
s s N
= + +
+
+ + + +
=
+
(4)
By using pole placement design concept, we can make
( ) * ( ) / *( )
c p
G s G s k s s N = + (5)
Figure 7 Closed-Loop configure
In a closed loop, we get
2
( ) ( ) * ( ) /(1 ( ) * ( )) /( * )
c p c p
G s G s G s G s G s k s N s k = + = + +
- 15 -
A suitable closed-loop control is to get a critically damped impulse response with
an assigned settling time
s
T . An approximation for the settling time that will be used is
4/
n
s
T = . Here is Damping Ratio, and
n
is Natural Frequency.
2 2 2 2
( ) /( * ) /( 2* * * )
n n n
G s k s a s k s s = + + = + +
For a critically damped output, we choose 1 = , then 4/
n s
T = , To identify the
coefficients in the above equation, we can determine the parameters , k a .
2
n
k = ,
2* * 2*
n n
N = =
According equations (3) (4) (5), we get
2
2
2
( / / / )* ( / 1/ ) * 1
*
( )* ( ) * *
* * 1
*( )
*( )
d i p i p i
i
c p
n
K K K K N s K K N s
K N l
G s G s
s s N m s n s
k
s s N
s s N
+ + + +
=
+ + +
=
+
=
+
After simply the equation, we get
2
2 2
( / / / ) * ( / 1/ ) * 1
* *
* 1
* * 1
d i p i p i
i
n
K K K K N s K K N s
K N l
m s n s
+ + + +
=
+ +
So
2
* 2*
n n
i
K
N l l
= =
1
*
2*
p
d
i i n
K
K
m
K K
+ =
1
2*
p
i n
K
n
K
+ =
Further we get
2
*
i
s
K
l T
=
2
*
64 8
d s s
i
K T n T
m
K
= +
8
p
s
i
K
T
n
K
= (6)
- 16 -
The above
, , , p i d
k k k relationship can give us rough initial setting startup
parameters.
After we can get nice tuning with PID controller, the data will be the initial setting
for nonlinear PID controller. From the fal function, we know that we choose 1 = , and
then the nonlinear fal function is equivalent to linear function.
2.2.2 NPID Design
NPID control law:
( , , ) ( , , ) ( , , )
p p p p i i i i d d d d
u K fal e K fal e dt K fal e = + +
&
1.Proportional Control part:
) , fal(e, * Kp p p
>
=
p e p e
p e e sign e
p p
p
p
1
/
) (
) , fal(e,
2.Integrate Control part:
) , fal(e, * Ki i i
>
=
i e i e
i e e sign e
i i
i
i
1
/
) (
) , fal(e,
3.Differentiate Control part:
) , , e fal( * Kd d d &
>
=
d e d e
d e e sign e
d d
d
d
& &
& & &
&
1
/
) (
) , , e fal(
For the proportional and the integral part, a commonly used value for is around
0.5, which gives a nonlinear mapping between e and y shown in Figure 5. Compared with
the linear function y = e, the nonlinear function fal (e, , ) gives high gain for small e
- 17 -
and small gain for large e. This strategy will help solve the integral wind-up problem,
which is frequently faced in practice. A commonly used value for is related to system
nature behavior and the actual noise status where the equipment is installed.
Recommended value is around 0.5 percent of the set point value. Too small, you will get
quite big gain setting, and it is easy to get oscillation; too big, it will approach to
traditional PID, and it will lose the benefit that nonlinear control brings to the system.
The principle here is to tune as small as possible.
For the derivative part, this item usually is used to prevent output from
overshooting during the error is large, and when system is nearly to get steady, it does not
help much for control, on the contrary it is more sensitive to noise to cause system
unstable. So by choosing
d
> 1, it makes the derivative gain small when error is small,
big when error is large.
d
Setting is related to noise level and step size of sampling.
Usually, we set / 2/
d p p
Vnoise h
> . Here h is step size of sampling,
p p
Vnoise
is peak-
to-peak voltage of the noise.
In practice, the pure differentiator is too sensitive to noise without any prevention
that it doesnt apply in industrial. Many approximated differentiator are proposed, and in
this case we will choose a Tracking Differentiator [8] to get the derivative signal for
NPID.
2.2.3 Tracking Differentiator
Based on the bang-bang control concept, a nonlinear filter-differentiator denoted
Tracking Differentiator(TD) is proposed by J. Han as
- 18 -
1 2
2 2
2 1
( ( ) )
2
x x
x x
x Msign x v t
M
=
= +
&
&
(7)
Where the output y =
1
x tracks the reference input v(t) in shortest time possible without
overshoot. Here M represents the maximum acceleration the system can obtain and is a
function of the maximum actuation available in the system.
2
x is the approximated
derivative signal of v(t).
It was shown [10] that 0 > and 0 > T 0
0
> M such that if
0
M M >
<
dt t v t x
T
0
1
) ( ) ( . Here, the only design parameter of the filter is the gain M, which
corresponds to the upper bound of acceleration, if
1
x can be viewed as a position signal.
Parameter
1
x
can track v(t) arbitrarily fast as long as M can be chosen arbitrarily large. The
parameter
2
x is the derivative of
1
x
and therefore it approximates the derivative of v(t),
even though it may not exist at certain points.
To improve the numerical properties and avoid high frequency oscillations, a
discrete time realization of TD was derived from equation (7). [10]
+ = +
+ = +
) , ), ( ), ( ), ( ( ) ( ) (
) ( ) ( ) (
2 1 2 2 2
2 1 1
h r t v t v t v fst h t v h t v
t v h t v h t v
(8)
Where v
1
and v
2
are the state variables, v(t) is the input signal, h is the step size and
the function fst
2
is defined as:
h r d = ; h d d =
0
;
2 1
v h v v y + =
y r d a 8
2
0
+ =
- 19 -
+
< +
=
0
0
2
0 2
,
2
) )( (
,
d y
d a y sign
v
d y
h
y
v
a (9)
>
=
d a a sign r
d a
d
a
r
fst
), (
,
2
The impact of TD is profound. First, as a noise filter, it blocks any part of the
signal with acceleration rates exceeding M. In practice, we often know the physical
boundary of a signal in terms of its acceleration rate. This knowledge can be conveniently
incorporated into TD to reject noise based on the understanding of the physics of the plant.
On the other hand, the traditional linear filter can only attenuate noises based on its
frequency contents.
Secondly, it is shown [6] that as a filter TD has a very desirable frequency response
characteristic. In particular, it has a much smaller phase shift compared to linear filters,
while maintaining an extremely flat gain within the pass band.
Finally, perhaps the most important role of TD is its ability to obtain the derivative
of a noisy signal with a good signal to noise ratio. It is well known that a pure
differentiator is not physically implementable. The error is often not differentiable in
practice due to the noise in the feedback and the discontinuities in the reference signal.
This explains why the PID controller is used primarily as a PI controller in most
applications. The use of the D part has been quite limited due to the extreme
amplification of noise by differentiation, or its approximations. This noise problem is
resolved in TD because
2
x is obtained via integration. This idea of using integration to
obtain differentiation goes back to 1920s when N. Wiener proposed the definition of
- 20 -
fractional differentiation based on integration. It leads to the concepts of generalized
function and generalized derivative, which were used widely in the theory of partial
differential equations.
As we discuss at above that M represents the maximum acceleration the system can
obtain. It is the only parameter we need set for TD. In theory, M is better to set as big as
possible.
2.2.4 A Practical NPID Design
Normal NPID gives us a great high gain when error is small. Even it provides us
good disturbance rejection and robustness during the small steady state error, but it may
make the controller too sensitive to noises. Therefore, a compromise is made between the
nonlinear proportional control and a limited nonlinear integral control.
For proportional term, we reformulate it into the G-function, which is a nonlinear
gain function shown in Figure 8, where the green line is normal linear gains and the blue
line represents the nonlinear G function. The design philosophy is fully explained in
[13]. Here, the intuition is that the gain should be higher when the error is smaller, which
makes the controller more stiff. That is, the proportional control is made more
sensitive to the small errors. This will also reduce the reliance on the integral control to
eliminate steady state errors. Note that the instability is often caused by the 90-degree
phase lag in the integral control.
- 21 -
Figure 8 G-Function
It is mathematically expressed as:
2 1 2
p p
1
* ( )* *sgn( ) | |
k *G ( ) ( )
* | |
p p p p p
p
p p
k e k k e e
e G e
k e e
+ >
=
(10)
For proportional part, when you switch your controller from linear PID to NPID,
it is good way to keep
1
1
p
k = ,
2 p
k default is 0.2, and
p
default is 0.5. At Next step, you
can tune
p
k as big as possible and fine tune
2 p
k and
p
as small as possible.
At the beginning high gain of integral control will cause overshoot, wind-up and
phase lag problem. The main purpose for using integral control is to eliminate the steady
state error, so we simplify the integral controller as below:
i i 2 1 2 i
1 i
i
k * G ( ) * ( ) * *sgn( ) | | G ( ) * 0
( )
* | | G ( ) * 0
k *0
i i i i i
i
i i
e dt k e k k e e e e
G e
k e e e e
+ >
=
<
(11)
That is, the integrator only integrates when the error is small, typically when the
output is within 10% of the set point. This design strategy allows the control to
effectively avoid undesirable overshoots and the integrator wind-up during transient
stage. Even the above fal function can make small gain during big error. But because
continuity of fal function and the converter systems huge requirement for integral gain to
eliminate steady-state error, it is difficulty to tune the integral gain to a low level when
- 22 -
error is big. The above-modified nonlinear integral control can effectively solve this
problem.
For integrate part, when you switch your controller from linear PID to NPID, it is
good way to keep
1
1
i
k = ,
2 i
k default is -5, and
i
default is 0.5. At Next step, you can
tune
i
k as big as possible, and fine tune
2 i
k and
i
as small as possible.
We also using G function and damping concept to simplify the differentiate
control [13]
2 1 2
d d
1
*( ) ( ) * *sgn( ) | |
k *G ( , ) ( )
*( ) | |
d d d d d
d d
d d
k y k k y y
y G y
k y y
+ >
=