You are on page 1of 6

Copynght © IFAC ArtificIal Intelligence In Agnculture,

Makuhan , Chiba, Japan, 1998

AN INTELLIGENT CONTROL TECHNIQUE BASED ON FUZZY CONTROLS,


NEURAL NETWORKS AND GENETIC ALGORITHMS
FOR GREENHOUSE AUTOMATION

Tetsuo Morimoto and Yasushi Hashimoto

Dept ofBiomechanical Systems, Ehime University, Tarumi, Matsuy ama, 790, Japan

Abstract: To overcome the complexity and uncertainty of agricultural systems, a new


intelligent control technique, which mimics empirical human thinking and actions by
employing a fuzzy controller and two optimizers, is proposed. The control input is
environment (relative humidity) during storage and the control output is fruit responses
(water loss and skin color). The main controller is a fuzzy controller. Two optimizers I
and 11, consisting of neural networks and genetic algorithms, search for optimal I-steps
of setpoints of the environment and make an optimal tuning of a fuzzy controller
through simulations of the corresponding neural-network models. The complexities of
the measured data are first evaluated by the concept of chaos for identification. It is
found that this control technique was quite useful for the sophisticated controls of
agricultural systems such as agricultural robots. Copyrzght © 1998 1FAC

Keywords: Optimization, agricultural systems, chaos, fuzzy logic control, neural


networks, genetic algorithms

1. INTRODUCTION For identification, it is important to measure the


complexity of the data. This one becomes possible by
In recent years, due to the shortage of expert growers introducing the concept of chaos (Crutchfield et aI. ,
and requests of higher quality of fruit in agriculture, 1986; Ditto and Pecora, 1993). High complexity,
more effective control techniques are severely near random, of the data prevent their identification
required in greenhouses and plant factories. The (or modeling) performances (Matsuba, 1991). It has
automation of plant production processes, including been reported that plant responses such as a net
storage process, makes up the labor shortage. photosynthetic rate can be regarded as chaos
(Hirafuji and Kubota, 1994; Shabala et al. , 1997). If
In general, however, it is difficult to realize the plant (or fruit) responses are evaluated to be chaos,
optimization of plant production processes because they can be described by mathematical equations. It
they can be defined as ill-defined processes looks, however, that actual plant (or fruit) responses
characterizing by nonlinearity and time-variation. have two properties; chaos and randomness. Against
They also include many unknown factors in their such systems, the use of neural networks seems to be
own systems. So, actual plant responses we can more effective than that of mathematical approaches.
measure look quite complex and uncertain. We can Anyway, identification and prediction become
indeed never observe the same responses as their possible if the data can be defined as chaos, not
previous ones even under the same condition. These random. It is noted that uses of any scientific
uncertainties probably arise from their own approaches become impossible if they were evaluated
physiological nonlinerity, disturbances and noises. to be completely random.

