Optimization Using The Gradient and Simplex Method
Optimization Using The Gradient and Simplex Method
Talanta
journal homepage: www.elsevier.com/locate/talanta
art ic l e i nf o a b s t r a c t
Article history: Traditionally optimization of analytical methods has been conducted using a univariate method, varying
Received 11 February 2015 each parameter one-by-one holding fixed the remaining. This means in many cases to reach only local
Received in revised form minima and not get the real optimum. Among the various options for multivariate optimization, this
21 May 2015
paper highlights the gradient method, which involves the ability to perform the partial derivatives of a
Accepted 25 May 2015
mathematical model, as well as the simplex method that does not require that condition.
Available online 12 June 2015
The advantages and disadvantages of those two multivariate optimization methods are discussed,
Keywords: indicating when they can be applied and the different forms that have been introduced. Different cases
Multivariate optimization are described on the applications of these methods in analytical chemistry.
Simplex
& 2015 Elsevier B.V. All rights reserved.
Maximum slope
Gradient
http://dx.doi.org/10.1016/j.talanta.2015.05.061
0039-9140/& 2015 Elsevier B.V. All rights reserved.
642 V. Cerdà et al. / Talanta 148 (2016) 641–648
Relative
maxima
Absolute
maximum
Fig. 1. Level curves with some local maxima and an absolute maximum.
Fig. 2. The gradient method with (a) constant vector size and (b) variable vector size.
V. Cerdà et al. / Talanta 148 (2016) 641–648 643
equilateral triangle and giving the point 3 as the worst response. Supposing the objective is to find a minimum, for example the
Thus, the response will probably increase in the opposite direction minimum of the sum of squared residuals, the target function “U”
to point 3. Therefore, the reflected triangle 1-2-4 is studied, being will be calculated as in Eq. (6):
4 the reflected point of point 3. A new experiment is carried out to 2
get the absorbance of point 4. If point 2 gives the worst answer of U (PN ) = ∑ (Mcalc − Mexp)
i (6)
the new simplex, the new triangle with the reflected point of 2 is
obtained. This procedure is successively repeated producing a This function is very used to refine experimental parameters
succession of simplexes that move rapidly over the response aiming to obtain a maximum adjustment between the calculated
surface. values of a function Mcalc(PN)i and the experimental data Mexp se-
To achieve a more efficient progress strategy, a series of rules lecting the right N parameters P(1),…..,P(N).
have been proposed as detailed below: In this example, the worst vertex will be that giving the highest
U value. Following the previously described strategy this vertex
1. Rule 1: The new simplex is created discarding the point giving has to be discarded to choose a new one according to a series of
the worst response and replacing it with its mirror image on a simple rules. The method is iterated to progressively improve the
line defined according to the other two points. If the new point U value until the optimum region is located.
gives the following worst response, rule 1 can no longer be The simplex vertexes are numbered, being S(3) the worst, S
applied since the reflected point will be the original one. The (2) the second worst and S(1) the best point. When defining B as
application of rule 1 will result in an endless loop between the the barycenter of the opposite face of S(3), the worst vertex S(3) is
two created simplexes. Thus, rule 2 has to be followed. deleted and the new one “R” is obtained by reflection according to
2. Rule 2: So if the new point gives the worst response, then the Eq. (7).
second worst point has to be selected and its reflected point
will be obtained to create the new simplex. A change in the R = B + (B − S(3)) (7)
progression direction to the optimum is obtained. This happens
The following exceptions should be taken into account:
usually when we are approaching the optimum.
3. Rule 3: Thus, if the new point is close to the optimum, all new
a. If U(R)oU(S(1)) and U(R)4U(D), where D is the expanded, i.e.
points will surpass the response surface apex and next sim-
at double distance of the reflected point, then:
plexes will turn around the optimum. This phenomenon is
shown in Fig. 6 where the turning starts from point 9. D = B + 2(B − S(3)) (8)
where,
7
(N + 1)2 + N − 1 (N + 1)1/2 − 1 8
R= K, T = K
2N 2N (5)
S(1)
5
6
C B C R
1
S(3) D
3 4 4
S(2) 2
Fig. 6. Reflected, expanded, and contracted simplex. Fig. 7. Simplex progress with reflections, expansions and contractions.
V. Cerdà et al. / Talanta 148 (2016) 641–648 645
Fig. 10. Supermodified simplex method. Fig. 12. Unidirectional progress of Sin direction S(3)–S(1).
646 V. Cerdà et al. / Talanta 148 (2016) 641–648
In 2010, an overview on the applications of the SIMPLEX al- [1] P. Gans, Coord. Chem. Rev. 19 (1976) 99–124.
gorithm for the optimization of analytical systems based on un- [2] B. Dejaegher, Y.V. Heyden, Sequential optimization methods, Ref. Modul.
Chem. Mol. Sci. Chem. Eng. Compr. Chemom. 1 (2009) 547–575.
segmented flow techniques was published by our group [3] L.V. Candioti, M.M. De Zan, M.S. Cámara, H.C. Goicoechea, Experimental design
[28,30,34]. The different response functions used for evaluation of and multiple response optimization. Using the desirability function in analy-
the optimization experimental data were compared and their ad- tical methods development, Talanta 124 (2014) 123–138.
[4] L.A. Sarabia, M.C. Ortiz, Response surface methodology, Ref. Modul. Chem.
vantages and shortcomings and the problematic of using SIMPLEX Mol. Sci. Chem. Eng. Compr. Chemom. 1 (2009) 345–390.
with a special focus on real-time application was shortly dis- [5] J.E. Dennis Jr., R.B. Schnabel, Numerical Methods for Unconstrained Optimi-
zation aAnd Nonlinear Equations, Prentice-Hall, 1983.
cussed. The analytical applications and parameters optimized by
[6] R. FIetcher, Practical Methods of Optimization, Vol I, Wiley, 1980.
SIMPLEX method were summarized in tabular form. [7] D.M. Himmelblau, Applied Nonlinear Programing, McGraw, New York, 1972.
[8] A.M. Cohén, Análisis Numérico, Reverte, Barcelona, 1977.
[9] P. Gans, A. Sabatini, A. Vacca, Talanta 43 (1996) 1739–1753.
[10] F. Gaizer, A. Puskás, Talanta 28 (1981) 565.
6. Conclusions [11] F. Gaizer, A. Puskás, Talanta 28 (1981) 925.
[12] V. Cerdà, R. Jara, Thermochim. Acta 87 (1985) 13.
[13] R. Forteza, V. Cerdá, Talanta 32 (1985) 1159.
1. In sequential optimization methods, the gradient method is [14] H. Chen, J. Zhang, Y. Dang, G. Shu, J. Chem. Pharm. Res. 6 (2014) 612–616.
recommended for functions with several variables and ob- [15] L. Escuder-Gilabert, Y. Martín-Biosca, S. Sagrado, M.J. Medina-Hernández, J.
Chromatogr. A 1363 (2014) 331–337.
tainable partial derivatives while the simplex method is re-
[16] G. Di Nicola, M. Pacetti, F. Polonara, G. Santori, R. Stryjek, J. Chromatogr. A 1190
commended for functions with several variables and un- (2008) 120–126.
obtainable partial derivatives. [17] K. Selber, F. Nellen, B. Steffen, J. Thömmes, M.-R. Kula, J. Chromatogr. B 743
(2000) 21–30.
2. It is advisable to start in as close to the optimum as possible.
[18] A. Herrero, M.C. Ortiz, M.J. Arcos, J. López-Palacios, Analyst 119 (1994)
Methods of approximate calculation can be used to fulfill this 1585–1592.
purpose. [19] P. Petersson, N. Lundell, K.E. Markides, J. Chromatogr. A 623 (1992) 129–137.
3. The gradient method is the best option when possible. [20] D. Wienke, C. Lucasius, G. Kateman, Anal. Chim. Acta 265 (1992) 211–225.
[21] J. Cerdá, V. Cerdá, Cuadernos de Ciencias y Técnicas Ambientales, in:
4. Optimization has to be repeated starting from different initial M. Blanco, V. Cerdà (Eds.), Serie Química Analítica, AEST, Barcelona, 1988.
points to assure that the optimum found is the absolute max- [22] W. Spendley, G.R. Hext, F.R. Himsworth, Technometrics 4 (1962) 441.
imum or minimum, and not a local one. [23] J.A. Nelder, R. Mead, Comput. J. 7 (1965) 308.
[24] M.W. Routh, P.A. Swartz, M.B. Denton, Anal. Chem. 49 (1977) 1422–1428.
5. Various programs have been developed to refine thermo- [25] P.F.A. van der Wiel, Anal. Chim. Acta 122 (1980) 421–433.
dynamic parameters based on the gradient method. [26] M. Blanco, V. Cerdà, J. Coello, J. Gené, H. Iturriaga, S. Maspoch, Anal. Lett. 25
(1992) 543–560.
[27] V. Cerdà, J.L. Cerdà, Optimization of analytical techniques using the gradient
and simplex methods. 19th International Conference on Flow Injection Ana-
lysis and Related Techniques. Fukuoka, Japan,.
[28] B. Horstkotte, A.T. Sánchez, C.M. Duarte, V. Cerdà, Anal. Chim. Acta 658 (2010)
Acknowledgments
147.
[29] A. Cladera, C. Tomás, J.M. Estela, V. Cerdà, G. Ramis, Anal. Chim. Acta 282
The authors acknowledge financial support from Spanish (1993) 613–623.
[30] M. Blanco, V. Cerdà (Eds.), Temas avanzados de Quimiometría, University of
Ministry of Economy and Competitiveness (MINECO) through the Balearic Islands, Palma de Mallorca. Spain, 2007, ISBN: 987-84-8384-006-
Project CTQ2013-47461-R co-financed by FEDER funds. 1.
[31] H.H. Rosenbrock, Comput. J. 3 (1960) 175.
[32] W.I. Zangwill, Manag. Sci. 13 (1967) 334.
[33] M.J.D. Powell, Non convex minimization calculations and the conjugate gra-
Appendix A. Suplementary Information dient method, in: Lecture Notes in Mathematics, vol. 1066, Springer (1984), p.
122–141.
[34] Burkhart Horstkotte, Carlos M. Duarte, Víctor Cerdà, TrAC Trends Anal. Chem.
Supplementary data associated with this article can be found in the 29 (2010) 1224–1235.
online version at http://dx.doi.org/10.1016/j.talanta.2015.05.061.