Bleaching Effect On Palm Oil
Bleaching Effect On Palm Oil
Bleaching Effect On Palm Oil
PALM OIL
NOVEMBER, 2006
II
BLEACHING OF PALM OIL is the result of my own research except for some
information which the source for each one has been stated.”
Dedicated to my beloved father, Haji Mohd Zin Haji Salleh for his constant
encouragement and motivation. To my beloved mother, Hajah Gayah Jali for her
inspiration and to my forever supportive family members.
ACKNOWLEDGEMENT
I would like to express my gratitude to Assoc. Prof. Dr. Noor Azian Morad and
Assoc. Prof. Dr. Khairiyah Yusop for their continuous guidance, advice and support
throughout this project.
To all CLEAR staffs, Ms. Nurul Azlina, Mr. Zaidi, Mr. Asani, Mr. Shaipudin
and Mr. Rani the best colleagues anyone could ever ask for.
And last but not least, thank you to all who had assisted and making this project
a success.
v
ABSTRACT
Palm oil (Elaeis guineensis) industry is one of the major contributors to the
Malaysia economic growths. The palm oil supply from Malaysia has increased
apparently over the last two decades due to vast increase in production. Crude palm
oil (CPO) obtained from the mesocarp of palm oil fruit undergoes several stages of
refining processes in order to produce refined, bleached palm oil (RBDPO).
Currently, in Malaysia, the type of refining used is physical refining. This method
involved the processing stages of degumming, bleaching and deodorization. From
refiners point of view, degumming and bleaching processes are recognized as critical
areas in the palm oil refinery and need to be carefully monitored, because any
imperfection during these processes will tremendously affect the later stages of
refining processes and finally affect the finished product. These stages are identified
as the major contributors to the total operating cost of the plant due to the cost of
chemicals (phosphoric acid and bleaching earth) that are being used in these
processes. In this research, a process model for degumming and bleaching operation
will be designed in order to help the refiners to predict the exact ratio of phosphoric
acid and bleaching earth to the crude palm oil. By doing so, we hope to reduce the
operating costs and time of the overall palm oil refining process. Therefore at the end
of this research, with the ANN model designed, the bleaching and degumming
efficiency can be improved thus can help to boost the Malaysian palm oil industry.
Key researchers :
Prof. Madya Dr. Noor Azian Morad
Prof. Madya Mustafa Kamal Abd Aziz
ROHANI BINTI MOHD ZIN
.E − mail : azian@citycampus.utm.my
Telephone no. : 03−2615 4894
Vote no. : 74198
vi
ABSTRAK
TABLE OF CONTENTS
1 INTRODUCTION
1.1 Research Background 1
1.2 Research Objective and Scope 5
1.3 Problem Statement 7
1.4 Research Contribution 8
2 LITERATURE REVIEW
2.1 Palm Oil (Elaeis guineensis) 9
2.1.1 Palm Oil Fruit Composition 12
2.1.2 Uses of Palm Oil 13
viii
5 METHODOLOGY
REFERENCES 153
APPENDICES 159
xii
LIST OF TABLES
LIST OF FIGURES
2.10 The flow chart for physical refining versus chemical refining
for palm oil 32
5.5 Porcelain dish containing CPO sample and magnesium oxide 103
xvii
MG - Monoglycerides
MIBK - Methyl Isobutyl Ketone
M&I - Moisture and Iodine
ml - milliliter
ML - Moisture loss
mm - millimeter
mmHg - millimeter mercury
MPOB - Malaysia Palm Oil Board
MT - metric tonne
N - normality of solution
Na - sodium
NaOH - sodium hydroxide
NN - neural network
nm - nanometer
NPO - Neutralized Palm Oil
NHP - Non-Hydratable Phosphatides
P - Phosphorus
PA - Phosphatidyl acid
PC - Phosphatidyl choline
PE - Phosphatidylethanolamine
PFAD - Palm Fatty Acid Distillate
pH - potential hydrogen
PI - Phosphatidylinositol
PIPOC - Proceedings of International Palm Oil Congress
PORAM - Palm Oil Refiners Association of Malaysia
PORIM - Palm Oil Research Institute of Malaysia
POFP - Palm Oil Familiarization Programme
ppm - part per million
PV - Peroxide Value
RBDPO - Refined Bleached Deodorized Palm Oil
RF - Refining Factor
RM - Ringgit Malaysia, monetary unit of Malaysian
RMS - root mean square
T - Temperature
xxii
TG - Triglyceride
UV - Ultraviolet
V - volume of NaOH solution used in ml
Vs - volume in ml of sodium thiosulphate solution of
normality N used for the determination
Vb - volume in ml of sodium thiosulphate solution of
normality N used for the blank test.
W - weight of sample/test portion
α - Alfa
β - Beta
γ - Gamma
d - Delta
c - quantity of residual substance dissolved
K - constant unrelated to the amounts of solute and
adsorbent
m - quantity of adsorbent
n - constant unrelated to the amounts of solute and
adsorbent
x - quantity of substance adsorbed
LIST OF SYMBOLS AND ABBREVIATIONS
GLOSSARY
Elaeis guineensis The oil palm, which is the source of palm oil (from the
mesocarp) and palm kernel oil (from the kernel). It is native to
Africa. Mainly grown in South East Asia and Africa.
Free fatty acid Fatty acid in unbound (underivatised) form. Oils and fats are
mainly triacylglycerols contain in their natural (crude) state
small amounts of free acids which may removed by
processing.
Linoleic acid An important C18 diene acid, 9C, 12C-18:2, present in most
seed oils, often in high proportions. It is the first member of
the (n-6) family of polyenoic acids and is an essential fatty
acid.
Lipoprotein Any of the class of proteins that contain a lipid combined with
a simple protein.
Lovibond value A system to express the colours of refined oils and fats. Red
and yellow galsses are used, of which the red glasses are
standardised
Monoglyceride The ester resulting from the combination of glycerol and one
fatty acid
Oleic acid Trivial name for 9-cis-octadecanoic, 18:1 (19-C). It is the most
widely distributed of all fatty acids and serves biosynthetically
as the precursor to the (n-9) families of acids. Present in high
xxvi
Refining process Industrial technology to obtain edible oils from crude oils
through processing steps such as degumming, neutralisation,
bleaching and deodorization.
oil loss %
RF =
FFA %
CHAPTER 1
INTRODUCTION
The oil palm, Elaeis guineensis, is native to Africa. The commercial values
of this crop lies mainly in the oil that can be obtained from the mesocarp of the fruit -
palm oil and the kernel of the nut - palm kernel oil. In fact, oil palm is the only fruit
that can give these two types of oil. Both are edible oils but with very different
chemical composition, physical properties and applications.
Palm oil is used mainly for cooking such as cooking oil, margarine and
shortening but also has non-food applications such as soap, detergent, cosmetics.
Figure 1.1 shows the cross-section of palm oil fruits indicating the mesocarp and
kernel of the fruit.
Mesocarp
Kernel
Although oil palm is native to Africa, Malaysia was the first country to
embark on large-scale planting and processing. It had to develop its own technology
and adopt innovative policies in order to boost production.
The first commercial oil palm estate in Malaysia was set up in 1917 at
Tennamaran Estate, Selangor. However, it was only in the 1960s, oil palms were
commercially cultivated in large scale in order to avoid over dependence on natural
rubber which are major commodity during previous years. Since then, palm oil
industry has expended rapidly and has emerged as the most remunerative agricultural
commodity, overtaking the natural rubber (Arrifin and Fairus 2002).
The growth of the industry has been phenomenal and Malaysia is now the
largest producer and exporter of palm oil in the world, accounting for 52 percent of
world production and 64 percent of world exports in 1999. Table 1.1 and Table 1.2
below, shows world annual production and annual exports of palm oil according to
the respective countries.
Table 1.1 : World Major Producers Of Palm Oil : 1994 - 2003 ('000 TONNES)
Country 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003
Malaysia 7,403 7,221 8,386 9,069 8,319 10,554 10,842 11,804 11,909 13,354
Indonesia 3,421 4,008 4,540 5,380 5,361 6,250 7,050 8,030 9,200 9,750
Nigeria 645 640 670 680 690 720 740 770 775 785
Colombia 323 353 410 441 424 501 524 548 528 543
Cote d'Ivoire 310 300 280 259 269 264 278 220 240 251
Thailand 297 316 375 390 475 560 525 620 600 630
Papua New Guinea 223 225 272 275 210 264 336 329 316 325
Ecuador 162 178 188 203 200 263 222 201 217 247
Costa Rica 84 90 109 119 105 122 138 138 140 144
Honduras 80 76 76 77 92 90 97 108 110 112
Brazil 54 71 80 80 89 92 108 110 118 132
Venezuela 21 34 45 54 44 60 73 80 80 79
Guatemala 16 22 36 50 47 53 65 70 81 91
Others 1,265 1,676 815 869 844 832 879 919 922 940
TOTAL 14,304 15,210 16,282 17,946 17,169 20,625 21,877 23,947 25,236 27,383
Source : i) Oil World Annual (1999 - 2003) & Oil World Weekly (12 December, 2003)
ii) MPOB - For data on Malaysia.
3
Table 1.2 : World Major Exporters Of Palm Oil : 1994 - 2003 ('000 TONNES)
Country 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003
Malaysia 6,750 6,513 7,212 7,490 7,465 8,911 9,081 10,618 10,886 12,248
Indonesia 2,173 1,856 1,851 2,982 2,260 3,319 4,140 4,940 6,379 6,830
Papua New Guinea 231 220 267 275 213 254 336 328 324 325
Cote d'Ivoire 148 120 99 73 102 101 72 75 65 63
Colombia 20 21 29 61 70 90 97 90 85 105
Singapore* 328 399 289 298 241 292 240 224 220 256
Hong Kong* 234 275 305 173 103 94 158 192 318 206
Others 876 791 711 860 680 787 884 1,107 956 1,083
TOTAL 10,760 10,195 10,763 12,212 11,134 13,848 15,008 17,574 19,233 21,116
Note : * - Includes Re-Exporting Countries
Source : i) Oil World Annual (1999 - 2003) & Oil World Weekly (12 December, 2003)
ii) MPOB - For data on Malaysia
Obviously now, palm oil has become an increasingly important vegetable oil
in the world market and today is the largest traded vegetable oil in the world. It was
recorded that in 2002, a trade surplus for palm oil industry is RM 54.1 billion
compared to RM 50.9 billion in 2001. It shows that palm oil industry plays an
important role in Malaysia’s economy.
The palm oil refining industry is today among the most important
manufacturing sectors in the country. Besides contributing to the Gross Domestic
Product (GDP) and increasing employment opportunities in the country. The refining
sector has contributed significantly to the growth of palm oil industry in Malaysia
(Arrifin and Fairus 2002).
The palm oil industry can be divided into several main sectors according to
their activities, namely:
(i) plantations - planting of the oil palm and harvesting of the fresh fruit
bunches (FFB)
(ii) palm oil mills – processing of the FFB into crude palm oil (CPO) and
palm kernels
(iii) palm kernel mills – extraction of the palm kernel oil
(iv) palm oil processing – refining and fractionation, production of
downstream products
4
This research study will focus on the degumming and bleaching processes of
the processing sector, which is in the refining process of palm oil.
Malaysia’s refining industry first started in 1972, where there were only 4
refineries in operation during that time, but at the end of 2002, there are already 47
refineries in operation with total refining capacity of 16.14 million tonnes of CPO
per annum. Most of these refineries are located close to the ports to facilitate exports
for example in southern region of Malaysia most of the palm oil industry are located
in Pasir Gudang , Johor where the port is situated.
When the palm oil refining industry first started in 1970’s, it had employed
mainly alkali or chemical refining process as alkali refining was the more establish
process for edible oil at that time. This mode produced neutralized palm oil (NPO)
and its products. In the late of 1970s however, physical refining began to be
preferred method as it is more cost effective (Ahmad and Mohammad, 1993). Further
elaboration on physical and chemical refining will be explained in Section 2.5 of
Chapter 2: Literature Review, in this thesis.
Currently in Malaysia, all palm oil refining plants are using physical refining
method as it is proven to be more cost effective compared to chemical refining
method. In general, physical refining of palm oil consists of 2 stages namely pre-
treatment stage and deodorization stage. Pre-treatment stage involves degumming
and bleaching of palm oil where the aim of the processes is to remove the undesired
impurities that affect the stability of final oil products. The aims of degumming and
bleaching processes are achieved by means of chemicals used to react and adsorb the
unwanted impurities. The chemicals used for these processes are phosphoric acid and
bleaching earth. Detailed elaboration on degumming and bleaching methods will be
further discussed in Chapter 3: Theory of Degumming and Bleaching.
.
5
In achieving the objective of the research there are a few important tasks need
to be carried out and three research scopes have been identified for accomplishing
the objective. The scopes are:
2. Design a lab scale experiment for degumming and bleaching in order to get
the data for modelling. This lab scale experiment is designed as degumming
and bleaching processes are carried out simultaneously and based on the most
optimal conditions and parameters identified. During this stage, the number
of experiments need to be run are determined through the design of
experiment (DOE) method.
From refiners’ point of view, degumming and bleaching process stage are
recognized as critical areas in the palm oil refinery. Separation of minor components
at these stages must be carefully monitored because any imperfection during these
processes will tremendously affect the later stages of refining processes and finally
affect the finished product. These stages are considered critical as it is identified as
major contributors to the total operating cost of the plant due to the cost of chemicals
(phosphoric acid and bleaching earth) that are being used in these processes.
In addition, Borner et al. (2003) also reported that bleaching is one of the
most cost-intensive processes for refining vegetable oils caused mainly by the
consumption of bleaching agents like bleaching earth and activated carbon, oil losses
in the spent bleaching and in certain cases for disposal of the spent agents. Therefore,
it’s become an interest of all refineries to reduce the consumption of bleaching earth
as much as possible. It is estimated about 20% of total operating cost are due to
bleaching and degumming process and currently the price of bleaching earth is RM
700-800 per MT and RM 3000 per MT for phosphoric acid.
Thus, it important to have a process model which can suggest a suitable ratio of
phosphoric acid and bleaching earth for the varying CPO quality.
8
it would introduce and enable transfer of this advanced technology to palm oil
refiners. It is anticipated that once the ANN technology on palm oil processing have
been developed, it will significantly reduced the operating cost of the plant since this
technology will help the palm oil refiners easily predict the exact amount of
phosphoric acid and bleaching earth to be used to refine the CPO fed in.
9
CHAPTER 2
LITERATURE REVIEW
In 1434, a Portugese sailor, Gil Eannes first reported about oil palms (Elaeis
guineensis) (Bockish, 1998). Today, they flourish mainly in the western part of
Africa, Indonesia, Malaysia and most recently in Brazil and Colombia. Oil palm tree
(Figure 2.1), grow up to 20 meter in height and grow best at temperature of 24-27oC.
Oil palm tree require a humid climate and the cultivated oil palm carry fruit from
their fourth year onward and can be harvested for 40-50 years (Bockish, 1993).
Palm oil is derived from the fleshy part or the mesocarp of the fruit of the
palm species Elaeis guineensis (Figure 2.2). However in Malaysia, Tenera (hybrid of
Dura X Psifera) palm fruit is widely cultivated due to commercial and processing
viability as harvesting becomes easier since the palm trees are relatively shorter,
producing good fruit bunch and higher fruit oil content (Noor Azian, 1995).
10
Figure 2.3 shows three genotypes of palm oil where clear differences in their
fruit morphology are revealed. The dura fruit form has a thick shell or endocarp
surrounding the kernel whereas psifera form has no shell. The hybrid between the
two, the tenera fruit form has a shell of intermediate thickness and a surrounding of
fibre strands in the mesocarp (Noor Azian, 1995).
Pericarp
Seed (Fruit-Wall)
(Kernel)
Exocarp (skin)
Testa
Mesocarp
Endosperm (oil bearing tissue)
(oil bearing tissue)
Fibre
Embryo
Endocarp (shell)
Figure 2.3: Tenera Hybrid obtained from Dura and Pisifera Parents
(Noor Azian, 1995).
12
Mesorcarp accounts for about 60% of the total composition of palm oil fruit
and crude palm oil is derived from this part. Figure 2.4 below shows overall
composition of palm oil.
Skins and
Stems
29%
Mesocarp
60% Nuts
11%
Figure 2.5 below shows the composition of mesocarp where the oil accounts
for 39 % of the overall composition. Crude palm oil (CPO) is obtained from the
mesocarp part of palm oil fruit after undergoing through several processes such as
sterilization process, stripping, extraction and purification.
Oil Water
39% 41%
Fiber
20%
As mentioned, the oil palm produces two types of oils, palm oil from the
fibrous mesocarp and palm kernel oil from the palm kernel. Palm oil and palm kernel
oil have a wide range of applications; about 80% are used of food applications while
the rest is feedstock for a number of non-food applications (Salmiah. 2000).
Among the food uses, refined, bleached and deodorised (RBD) olein is used
mainly as cooking and frying oils, shortenings and margarine while RBD stearin is
used for the production of shortenings and margarine. RBD palm oil, which is the
unfractionated palm oil, is used for producing margarine, shortenings, vanaspati
(vegetable ghee), frying fats and ice cream (Salmiah. 2000).
Crude palm oil (CPO) is the oil obtained from the mesocarp part of palm oil
fruit. Figure 2.7 shows the processes undergone by fresh fruit bunches (FFB) to
produce CPO. The crude palm oil (CPO) produced, is further processed to yield
either red or bleached cooking oil or detergents.
Extraction in a Purifications in a
homogenous oil mash continuous
clarification tank
Table 2.1: General Compositions Of Crude Palm Oil (Abdul Azis, 2000).
Table 2.2 below, shows the typical composition of the main constituents of
Malaysian crude palm oil. (Noor Azian, 1995)
In general, quality of crude palm oil is dependant on the contents of free fatty
acids, moisture, heavy metals, DOBI, oxidized products and minor constituents such
as phosphatides, carotenes and tocopherols.
The FFA content of crude palm oil is always used as an index of oil quality
by the commercial oil refiners in Malaysia. FFA are formed when the bound fatty
acids in triglyceride, diglyceride and monoglyceride molecules are split either by
chemical or enzymatic hydrolysis.
According to Formo et al. (1979), the high moisture content of palm oil fruit
is favourable to the enzyme action; hence this material should be processed promptly
in order to yield oil with low free fatty acid (FFA) content. Palm oil fruits are
susceptible to deterioration. Their lipolytic enzymes are so active that even under
favourable conditions palm oil seldom produced with free fatty acid content less than
2 %.
Thus, crude palm oils that have low FFA are indicating that, the oil are being
processed from fresh, unbruised fruits and carefully handled during production,
storage and transportation. High FFA content must be avoided, as it will result in
higher refining losses and possible bleachability problems during refining (Formo et
al., 1979).
(ii) Moisture
The miscibility of oils and water, under certain conditions will hydrolyzed
the triglycerides of oils to free fatty acids and glycerol (Formo et al.,1979)
Heavy (trace) metals such as iron (Fe) and copper (Cu) are usually resulted
from corrosion and mechanical wear at the mills and refineries. These metals are pro-
oxidant and thus, detrimental to the oil quality.
Other metals reported in palm oil are manganese, cadmium and lead. These
metals are found in very low concentrations and their effects on oxidation appeared
to be negligible.
19
(iv) DOBI
DOBI is an indication of the bleachability of the crude palm oil based on the
amount of carotenes still present in the crude oil and the amount of secondary
oxidation products. A good easily bleached crude palm oil will have a DOBI of 4,
while average quality crude will exhibit a DOBI of 2.5 to 3.
Table 2.3 below, shows the refinability of CPO according to DOBI values.
DOBI Grade
< 1.7 Poor
1.8-2.3 Fair
2.4-2.9 Good
3.0-3.2 Very good
> 3.3 Excellent
The formation of oxidized products, which are difficult to remove, will result
in poor bleachability during refining and consequently will lead to refined oils will
poor stability and keepability. Apart from that, off-flavours and odours in oils are
normally caused by the reaction of oxygen with double bond of unsaturated fatty
acids. Therefore, it is vital to prevent or minimize the deterioration in crude oils by
avoiding aeration of the oil and by avoiding gross contamination with iron or copper.
The oxidation conditions can also be hindered by avoiding the oil from exposure to
light, elevated temperature and the presence of pro-oxidants.
Although present in small quantities in the palm oil, these minor constituents,
to a certain extent, will affect the bleachability, stability and nutritional value of the
palm oil. Phospholipids, which are complex esters that contain phosphorus, nitrogen
bases, sugars and long-chain fatty acids, are the main culprit that needs to be
removed during degumming by coagulating the phosphatides contents with
phosphoric acid. The importance of removing this component will be discussed
further in the next section on physical refining.
21
In Malaysia, the generally accepted trading specifications for crude palm oil
are; 5 % maximum FFA; 2.5 % maximum moisture and impurities (Goh, 1991),
while the Palm Oil Refiners Association of Malaysia (PORAM) standard
specifications for refined palm oils are given in Table 2.3.
It is a goal for a refiner to maintain the quality of the palm oil products at the
levels acceptable to the buyers or producing a better quality of finished product
while minimizing the operating costs.
Therefore, to achieve this goal, quality control are applied at each important
process stage in refining where suitable analysis are carried out in order to evaluate
the efficiency of each process stage. Typical analysis for crude, bleached degummed
oil and refined bleached deodorized oil are shown in Table 2.4 below (Er, 1985).
22
Table 2.4: Typical Analysis of Crude, Degummed, Bleached and RBD Palm Oil
(Er, 1985).
In this study, the focus of the research is on the degumming and bleaching
process. Therefore, it is important to monitor the quality of CPO input and the
output of degumming and bleaching process, which is degummed and bleached
palm oil (DBPO).
The heavy metal impurities such as copper and iron are removed up to about
0.05 ppm and 0.15 ppm respectively in order to prevent excessive oxidation at olefin
bonds of the oleic and linoleic acids resulting in rancidity.
23
Refining process is a necessary step for the production of edible oils and fats
products. The objective of this process is to remove the impurities and other
components, which will affect the quality of finished product. The qualities of the
finished product that need to be monitored are flavour, shelf-life stability and colour
of the products (Leong, 1992).
In industry perspective, the main aim of refining is to convert the crude oil to
a quality edible oil by removing objectionable impurities to the desired levels in the
most efficient manner. This also means that, where possible, losses in the desirable
components are kept minimal and cost effective.
The differences between these 2 types are basically based on the type of
chemicals used and mode of removing the FFA.
25
In its early years of inception, the palm oil refining industry of Malaysia was
mainly alkali-refining based. Alkali refining then was the more established process
for edible oil. It was not until the late 1970s, that physical refining of palm oil in
Malaysia started to emerge as a better alternative, in many ways, to alkali refining
(Yusoff and Thiagarajan, 1993). Over the years, physical refining has proven to be
very successful for palm oil and modern refineries in Malaysia are mainly using
physical refining routes.
oil loss %
RF =
FFA %
Soap Alkali
Bleaching Stock Neutralization
Splitting
Deodorization Bleaching
FFA
Deodorization
The oil mass is then neutralised with alkali for removal for free fatty acid in
the form of soap stock. This soap stock is removed from oil mass by gravity
separation method. For removal of alkali traces, oil is washed with hot water. The
chemical reaction involved in this operation is as follows:
The neutralised washed oil is then taken to the second step in refining, which
is bleaching. In this operation, the oil is taken into cylindrical vessel with agitator
called `Bleacher' and kept under vacuum and heated up to 90oC with steam.
28
The moisture from oil is thus evaporated and oil becomes dry. The dried oil
is treated with bleaching earth (fuller's earth) and carbon. These bleaching agents will
adsorb most of the residual colour of the remaining oil after neutralisation.
The mixture of oil and bleaching agent is filtered through a standard plate
and frame press for separation. The clear oil obtained is bleached oil and is very
much lighter in colour than the neutralised oil.
The oil charge is dehydrated under vacuum to avoid any further deterioration
due to oxygen. In this operation, the coloured pigments in oil are adsorbed by certain
bleaching agents under specific conditions.
2.5.2.3 Deodorisation
The oil after bleaching is practically pure, but contains minute quantities of
original odoriferous matter and also the chemicals used during neutralisation process.
This bleached oil are then sent to a cylindrical vessel called `Deodoriser'.
The Deodoriser is kept under very high vacuum and the bleached oil is then
heated at high temperature 200oC with high-pressure steam and open steam is passed
through the oil. The volatile materials are evaporated off with some carrier
(commonly direct steam).
This oil is then cooled and clarified through a Filter Press to get sparkling oil.
The purpose of deodorisation is to make oil blend and tasteless. In this process, the
peroxide value of oil is brought down as minimum as possible.
29
Physical refining is a modern alternative for processing crude palm oil where
the removal of free fatty acid is by distillation at higher temperature and low vacuum.
This replaces chemical reaction mode using an alkali (caustic soda) in chemical
refining.
The advantages of this physical refining method over the chemical refining
method of palm oil refinery are;
• Better yields
• High Quality of fatty acids as by-products
• Good oil stability
• Simultaneous distillation of fatty acids and deodorization
• Lower cost of equipment
• Simplicity of operation
Figure 2.7 shows the simplified flowsheet of physical refining which consists
of pre-treatment stage (degumming and bleaching) and deodorization stage.
29
Degumming Process
In this unit operation, the incoming crude palm oil is first heated up to a
temperature of about 90oC - 110oC before it is treated with phosphoric acid. The
dosage of phosphoric acid normally used is within the range of 0.05 – 0.1 % of oil
weight with acid concentration approximately about 80 - 85 %. It is meant to
decompose the non-hydratable phosphatides as well as to coagulate the phosphatides
making them insoluble and thus easily removed during bleaching.
Bleaching Process
During bleaching process in palm oil refinery, degummed oil is treated with
bleaching earth and heated up to a temperature of about 100oC before entering the
vacuum bleacher. The dosage of acid activated clay used is typically within the
range of 0.5 – 2.0 % by weight of oil and the contact time with continuous agitation
is about 30 minutes.
31
During this stage, trace metal complexes such as iron and copper, pigments,
phosphatides and oxidation products are removed by adsorptive effect of the
bleaching earth. Any residual of phosphoric acid are removed during this stage too.
The bleached oil is then filtered on industrial filters such as plate and frame filter
press or vertical leaf pressure filter.
2.5.2.2 Deodorisation
The filtered oil (DBPO) is then channelled into the deodorizer for the
deacidification and deodorisation treatment. This process utilises a combination of
high temperature heating approximately about 240 - 260oC, under vacuum (2 - 4
mmHg) and direct steam injection of about 2.5 - 4.0 % by weight of oil (Leong,
1992).
During this deodorization process, free fatty acid (FFA) in the form of palm
fatty acid distillate (PFAD) is removed as refining waste, at the upper section of
deodorizer. Apart from FFA, carotenoids pigments, primary and secondary oxidation
products are also being removed as it may contribute to off-flavours. The deodorised
oil is then cooled before it is filtered by means of a polishing filter and sent to
storage tanks.
32
Why?
Figure 2.8: The flow chart for physical refining versus chemical refining
for palm oil.
There are several factors affecting the refining process of crude palm oil, the
factors that are mentioned here are particularly focussed on the upstream operation of
the refining process, which are degumming and bleaching. The factors are, quality
of CPO, bleaching time, operating temperature, operating pressure, phosphoric acid
dosage and bleaching earth dosage.
The quality of the crude palm oil is of utmost importance to the refiners as it
relates directly to the processing cost and the product’s shelf life (Wong, 1983). This
is because refiners are requested to meet stringent specifications. Refiners want a
crude palm oil (CPO), which can be easily processed to a bland and light coloured oil
with good oxidative and colour stability. All requirements should preferably be
obtained at the minimum refining cost, in other words, low oil losses with minimal
use of bleaching aids. Therefore, an ideal CPO should posses the quality as shown in
Table 2.5 below;
Table 2.5: Ideal quality targets of Crude Palm Oil (Ai, 1990)
Figure 2.9: Effect of Bleaching Time on Oil Colour, Peroxide Value (PV) and
Free Fatty Acid (FFA)
36
Based on the Figure 2.10, it can be noted that the bleached oil colour tends to
continuously fall as the temperature is increased, but the deodorized oil colour
reaches a minimum when the bleaching temperature is about 100oC. It is also
deduced that, the fall in bleached colour with increasing temperature is due to the
heat bleaching effect.
37
From Figure 2.11, it can be clearly seen that the FFA of bleached oil is
minimised when the bleaching temperature is about 110oC.
38
Figure 2.12 shows the effect of bleaching temperature on peroxide value (PV)
and anisidine value (AV) of palm oil. From the graph, it can be seen that the
peroxide value decreases with increasing bleaching temperature, however it effect is
vice versa for anisidine value as the AV value rises rapidly as temperature increases
particularly at temperature above 1110oC. This indicates that the secondary oxidation
products are not effectively being removed at higher temperature. The total oxidation
of the oil is seems to be minimum at temperature about 100oC (Howes et al., 1991).
39
Bleaching earth dosage is also one of the factors that can influence the
efficiencies of degumming and bleaching processes. This factor is one of the easiest
variables to modify.
From Figure 2.13, it can be seen that the colour of bleached and deodorized
oil continue to fall with increasing earth dosage. It is claimed that at high bleaching
earth dosage, the bleached oil colour reduction is mainly due to the carotene
adsorption which could be remove more cost-effectively during deodorization stage
(Howes et al., 1991). The optimum earth dosage will depend on the quantity and the
nature of impurities in the crude palm oil.
40
Figure 2.14 shows the effect of bleaching dosage on peroxide value (PV) and
anisidine value (AV) of palm oil. Based on this graph, it can be deduced that PV and
AV are reduced with increasing bleaching earth dosage. This condition is contrast
with the reduction in PV alone when high bleaching temperature is utilized.
41
Based on figure 2.15, it is found out that the phosphatides removal are
improved by increasing the bleaching earth dosage.
42
CHAPTER 3
HEATING 90-100 oC
PHOSPHORIC
MIXING
ACID
BLEACHING
MIXING
EARTH
FILTRATION SPENT
EARTH
DRY-DEGUMMED OIL
Crude Oil
HEATING 80-100 oC
HOLDING
SEPARATING
DRYING
WATER
DEGUMMED OIL
COMMERCIAL
LECITHIN
In this acid degumming process, gums are precipitated by some form of acid
conditioning process and subsequently removed by centrifugal separation. In this
process method, the gums can be hydrated at temperature higher than 40 oC and the
process may lead to some dewaxing which usually associated with processing of
sunflower and rice bran oils. In organic refining process, dilute organic (citric) acid is
normally used and the removal of residual phosphatides is by bleaching using silica
hydrogel.
Crude Oil
HOLDING
SEPARATING
DRYING GUMS
ACID
DEGUMMED OIL
Crude Oil
HEATING 75-80 oC
EDTA
(WETTING AGENT) MIXING
SEPARATING
DRYING GUMS
EDTA-DEGUMMED OIL
During oil processing, miscella, which contain 25-30% of crude oil and 70-
75% hexane are obtained from extraction prior to solvent removal. Phospholipids can
be separated from triglyceride in the miscella stage using appropriate membrane.
This processing method is typically used for cottonseed oil. Figure 3.6 below
shows the flow diagram of membrane degumming of crude vegetable oils.
52
FLAKES/CAKE
PRE-FILTRATION
FINES 15-30 minutes
PERMEATE
LECITHIN
HEXANE EVAPORATION
There are 2 kinds of phospholipids exists, those that hydratable and those that
cannot be hydrated (non-hydratable phosphatides -NHP). Hydratable phospholipids
can be removed easily by the addition of water where the process can be conducted
rapidly at elevated temperature or slowly at low temperature. However the
temperature should stay below the temperature at which the phospholipids hydrate
starts to become liquid crystals (usually ~ 40 oC). By taking up water, phospholipids
lose their lipophilic character and become lipophobic and thus precipitate from oil
(Bockish, 1998).
Phospholipid Percentage
Phosphatidylcholine (PC) 36
Phosphatidylethanolamine (PE) 24
Phosphatidylinositol (PI) 22
Phosphatidylglycerol 9
Disphosphatidylglycerol 4
Phosphatidic Acid (PA) 3
Lysophosphatidylethanolamine 2
Phosphatidylserine trace
Lysophosphatidylcholine trace
55
There are two types of degumming agents that are usually being used in palm
oil refining industry, which are phosphoric acid and citric acid.
3.1.4 Phosphoric Acid Versus Citric Acid as Degumming Agent for Palm Oil
Refining
Why?
Figure 3.9: The flow chart for phosphoric acid versus citric acid as
degumming agent for palm oil refining
The term bleaching refers to the treatment that is given to remove colour-
producing substances and to further purify the fat or oil. The usual method of
bleaching is by adsorption of the colour producing substances on an adsorbent
material. There a lot of adsorbent materials are being used in vegetable oil industry
for examples; acid activated bleaching earth, natural bleaching earth, activated
carbon and synthetic silicates.
There are 3 types of bleaching methods can be used in edible oil industry
(Gunstone and Norris, 1983) , namely :
Some pigments for example carotenoids are made colorless or less colored by
oxidation. But such oxidation invariably affects the glycerides and destroys natural
antioxidants. Consequently, it is never used for edible oil but restricted to oils for
technical purposes, such as soap-making
59
3.2.1.3 Adsorption
Adsorption is the common method usually used for bleaching the edible oil
by using bleaching agents. Examples of bleaching agents are bleaching earths,
activated carbon and silica gel. Bleaching agents normally posses a large surface
that has a more or less specific affinity for pigment-type molecules, thus removing
them from oil without damaging the oil itself.
60
Figure 3.11 below shows arithmetic graphs of some typical isotherm shapes
(McCabe, 1993). Linear isotherm indicates the amount of adsorbed is proportional to
the concentration in fluid. Favourable process is achieved when the isotherms are
convex upward because a relatively high solid loading can be obtained at low
concentration in the fluid. The isotherm for this favourable adsorption process is
Langmuir Isotherm. The assumption made when deriving the Langmuir isotherm is
that the process happens at uniform surface. However this relation only works well
for gases that a weakly adsorbed (McCabe, 1993).
Langmuir
Isotherm
Freundlich
Isotherm
This Freundlich equation relates the specific adsorption (x/m), i.e the amount
of substance adsorbed per unit of adsorbent weight, to residual solute concentration
(c), at the equilibrium for a given temperature ((Rossi et al., 2003).
Oils and fats are bleached in order to remove undesired colorants because
these colorants can negatively affect the taste of the oil and in part because the colour
would disturb the consumers, therefore on the whole, these colorants limit use and
marketability. In addition to that, some particles or pigments that promote
deterioration to oil quality is also being removed during bleaching process mainly
due to their pro-oxidative properties that promotes oxidation (Bockish, 1998).
There are few types of bleaching agents that are being used in vegetable oil
industry such as acid activated bleaching earth, natural bleaching earth, activated
carbon, synthetic silicates and synthetic resins.
While some of these earths are naturally bleaching, some have to be treated
with mineral acids. This activation results in the replacement of some of the
aluminium ions by hydrogen ions from the acid. This further results in the creation of
net negative charges on the clay lattice structure and creates the cation adsorption
properties of the acid-activated bleaching earths clays. (Hymore, 1996)
Bleaching earth works based on its character of adsorption and ion exchange.
The adsorption process is influenced by some factors as follow :
• particle size
• adsorbent polarity
• surface area
• pore volume
• pore size.
65
Natural bleaching clays are found in special strata and are naturally active.
This material is also used for bleaching. According to Rossi et al. (2003), they are
excellent metal adsorbents as they are able ;
(i). to decrease the levels of chlorophyll and colour bodies
(ii). to remove soaps and phospholipids
(iii). to minimizes free fatty acid increase during bleaching.
66
Synthetic silicates are now commonly used in edible oil bleaching. Although
synthetic silicates has a moderate capacity for pigment removal, small amounts of it
are used in combination with bleaching clay and due to their synergic action the
amount of bleaching clays needed to optimize the bleaching processes is reduced
(Roosi et al., 2003). Silica had the capability of enhancing the earth’s ability to
remove colour bodies, phosphorus and other minor components that affect the colour
stability of the oil (Siew et al., 1994).
67
Based on Cheah and Siew (1999) study, they concluded that in general, acid
activated earths were more efficient in removing color components. This conclusion
can be supported by Howes et al. (1991) study, where they plotted a graph of colour
stability of palm oil as a function of bleaching earth type (Figure 3.16). From the
graph, we can see that the colour pigments were removed better by using acid
activated earth instead of natural/neutral (non-activated) bleaching earths.
Conclusion
70
Figure 3.4 shows a conventional batch bleaching unit where its operation is
rather simple. The bleacher is fed by a set amount of oil and heated by steam while
the apparatus is maintained under vacuum by the barometric condenser and vacuum
pump. When the desired temperature is reached, the mechanical agitator of the
bleacher is put into action until moisture present in the oil is completely removed.
During this stage the bleaching kettle will act as dryer. After drying, a metered
amount of bleaching is added to the mass and the adsorbent is pulled into the vessel
by the vacuum existing therein. Upon completion of bleaching, the oil-bleaching
earth suspension is pumped to filtration section where the two components are
separated (Bernardini, 1985)
71
Figure 3.7 shows another type of continues bleaching plant. The main
advantage of this type of plant is that the bleaching earth is loaded on the ground
floor. The operation of this type of plant is nearly the same as the previous one.
74
(a) For the first approach (refer to Figure 3.18 below), the phosphoric acid is
mixed with small amount of crude palm oil in the mixer before it is sent to
degumming vessel for more efficient mixing. This mixture will be further
sent to bleaching vessel where the bleaching earth is added. The process
will continue with filtration where the gums and spent bleached earth are
separated from the degummed and bleached oil.
The second approach that is found from the survey is described as below;
(b) For this second approach (refer to METHOD B below), small quantities
crude palm oil (CPO) is mixed with phosphoric acid and bleaching earth in
2 separate mixers before entering the bleaching vessel. No degumming
vessel is required. Degumming and bleaching took place simultaneously in
bleaching tank. Filtration similar to the first approach is carried out after
that.
CHAPTER 4
DOE consists of a set of Experimental runs, which each run defined by the
combination of each factor level (variables) and the analysis of the experiments. DOE
helps to make product and processes more robust. DOE is a proven technique that
continues to show increasing usage in chemical process industries especially for fast, cost
saving and accurate result.
77
DOE technique now has become a very useful statistical tool to help us
understand process characteristics and to investigate how inputs affect responses based
on statistical backgrounds. In addition, it has been used to systematically determine the
optimal process parameters with fewer testing trials (Park and Ahn, 2004). Thomas
(1997) pinpointed that, the advantages of statistical design are ;
There a several experimental design techniques that can be used in DOE such as
Factorial design, Response Surface Method (RSM) design, Mixture design and Taguchi
design. In order to select the best design method to be used, one must be carefully
consider the objectives /goals for an experiment.
In response surface objective, the experiment that are designed are used;
• to hit a target
• to maximize or minimize a response
• to reduce variation by locating a region where the process is easier to
manage
• to make a process robust
In this study, the objectives are; to hit a target (to find the exact dosage of
phosphoric acid and bleaching earth and phosphoric acid to be added to CPO fed) and to
maximize a response (to optimize degumming and bleaching process).
According to Dey et al., (2001) and Prado et al., (2004), the chosen method for
optimisation of the response factor was efficient, relatively simple with time and material
saving by using response surface methodology. It is found out that, the RSM technique
has been successfully applied in the field of quality experimental work (Muralidhar et al.,
2001; Amin and Anggoro, 2003; Varnalis et al., 2004; Jose et al., 2004).
Response surface method is created from factorial design and there are two
categories of quadratic factorial designs, namely; central composite design (CCD) and
Box-Behnken design. CCD contains an imbedded factorial or fractional factorial design
with center points that is augmented with a group of `star points' that allow estimation of
curvature.
A designed training data sets are more desirable than random experimental sets,
due to their higher orthogonality (Lanouette et al., 1998 and Kapur et al., 2004 ). Central
Composite Design (CCD) is well-liked among researchers to design the training data set
and to analyze the influence of variables due to its ability to show which variables
significantly affect each response. The central composite designs satisfy the general
requirements of response surface designs, which are (Mead, 1992);
the observation are spread fairly evenly over the region within which information
about the surface is required.
Peng et al.(2002) point out that, to have a robust model for optimization, the
CCD, generally is the best design for RSM optimisation. CCD allows us to show which
variables significantly affect each response and performs optimisation on the value of
variables that are found significant.
For example, CCD with three experimental factors employed 16 experiments. The
experiments contain eight runs at two level (-1, +1), six star point (-∗, +∗) and two
replicates at the centre point (0) to allow estimation of the error and provide a check on
linearity.
81
Neural networks posses the ability to learn what happens in the process without
actually modelling the physical and chemical laws that govern the system. The success in
obtaining a reliable and robust network depends strongly on the choice of the process
variables involved as well as the available set of data and the domain used for training
purposes (Nascimento, 1997).
There are a few functions that can be used in the neural e.g. Radial Basis
Function, feed forward neural network (also know as preceptron) and Fuzzy Logic. A
feed forward neural network is most commonly used because it is most applicable to
science and engineering, least complicated and most straightforward to implement
(Braughman and Liu, 1995).
84
Baughman and Liu (1995), stated that the feedforward connection is used where
the outputs from a node feed into nodes in the subsequent layer .The first layer is the
input layer which it receives information from an external source and feeds it into the
network for processing. The second layer is called the hidden layer. It receives
information from the input layer and processes it. The third layer is the output layer
which receives the processed information from the hidden layer and sends the results to
an external receptor.
The output from the node is then transferred to the next processing nodes called
the hidden layer. A simple model of a node and its components is shown in Figure 4.2
below;
Weight Factors
85
The input to the node are represented by an input vector, an. The node manipulates
these inputs to give the output, bj. This output then forms part of the input to another
node
Each node usually will receive several inputs at the same time. There is also a
weight factor, wij that affects the output from the node besides the component value of
the input vector. According to Baughman and Liu (1995), every input vector is
multiplied by its weight factor and the node uses the weighted input to perform further
calculations.
The weight factors will determine how much each input will affect the output
from the node. If the weight factor is large, it will excite the node. If the weight factor is
small, it will inhibit the node and that input signal has little effect on the output
The transfer function is the final factor governing the output from a node. The
node calculates the dot product of the weight factor, wij and input vector, ai.
Afterwards, it subtracts the threshold Tj from it. This result will then be passed on to a
86
transfer function, f(). The transfer function changes this result to an output. The
function is generally chosen to be continuous and non-linear. Some of useful functions
are the sigmoid, hyperbolic tangent and radial basis transfer function
The goal of back propagation training is to change iteratively the weights between
the neurons in a direction that minimizes the error E, defined as the squared difference
between the desired outputs of the actual outputs of the outputs output nodes, summed
over the training patterns (training data set) and the output neurons according to the
steepest descent method (Marini et al, 2003).
(3) an output layer, where each neuron is associated to the response and
provide an answer for a given set of input values.
The signal moves from the input layer towards the output layer as per shown in
Figure 4.3, and in this process each neuron uploads all the neurons of the successive
layers, transferring a portion of the signal that has been accumulated. The portion of
signal transferred is regulated by a transfer function (Marengo et al., 2004).
Back propagation is a form of supervised learning where the error rate is sent
back through the network to alter the weights to improve prediction and decrease error.
The general process to build a neural network model included creating data sets for
training and testing, training multiple networks with varied parameters, analyzing
network results, and testing the models
The process of neural network development can be divided in three main phases
(Baughman and Liu 1995);
Prior to these three phases of neural network development, a few steps need to be
taken first, which are database collection, normally through experimental works or obtain
from literature review and also analysis and pre-processing of the data gained.
89
The design and training of neural network is the first phase of neural network
development process. At this phase, the network is fed with a set of known input-output
patterns. The weight factors of the nodes are adjusted until each input yields the desired
output.
In learning phase, it is where the actual process of adjusting the weights factors
until the desired outputs are obtained. In this way, the neural network (NN) needs to learn
about the problem under study. This process usually starts with random values for the
weights of the NN. As mentioned earlier, there are two types of learning method;
supervised learning, learning by example with outputs, or unsupervised learning, self-
organizing without outputs and back-propagation is a form of supervised learning.
In recall process, the performance of the network is checked and evaluated once
the training phase is completed. The network is given an array of input patterns that was
previously seen during the training phase. The output error from the network is then
assessed. A well-trained network should produce outputs that deviate very little from the
desired value.
The generalisation phase is where a new set of input patterns, which the network
has not seen before, is introduced to it. The network output is then compared to the
desired output. Therefore, the performance of the neural network in predicting new input
patterns can be evaluated
90
Even though application of ANN in modeling can be used to solve problems that
are not suitable using conventional statistical methods but ANN is not a solid solution for
all modeling problems and therefore it is important to understand the strengths and
limitations of ANN with compared to first principle models or other empirical models.
Baughman and Liu (1995) has stated that the strengths of ANN are :
5. Automated abstraction
ANN can determine the essentials of input-output relationships automatically as
it will not need any domain expert (an expert in a problem-solving domain) to
develop the knowledge base.
Baughman and Liu (1995) have described the limitations of ANN as follows:
There is no guarantee that the resulting model is perfect for the system, even
though the network contains parameters that can be tuned by the training
algorithm. It can be that tuned model may be accurate in one region but
inaccurate in another.
.
93
CHAPTER 5
METHODOLOGY
Surveys are done by distributing questionnaires to all the registered palm oil
refineries in Malaysia. There are 2 set of questionnaires (refer to Appendix A and
Appendix B) that has been distributed, with the objectives;
Few plants visits are conducted in order to get familiarize with actual plant
operation and to have a closer look at degumming and bleaching operation. The
visits were accompanied by the supervisors, lecturers and research officers. During
the visits, discussions are made with the industrial expertise in order to get their
opinions, suggestions and feedback from their point of view regarding the proposed
research.
In this study, 3 models of ANN were developed, and performance of each model is
evaluated in term of error generated and model fitness.
Compare
Conclude
One of the main parts of this research study is to identify the optimal
operating parameters for bleaching and degumming processes. There are various
operating conditions for degumming and bleaching processes of palm refining. Based
on preliminary studies through surveys and literature it is found that the optimal
operating conditions for a typical configuration of palm oil refinery are identified as
per shown in Table 5.1 below;
It is found out that from the preliminary survey, the bleaching and
degumming processes is conducted under vacuum condition of about 50 torr.
Operating under vacuum condition is desired in the operation of bleaching process
while removing all the unwanted gums (from precipitation during degumming), trace
metals, peroxides and some volatile and oxidized products in order to keep the
moisture level low. It is important in order to keep the moisture level low as high
level of moisture must be avoided since it might hydrolyzed the triglycerides causing
more formation of free fatty acids and thus affecting the stability of oil.
From the preliminary studies survey, 30 minutes of contact time is the normal
time cycles used for bleaching process by the refiners in Malaysia. Although, higher
efficiency of bleaching process can be achieved by increasing the bleaching time but
by increasing the contact time between bleaching earth and the degummed oil, the
daily production of a refinery will be affected, as the overall refinery operating time
will be increased. And consequently affect the profit of a refinery, since it will
reduce the daily production. Therefore, a commercial equilibrium balance should be
considered between the lower cycle times and higher daily production. Thus, it can
be concluded that the optimal bleaching and degumming time for a typical
configuration of palm oil refinery is 30 minutes.
The crude palm oil (CPO) samples used in this research study were obtained
from Pandamaran Delima Oil, Klang (for high FFA content) and Golden Jomalina
Food Ind., Sdn Bhd, Banting (for low FFA content). Due to the inconsistent content
of FFA content in CPO samples obtained, the samples were divided into 3 main
categories namely;
(1) Category A: CPO with FFA content less than 2.5%
(2) Category B: CPO with FFA content between 2.6 –3.5%
(3) Category C: CPO with FFA content more than 3.6%
5.2.5 Bleaching Earth and Phosphoric Acid Quality
Bleaching earth and phosphoric acid used were obtained from Pandamaran
Delima Oil, Klang Selangor. Bleaching earth used is acid activated clays and
phosphoric acid is 85% concentrated.
The ranges of these parameters are set as per tabulated in Table 3.1 below.
These ranges are identified based on the maximum acceptable and allowable values
used by the refiners.
Table 5.2: Ranges of parameters
Parameters Range
Dosage of phosphoric acid Maximum : 1.00 % (per 1MT of CPO)
Dosage of bleaching earth Maximum : 2.00% (per 1MT of CPO)
FFA Maximum: 5 %
Quality of CPO Moisture Maximum : 2 %
DOBI 2-3.5
Peroxide Value 1.5-5 meq/kg
Phosphorus 10-18 ppm
Iron (Fe) 4-10 ppm
5.3 Experimental Rigs of Degumming and Bleaching
Experimental rigs are designed and set up, according to the optimal
conditions for a typical a typical configuration of palm oil refinery, which are 100oC,
under vacuum of 50 torr and contact time of 30 minutes;
5.3.1 Equipment
Vacuum Pressure
Indicator
Vacuum Pressure
Controller CPO Samples
Heating Element
Temperature Controller
& Indicator
Figure 5.2: Rotavapor unit used for deguming and bleaching process
5.3.2 Experimental Procedure for Degumming and Bleaching Processes
In this study, the CPO sample used for degumming and bleaching processes
is 500g for each run. The CPO sample, bleaching earth and phosphoric acid are put
into a conical flask before it is attached to rotavapor unit.
Heating element used in this experiment is silicon oil. The silicon oil is
initially heated up to 100oC and vacuum is set to 50 torr before attaching the conical
flask containing the CPO sample, certain dosages of bleaching earth and phosphoric
acid.
The dosages of bleaching earth and phosphoric acid are added accordingly
based on the experimental arrangement given by the DOE as shown later in Table
5.3, in section 5.3.
When 100oC temperature and 50 torr vacuum are achieved, the bleaching and
degumming processes will be carried out for 30 minutes and the mixture will be
rotated continuously in order to have complete mixing between CPO, phospohoric
acid and bleaching earth.
After 30 minutes, the degummed and bleached oil (DBPO) will be filtered
with Whatman filter paper under vacuum as soon as possible in order to prevent any
undesirable oxidation. Thereafter, the further quality checking experiments will be
carried out for analysis.
5.4 Quality Checking Parameters Experiment & Experimental Procedures
The experiments for CPO and DBPO qualities are conducted based on the
standard method by PORAM and AOCS.
Free fatty acids content in the crude palm oil or degummed and bleached oil
can be determine by using titration method according to the PORIM Test Methods
(1995). The experimental procedures for the FFA content determination are as
follow;
(a) Prepare the sample for the analysis by melting the sample at 60 oC to 70
o
C and thoroughly homogenise it before sampling
(b) Determine the size of sample from the following table
Sodium
Hydroxide
DBPO
sample
The experimental procedures for the determination for DOBI value are as
follows:
(a). Weigh about 0.1 g of completely melted and homogenised palm oil sample
into 25 ml volumetric flask. Dissolve in so-octane or n-hexane (0.5 –1.0 %
concentration) and make-up to the desired volume.
(b). Fill a 10 mm cuvettes with oil solution and measure its absorbances at 269
nm and 446 nm against pure solvent using spectrophotometer (Figure 5.4)
Spectrophotometer
Cuvettes
where ;
Vs = volume in ml of sodium thiosulphate solution of normality N
used for the determination
Vb = volume in ml of sodium thiosulphate solution of normality N
used for the blank test.
W = weight in grams of the test portion
N = normality of sodium thiosulphate solution
5.4.4 Phosphorus Content Experiment
This method determines total phosphorus content by charring and ashing in the
presence of magnesium oxide followed by colorimetric measurement as
phosphovanadomolybdic complex. The procedures are described as below:
Figure 5.5: Furnace used for the determination of phosphorus content experiment
Mixture of CPO &
magnesium oxide
Figure 5.6: Crucible porcelain containing CPO sample and magnesium oxide
(a) Weigh accurately about 15-20 g of well-mixed palm oil sample into
tared filter flask containing a magnetic bar as a part of tared weight.
(b) Add 5 ml acetone, using graduated cylinder. Stoppered the flask and
placed in glycerol bath which is heated by means of electric hot plate.
(c) The flask is placed under vacuum and with continuous stirring, heated
to 100 oC for 20 min
(d) Remove the flask from the hot bath and cooled at the room temperature
while maintaining the vacuum.
(e) Carefully release the vacuum and dry the flask. Place the flask in
desiccator (Figure 5.6) for a few minutes and weighed.
The experiment measures iron in palm oil dissolved in methyl isobutyl ketone
(MIBK). The method used will be based on the PORIM Test Methods (1995). The
principal of this experiment is analysing the iron by direct aspiration. The
experimental procedures are divided into 2 parts:
(a) Weigh exactly 250.00 gn of RBD palm oil in a clean 500 ml round
bottom flask
(b) Weigh 0.1581 g of Ferric acetlacetone in a clean 50 ml beaker
(c) Dissolve the salt in approximately 25 ml ethanol and transfer
quantitatively to the flask. Wash the beaker thoroughly with a further 25
ml ethanol into the flask.
(d) Evaporate all the ethanol from the oil using rotary evaporator under
vacuum at 60 oC until constant weight.
* P: Phosphorus
Fe: Iron
The response factors or outputs were phosphoric acid dosage (Y1) and
bleaching earth dosage (Y2).
In modelling a neural network, after dividing the experimental data for
training and validation, the next step is to do normalization of experimental data.
This is because the process inputs for neural network models were inconsistent in
term of their magnitudes. Therefore, these input data were scaled to be within a
consistent range (from 0 to 1), before introducing them to the input layer of the
network to ensure that each data was given a fair contribution in determining the
network output. The data scaling method employed in this research is shown as
follows:
X i - X i min
X is =
X i max - X i min
where, X is is scaled input and X i is the actual input before scaling whereas X i min and
X i max are the minimum and maximum values of the inputs respectively. The
maximum and minimum values of the input were selected based on training data.
As mention previously, there are two types of networks were developed and
studied namely;
(i) Multi-Input Single-Output (MISO) network
(ii) Multi-Input Multi-Output (MIMO) network.
Two MISO (MISO 1 and MISO2) and one MIMO networks were developed,
as per shown in Figure 5.7. A back-propagation feed forward neural network was
employed for both networks.
Figure 5.7 :
The selection criterion is dependent on the efficiency of the two networks in
predicting the process output. Therefore, the performance of both networks were
tested and compared. The best network with smallest error was chosen to represent
the process.
The M-file for MISO network of each response factors (phosphoric acid
dosage (Y1) and bleaching earth dosage (Y2) are shown in Appendix C and D.
Whereas, the M-File for MIMO network is shown in Apendix E.
Neural Network toolbox in MATLAB 7 was used to design and simulate the
networks. The transfer functions employed in the networks were log-sigmoid transfer
function and purelin transfer function and the networks were trained using
Levenberg-Marquardt learning algorithm (Trainlm).
The network with smallest root mean sum of squares of the errors (RMSE)
was selected to represent the process. The values of weights and biases associated to
each connection between neurons of adjacent layers of chosen network were
obtained. The RMSE is defined as
∑ (Observed − Pr edicted )
2
RMSE =
No. of Data
(a)
(b)
Figure 3.4 Feed Forward Neural Networks Topology (a) MISO Neural Networks
(b) MIMO neural Networks
There were 22 experimental data used to develop the neural networks models
where 16 experimental data arranged by response surface methodology were
employed as training data and six experimental data were used as generalized data or
validation data
W2
FFAi
W3
DOBIi W4
W5
PVi
W6
Pi W7
(a)
W8
H2Oi
W9
Fei W10
W11
FFAo
W12
DOBIo W13
W14
PVo
W15
Po W16
W17
H2Oo
W18
W19
Feo
W20
b1
W21
W22
Bias 1
W23
W24
119
CHAPTER 6
In this research, there are two methods in the determining the suitable ratio of
phosphoric acid and bleaching earth dosage to be added to degumming and bleaching
process of palm oil refining, which is via experimental works and through modelling
of ANN.
For ANN modelling part, the experimental data obtained are also then be
used as the input vectors to the network. Three NN models (two MISO and one
MIMO) were developed and compared in which the best model will be selected best
on the smallest error generated.
These results will at the end gives some valuable information that would
suggest some improvements to the degumming and bleaching practices in Malaysia’s
palm oil refineries.
120
The graphs are plotted based on varying the bleaching earth dosage at
constant phosphoric acid dosage at 0.5 wt% and 1.0 wt% for each parameter
involved.
121
4.5
4.0
FFA Content (%)
3.5
3.0
2.5
2.0
1.5
1.0
0.5
0.0
0 1 1 1 2
BE dosage
Before degumming & bleaching After degumming & bleaching
Figure 6.1: FFA Content of CPO Before & After Degumming and Bleaching
Processes at 0.5 wt % of Phosphoric Acid
5.0
FFA Content (%)
4.0
3.0
2.0
1.0
0.0
0 0 1 2 2
BE dosage
Figure 6.2: FFA Content of CPO Before & After Degumming and Bleaching
Processes at 1.0 wt % of Phosphoric Acid
122
Higher FFA means lower triglyceride (TG) since FFA is derived from
triglycerides (TG). In addition, high FFA not only infers lower extractable oil but
also corresponds to the higher content of emulsifiers namely diglycerides (DG) and
monoglyceride (MG) and significant presence of DG and MG has shown effects on
crystallization of oil during fractionation process (Abdul Azis, 2000).
Figure 6.1 and 6.2 show the effects on FFA content on all categories of CPO
(A, B and C) by varying the bleaching earth dosage at 0.5 wt% and 1.0 wt%
phosphoric acid dosage respectively.
Generally, the graph in Figure 6.1 shows the content of FFA is found higher
after degumming and bleaching processes, for all points due to acidic nature of
phosphoric acid added and due to splitting or hydrolysis of triglyceride by heating.
The reaction is shown as below, (Gapor and Chong, 1985);
From the graph, when phosphoric acid is added at 0.5 wt % but with no bleaching
earth the increment of FFA content is highest about 0.44 %. This is because no
adsorption process occurs due to the absence of bleaching earth.
123
However, even though bleaching earth are added during the degumming and
bleaching process there is still some rise (about 0.2 - 0.35%) of the FFA content in
degummed oil. Traces of phosphoric acid remaining in the oil after degumming
treatment are said to be responsible for such situation to occur (Rossi et al. 2003).
For this graph, the lowest FFA increment detected is for category A of oil at 1.0 wt%
of bleaching earth with 0.5 wt% phosphoric acid which is about 0.21% Figure 61.
Figure 6.2 shows the effect on FFA content at various dosage of bleaching
earth at 1.0 wt% of phosphoric acid. From the graph, it can be observed that similar
trend with the previous graph, where when there is no bleaching earth added to the
degumming and bleaching treatment (means adsorption process), the rise in FFA
content is quite high, about 0.8% in average. This rise of FFA is also attributed to the
higher acidity of phosphoric used during the treatment which is 1.0 wt%.
Based on the both graphs it can be deduced that the optimal dosage of
bleaching earth and phosphoric acid for all categories of CPO (A,B and C) is 1.0 –
2.0 wt% and 0.5 –1.0 wt% respectively
124
4.5
4.0
3.5
DOBI Value
3.0
2.5
2.0
1.5
1.0
0.5
0.0
0 1 1 1 2
BE Dosage
Figure 6.3: DOBI Value of CPO Before & After Degumming and Bleaching
Processes at 0.5 wt % of Phosphoric Acid
3.5
3.0
2.5
DOBI Value
2.0
1.5
1.0
0.5
0.0
0 0 1 2 2
BE Dosage
Figure 6.4: DOBI Value of CPO Before & After Degumming and Bleaching
Processes at 1.0 wt % of Phosphoric Acid
125
According to Abdul Azis (2000), all refineries will undoubtedly prefer crude
palm oil (CPO) exhibiting good DOBI value which is minimum of 2.3 and the value
will equate nicely with reduced bleaching earth requirement. Low DOBI value
relates to high oxidation products. High oxidation products require high dosage of
bleaching earth.
Therefore, with high oxidation products (low DOBI) and with increase of
FFA, the cost of utilities on a per tonne basis of RBDPO production will
subsequently increased. The deodorization conditions may have to be reformatted to
ensure complete removal of stubborn volatiles (oxidized products, moisture, carotene
and its derivatives) and all remnants of FFA. These measures will associate with
higher utility requirements (Abdul Azis, 2000).
Figure 6.3 and 6.4 show the effects on DOBI value on all categories of CPO
(A, B and C) by varying the bleaching earth dosage at 0.5 wt% and 1.0 wt%
phosphoric acid dosage respectively.
Generally for the graph in Figure 6.3, all the CPO samples used exhibit a
good DOBI value which is higher than 2.3. This indicates that all the samples used
have low oxidation products. After degumming and bleaching processes, the DOBI
values are generally reduced. However, the reduction in DOBI value is quite small,
when there is no bleaching earth is added to the process. Thus, no adsorption process
of oxidized products can take place due to the absence of bleaching earth. But, it
seems that an effective degumming and bleaching process happen for category A of
oil when the bleaching earth added is at 1.0 wt% where the reduction of DOBI value
is more than half of its initial value (from 3.84 to 1.61).
Whereas for the samples used for the second graph in Figure 6.4, all the
samples except for the last sample (category C) of oil, exhibit good DOBI values. An
effective degumming and bleaching process seems to happen for category B and A of
oil when the bleaching earth added is at 1.0 wt% and 2.0 wt% respectively. The
reduction of DOBI values for both categories is about 1.2.
126
4.0
3.5
3.0
PV (meq/kg)
2.5
2.0
1.5
1.0
0.5
0.0
0 1 1 1 2
BE Dosage
4.0
3.5
3.0
PV (meq/kg)
2.5
2.0
1.5
1.0
0.5
0.0
0 0 1 2 2
BE Dosage
Figure 6.5 and 6.6 show the effects on peroxide value (PV) on all categories
of CPO (A, B and C) by varying the bleaching earth dosage at 0.5 wt% and 1.0 wt%
phosphoric acid dosage respectively.
Unlike FFA, the variations in bleaching earth and phosphoric acid dosage
affecting values of PV, the graphs will be discussed together. Overall, for both
graphs the peroxide value (PV) decreases after degumming and bleaching processes.
For both graphs, the decrease in PV is quite small when no bleaching earth is added
at 0.5 wt% of phosphoric acid. This proves that degumming treatment by itself
reduces only slightly the PV value.
16
14
12
10
8
6
4
2
0
0 1 1 1 2
BE Dosage
Before degumming & bleaching After degumming & bleaching
Figure 6.7: Phosphorus Content of CPO Before & After Degumming and Bleaching
Processes at 0.5 wt % of Phosphoric Acid
20
18
16
14
12
10
8
6
4
2
0
0 0 1 2 2
BE Dosage
Figure 6.8: Phosphorus Content of CPO Before & After Degumming and Bleaching
Processes at 1.0 wt % of Phosphoric Acid
130
Figure 6.7 and 6.8 show the effects on phosphorus content on all categories of
CPO (A, B and C) by varying the bleaching earth dosage at 0.5 wt% and 1.0 wt%
phosphoric acid dosage respectively.
In general, for both graphs, the phosphorus content is higher before the
degumming and bleaching processes. After the degumming and bleaching process,
the phosphorus content is generally reduced. However, for both graphs when there is
no bleaching earth added, the amount of phosphorus reduction is considered small
about 1-2 ppm. This is because no adsorption of phosphors can occur due to the
absence of bleaching earth
Whereas, for the graph in Figure 6.8, the reduction of phosphorus occurred
efficiently at bleaching earth of 2 wt % with 1.0 wt% of phosphoric acid. This proves
the deduction made by Wei et al., (2003), that the reduction of phosphorus is
proportional to the bleaching earth dosage; higher bleaching earth dosage the better
the reduction of phosphorus in oil.
132
2.5
Moisture Content (%)
2.0
1.5
1.0
0.5
0.0
0 1 1 1 2
BE Dosage
Before degumming & bleaching After degumming & bleaching
Figure 6.9: Moisture Content of CPO Before & After Degumming and Bleaching
Processes at 0.5 wt % of Phosphoric Acid
4.0
3.5
Moisture Content (%)
3.0
2.5
2.0
1.5
1.0
0.5
0.0
0 0 1 2 2
BE Dosage
Figure 6.10: Moisture Content of CPO Before & After Degumming and Bleaching
Processes at 1.0 wt % of Phosphoric Acid
133
The main reactions that cause the quality deterioration of palm oil are
hydrolysis and oxidation. Among the factors that causing these reactions are the
presence of moisture and trace metals content (Gapor and Chong, 1985).
The presence of moisture could cause the hydrolysis of palm oil triglycerides
resulting in the formation of free fatty acids (FFA) and partial glycerides (Gapor and
Chong, 1985) and the reaction is as per shown in equation 6.1 earlier.
Figure 6.9 and 6.10 shows the effects of phosphoric acid and bleaching earth
dosage on moisture content during degumming and bleaching processes for all
categories of CPO (A, B and C).
134
When the bleaching earth dosage is added at 1wt% and 2 wt%, the moisture
content is reduced up to acceptable level of DBPO between 0.16 – 0.19 %. From
Figure 6.9, it seems the moisture adsorption process on bleaching earth surface
occurred effectively at the dosage of 0.5 wt% phosphoric acid and 1wt % bleaching
earth, as it reduces the level of moisture content from 2.11 % to 0.27%.
Same trend are observed in Figure 6.10, where the moisture level becomes
higher after degumming and bleaching processes when 1.0 wt% phosphoric acid are
added but with absence of bleaching earth. Nevertheless, the increase of moisture
content is relatively higher (0.7 - 0.9 %) compared to when 0.5 wt% of phosphoric
acid (0.5 %) with no bleaching earth are added to the CPO. This is because higher
moisture content in 1wt% of phosphoric acid compared to 0.5 wt% of phosphoric
acid.
135
5.0
4.5
Iron Content (ppm)
4.0
3.5
3.0
2.5
2.0
1.5
1.0
0.5
0.0
0 1 1 1 2
BE Dosage
Figure 6.11: Iron Content of CPO Before & After Degumming and Bleaching
Processes at 0.5 wt % of Phosphoric Acid
5.0
4.5
Iron Content (ppm)
4.0
3.5
3.0
2.5
2.0
1.5
1.0
0.5
0.0
0 0 1 2 2
BE Dosage
Figure 6.12: Iron Content of CPO Before & After Degumming and Bleaching
Processes at 1.0 wt % of Phosphoric Acid
136
Trace metals such as iron and copper, present in palm oil are chiefly present
in the form of metal soaps produced by the action of free fatty acids on storage tanks
and other metallic equipment (Shaw and Tribe, 1983). It is believed that, these
metals exhibit pro-oxidant effect on the oil by being catalyst to the decomposition of
hydroperoxides. Equation 6.2 below shows the decomposition of hydroperoxides due
to iron;
It can be envisaged that two possible mechanisms exists for iron and copper
removal (Shaw and Tribe, 1983);
According to Shaw and Tribe, (1983) treatment of palm oil with bleaching
earth with phosphoric acid followed by bleaching earth gave residual iron levels
much lower than bleaching earth alone or phosphoric acid alone. Thus, it is important
to have combination process of degumming and bleaching to give optimum
performance, in order to obtain the desired level of iron in DBPO and to produce an
excellent decolourised and purified palm oil with good stability towards
autoxidation.
Figure 6.11 and 6.12 shows the effects phosphoric acid and bleaching earth
dosage on iron content during degumming and bleaching processes for all categories
of CPO (A, B and C).
137
From the graph in Figure 6.11, when there is no bleaching earth are added in
the process, the reduction in iron content is not much significant as the removal
process of iron is due to degumming treatment alone. However, when both
degumming and bleaching processes occurred at 1.0 –2.0 wt% of bleaching earth and
0.5 wt % of phosphoric acid the removal process of iron is effective.
Based on the experimental data analysis done, it can be concluded that the
removal or reduction level of moisture, phosphorus, peroxide value (PV) and DOBI
are mainly due to bleaching treatment process. Whereas degumming treatment is
responsible for influencing the increment in FFA level in CPO and DBPO. For iron,
both degumming and bleaching processes are essential to ensure the removal process
run effectively.
In this study, three layers of MIMO and MISO network were developed the
model for prediction of phosphoric acid and bleaching earth dosage.
From Table 6.1, it can be observed that the validation error increased as the
number of nodes in hidden layer increased. For example, in MISO 1 network, the
validation error increased from 0.6305 to 1.1924 when number of nodes in hidden
layer increased from 24 to 26.
Same trend was also observed for MISO 2 and MIMO network. In MIMO
network, the validation error increased from 0.9991 to 1.0950 when the number of
nodes in hidden layer increased from 24 to 26 nodes. As a result, it can be concluded
that the higher the number of nodes in hidden layer, higher validation error was
achieved in MIMO and MISO network.
From Table 6.1, it also can be observed that, the smallest validation errors of
MISO 1, MISO 2 and MIMO networks were observed when 24 nodes available in
the hidden layer with 0.6305, 0.0026 and 0.9991 respectively.
In addition, the value of validation error of MIMO network was larger than
MISO 1 and MISO 2 network. This was most likely caused by the over trained
network due to the complexity of the network that allow too many iterations.
From the analyses done, it can be concluded that, the optimum hidden layer
nodes for MIMO and MISO network is 24 nodes. Interesting observation was
obtained in which the validation error and training error increased as the number of
nodes increased after the network reached its optimum network for MISO networks.
This is perhaps due to the result of over trained network which occur when the
capacity of the ANN for training is too great to allow too many training iterations
(Yin et al., 2003)
141
Table 6.1: Training and Validation Error of MISO and MIMO networks for various number of nodes in hidden layer.
No. of Nodes 24 25 25
The criterion to select the most optimum network among the networks tested
is based on the smallest cross-validation errors produced. Thus, from the result in
Table 6.1, the optimum MISO network for response factor of phosphoric acid dosage
and bleaching earth dosage prediction were selected from topologies with 12 input
nodes, 24 hidden layer nodes and one output node. The selection of the network was
based on the smallest validation error among other hidden layer nodes.
where wij , aij and b j represent weight, input and bias of i row in j layer. Once the
node was calculated, it passed the result to the transfer function, f ( y ) . The functions
used in this study were sigmoidal function and purelin function because the
normalization value of training and validation data for this simulation were in the
range of 0 to 1. Thus, the complete node calculation for a sigmoidal function was:
1
f ( y) = …………………………………..6.4
1 + e−y
f ( y) = y ……………………………………..6.5
Therefore, the input weight, layer weight and biases for all the input namely
FFA, DOBI, PV, Phosphorus, moisture, and iron are presented in Table 6.2 for
optimum MISO network of 12 input nodes, 24 hidden layer nodes and one output
node with phosphoric acid dosage and bleaching earth dosage respectively. The
initial value of weights and biases were set to 0 for all MISO networks.
In addition, Table 6.5 shows the input weight, layer weight and biases for
MIMO network to predict hydrogen selectivity and H2/CO ratio. The initial value of
weights and biases were also set to 0 for MIMO network.
144
Table 6.2: The value of biases and weight for back-propagation model for MISO 1 and MISO 2 network
3.8076
-3.2642
-3.0170 Columns 1 through 9
-2.7032
2.3636 0.8476 0.0923 0.2623 0.0686 -0.6295
-2.2543
-1.7443 -0.0477 0.0030 0.2455 0.4980
Phosphoric Refer to Table 6.3 -1.5053
1.1024
Acid -0.8244
0.7833
Columns 10 through 18
Dosage -0.3874
-0.1838 -0.9316 -0.2888 1.2398 0.3311 -0.5409
(MISO 1) 0.9276
0.3723 1.0028 -0.2718 -0.0698 1.0064
-0.9117
1.1216
-1.2967
-1.8235 Columns 19 through 24
-2.0356
-2.6445 0.8068 -0.2802 -1.4940 -0.2896 -1.1511
2.5204
3.0226 - 0.6698
-3.2656
3.5141
145
3.7843
3.3615
3.1318 Columns 1 through 9
-2.6985
-2.4426 -0.5640 -0.0027 -0.8642 0.0691 -0.3999
2.1195 0.7023 1.3788 -0.7725 0.5487
-1.4090
-1.4335
-1.1400
Bleaching -0.8856
Columns 10 through 18
Earth Refer to Table 6.4 0.8565 -0.7506
-0.1284 -0.8471 -1.0427 -0.3500 -0.1677 -0.6376
Dosage 0.1057 0.3788 -0.0418 0.7541 0.8467
0.5493
(MIMO 2)
0.7458
-1.2919 Columns 19 through 24
-1.4247
1.8070 0.3356 0.2461 0.5496 0.8463 0.9447
2.0467
-2.4080 0.3717
2.7698
-2.9673
-3.3607
-3.6404
146
-1.6567 0.7457 0.4149 -1.31 0.3496 0.8274 0.9474 1.2256 0.88 1.3469 0.8047 1.3556
1.7544 1.037 0.8621 -0.6345 0.8843 1.718 0.8107 -0.7724 0.5217 0.7824 1.6136 -0.377
1.4493 1.1046 -1.429 0.3825 -0.7679 0.1984 1.2193 1.3727 0.2202 -1.4927 -1.2004 0.1121
0.3466 0.5758 -0.2428 -1.0961 -0.798 -1.6295 -0.9711 -1.3313 -0.8546 -1.4456 -1.2704 -1.065
-1.0007 -1.2545 -0.5194 0.7495 1.1472 0.5503 -0.148 -1.4932 1.5043 -1.6587 1.3063 0.2439
1.2495 -0.5733 -1.2435 -1.1301 0.9608 1.0781 -1.5311 -0.8079 -0.9555 -1.2022 0.7806 -0.0822
0.0513 0.4545 1.2006 0.316 1.7568 1.7249 1.2697 1.5581 0.914 0.0559 0.5472 0.5755
1.0708 0.2247 1.6425 -0.0005 -0.1681 -1.2209 0.1709 -2.1207 0.8449 -0.1239 1.2252 0.8401
-0.3072 -1.7456 -0.1903 -0.1563 1.5735 0.7946 -0.71 -0.9088 -1.1213 0.7952 0.6568 1.8125
1.5357 -1.4586 1.5659 0.0767 -0.0386 0.0869 -0.3727 1.8196 0.414 0.3122 1.4072 -1.0003
-1.2322 -0.8338 -1.0361 1.6503 0.9969 1.3029 1.3413 -1.0051 0.2831 0.0089 -0.675 -1.2371
Input weight 0.1545 -0.3529 1.7727 -1.0874 1.3574 1.2331 -0.8683 -0.1195 0.8776 -2.1219 -0.4833 -0.0253
-0.763 -0.0896 0.8867 -0.299 -1.1695 -0.9255 -1.5598 -0.7997 -1.1648 -1.0854 -1.0349 1.6885
1.3369 1.6293 -0.1038 -0.8871 -0.4742 -0.2997 -1.0915 0.7711 0.5109 -0.5683 -1.8235 -1.7235
-0.4865 0.1466 0.1147 -0.2996 -0.2517 -1.1269 -1.8556 1.5388 -1.1326 -0.5793 -1.4749 1.2503
0.6014 -0.5697 1.5629 -0.7337 0.7553 1.6655 0.1793 0.9022 0.1099 0.9686 1.2081 -1.6769
-2.2206 -0.0248 0.8853 -0.5531 0.3267 -0.8633 -1.8088 0.762 0.4954 -1.2167 -0.9778 0.0228
-0.6982 0.4993 -1.1478 -0.0081 -0.2217 -2.0029 0.0043 -1.8058 1.0095 0.7705 -0.1169 -1.4448
0.0022 -1.2377 -0.6005 0.8018 -0.1781 0.929 -1.3598 -1.5295 0.5991 1.7143 1.4813 0.6739
-0.286 1.2876 -1.2324 -0.5166 -1.1096 1.4393 0.9272 -1.4463 1.4122 0.1203 -0.7209 -0.593
-0.0989 1.81 0.1095 -1.4032 -0.3115 -0.9999 -0.5032 -0.3343 -1.7492 1.3459 1.0503 1.7691
0.5383 0.4956 -0.4399 -0.1924 -0.6205 -1.1745 1.4725 1.4778 -0.8654 1.5576 0.7542 -1.6433
-1.0637 -1.4128 0.1726 0.0027 -0.6313 1.3303 -1.2969 1.724 0.9342 1.3452 1.2329 0.4253
1.2495 1.1547 0.5046 -1.5873 1.028 -1.1684 0.3248 -1.263 -0.5957 -1.3201 -0.1206 1.5126
147
-1.2845 1.9211 0.8418 -1.0545 -0.1736 -1.4542 0.1363 0.3052 0.8041 0.0221 -0.0187 1.8057
-1.3545 0.1571 -1.2698 0.3053 -1.8491 -0.1139 -0.5626 -0.8984 1.0779 1.2813 1.4905 -0.2534
-0.603 0.0174 0.8144 2.1803 1.5369 0.4509 -0.9895 0.7374 -0.0471 -0.7793 1.2632 1.0373
1.6548 1.5711 -0.5478 0.4088 -0.1311 -1.0396 -0.4274 0.5144 -1.4933 0.8904 0.6096 1.6472
1.6281 -0.9379 0.5305 -1.4496 1.0161 0.1241 0.7338 1.4883 0.2807 -1.066 -0.5722 -1.398
-1.2763 -0.7118 0.1165 -1.2838 1.3403 0.6116 1.2424 -0.7909 1.3262 1.1618 -0.7465 -1.3493
0.9874 1.103 1.4139 -0.7306 0.7502 0.2754 -1.4638 -1.8554 -0.262 -1.4025 1.1286 0.581
0.05 1.406 -1.5171 1.0991 -0.5003 0.5477 -0.3304 -1.3809 1.1996 1.5264 -0.4637 -1.229
0.5453 0.5548 -0.2707 -1.8244 -1.3503 -0.4453 -0.7656 1.6226 1.2284 0.165 -1.2608 -1.5033
1.5111 -0.3449 1.357 -1.5764 0.5141 0.7969 1.329 -0.3882 0.6019 -0.1205 1.5476 -1.0946
-1.6761 1.3617 0.0545 -1.2584 -1.6574 -1.2073 0.8451 -0.1959 1.3976 -0.838 0.6656 0.1457
Input weight 1.4523 0.8545 1.078 -0.189 -0.4095 0.6548 1.2031 -1.4698 0.8372 1.5971 0.3872 -1.3358
0.7989 0.8457 -0.9474 0.9449 0.0907 1.2707 -1.4718 1.6473 -0.7802 0.7849 1.4075 0.6738
1.5587 0.7188 1.5397 -1.0779 0.7716 -1.3317 1.4042 1.6623 -0.0889 0.0569 -0.2108 0.6772
0.1028 1.8551 1.1812 -1.0316 -1.5239 -0.2876 0.1122 -0.3821 1.7928 0.2023 0.824 1.1461
-0.7109 -1.4798 1.4704 0.2912 1.175 0.9636 1.3765 0.9377 -1.0545 -0.6769 -0.5868 1.2511
-0.5725 1.5055 -0.8804 -0.5986 1.3724 1.1875 -0.152 0.719 -1.5786 0.7594 1.54 0.7421
0.2734 -0.7969 1.8669 -1.0559 -1.591 0.9419 0.5943 0.2302 -0.7334 0.3311 0.3362 -1.829
1.1379 1.2909 0.6285 1.5511 -0.6078 -1.3762 -0.0369 1.4864 -0.526 -1.5601 -0.2705 -0.5676
-0.8796 -0.7366 -0.16 -0.7869 0.8761 -1.3573 1.5735 1.3129 -1.537 0.9678 -0.9008 -0.5984
0.2181 0.9123 0.6171 -0.3502 0.0993 -1.5719 1.3115 -1.3089 -0.6539 -1.3321 1.5347 0.9842
-0.5823 0.8943 -1.7538 -1.2649 0.4946 1.2428 -0.294 1.4481 -0.9649 -1.1994 0.9452 0.6755
-0.1889 -1.3159 -1.3838 0.4747 0.7957 0.9406 0.9631 0.3606 -1.6267 -1.8313 0.2699 -1.0248
-0.4934 -1.9808 1.205 0.9834 0.6658 0.6883 -0.0484 -0.988 -0.8976 -0.0118 1.8441 0.8577
148
Table 6.5: The value of biases and weight of back-propagation model for MIMO network
In this study three ANN models were developed, which are two MISO
networks and one MIMO network. The criterion of selection for the best model is
based on the least validation error generated among these network. Thus, the
optimum network for response factor of phosphoric acid dosage and bleaching earth
dosage prediction were selected from topologies of MISO network with 12 input
nodes, 24 hidden layer nodes and one output node.
CHAPTER 7
6.1 Conclusions
2. The optimum number of experiment to be run for the study was determined
through Design of Experiment (DOE) method. There are 20 set of experiment
were arranged. All the 20 set of experiments with 6 quality checking
experiments each, has been determined through Central Composite Design
(CCD) technique via Response Surface Method (RSM) using Minitab 14
environment.
level in CPO and DBPO. For iron, both degumming and bleaching processes
are essential to ensure the removal process run effectively.
5. The optimum network for response factor of phosphoric acid dosage and
bleaching earth dosage prediction were selected from topologies of MISO
network with 12 input nodes, 24 hidden layer nodes and one output node.
6.2 Recommendations
Based on the results, discussions and experimental data analysis done, these
recommendations can be taken into considerations to upgrade future studies of
degummming and bleaching processes;
APPENDIX A
clear
clc
% ------------------------------------------------------------------------------------------------------
% INITIAL VALUES OF WEIGHT AND BIAS SET UP
%-------------------------------------------------------------------------------------------------------
net.IW{1,1} = [0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0
0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0
0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0
0 0 0 0 0 0 0 0 0 0];
net.b{1,1}= [ 0; 0; 0; 0;0; 0;0; 0; 0; 0; 0;0; 0];
net.b{2,1}=[0];
net.LW{2,1}= [ 0 0 0 0 0 0 0 0 0 0 0 0 0];
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR TRAINING
%---------------------------------------------------------------------------------------------------------
ffa=[ 3.05 1.21 1.35 2.90 3.69 1.48 3.12 3.23 1.36 3.09 2.90 3.76 3.81 3.65]; % input FFA in;
dobi = [3.000 3.835 2.375 2.345 2.218 3.203 2.980 2.222 3.038 2.986 2.977 2.380 2.390 3.001];
% input DOBI in;
moisture = [2.11 0.92 0.1 0.75 2.51 2.26 2.08 0.94 2.54 2.05 2.10 2.99 2.78 0.41]; % input
moisture in;
peroxide = [1.97 2.40 2.90 2.11 3.29 1.40 2.04 1.17 2.84 1.84 2.17 3.63 3.38 3.43]; % input
peroxide value in;
phosphorus = [10.18 10.30 12.02 10.72 16.84 10.46 11.14 10.46 11.06 10.51 11.03 16.00 18.2
13.44]; % input phosphorus in;
iron = [0.15 0.54 0.65 0.23 4.59 0.34 0.17 0.38 0.78 0.17 0.21 3.2 3.96 4.09]; % input iron in;
ffao=[3.40 1.42 1.42 3.14 4.48 2.30 3.32 3.84 1.39 3.46 3.30 3.97 4.07 3.87]; % input FFA out;
dobio = [1.798 1.610 1.972 1.622 1.578 1.920 1.810 2.030 3.808 1.813 1.805 2.788 2.047 1.820];
% input DOBI out;
moistureo = [0.27 0.16 0.98 0.19 0.25 0.39 0.25 0.63 2.46 0.24 0.29 2.82 3.57 0.15]; % input
moisture out;
peroxideo = [0 0 2.83 0 0 0 0 0 2.64 0 0 3.32 3.14 0]; % input peroxide value out;
phosphoruso = [4.14 4.18 10.5 3.52 3.1 3.14 4.21 10.24 10.18 4.21 4.11 15.4 16.7 11.88]; % input
phosphorus out;
160
irono= [0.11 0.28 0.04 0.12 2.07 0.24 0.13 0.13 0.49 0.12 0.18 3.19 0.44 1.31]; % input iron out;
pa = [0.5 0.5 1 0.5 1 1 0.5 0 0 0.5 0.5 0 1 0]; % input bleaching earth;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE TRAINING DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffai=1.21;
% maxffai=3.81;
[ffas,minffai,maxffai]=premnmx(ffa);
% mindobii=2.222;
% maxdobii=3.835;
[dobis,mindobii,maxdobii]=premnmx(dobi);
% minmoisturei=0.10;
% maxmoisturei=2.99;
[moistures,minmoisturei,maxmoisturei]=premnmx(moisture);
% minperoxidei=1.36;
% maxperoxidei=3.63;
[peroxides,minperoxidei,maxperoxidei]=premnmx(peroxide);
% minphosphorusi=10.18;
% maxphosphorusi=18.2;
[phosphoruss,minphosphorusi,maxphosphorusi]=premnmx(phosphorus);
% minironi=0.15;
% maxironi=4.59;
[irons,minironi,maxironi]=premnmx(iron);
% min ffaoi=1.39;
% max ffaoi= 4.48;
[ffaos,minffaoi,maxffaoi]=premnmx(ffao);
% mindobioi=1.610;
% maxdobioi=3.808;
[dobios,mindobioi,maxdobioi]=premnmx(dobio);
% minmoistureoi=0.15;
% maxmoistureoi=3.57;
[moistureos,minmoistureoi,maxmoistureoi]=premnmx(moistureo);
% minperoxideoi=0;
% maxperoxideoi=3.32;
[peroxideos,minperoxideoi,maxperoxideoi]=premnmx(peroxideo);
% minphosphorusoi=3.1;
161
% maxphosphorusoi=16.7;
[phosphorusos,minphosphorusoi,maxphosphorusoi]=premnmx(phosphoruso);
% minironoi=0.04;
% maxironoi=2.07;
[ironos,minironoi,maxironoi]=premnmx(irono);
% minpai=0;
% maxpai=1;
[pas,minpai,maxpai]=premnmx(pa);
M=14;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR VALIDATION
%---------------------------------------------------------------------------------------------------------
ffav =[1.25 2.94 3.10 3.04 2.84 3.74]; % input FFA in;
dobiv = [2.851 3.030 3.019 3.172 2.43 3.000]; % input DOBI in;
moisturev = [0.34 2.14 2.12 2.05 1.87 0.42]; % input moisture in;
peroxidev = [2.33 2.24 2.09 1.46 1.78 3.41]; % input peroxide value;
phosphorusv = [10.52 11.24 11.17 11.38 11.05 14.2]; % input phosphorus in;
dobiov =[1.938 1.779 1.910 1.994 1.978 2.214 ]; % input DOBI out;
162
moistureov = [0.18 0.31 0.26 0.64 2.38 0.19]; % input moisture out;
phosphorusov = [8.16 3.87 4.19 3.54 9.87 4.1]; % input phosphorus out;
ironov=[0.28 0.16 0.21 0.29 0.15 0.63]; % input iron out;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE VALIDATION.DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffaiv=1.25;
% maxffaiv=3.74;
[ffavs,minffaiv,maxffaiv]=premnmx(ffav);
% mindobiiv=2.43;
% maxdobiiv=3.172;
[dobivs,mindobiiv,maxdobiiv]=premnmx(dobiv);
% minmoistureiv=0.34;
% maxmoistureiv=2.14;
[moisturevs,minmoistureiv,maxmoistureiv]=premnmx(moisturev);
% minperoxideiv=1.46;
% maxperoxideiv=3.41;
[peroxidevs,minperoxideiv,maxperoxideiv]=premnmx(peroxidev);
% minphosphorusiv=10.52;
% maxphosphorusiv=14.20;
[phosphorusvs,minphosphorusiv,maxphosphorusiv]=premnmx(phosphorusv);
% minironiv=0.25;
% maxironiv=4.56;
[ironvs,minironiv,maxironiv]=premnmx(ironv);
% min ffaoiv=1.40;
% max ffaoiv= 3.97;
[ffaovs,minffaoiv,maxffaoiv]=premnmx(ffaov);
% mindobioiv=1.779;
% maxdobioiv=2.214;
[dobiovs,mindobioiv,maxdobioiv]=premnmx(dobiov);
% minmoistureoiv=0.18;
% maxmoistureoiv=2.38;
163
[moistureovs,minmoistureoiv,maxmoistureoiv]=premnmx(moistureov);
% minperoxideoiv=0;
% maxperoxideoiv=1.53;
[peroxideovs,minperoxideoiv,maxperoxideoiv]=premnmx(peroxideov);
% minphosphorusoiv=4.1;
% maxphosphorusoiv=9.87;
[phosphorusovs,minphosphorusoiv,maxphosphorusoiv]=premnmx(phosphorusov);
% minironiv=0.15;
% maxironiv=0.63;
[ironovs,minironoiv,maxironoiv]=premnmx(ironv);
% minpaiv=0;
% maxpaiv=1;
[pavs,minpaiv,maxpaiv]=premnmx(pav);
X=6;
%-----------------------------------------------------------------------------------------------------
% OBJECTIVE: NETWORK SETUP
%-----------------------------------------------------------------------------------------------------
S1=24; % Number of nodes
net=newff(minmax(tinput),[S1 1],{'logsig' 'purelin'},'trainlm');
net.trainparam.epochs=500; % Max epoch number
net.trainParam.goal=1e-5;
net.trainParam.show=10;
164
net.trainParam.max_fail=10;
net=init(net);
%---------------------------------------------------------------------
% Objective: to train, error calculation and predict the output for validation and training
% an= predicted data for training
%van=predicted data for validation
% error= predicted data- onserved data
% trainrmse= root mean square training error
% valmse= root mean square validation error
%----------------------------------------------------------------------
[net,tr]=train(net,tinput,toutput);
initIW=net.IW{1,1};
initB=net.b{1,1};
initLW=net.LW{2,1};
an=sim(net,tinput);
error=an-toutput;
trainmse=sumsqr(error)/M;
trainerr=sumsqr(error);
trainrmse=sqrt(trainerr/M);
van=sim(net,vinput);
verror=van-voutput;
valmse=sumsqr(verror)/X;
valerr=sumsqr(verror);
valrmse=sqrt(valerr/X);
165
APPENDIX B
clear
clc
% ------------------------------------------------------------------------------------------------------
% INITIAL VALUES OF WEIGHT AND BIAS SET UP
%-------------------------------------------------------------------------------------------------------
net.IW{1,1} = [0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0
0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0
0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0
0 0 0 0 0 0 0 0 0 0];
net.b{1,1}= [ 0; 0; 0; 0;0; 0;0; 0; 0; 0; 0;0; 0];
net.b{2,1}=[0];
net.LW{2,1}= [ 0 0 0 0 0 0 0 0 0 0 0 0 0];
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR TRAINING
%---------------------------------------------------------------------------------------------------------
ffa=[ 3.05 1.21 1.35 2.90 3.69 1.48 3.12 3.23 1.36 3.09 2.90 3.76 3.81 3.65]; % input FFA in;
dobi = [3.000 3.835 2.375 2.345 2.218 3.203 2.980 2.222 3.038 2.986 2.977 2.380 2.390 3.001];
% input DOBI in;
moisture = [2.11 0.92 0.1 0.75 2.51 2.26 2.08 0.94 2.54 2.05 2.10 2.99 2.78 0.41]; % input
moisture in;
peroxide = [1.97 2.40 2.90 2.11 3.29 1.40 2.04 1.17 2.84 1.84 2.17 3.63 3.38 3.43]; % input
peroxide value in;
phosphorus = [10.18 10.30 12.02 10.72 16.84 10.46 11.14 10.46 11.06 10.51 11.03 16.00 18.2
13.44]; % input phosphorus in;
iron = [0.15 0.54 0.65 0.23 4.59 0.34 0.17 0.38 0.78 0.17 0.21 3.2 3.96 4.09]; % input iron in;
ffao=[3.40 1.42 1.42 3.14 4.48 2.30 3.32 3.84 1.39 3.46 3.30 3.97 4.07 3.87]; % input FFA out;
dobio = [1.798 1.610 1.972 1.622 1.578 1.920 1.810 2.030 3.808 1.813 1.805 2.788 2.047 1.820];
% input DOBI out;
moistureo = [0.27 0.16 0.98 0.19 0.25 0.39 0.25 0.63 2.46 0.24 0.29 2.82 3.57 0.15]; % input
moisture out;
peroxideo = [0 0 2.83 0 0 0 0 0 2.64 0 0 3.32 3.14 0]; % input peroxide value out;
166
phosphoruso = [4.14 4.18 10.5 3.52 3.1 3.14 4.21 10.24 10.18 4.21 4.11 15.4 16.7 11.88]; % input
phosphorus out;
irono= [0.11 0.28 0.04 0.12 2.07 0.24 0.13 0.13 0.49 0.12 0.18 3.19 0.44 1.31]; % input iron out;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE TRAINING DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffai=1.21;
% maxffai=3.81;
[ffas,minffai,maxffai]=premnmx(ffa);
% mindobii=2.222;
% maxdobii=3.835;
[dobis,mindobii,maxdobii]=premnmx(dobi);
% minmoisturei=0.10;
% maxmoisturei=2.99;
[moistures,minmoisturei,maxmoisturei]=premnmx(moisture);
% minperoxidei=1.36;
% maxperoxidei=3.63;
[peroxides,minperoxidei,maxperoxidei]=premnmx(peroxide);
% minphosphorusi=10.18;
% maxphosphorusi=18.2;
[phosphoruss,minphosphorusi,maxphosphorusi]=premnmx(phosphorus);
% minironi=0.15;
% maxironi=4.59;
[irons,minironi,maxironi]=premnmx(iron);
% min ffaoi=1.39;
% max ffaoi= 4.48;
[ffaos,minffaoi,maxffaoi]=premnmx(ffao);
% mindobioi=1.610;
% maxdobioi=3.808;
[dobios,mindobioi,maxdobioi]=premnmx(dobio);
% minmoistureoi=0.15;
% maxmoistureoi=3.57;
[moistureos,minmoistureoi,maxmoistureoi]=premnmx(moistureo);
% minperoxideoi=0;
% maxperoxideoi=3.32;
[peroxideos,minperoxideoi,maxperoxideoi]=premnmx(peroxideo);
167
% minphosphorusoi=3.1;
% maxphosphorusoi=16.7;
[phosphorusos,minphosphorusoi,maxphosphorusoi]=premnmx(phosphoruso);
% minironoi=0.04;
% maxironoi=2.07;
[ironos,minironoi,maxironoi]=premnmx(irono);
% minbei=0;
% maxbei=2;
[bes,minbei,maxbei]=premnmx(be);
M=14;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR VALIDATION
%---------------------------------------------------------------------------------------------------------
ffav =[1.25 2.94 3.10 3.04 2.84 3.74]; % input FFA in;
dobiv = [2.851 3.030 3.019 3.172 2.43 3.000]; % input DOBI in;
moisturev = [0.34 2.14 2.12 2.05 1.87 0.42]; % input moisture in;
peroxidev = [2.33 2.24 2.09 1.46 1.78 3.41]; % input peroxide value;
phosphorusv = [10.52 11.24 11.17 11.38 11.05 14.2]; % input phosphorus in;
dobiov =[1.938 1.779 1.910 1.994 1.978 2.214 ]; % input DOBI out;
moistureov = [0.18 0.31 0.26 0.64 2.38 0.19]; % input moisture out;
phosphorusov = [8.16 3.87 4.19 3.54 9.87 4.1]; % input phosphorus out;
ironov=[0.28 0.16 0.21 0.29 0.15 0.63]; % input iron out;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE VALIDATION.DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffaiv=1.25;
% maxffaiv=3.74;
[ffavs,minffaiv,maxffaiv]=premnmx(ffav);
% mindobiiv=2.43;
% maxdobiiv=3.172;
[dobivs,mindobiiv,maxdobiiv]=premnmx(dobiv);
% minmoistureiv=0.34;
% maxmoistureiv=2.14;
[moisturevs,minmoistureiv,maxmoistureiv]=premnmx(moisturev);
% minperoxideiv=1.46;
% maxperoxideiv=3.41;
[peroxidevs,minperoxideiv,maxperoxideiv]=premnmx(peroxidev);
% minphosphorusiv=10.52;
% maxphosphorusiv=14.20;
[phosphorusvs,minphosphorusiv,maxphosphorusiv]=premnmx(phosphorusv);
% minironiv=0.25;
% maxironiv=4.56;
[ironvs,minironiv,maxironiv]=premnmx(ironv);
% min ffaoiv=1.40;
% max ffaoiv= 3.97;
[ffaovs,minffaoiv,maxffaoiv]=premnmx(ffaov);
% mindobioiv=1.779;
% maxdobioiv=2.214;
[dobiovs,mindobioiv,maxdobioiv]=premnmx(dobiov);
% minmoistureoiv=0.18;
% maxmoistureoiv=2.38;
169
[moistureovs,minmoistureoiv,maxmoistureoiv]=premnmx(moistureov);
% minperoxideoiv=0;
% maxperoxideoiv=1.53;
[peroxideovs,minperoxideoiv,maxperoxideoiv]=premnmx(peroxideov);
% minphosphorusoiv=4.1;
% maxphosphorusoiv=9.87;
[phosphorusovs,minphosphorusoiv,maxphosphorusoiv]=premnmx(phosphorusov);
% minironiv=0.15;
% maxironiv=0.63;
[ironovs,minironoiv,maxironoiv]=premnmx(ironv);
% minbeiv=0;
% maxbeiv=2;
[bevs,minbeiv,maxbeiv]=premnmx(bev);
X=6;
%-----------------------------------------------------------------------------------------------------
% OBJECTIVE: NETWORK SETUP
%-----------------------------------------------------------------------------------------------------
S1=24; % Number of nodes
net=newff(minmax(tinput),[S1 1],{'logsig' 'purelin'},'trainlm');
net.trainparam.epochs=500; % Max epoch number
net.trainParam.goal=1e-5;
net.trainParam.show=10;
170
net.trainParam.max_fail=10;
net=init(net);
%---------------------------------------------------------------------
% Objective: to train, error calculation and predict the output for validation and training
% an= predicted data for training
%van=predicted data for validation
% error= predicted data- onserved data
% trainrmse= root mean square training error
% valmse= root mean square validation error
%----------------------------------------------------------------------
[net,tr]=train(net,tinput,toutput);
initIW=net.IW{1,1};
initB=net.b{1,1};
initLW=net.LW{2,1};
an=sim(net,tinput);
error=an-toutput;
trainmse=sumsqr(error)/M;
trainerr=sumsqr(error);
trainrmse=sqrt(trainerr/M);
van=sim(net,vinput);
verror=van-voutput;
valmse=sumsqr(verror)/X;
valerr=sumsqr(verror);
valrmse=sqrt(valerr/X);
171
APPENDIX C
clear
clc
% ------------------------------------------------------------------------------------------------------
% INITIAL VALUES OF WEIGHT AND BIAS SET UP
%-------------------------------------------------------------------------------------------------------
net.IW{1,1} = [0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0
0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0
0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0
0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0];
net.b{1,1}= [ 0; 0; 0; 0;0; 0;0; 0; 0; 0; 0;0; 0;0];
net.b{2,1}=[0];
net.LW{2,1}= [ 0 0 0 0 0 0 0 0 0 0 0 0 0 0];
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR TRAINING
%---------------------------------------------------------------------------------------------------------
ffa=[ 3.05 1.21 1.35 2.90 3.69 1.48 3.12 3.23 1.36 3.09 2.90 3.76 3.81 3.65]; % input FFA in;
dobi = [3.000 3.835 2.375 2.345 2.218 3.203 2.980 2.222 3.038 2.986 2.977 2.380 2.390 3.001];
% input DOBI in;
moisture = [2.11 0.92 0.1 0.75 2.51 2.26 2.08 0.94 2.54 2.05 2.10 2.99 2.78 0.41]; % input
moisture in;
peroxide = [1.97 2.40 2.90 2.11 3.29 1.40 2.04 1.17 2.84 1.84 2.17 3.63 3.38 3.43]; % input
peroxide value in;
phosphorus = [10.18 10.30 12.02 10.72 16.84 10.46 11.14 10.46 11.06 10.51 11.03 16.00 18.2
13.44]; % input phosphorus in;
iron = [0.15 0.54 0.65 0.23 4.59 0.34 0.17 0.38 0.78 0.17 0.21 3.2 3.96 4.09]; % input iron in;
ffao=[3.40 1.42 1.42 3.14 4.48 2.30 3.32 3.84 1.39 3.46 3.30 3.97 4.07 3.87]; % input FFA out;
dobio = [1.798 1.610 1.972 1.622 1.578 1.920 1.810 2.030 3.808 1.813 1.805 2.788 2.047 1.820];
% input DOBI out;
moistureo = [0.27 0.16 0.98 0.19 0.25 0.39 0.25 0.63 2.46 0.24 0.29 2.82 3.57 0.15]; % input
moisture out;
peroxideo = [0 0 2.83 0 0 0 0 0 2.64 0 0 3.32 3.14 0]; % input peroxide value out;
172
phosphoruso = [4.14 4.18 10.5 3.52 3.1 3.14 4.21 10.24 10.18 4.21 4.11 15.4 16.7 11.88]; % input
phosphorus out;
irono= [0.11 0.28 0.04 0.12 2.07 0.24 0.13 0.13 0.49 0.12 0.18 3.19 0.44 1.31]; % input iron out;
pa = [0.5 0.5 1 0.5 1 1 0.5 0 0 0.5 0.5 0 1 0]; % input phosphoric acid;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE TRAINING DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffai=1.21;
% maxffai=3.81;
[ffas,minffai,maxffai]=premnmx(ffa);
% mindobii=2.222;
% maxdobii=3.835;
[dobis,mindobii,maxdobii]=premnmx(dobi);
% minmoisturei=0.10;
% maxmoisturei=2.99;
[moistures,minmoisturei,maxmoisturei]=premnmx(moisture);
% minperoxidei=1.36;
% maxperoxidei=3.63;
[peroxides,minperoxidei,maxperoxidei]=premnmx(peroxide);
% minphosphorusi=10.18;
% maxphosphorusi=18.2;
[phosphoruss,minphosphorusi,maxphosphorusi]=premnmx(phosphorus);
% minironi=0.15;
% maxironi=4.59;
[irons,minironi,maxironi]=premnmx(iron);
% min ffaoi=1.39;
% max ffaoi= 4.48;
[ffaos,minffaoi,maxffaoi]=premnmx(ffao);
% mindobioi=1.610;
% maxdobioi=3.808;
[dobios,mindobioi,maxdobioi]=premnmx(dobio);
% minmoistureoi=0.15;
% maxmoistureoi=3.57;
[moistureos,minmoistureoi,maxmoistureoi]=premnmx(moistureo);
% minperoxideoi=0;
% maxperoxideoi=3.32;
173
[peroxideos,minperoxideoi,maxperoxideoi]=premnmx(peroxideo);
% minphosphorusoi=3.1;
% maxphosphorusoi=16.7;
[phosphorusos,minphosphorusoi,maxphosphorusoi]=premnmx(phosphoruso);
% minironoi=0.04;
% maxironoi=2.07;
[ironos,minironoi,maxironoi]=premnmx(irono);
% minpai=0;
% maxpai=1;
[pas,minpai,maxpai]=premnmx(pa);
% minbei=0;
% maxbei=2;
[bes,minbei,maxbei]=premnmx(be);
M=14;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR VALIDATION
%---------------------------------------------------------------------------------------------------------
ffav =[1.25 2.94 3.10 3.04 2.84 3.74]; % input FFA in;
dobiv = [2.851 3.030 3.019 3.172 2.43 3.000]; % input DOBI in;
moisturev = [0.34 2.14 2.12 2.05 1.87 0.42]; % input moisture in;
peroxidev = [2.33 2.24 2.09 1.46 1.78 3.41]; % input peroxide value;
phosphorusv = [10.52 11.24 11.17 11.38 11.05 14.2]; % input phosphorus in;
dobiov =[1.938 1.779 1.910 1.994 1.978 2.214 ]; % input DOBI out;
moistureov = [0.18 0.31 0.26 0.64 2.38 0.19]; % input moisture out;
phosphorusov = [8.16 3.87 4.19 3.54 9.87 4.1]; % input phosphorus out;
ironov=[0.28 0.16 0.21 0.29 0.15 0.63]; % input iron out;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE VALIDATION.DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffaiv=1.25;
% maxffaiv=3.74;
[ffavs,minffaiv,maxffaiv]=premnmx(ffav);
% mindobiiv=2.43;
% maxdobiiv=3.172;
[dobivs,mindobiiv,maxdobiiv]=premnmx(dobiv);
% minmoistureiv=0.34;
% maxmoistureiv=2.14;
[moisturevs,minmoistureiv,maxmoistureiv]=premnmx(moisturev);
% minperoxideiv=1.46;
% maxperoxideiv=3.41;
[peroxidevs,minperoxideiv,maxperoxideiv]=premnmx(peroxidev);
% minphosphorusiv=10.52;
% maxphosphorusiv=14.20;
[phosphorusvs,minphosphorusiv,maxphosphorusiv]=premnmx(phosphorusv);
% minironiv=0.25;
% maxironiv=4.56;
[ironvs,minironiv,maxironiv]=premnmx(ironv);
% min ffaoiv=1.40;
% max ffaoiv= 3.97;
[ffaovs,minffaoiv,maxffaoiv]=premnmx(ffaov);
175
% mindobioiv=1.779;
% maxdobioiv=2.214;
[dobiovs,mindobioiv,maxdobioiv]=premnmx(dobiov);
% minmoistureoiv=0.18;
% maxmoistureoiv=2.38;
[moistureovs,minmoistureoiv,maxmoistureoiv]=premnmx(moistureov);
% minperoxideoiv=0;
% maxperoxideoiv=1.53;
[peroxideovs,minperoxideoiv,maxperoxideoiv]=premnmx(peroxideov);
% minphosphorusoiv=4.1;
% maxphosphorusoiv=9.87;
[phosphorusovs,minphosphorusoiv,maxphosphorusoiv]=premnmx(phosphorusov);
% minironiv=0.15;
% maxironiv=0.63;
[ironovs,minironoiv,maxironoiv]=premnmx(ironv);
% minpaiv=0;
% maxpaiv=1;
[pavs,minpaiv,maxpaiv]=premnmx(pav);
% minbeiv=0;
% maxbeiv=2;
[bevs,minbeiv,maxbeiv]=premnmx(bev);
X=6;
%-----------------------------------------------------------------------------------------------------
% OBJECTIVE: NETWORK SETUP
%-----------------------------------------------------------------------------------------------------
S1=20; % Number of nodes
net=newff(minmax(tinput),[S1 1],{'logsig' 'purelin'},'trainlm');
net.trainparam.epochs=500; % Max epoch number
net.trainParam.goal=1e-5;
net.trainParam.show=10;
net.trainParam.max_fail=10;
net=init(net);
%---------------------------------------------------------------------
% Objective: to train, error calculation and predict the output for validation and training
% an= predicted data for training
%van=predicted data for validation
% error= predicted data- onserved data
% trainrmse= root mean square training error
% valmse= root mean square validation error
%----------------------------------------------------------------------
[net,tr]=train(net,tinput,toutput);
initIW=net.IW{1,1};
initB=net.b{1,1};
initLW=net.LW{2,1};
an=sim(net,tinput);
error=an-toutput;
trainmse=sumsqr(error)/M;
trainerr=sumsqr(error);
trainrmse=sqrt(trainerr/M);
van=sim(net,vinput);
verror=van-voutput;
valmse=sumsqr(verror)/X;
valerr=sumsqr(verror);
valrmse=sqrt(valerr/X);
153
REFERENCES
Abdul Azis A (2000). The Effect of CPO Quality Parameters (FFA, M&I,
IV, PV, AV , DOBI and Colour) on the Refinery Production
Efficiency. Proceedings of the 2000 National Seminar on Palm Oil
Milling, Refining Technology, Quality and Environment. July 3-4.
Genting Hotel, Genting Highlands,Malaysia. 79-88
Ahmad I, Mohammad J A (1993). Selected Readings on Palm Oil and its
Uses. Palm Oil Familiarization Programme 1993 (POFP 2002). Kuala
Lumpur. 1-9
Ai T Y (1990). Analytical Techniques in Palm and Palm Kernel Oil
Specifications. 10th Palm Oil Familiarization Programme 1990 (POFP
1990). Bangi. 1-10
Amin N.A.S, Anggoro D.D. (2004). Optimization of Direct Conversion of
Methane to Liquid Fuels Over Cu Loaded W/ZSM-5 Catalyst. Fuel. (83):
487-494
Arrifin D, Fairus H (2002). Introduction to Malaysian Palm Oil Industry.
Palm Oil Familiarization Programme 2002 (POFP 2002). Kuala Lumpur.
1-15
Baughman D.R., Liu. Y.A. (1995). Neural Network in Bioprocessing and
Chemical Engineering. California. Academic Press Inc
Bernardini E (1985). Vegetable Oils and Fats Processing (Volume II).
Interstampa Rome Inc.
Bockish M. (1998). Fats and Oils Handbook. AOCS Press.
Borner G, Hollien J, Schneider M (2003). Latest Development of Cost
Savings for Bleaching Process. Proceedings of the PIPOC 2003
International Palm Oil Congress (Chemistry and Technology). 136-148
154
clear
clc
% ------------------------------------------------------------------------------------------------------
% INITIAL VALUES OF WEIGHT AND BIAS SET UP
%-------------------------------------------------------------------------------------------------------
net.IW{1,1} = [0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0
0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0
0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0
0 0 0 0 0 0 0 0 0 0];
net.b{1,1}= [ 0; 0; 0; 0;0; 0;0; 0; 0; 0; 0;0; 0];
net.b{2,1}=[0];
net.LW{2,1}= [ 0 0 0 0 0 0 0 0 0 0 0 0 0];
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR TRAINING
%---------------------------------------------------------------------------------------------------------
ffa=[ 3.05 1.21 1.35 2.90 3.69 1.48 3.12 3.23 1.36 3.09 2.90 3.76 3.81 3.65]; % input FFA in;
dobi = [3.000 3.835 2.375 2.345 2.218 3.203 2.980 2.222 3.038 2.986 2.977 2.380 2.390 3.001];
% input DOBI in;
moisture = [2.11 0.92 0.1 0.75 2.51 2.26 2.08 0.94 2.54 2.05 2.10 2.99 2.78 0.41]; % input
moisture in;
peroxide = [1.97 2.40 2.90 2.11 3.29 1.40 2.04 1.17 2.84 1.84 2.17 3.63 3.38 3.43]; % input
peroxide value in;
phosphorus = [10.18 10.30 12.02 10.72 16.84 10.46 11.14 10.46 11.06 10.51 11.03 16.00 18.2
13.44]; % input phosphorus in;
iron = [0.15 0.54 0.65 0.23 4.59 0.34 0.17 0.38 0.78 0.17 0.21 3.2 3.96 4.09]; % input iron in;
ffao=[3.40 1.42 1.42 3.14 4.48 2.30 3.32 3.84 1.39 3.46 3.30 3.97 4.07 3.87]; % input FFA out;
dobio = [1.798 1.610 1.972 1.622 1.578 1.920 1.810 2.030 3.808 1.813 1.805 2.788 2.047 1.820];
% input DOBI out;
moistureo = [0.27 0.16 0.98 0.19 0.25 0.39 0.25 0.63 2.46 0.24 0.29 2.82 3.57 0.15]; % input
moisture out;
peroxideo = [0 0 2.83 0 0 0 0 0 2.64 0 0 3.32 3.14 0]; % input peroxide value out;
phosphoruso = [4.14 4.18 10.5 3.52 3.1 3.14 4.21 10.24 10.18 4.21 4.11 15.4 16.7 11.88]; % input
phosphorus out;
irono= [0.11 0.28 0.04 0.12 2.07 0.24 0.13 0.13 0.49 0.12 0.18 3.19 0.44 1.31]; % input iron out;
be = [1 1 0 2 2 2 1 1 0 1 1 0 0 2]; % input bleaching earth;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE TRAINING DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffai=1.21;
% maxffai=3.81;
[ffas,minffai,maxffai]=premnmx(ffa);
% mindobii=2.222;
% maxdobii=3.835;
[dobis,mindobii,maxdobii]=premnmx(dobi);
% minmoisturei=0.10;
% maxmoisturei=2.99;
[moistures,minmoisturei,maxmoisturei]=premnmx(moisture);
% minperoxidei=1.36;
% maxperoxidei=3.63;
[peroxides,minperoxidei,maxperoxidei]=premnmx(peroxide);
% minphosphorusi=10.18;
% maxphosphorusi=18.2;
[phosphoruss,minphosphorusi,maxphosphorusi]=premnmx(phosphorus);
% minironi=0.15;
% maxironi=4.59;
[irons,minironi,maxironi]=premnmx(iron);
% min ffaoi=1.39;
% max ffaoi= 4.48;
[ffaos,minffaoi,maxffaoi]=premnmx(ffao);
% mindobioi=1.610;
% maxdobioi=3.808;
[dobios,mindobioi,maxdobioi]=premnmx(dobio);
% minmoistureoi=0.15;
% maxmoistureoi=3.57;
[moistureos,minmoistureoi,maxmoistureoi]=premnmx(moistureo);
% minperoxideoi=0;
% maxperoxideoi=3.32;
[peroxideos,minperoxideoi,maxperoxideoi]=premnmx(peroxideo);
% minphosphorusoi=3.1;
% maxphosphorusoi=16.7;
[phosphorusos,minphosphorusoi,maxphosphorusoi]=premnmx(phosphoruso);
% minironoi=0.04;
% maxironoi=2.07;
[ironos,minironoi,maxironoi]=premnmx(irono);
% minbei=0;
% maxbei=2;
[bes,minbei,maxbei]=premnmx(be);
M=14;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR VALIDATION
%---------------------------------------------------------------------------------------------------------
ffav =[1.25 2.94 3.10 3.04 2.84 3.74]; % input FFA in;
dobiv = [2.851 3.030 3.019 3.172 2.43 3.000]; % input DOBI in;
moisturev = [0.34 2.14 2.12 2.05 1.87 0.42]; % input moisture in;
peroxidev = [2.33 2.24 2.09 1.46 1.78 3.41]; % input peroxide value;
phosphorusv = [10.52 11.24 11.17 11.38 11.05 14.2]; % input phosphorus in;
dobiov =[1.938 1.779 1.910 1.994 1.978 2.214 ]; % input DOBI out;
moistureov = [0.18 0.31 0.26 0.64 2.38 0.19]; % input moisture out;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE VALIDATION.DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffaiv=1.25;
% maxffaiv=3.74;
[ffavs,minffaiv,maxffaiv]=premnmx(ffav);
% mindobiiv=2.43;
% maxdobiiv=3.172;
[dobivs,mindobiiv,maxdobiiv]=premnmx(dobiv);
% minmoistureiv=0.34;
% maxmoistureiv=2.14;
[moisturevs,minmoistureiv,maxmoistureiv]=premnmx(moisturev);
% minperoxideiv=1.46;
% maxperoxideiv=3.41;
[peroxidevs,minperoxideiv,maxperoxideiv]=premnmx(peroxidev);
% minphosphorusiv=10.52;
% maxphosphorusiv=14.20;
[phosphorusvs,minphosphorusiv,maxphosphorusiv]=premnmx(phosphorusv);
% minironiv=0.25;
% maxironiv=4.56;
[ironvs,minironiv,maxironiv]=premnmx(ironv);
% min ffaoiv=1.40;
% max ffaoiv= 3.97;
[ffaovs,minffaoiv,maxffaoiv]=premnmx(ffaov);
% mindobioiv=1.779;
% maxdobioiv=2.214;
[dobiovs,mindobioiv,maxdobioiv]=premnmx(dobiov);
% minmoistureoiv=0.18;
% maxmoistureoiv=2.38;
[moistureovs,minmoistureoiv,maxmoistureoiv]=premnmx(moistureov);
% minperoxideoiv=0;
% maxperoxideoiv=1.53;
[peroxideovs,minperoxideoiv,maxperoxideoiv]=premnmx(peroxideov);
% minphosphorusoiv=4.1;
% maxphosphorusoiv=9.87;
[phosphorusovs,minphosphorusoiv,maxphosphorusoiv]=premnmx(phosphorusov);
% minironiv=0.15;
% maxironiv=0.63;
[ironovs,minironoiv,maxironoiv]=premnmx(ironv);
% minbeiv=0;
% maxbeiv=2;
[bevs,minbeiv,maxbeiv]=premnmx(bev);
X=6;
%-----------------------------------------------------------------------------------------------------
% OBJECTIVE: NETWORK SETUP
%-----------------------------------------------------------------------------------------------------
S1=20; % Number of nodes
net=newff(minmax(tinput),[S1 1],{'logsig' 'purelin'},'trainlm');
net.trainparam.epochs=500; % Max epoch number
net.trainParam.goal=1e-5;
net.trainParam.show=10;
net.trainParam.max_fail=10;
net=init(net);
%---------------------------------------------------------------------
% Objective: to train, error calculation and predict the output for validation and training
% an= predicted data for training
%van=predicted data for validation
% error= predicted data- onserved data
% trainrmse= root mean square training error
% valmse= root mean square validation error
%----------------------------------------------------------------------
[net,tr]=train(net,tinput,toutput);
initIW=net.IW{1,1};
initB=net.b{1,1};
initLW=net.LW{2,1};
an=sim(net,tinput);
error=an-toutput;
trainmse=sumsqr(error)/M;
trainerr=sumsqr(error);
trainrmse=sqrt(trainerr/M);
van=sim(net,vinput);
verror=van-voutput;
valmse=sumsqr(verror)/X;
valerr=sumsqr(verror);
valrmse=sqrt(valerr/X);
MISO 1: MULTIPLE INPUT AND SINGLE OUPUT (PHOSPHORIC ACID DOSAGE)
clear
clc
% ------------------------------------------------------------------------------------------------------
% INITIAL VALUES OF WEIGHT AND BIAS SET UP
%-------------------------------------------------------------------------------------------------------
net.IW{1,1} = [0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0
0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0
0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0
0 0 0 0 0 0 0 0 0 0];
net.b{1,1}= [ 0; 0; 0; 0;0; 0;0; 0; 0; 0; 0;0; 0];
net.b{2,1}=[0];
net.LW{2,1}= [ 0 0 0 0 0 0 0 0 0 0 0 0 0];
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR TRAINING
%---------------------------------------------------------------------------------------------------------
ffa=[ 3.05 1.21 1.35 2.90 3.69 1.48 3.12 3.23 1.36 3.09 2.90 3.76 3.81 3.65]; % input FFA in;
dobi = [3.000 3.835 2.375 2.345 2.218 3.203 2.980 2.222 3.038 2.986 2.977 2.380 2.390 3.001];
% input DOBI in;
moisture = [2.11 0.92 0.1 0.75 2.51 2.26 2.08 0.94 2.54 2.05 2.10 2.99 2.78 0.41]; % input
moisture in;
peroxide = [1.97 2.40 2.90 2.11 3.29 1.40 2.04 1.17 2.84 1.84 2.17 3.63 3.38 3.43]; % input
peroxide value in;
phosphorus = [10.18 10.30 12.02 10.72 16.84 10.46 11.14 10.46 11.06 10.51 11.03 16.00 18.2
13.44]; % input phosphorus in;
iron = [0.15 0.54 0.65 0.23 4.59 0.34 0.17 0.38 0.78 0.17 0.21 3.2 3.96 4.09]; % input iron in;
ffao=[3.40 1.42 1.42 3.14 4.48 2.30 3.32 3.84 1.39 3.46 3.30 3.97 4.07 3.87]; % input FFA out;
dobio = [1.798 1.610 1.972 1.622 1.578 1.920 1.810 2.030 3.808 1.813 1.805 2.788 2.047 1.820];
% input DOBI out;
moistureo = [0.27 0.16 0.98 0.19 0.25 0.39 0.25 0.63 2.46 0.24 0.29 2.82 3.57 0.15]; % input
moisture out;
peroxideo = [0 0 2.83 0 0 0 0 0 2.64 0 0 3.32 3.14 0]; % input peroxide value out;
phosphoruso = [4.14 4.18 10.5 3.52 3.1 3.14 4.21 10.24 10.18 4.21 4.11 15.4 16.7 11.88]; % input
phosphorus out;
irono= [0.11 0.28 0.04 0.12 2.07 0.24 0.13 0.13 0.49 0.12 0.18 3.19 0.44 1.31]; % input iron out;
pa = [0.5 0.5 1 0.5 1 1 0.5 0 0 0.5 0.5 0 1 0]; % input bleaching earth;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE TRAINING DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffai=1.21;
% maxffai=3.81;
[ffas,minffai,maxffai]=premnmx(ffa);
% mindobii=2.222;
% maxdobii=3.835;
[dobis,mindobii,maxdobii]=premnmx(dobi);
% minmoisturei=0.10;
% maxmoisturei=2.99;
[moistures,minmoisturei,maxmoisturei]=premnmx(moisture);
% minperoxidei=1.36;
% maxperoxidei=3.63;
[peroxides,minperoxidei,maxperoxidei]=premnmx(peroxide);
% minphosphorusi=10.18;
% maxphosphorusi=18.2;
[phosphoruss,minphosphorusi,maxphosphorusi]=premnmx(phosphorus);
% minironi=0.15;
% maxironi=4.59;
[irons,minironi,maxironi]=premnmx(iron);
% min ffaoi=1.39;
% max ffaoi= 4.48;
[ffaos,minffaoi,maxffaoi]=premnmx(ffao);
% mindobioi=1.610;
% maxdobioi=3.808;
[dobios,mindobioi,maxdobioi]=premnmx(dobio);
% minmoistureoi=0.15;
% maxmoistureoi=3.57;
[moistureos,minmoistureoi,maxmoistureoi]=premnmx(moistureo);
% minperoxideoi=0;
% maxperoxideoi=3.32;
[peroxideos,minperoxideoi,maxperoxideoi]=premnmx(peroxideo);
% minphosphorusoi=3.1;
% maxphosphorusoi=16.7;
[phosphorusos,minphosphorusoi,maxphosphorusoi]=premnmx(phosphoruso);
% minironoi=0.04;
% maxironoi=2.07;
[ironos,minironoi,maxironoi]=premnmx(irono);
% minpai=0;
% maxpai=1;
[pas,minpai,maxpai]=premnmx(pa);
M=14;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR VALIDATION
%---------------------------------------------------------------------------------------------------------
ffav =[1.25 2.94 3.10 3.04 2.84 3.74]; % input FFA in;
dobiv = [2.851 3.030 3.019 3.172 2.43 3.000]; % input DOBI in;
moisturev = [0.34 2.14 2.12 2.05 1.87 0.42]; % input moisture in;
peroxidev = [2.33 2.24 2.09 1.46 1.78 3.41]; % input peroxide value;
phosphorusv = [10.52 11.24 11.17 11.38 11.05 14.2]; % input phosphorus in;
dobiov =[1.938 1.779 1.910 1.994 1.978 2.214 ]; % input DOBI out;
moistureov = [0.18 0.31 0.26 0.64 2.38 0.19]; % input moisture out;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE VALIDATION.DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffaiv=1.25;
% maxffaiv=3.74;
[ffavs,minffaiv,maxffaiv]=premnmx(ffav);
% mindobiiv=2.43;
% maxdobiiv=3.172;
[dobivs,mindobiiv,maxdobiiv]=premnmx(dobiv);
% minmoistureiv=0.34;
% maxmoistureiv=2.14;
[moisturevs,minmoistureiv,maxmoistureiv]=premnmx(moisturev);
% minperoxideiv=1.46;
% maxperoxideiv=3.41;
[peroxidevs,minperoxideiv,maxperoxideiv]=premnmx(peroxidev);
% minphosphorusiv=10.52;
% maxphosphorusiv=14.20;
[phosphorusvs,minphosphorusiv,maxphosphorusiv]=premnmx(phosphorusv);
% minironiv=0.25;
% maxironiv=4.56;
[ironvs,minironiv,maxironiv]=premnmx(ironv);
% min ffaoiv=1.40;
% max ffaoiv= 3.97;
[ffaovs,minffaoiv,maxffaoiv]=premnmx(ffaov);
% mindobioiv=1.779;
% maxdobioiv=2.214;
[dobiovs,mindobioiv,maxdobioiv]=premnmx(dobiov);
% minmoistureoiv=0.18;
% maxmoistureoiv=2.38;
[moistureovs,minmoistureoiv,maxmoistureoiv]=premnmx(moistureov);
% minperoxideoiv=0;
% maxperoxideoiv=1.53;
[peroxideovs,minperoxideoiv,maxperoxideoiv]=premnmx(peroxideov);
% minphosphorusoiv=4.1;
% maxphosphorusoiv=9.87;
[phosphorusovs,minphosphorusoiv,maxphosphorusoiv]=premnmx(phosphorusov);
% minironiv=0.15;
% maxironiv=0.63;
[ironovs,minironoiv,maxironoiv]=premnmx(ironv);
% minpaiv=0;
% maxpaiv=1;
[pavs,minpaiv,maxpaiv]=premnmx(pav);
X=6;
%-----------------------------------------------------------------------------------------------------
% OBJECTIVE: NETWORK SETUP
%-----------------------------------------------------------------------------------------------------
S1=20; % Number of nodes
net=newff(minmax(tinput),[S1 1],{'logsig' 'purelin'},'trainlm');
net.trainparam.epochs=500; % Max epoch number
net.trainParam.goal=1e-5;
net.trainParam.show=10;
net.trainParam.max_fail=10;
net=init(net);
%---------------------------------------------------------------------
% Objective: to train, error calculation and predict the output for validation and training
% an= predicted data for training
%van=predicted data for validation
% error= predicted data- onserved data
% trainrmse= root mean square training error
% valmse= root mean square validation error
%----------------------------------------------------------------------
[net,tr]=train(net,tinput,toutput);
initIW=net.IW{1,1};
initB=net.b{1,1};
initLW=net.LW{2,1};
an=sim(net,tinput);
error=an-toutput;
trainmse=sumsqr(error)/M;
trainerr=sumsqr(error);
trainrmse=sqrt(trainerr/M);
van=sim(net,vinput);
verror=van-voutput;
valmse=sumsqr(verror)/X;
valerr=sumsqr(verror);
valrmse=sqrt(valerr/X);
MIMO 1: MULTIPLE INPUT MULTIPLE OUPUT
clear
clc
% ------------------------------------------------------------------------------------------------------
% INITIAL VALUES OF WEIGHT AND BIAS SET UP
%-------------------------------------------------------------------------------------------------------
net.IW{1,1} = [0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0
0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0
0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0;0 0 0 0 0 0 0 0 0 0 0 0;0 0
0 0 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 0 0 0 0 0];
net.b{1,1}= [ 0; 0; 0; 0;0; 0;0; 0; 0; 0; 0;0; 0;0];
net.b{2,1}=[0];
net.LW{2,1}= [ 0 0 0 0 0 0 0 0 0 0 0 0 0 0];
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR TRAINING
%---------------------------------------------------------------------------------------------------------
ffa=[ 3.05 1.21 1.35 2.90 3.69 1.48 3.12 3.23 1.36 3.09 2.90 3.76 3.81 3.65]; % input FFA in;
dobi = [3.000 3.835 2.375 2.345 2.218 3.203 2.980 2.222 3.038 2.986 2.977 2.380 2.390 3.001];
% input DOBI in;
moisture = [2.11 0.92 0.1 0.75 2.51 2.26 2.08 0.94 2.54 2.05 2.10 2.99 2.78 0.41]; % input
moisture in;
peroxide = [1.97 2.40 2.90 2.11 3.29 1.40 2.04 1.17 2.84 1.84 2.17 3.63 3.38 3.43]; % input
peroxide value in;
phosphorus = [10.18 10.30 12.02 10.72 16.84 10.46 11.14 10.46 11.06 10.51 11.03 16.00 18.2
13.44]; % input phosphorus in;
iron = [0.15 0.54 0.65 0.23 4.59 0.34 0.17 0.38 0.78 0.17 0.21 3.2 3.96 4.09]; % input iron in;
ffao=[3.40 1.42 1.42 3.14 4.48 2.30 3.32 3.84 1.39 3.46 3.30 3.97 4.07 3.87]; % input FFA out;
dobio = [1.798 1.610 1.972 1.622 1.578 1.920 1.810 2.030 3.808 1.813 1.805 2.788 2.047 1.820];
% input DOBI out;
moistureo = [0.27 0.16 0.98 0.19 0.25 0.39 0.25 0.63 2.46 0.24 0.29 2.82 3.57 0.15]; % input
moisture out;
peroxideo = [0 0 2.83 0 0 0 0 0 2.64 0 0 3.32 3.14 0]; % input peroxide value out;
phosphoruso = [4.14 4.18 10.5 3.52 3.1 3.14 4.21 10.24 10.18 4.21 4.11 15.4 16.7 11.88]; % input
phosphorus out;
irono= [0.11 0.28 0.04 0.12 2.07 0.24 0.13 0.13 0.49 0.12 0.18 3.19 0.44 1.31]; % input iron out;
pa = [0.5 0.5 1 0.5 1 1 0.5 0 0 0.5 0.5 0 1 0]; % input phosphoric acid;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE TRAINING DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffai=1.21;
% maxffai=3.81;
[ffas,minffai,maxffai]=premnmx(ffa);
% mindobii=2.222;
% maxdobii=3.835;
[dobis,mindobii,maxdobii]=premnmx(dobi);
% minmoisturei=0.10;
% maxmoisturei=2.99;
[moistures,minmoisturei,maxmoisturei]=premnmx(moisture);
% minperoxidei=1.36;
% maxperoxidei=3.63;
[peroxides,minperoxidei,maxperoxidei]=premnmx(peroxide);
% minphosphorusi=10.18;
% maxphosphorusi=18.2;
[phosphoruss,minphosphorusi,maxphosphorusi]=premnmx(phosphorus);
% minironi=0.15;
% maxironi=4.59;
[irons,minironi,maxironi]=premnmx(iron);
% min ffaoi=1.39;
% max ffaoi= 4.48;
[ffaos,minffaoi,maxffaoi]=premnmx(ffao);
% mindobioi=1.610;
% maxdobioi=3.808;
[dobios,mindobioi,maxdobioi]=premnmx(dobio);
% minmoistureoi=0.15;
% maxmoistureoi=3.57;
[moistureos,minmoistureoi,maxmoistureoi]=premnmx(moistureo);
% minperoxideoi=0;
% maxperoxideoi=3.32;
[peroxideos,minperoxideoi,maxperoxideoi]=premnmx(peroxideo);
% minphosphorusoi=3.1;
% maxphosphorusoi=16.7;
[phosphorusos,minphosphorusoi,maxphosphorusoi]=premnmx(phosphoruso);
% minironoi=0.04;
% maxironoi=2.07;
[ironos,minironoi,maxironoi]=premnmx(irono);
% minpai=0;
% maxpai=1;
[pas,minpai,maxpai]=premnmx(pa);
% minbei=0;
% maxbei=2;
[bes,minbei,maxbei]=premnmx(be);
M=14;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: TO CREATE DATA FOR VALIDATION
%---------------------------------------------------------------------------------------------------------
ffav =[1.25 2.94 3.10 3.04 2.84 3.74]; % input FFA in;
dobiv = [2.851 3.030 3.019 3.172 2.43 3.000]; % input DOBI in;
moisturev = [0.34 2.14 2.12 2.05 1.87 0.42]; % input moisture in;
peroxidev = [2.33 2.24 2.09 1.46 1.78 3.41]; % input peroxide value;
phosphorusv = [10.52 11.24 11.17 11.38 11.05 14.2]; % input phosphorus in;
dobiov =[1.938 1.779 1.910 1.994 1.978 2.214 ]; % input DOBI out;
moistureov = [0.18 0.31 0.26 0.64 2.38 0.19]; % input moisture out;
phosphorusov = [8.16 3.87 4.19 3.54 9.87 4.1]; % input phosphorus out;
ironov=[0.28 0.16 0.21 0.29 0.15 0.63]; % input iron out;
%--------------------------------------------------------------------------------------------------------
% OBJECTIVE: SCALED UP THE VALIDATION.DATA IN A RANGE OF 0 TO 1
%---------------------------------------------------------------------------------------------------------
% minffaiv=1.25;
% maxffaiv=3.74;
[ffavs,minffaiv,maxffaiv]=premnmx(ffav);
% mindobiiv=2.43;
% maxdobiiv=3.172;
[dobivs,mindobiiv,maxdobiiv]=premnmx(dobiv);
% minmoistureiv=0.34;
% maxmoistureiv=2.14;
[moisturevs,minmoistureiv,maxmoistureiv]=premnmx(moisturev);
% minperoxideiv=1.46;
% maxperoxideiv=3.41;
[peroxidevs,minperoxideiv,maxperoxideiv]=premnmx(peroxidev);
% minphosphorusiv=10.52;
% maxphosphorusiv=14.20;
[phosphorusvs,minphosphorusiv,maxphosphorusiv]=premnmx(phosphorusv);
% minironiv=0.25;
% maxironiv=4.56;
[ironvs,minironiv,maxironiv]=premnmx(ironv);
% min ffaoiv=1.40;
% max ffaoiv= 3.97;
[ffaovs,minffaoiv,maxffaoiv]=premnmx(ffaov);
% mindobioiv=1.779;
% maxdobioiv=2.214;
[dobiovs,mindobioiv,maxdobioiv]=premnmx(dobiov);
% minmoistureoiv=0.18;
% maxmoistureoiv=2.38;
[moistureovs,minmoistureoiv,maxmoistureoiv]=premnmx(moistureov);
% minperoxideoiv=0;
% maxperoxideoiv=1.53;
[peroxideovs,minperoxideoiv,maxperoxideoiv]=premnmx(peroxideov);
% minphosphorusoiv=4.1;
% maxphosphorusoiv=9.87;
[phosphorusovs,minphosphorusoiv,maxphosphorusoiv]=premnmx(phosphorusov);
% minironiv=0.15;
% maxironiv=0.63;
[ironovs,minironoiv,maxironoiv]=premnmx(ironv);
% minpaiv=0;
% maxpaiv=1;
[pavs,minpaiv,maxpaiv]=premnmx(pav);
% minbeiv=0;
% maxbeiv=2;
[bevs,minbeiv,maxbeiv]=premnmx(bev);
X=6;
%-----------------------------------------------------------------------------------------------------
% OBJECTIVE: NETWORK SETUP
%-----------------------------------------------------------------------------------------------------
S1=20; % Number of nodes
net=newff(minmax(tinput),[S1 1],{'logsig' 'purelin'},'trainlm');
net.trainparam.epochs=500; % Max epoch number
net.trainParam.goal=1e-5;
net.trainParam.show=10;
net.trainParam.max_fail=10;
net=init(net);
%---------------------------------------------------------------------
% Objective: to train, error calculation and predict the output for validation and training
% an= predicted data for training
%van=predicted data for validation
% error= predicted data- onserved data
% trainrmse= root mean square training error
% valmse= root mean square validation error
%----------------------------------------------------------------------
[net,tr]=train(net,tinput,toutput);
initIW=net.IW{1,1};
initB=net.b{1,1};
initLW=net.LW{2,1};
an=sim(net,tinput);
error=an-toutput;
trainmse=sumsqr(error)/M;
trainerr=sumsqr(error);
trainrmse=sqrt(trainerr/M);
van=sim(net,vinput);
verror=van-voutput;
valmse=sumsqr(verror)/X;
valerr=sumsqr(verror);
valrmse=sqrt(valerr/X);