61
le
In order to realize the optimization of complex L.n(-c) = l: { Iy(m +i-c) - y(m +(i-I)-c) I' Norm I"t }
m=J
systems, it might be essential to mimic expert
grower's skills and thinking because they can treat Norm = (iV-I)! [(iV-m)/-c] . -c
complex systems such as plant and fruit successfully Mn = [(iV-m)I"t], [ ]: Gauss' notation
based on their own intuition and experience without
any priori information. 2.2 An Intelligent control technique

It is well known that intelligent approaches such as Figure 1 shows an intelligent control system which
neural networks, genetic algorithms and fuzzy consists of a fuzzy controller and two optirnizers I
controls are effective tools for imitating the skilled and IT comprising neural networks and genetic
grower's actions and strategy. We have developed algorithms. An optimizer I determines optimal
several types of optimization techniques for setpoints of the environment based on fruit (or plant)
cultivation and storage processes using intelligent responses and an optimizer 11 optimizes parameters
approaches (Morimoto et al., 1996 and 1997a). of a fuzzy controller, such as membership functions
and control rules. Comparing the control perform-
This paper presents a new intelligent control ances in various types of membership functions and
technique to achieve optimization of agricultural control rules, their optimal patterns are selected from
systems with the sophisticated actions. In the method, among them (Morimoto et 01. , 1997b).
fuzzy control, neural networks and genetic
algorithms are successfully employed for mimicking The feature of this algorithm is to mimic human
the learning, decision and actions of a skilled grower. thinking processes in decision and actions through
Then, it was applied to two optimization problems. three steps: identification using neural networks
One is an optimization of relative humidity during (="learning"), search for an optimal value using
the fruit storage process and the other is an genetic algorithms (="decision") and actions using a
optimization of a fuzzy controller to optimally fuzzy controller ("action"), in order to realize
control the relative humidity. optimization.

2. INTELLIGENT CONTROL TECHNIQUE (1) Fuzzy controller


Fuzzy control techniques seem to be effective for
2.1 Chaos and fractal dimension controlling complex ill-defined systems, in which a
Plant responses measured by sensors contain noise skilled human operator plays an important role,
and disturbance and, furthermore, have their own because they can quantitatively treat the expert
physiological uncertainties. Before implementing knowledge of a skilled grower by using membership
identification (modeling), therefore, it is important to functions and linguistic control rules (Lee, 1990a). A
investigate the complexities of such data and main controller is a fuzzy logic controller which
possibilities for identification. In this study, the performs sophisticated controls of the environment in
concept of chaos is introduced to evaluate the the storage chamber, based on the optimal setpoints
complexities of the measured data, aiming at better determined by an optimizer I.
identification (modeling) (Crutchfield et al. , 1986;
10,_ _ 1
Ditto and Pecora, 1993). If the data were evaluated to 1
"Decwon"
Sean:h for optimal setpoUlts
be chaos, they can be successfully identified using of envu-onment
scientific approaches such as neural networks. If they (GeMIc: Illcorf11ua)

are evaluated to be random, in contrary, their


identification are impossible.

Let {y(l), y(2), ... , y(N)} be the time series of the


data. Attractor is a geometric form ploUed in the
topological space of (y(m) , y(m+t), y(m+2-c), ... ,
y(m+[(N-m)l"t] -c) (m : initial time, -c: time lag). On the
other hand, the fractal dimension, D, was calculated
according to Higuchi's method (Higuchi, 1988) as
follows.

D = - log L(-c) / log -c Fig. I. An intelligent control system consisting of a


Mn fuzzy controller and two optimizers, I and 11,
L(-c) cc -c- D , L(-c) = II"t l: Lm(-c) which are both composed of neural networks
I= J
and genetic algorithms.

62
Fuzzy reasoning and defuzzification: A fuzzy evolution. Each individual represents a candidate for
reasoning was conducted based on Mamdani' s an optimal solution (one possible solution to the
minimum operation rule. A center of area method problem). If the solution consists of mth decision
which calculates the center of gravity of the variables {x), X2, ... , x.n}, then the individual can be
possibility distribution of a control action was used defined as {XI , X2, ... , xm}. A set of individuals is
for defuzzification (Lee, 1990b). called a "population".

(2) Optimizers I and 11 Cording: The second step is to code all individuals as
Optimizers I and IT, consisting of neural networks finite-length binary strings to promote efficiency of
and genetic algorithms, respectively find optimal genetic operations.
setpoints of environment and tune a fuzzy controller
optimally through simulation of their identified Fitness: Fitness is an indicator for measuring
neural-network models using genetic algorithms individual's quality for survival. Its concept is
(Morimoto et al., 1996, 1997a and 1997b). similar to that of an objective function in
conventional optimization problems. Relatively good
(3) Neural networks individuals with higher fitness reproduce, and
Neural networks are shown to be effective to perform relatively bad individuals with lower fitness die
nonlinear mappings in patterns of information. They during evolution. An individual with maximum
mimic the biological human learning process and fitness means an optimal solution (Holland, 1992).
can identify nonlinear relationships between inputs
and outputs of a system with their own high learning Procedure : Figure 2 shows a procedure of the genetic
abilities (Hunt, et al. , 1992). In an optimizer I, the algorithm. Step 1: The initial population consisting
neural network is used for identifying fruit responses, of Ni types of individuals is generated at random.
as affected by environment, during storage. In an Step 2: No types of individuals are added to the
optimizer 11, on the other hand, it is used for original population from another population. Step 3:
identifying the storage environment, as affected by Genetic operations, crossover and mutation, are
manipulated variables (e.g., ventilation), aiming at applied to those individuals. Through the crossover,
the model simulation for controller alternation. The Ne sorts of individuals are newly created according to
learning algorithm of the neural networks is error the crossover rate Pe and, then, Nm sorts of
backpropagation (Rumelhart et aI. , 1986). individuals are newly generated according to the
mutation rate Pm. From these operations, N (=Ni
Model structure: The system parameter number, n, +No+Ne +Nm ) types of individuals are obtained. Step
4: The fitness of all individuals is calculated using
and the hidden neuron number of the neural network,
the identified neural-network model. Step 5: Nr
nh, were determined through cross-validation and,
individuals with higher fitness are selected and
also, based on AlC (Ljung and Glad, 1994).
retained for next generation. An optimal value can be
obtained by repeating these procedures.
AlC = - 2In (maximum likelihood) + 2n

The data sampled were divided into two data sets:


training data set for training the neural network and
the test data set for evaluating the model accuracy.

(4) Genetic algorithms


...
' .. ...
--... ,.
AaolMr .

'

•• • ••
Genetic algorithms are effective tools for finding an
optimal value in complex optimization problems.
They mimic the biological evolutionary process and
searches for an optimal value in parallel with a
multi-point search procedure, based on crossover and
mutation in genetics (Goldberg, 1989; Holland,
1992). Here, optimal setpoints of the environment
during storage (problem I) and optimal membership
functions and control rules in a fuzzy controller
(problem 11) are sought through simulation of the No

identified models.

Definition of individual: The first step in the GA


application is to define an "individual" for genetic Fig. 2 Search algorithm by genetic algorithm.

63
h(k) ~ Output (hI, .. ., hi), each parameter in an individual is
Input . expressed with 7-bit binary strings as follows:
[
h(k-n)

\'.b(k-I)
, . . ., hi = 0000101 . . . . 111000 1
Individual= hI'

3.2 Optimization of a fuzzy controller


Problem II: The optimization problem 11 is to select
Time delay optimal membership functions and control rules of a
Time delay
fuzzy controller to optimally maintain the optimum
setpoints of the storage environment determined by
an optimizer I. Comparing the control performances,
Fig. 3. A three-layer neural network for identifying
the optimal patterns of membership functions and
dynamic responses of the water loss Wh(k) and
the fungal development Dh(k) of fruit, as control rules are selected. In this study, the control
affected by relative humidity h. input is the on-off operations of ventilation. An
objective function, F2 , representing the control
performance, is the error between the desired value
3. OPTIMIZATION PROBLEMS AND and the response of the relative humidity as follows :
OPTIMIZERSTRUCTURES N
F = L: ( h(k) - 85 )2
An intelligent approach proposed here is applied to k=l
two optimization problems in the fruit-storage where h(k) is the dynamic response of the relative
process. humidity, as affected by the on-off of ventilation. The
aim in problem 11 is to select optimal membership
3.1 Optimization of storage environment functions and control rules which minimize the
objective function. The control input (on-offtimes of
Problem I: The most severe disorder during storage
ventilation) are determined through fuzzy reasoning.
seems to be the wilting of fruit. A higher humidity
The on-off control, which means a control based on
prevents the evapotranspiration of fruit. However, a
the on-off of input, seems to be the simplest control
continuously high humidity induces putrefaction
technique.
caused by fungi . So, it is found that an optimal value
of relative humidity does exist for the storage. From
Figure 4 shows the membership functions to be tuned.
these findings, an objective function FI(h) (h=h(k):
These functions have very simple and common
relative humidity, k=l , 2, ..., N: sampling time, N:
shapes. In this fuzzy reasoning, the operational time
data number) was defined as follows:
(=on-time) of the ventilation (T) is estimated from
N the error (E) between the desired value and the real
FI(h) = 1 / ~ (u'Wh (k) + f3'D h (k») response of the relative humidity and its change rate
k=l
(Iill) . E: {AI= "low (L)" , A2="medium (M)" and
where Wh(k) and Dh(k) are dynamic responses in the A3="high (H)"} , Iill: {BI= "negative high (NH)",
water loss and the fungal development of the fruit, as B2="zero (ZERO)" and B3= "positive high (PH)"} ,
affected by relative humidity h (u, f3 : coefficients). T : {CI="zero (ZERO)", C2= "short (S)", C3=
"medium (M)" and C4= "slightly long (SL)" Cs=
Thus, an optimization problem I is to determine "long (L)"}. Parameters on the x-axis (a, b and c) are
optimal I-step setpoints of relative humidity whi~h respectively basic values for shaping the three types
maximize FI (h). The FI (h) is also used for fitness m
of membership functions. We assumed that the
the genetic algorithm application. membership functions on E, Iill and T are
respectively shaped by the multiples of the
Neural network architecture: Figure 3 shows a 3-
corresponding basic values a, b and c.
layer neural network in the case of identifying the
dynamic responses of Wh(k) and Dh(k). The current Figure 5 shows the matrix for control rules. Here,
outputs, Wh(k) and Dh(k), are estimated from the only three output fuzzy sets, XI , X2 and X3, in the
(n+ 1)th historical input data {h(k), ..., h(k-n)} and
row, A2 , are objects for the tuning. Optimal values of
the two nth past historical output data {Wh(k-l), ... , the three basic parameters (a, b and c) in the
Wh(k-n)} and {Oh (k-l), ..., Oh (k-n)} . membership functions and three fuzzy sets (XI , X 2
and X3) are determined so that the objective function
Genetic algorithm architecture: Since an optimal becomes minimum. Hence, the decision variable is
value is given by I-step setpoints of relative humidity given by six parameters (a, b, c, XI, X2 , X3).

64
Grade ofmemberslup Grade of memberslup 4. CONTROL PERFORMANCES

The optimal setpoints of the relative humidity are


determined using an optimizer I. Figure 6 shows the
time series of the optimal setpoints of the relative
humidity and the corresponding control
performances (simulation results) of the water loss

~
Wh(k) and the development of lesion ~(k) under
different division number, 1(/=1, 2, 3 and 4), of the
control process. Figure 7 shows comparison of the
values of the objective function. From the figure,
°0 t le le .(C: "'x
optimal setpoints in the 2-, 3- and 4-step divisions
Operal1OnaI time of ventilation, T have a same tendency, which have a slightly low
humidity during the first few days after storage and
Fig. 4. Membership functions of the error E, the then higher humidity. Also, the values of fitness were
change rate !lE, and the operational time T of the larger in the 2-, 3- and 4-step division than in the 1-
ventilation. step division. This shows that, for storage
optimization, a flexible control is more effective than
a constant control for realizing the qualitative
~ Low Med High
improvement of fruit.
Negative M
High
ZERO Xl
Next, a fuzzy controller, optimally tuned by an
ZERO ZERO X2 SL optimizer 11, controls the relative humidity at the
Possitive S L
High X3
0.8 r--------------,
......... I ....tep division
- - - 2....tep division
Fig. 5. A matrix representing the control rules. lO.6 - f t - 3 ....tep division

- - 4....tep division ......


] 0.4
Thus, an optimization problem 11 is to determine Is
optimal fuzzy parameters of (a, b, c, XI, X2, X3) ~ 0.2
which maximize F2 (h). The F2(h) is also used for the
fitness in the genetic algorithm application.
2 3 4 5 6 7 8
Days after storage
Neural network architecture: A three-layer neural
network was used for identifying the dynamic ~
N
1500
......... l-stcp division
responses of the relative humidity h(k), as affected by
ventilation (single input and single output system). !ii 1000
- - - 2-s!cp
- f t - 3-stcp
division
division
e - - 4-stcp division
j
Definition of individual: In the optimization 11,
since the decision variable is given by three basic ~
;;
500

parameters (a, b and c) in three membership function 00

and three parameters (XI, X2 and X3) in the control ~ 0


0 2 3 4 S 6 7 8
rules, an individual is defined as follows . Days after storage

~ lOO .............. ./,y..............................


All parameters to be determined were coded as 6-bit
~ 80
binary strings. Co ......... I steps
:.;:;
.~ 60 --0-- 2 steps
---0-- 3 steps
3.3 Experimental condition ::c - 4 steps
Apples (Golden Delicious) and oranges (Iyokan) 2 3 4 5 6 7 8
were used for the experiment. A storage chamber Days after storage
used here is a thermo-hygrostat (Tabai-espec, LHU-
Fig. 6. Optimal setpoints of relative humidity and the
112M) where air temperature and relative humidity
corresponding control performances of the
are controlled at the accuracy of 0.1°Cand 2O/oRH,
water loss and the fungal development of fruits
respectively.
under different division number.

65
3~---------------------, 95
8
--Optimal fuzzy on-otf control
] 2.8
...... ... Simple on-otf control
.i 2.6
• .• .• . Desired value

:s'2.4
'Cl
g 2 .2

:; 2
1 ltepo 2 atepo 3 ltepo 4 atepo
Division number
80
o 30 60 90 120
Time (min)
Fig. 7. Comparison of the values of the objective
function under different division number of the
control process.

optimal setpoints. Figure 8 shows a comparison of


30 60 90 120
the control performances of the relative humidity in
Time (min)
the fruit storage house between an optimal fuzzy on-
off control and a simple on-off control which means Fig. 8. Optimal fuzzy control performance of the
a conventional on-off feedback control with relay relative humidity in the storage chamber as
operation. The control aim is to reduce the relative affected by ventilation.
humidity and then maintain it at the optimal value
(85 o/oRH). It is found that the performance of a fuzzy
on-off control is superior to that of a simple on-off Lee, C.C. (1990a). Fuzzy logic in control systems:
control. The control accuracy of the relative humidity fuzzy logic controller - part I. IEEE Trans. Sys.,
was significantly improved by using this control Man , Cyber., 20(2), 404-418.
technique. Lee, C.C. (1990b). Fuzzy logic in control systems:
fuzzy logic controller - part 11. IEEE Trans. Sys.,
5. CONCLUSION Man, Cyber. , 20(2),419-435.
Ljung, L. and T. Glad (1994). Modeling of dynamic
An intelligent control technique proposed here was systems. PTR Prentice Hall, Englewood Cliffs,
shown to be effective on the optimization of New Jersey.
unknown nonlinear systems in agriculture with Matsuba, I. (1991). Application of neural sequential
elaborate and sophisticated matters. associator to long-term stock price prediction.
Proc, ofInternational Joint Conference of Neural
REFERENCES Networks, 1196-1201.
Morimoto, T., Hatou, K., and Hashimoto, Y. (1996).
Crutchfield, J.P., 1.D. Farmer, N.H. Packard and RS. Intelligent control for plant production system.
Shaw (1986). Chaos. Scientific American, Control Engineering Practice, 4(6) : 773-784.
December, 38-51. Morimoto, T. , W. Purwanto, 1. Suzuki and Y.
Ditto, W.L. and L.M. Pecora (1993). Mastering Hashimoto (1997a). Optimization of heat
chaos. SCientific American, August, 62-68. treatment for fruit during storage using neural
Goldberg, D. (1989). Genetic algorithms in search, networks and genetic algorithms. Computers and
optimization and machine learning, Addison- Electronics in Agriculture, 19, 87-101.
Wesley.
Morimoto, T., 1. Suzuki and Y. Hashimoto (1997b).
Higuchi, T. (1988). Approach to an irregular time
Optimization of a fuzzy controller for fruit storage
series on the basis of the fractal theory. Physica,
using neural networks and genetic algorithms.
D31 , 277-283 .
Engineering Applications ofArtifiCial Intelligence ,
Hirafuji, M. and T. Kubota (1994). Chaos of plant
10(5), 453-461.
growth under changing environment. Environ-
Rumelhart, D.E., G.E. Hinton and RJ. Williams
ment Control in Biology, 32(1), 31-39.
(1986). Learning representation by back-
Holland, 1. H. (1992) Genetic algorithms.
propagation error. Nature, 323(9), 533-536.
Scientific American, July, 44-50.
Shabala, S., R Delbourgo and I. Newman (1997).
Hunt K.1., Sbarbaro, D., Zbikowski, R and
Observations of bifurcation and chaos in plant
Gawthrop, PJ. (1992). Neural networks for
physiological responses to light. Aust. J. Plant
control systems - Survey. Automatica, 28(6):
Physiol., 24, 91-96.
1083-1112.

66

You might also like