03-Feb-2021 09:17:35 test_min_test MATLAB/Octave version 9.9.0.1467703 (R2020b) Test test_min. p00_title_test p00_title prints the title for each problem. Problem Title 1: "Simple quadratic, (x-2)^2+1." 2: "Quadratic plus exponential, x^2 + e^(-x)." 3: "Quartic, x^4 + 2x^2 + x + 3." 4: "Steep valley, e^x + 1/(100x)." 5: "Steep valley, e^x - 2x + 1/(100x) - 1/(1000000x^2)." 6: "line, 2 - x." 7: "The dying snake, ( x + sin(x) ) * e^(-x^2)." 8: "The "Thin Pole", x^2+1+log((pi-x)^2)/pi^4" 9: "The oscillatory parabola" 10: "The cosine combo" 11: "1 + |3x-1|" 12: "The fuzzy parabola" 13: "The lazy W" 14: "Humps" p00_title_test Normal end of execution. P00_INTERVAL_TEST P00_INTERVAL returns the finite interval [A,B] over which the optimization procedure is to be carried out. Problem A F(A) B F(B) 1 0 5 3.14159 2.30323 2 0 1 1 1.36788 3 -2 25 2 29 4 0.0001 101 1 2.72828 5 0.0002 25.9998 2 3.39406 6 7 -5 9 -7 7 -10 -3.5177e-43 10 3.5177e-43 8 2 13.0027 4 48.9969 9 -5 34.1652 5 30.3657 10 0 16 7 13.3791 11 0 2 1 3 12 -2 4.72714 2 3.27286 13 -2 3 2 15 14 0.3 96.5 0.8 17.8462 P00_START_TEST P00_START returns a suggested starting point for an optimization procedure, for any problem. Problem Xstart F(Xstart) 1 3.14159 2.30323 2 0.8 1.08933 3 1.5 14.0625 4 0.95 2.59624 5 1.5 1.48836 6 7.2 -5.2 7 -5 -5.61222e-11 8 3.1 29.7647 9 -2 9.36573 10 0.5 -1.33593 11 0.75 2.25 12 1 1.39593 13 -0.1 4.6302 14 0.4 47.4483 p00_sol_test p00_sol returns a minimizer for the optimization function f(x) for any problem. Problem X F(X) F'(X) F"(X) 1 2 1 0 2 2 0.351734 0.827184 7.80628e-07 2.70347 3 -0.236733 2.87849 -4.49194e-07 4.67251 4 0.0953446 1.20492 -4.15817e-07 24.175 5 0.703206 0.628026 2.40939e-06 2.07771 6 9 -7 -1 0 7 -0.679579 -0.824239 2.40358e-10 0.915822 8 3.14159 -10000 0 1 9 0.146621 -9.97791 -8.36093e-05 75.4778 10 5.97569 -13.0797 -0.000298922 564.868 11 0.333333 1 3 0 12 0.0888588 -0.9921 0.0253988 2810.99 13 -1.41923 -5.24307 0.00019313 34.3411 14 0.637009 11.2528 7.04447e-06 608.018 P00_F_TEST P00_F evaluates the optimization function f(x) at any point x, and for any problem. Problem X F(X) 1 3.14159 2.30323 2 0.8 1.08933 3 1.5 14.0625 4 0.95 2.59624 5 1.5 1.48836 6 7.2 -5.2 7 -5 -5.61222e-11 8 3.1 29.7647 9 -2 9.36573 10 0.5 -1.33593 11 0.75 2.25 12 1 1.39593 13 -0.1 4.6302 14 0.4 47.4483 P00_F1_TEST P00_F1 evaluates the derivative of the optimization function f(x) at any point x, and for any problem. Problem X F'(X) 1 3.14159 2.28319 2 0.8 1.15067 3 1.5 20.5 4 0.95 2.57463 5 1.5 2.47725 6 7.2 -1 7 -5 -5.43395e-10 8 3.1 18.1064 9 -2 55.0698 10 0.5 41.2254 11 0.75 3 12 1 -46.669 13 -0.1 4.392 14 0.4 -488.109 P00_F1_DIF_TEST P00_F1_DIF approximates the first derivative F1 by a finite difference F1_DIF. Problem X F1(X) F1_DIF(X) 1 3.14159 2.28319 2.28319 2 0.8 1.15067 1.15067 3 1.5 20.5 20.5 4 0.95 2.57463 2.57463 5 1.5 2.47725 2.47725 6 7.2 -1 -1 7 -5 -5.43395e-10 -5.43395e-10 8 3.1 18.1064 18.1064 9 -2 55.0698 55.0698 10 0.5 41.2254 41.2254 11 0.75 3 3 12 1 -46.669 -46.669 13 -0.1 4.392 4.392 14 0.4 -488.109 -488.109 P00_F2_TEST P00_F2 evaluates the second derivative of the optimization function f(x) at any point x, and for any problem. Problem X F"(X) 1 3.14159 2 2 0.8 2.44933 3 1.5 31 4 0.95 2.60904 5 1.5 4.48761 6 7.2 0 7 -5 8.39789e-09 8 3.1 -5.86854 9 -2 -277.798 10 0.5 177.651 11 0.75 0 12 1 -1110.15 13 -0.1 -13.76 14 0.4 5058.22 P00_F2_DIF_TEST P00_F2_DIF approximates the second derivative F2 by a finite difference F2_DIF. Problem X F2(X) F2_DIF(X) 1 3.14159 2 2 2 0.8 2.44933 2.44933 3 1.5 31 31 4 0.95 2.60904 2.60904 5 1.5 4.48761 4.48762 6 7.2 0 0 7 -5 8.39789e-09 -5.15675e-09 8 3.1 -5.86854 -5.86855 9 -2 -277.798 -277.798 10 0.5 177.651 177.651 11 0.75 0 0 12 1 -1110.15 -1110.15 13 -0.1 -13.76 -13.76 14 0.4 5058.22 5058.22 P00_BISECTION_TEST For each problem, take a few steps of the bisection method. Problem 1 Simple quadratic, (x-2)^2+1. 0 X: 0.000000e+00 1.570796e+00 3.141593e+00 F: 5.000000e+00 2.303234e+00 1.184216e+00 1 X: 1.570796e+00 2.356194e+00 3.141593e+00 F: 2.303234e+00 1.126875e+00 1.184216e+00 2 X: 1.570796e+00 1.963495e+00 2.356194e+00 F: 2.303234e+00 1.001333e+00 1.126875e+00 3 X: 1.767146e+00 1.963495e+00 2.159845e+00 F: 1.054221e+00 1.001333e+00 1.025550e+00 4 X: 1.865321e+00 1.963495e+00 2.061670e+00 F: 1.018139e+00 1.001333e+00 1.003803e+00 5 X: 1.963495e+00 2.012583e+00 2.061670e+00 F: 1.001333e+00 1.000158e+00 1.003803e+00 6 X: 1.963495e+00 1.988039e+00 2.012583e+00 F: 1.001333e+00 1.000143e+00 1.000158e+00 7 X: 1.988039e+00 2.000311e+00 2.012583e+00 F: 1.000143e+00 1.000000e+00 1.000158e+00 8 X: 1.994175e+00 2.000311e+00 2.006447e+00 F: 1.000034e+00 1.000000e+00 1.000042e+00 9 X: 1.997243e+00 2.000311e+00 2.003379e+00 F: 1.000008e+00 1.000000e+00 1.000011e+00 10 X: 1.998777e+00 2.000311e+00 2.001845e+00 F: 1.000001e+00 1.000000e+00 1.000003e+00 Problem 2 Quadratic plus exponential, x^2 + e^(-x). 0 X: 0.000000e+00 5.000000e-01 1.000000e+00 F: 1.000000e+00 1.367879e+00 8.565307e-01 1 X: 0.000000e+00 2.500000e-01 5.000000e-01 F: 1.000000e+00 8.413008e-01 1.367879e+00 2 X: 2.500000e-01 3.750000e-01 5.000000e-01 F: 8.413008e-01 8.279143e-01 1.367879e+00 3 X: 3.125000e-01 3.750000e-01 4.375000e-01 F: 8.292719e-01 8.279143e-01 8.370548e-01 4 X: 3.125000e-01 3.437500e-01 3.750000e-01 F: 8.292719e-01 8.272702e-01 8.279143e-01 5 X: 3.437500e-01 3.593750e-01 3.750000e-01 F: 8.272702e-01 8.272629e-01 8.279143e-01 6 X: 3.437500e-01 3.515625e-01 3.593750e-01 F: 8.272702e-01 8.271841e-01 8.272629e-01 7 X: 3.476562e-01 3.515625e-01 3.554688e-01 F: 8.272065e-01 8.271841e-01 8.272029e-01 8 X: 3.496094e-01 3.515625e-01 3.535156e-01 F: 8.271901e-01 8.271841e-01 8.271883e-01 9 X: 3.505859e-01 3.515625e-01 3.525391e-01 F: 8.271858e-01 8.271841e-01 8.271849e-01 10 X: 3.510742e-01 3.515625e-01 3.520508e-01 F: 8.271846e-01 8.271841e-01 8.271842e-01 Problem 3 Quartic, x^4 + 2x^2 + x + 3. 0 X: -2.000000e+00 0.000000e+00 2.000000e+00 F: 2.500000e+01 2.900000e+01 3.000000e+00 1 X: -2.000000e+00 -1.000000e+00 0.000000e+00 F: 2.500000e+01 5.000000e+00 2.900000e+01 2 X: -1.000000e+00 -5.000000e-01 0.000000e+00 F: 5.000000e+00 3.062500e+00 2.900000e+01 3 X: -5.000000e-01 -2.500000e-01 0.000000e+00 F: 3.062500e+00 2.878906e+00 2.900000e+01 4 X: -3.750000e-01 -2.500000e-01 -1.250000e-01 F: 2.926025e+00 2.878906e+00 2.906494e+00 5 X: -3.125000e-01 -2.500000e-01 -1.875000e-01 F: 2.892349e+00 2.878906e+00 2.884048e+00 6 X: -2.812500e-01 -2.500000e-01 -2.187500e-01 F: 2.883210e+00 2.878906e+00 2.879243e+00 7 X: -2.500000e-01 -2.343750e-01 -2.187500e-01 F: 2.878906e+00 2.878506e+00 2.879243e+00 8 X: -2.421875e-01 -2.343750e-01 -2.265625e-01 F: 2.878562e+00 2.878506e+00 2.878733e+00 9 X: -2.421875e-01 -2.382812e-01 -2.343750e-01 F: 2.878562e+00 2.878498e+00 2.878506e+00 10 X: -2.382812e-01 -2.363281e-01 -2.343750e-01 F: 2.878498e+00 2.878493e+00 2.878506e+00 Problem 4 Steep valley, e^x + 1/(100x). 0 X: 1.000000e-04 5.000500e-01 1.000000e+00 F: 1.010001e+02 2.728282e+00 1.668802e+00 1 X: 1.000000e-04 2.500750e-01 5.000500e-01 F: 1.010001e+02 1.324110e+00 2.728282e+00 2 X: 1.000000e-04 1.250875e-01 2.500750e-01 F: 1.010001e+02 1.213192e+00 1.324110e+00 3 X: 6.259375e-02 1.250875e-01 1.875812e-01 F: 1.224355e+00 1.213192e+00 1.259638e+00 4 X: 6.259375e-02 9.384062e-02 1.250875e-01 F: 1.224355e+00 1.204948e+00 1.213192e+00 5 X: 7.821719e-02 9.384062e-02 1.094641e-01 F: 1.209207e+00 1.204948e+00 1.207034e+00 6 X: 8.602891e-02 9.384062e-02 1.016523e-01 F: 1.206078e+00 1.204948e+00 1.205373e+00 7 X: 8.993477e-02 9.384062e-02 9.774648e-02 F: 1.205295e+00 1.204948e+00 1.204989e+00 8 X: 9.384062e-02 9.579355e-02 9.774648e-02 F: 1.204948e+00 1.204923e+00 1.204989e+00 9 X: 9.481709e-02 9.579355e-02 9.677002e-02 F: 1.204924e+00 1.204923e+00 1.204945e+00 10 X: 9.481709e-02 9.530532e-02 9.579355e-02 F: 1.204924e+00 1.204921e+00 1.204923e+00 Problem 5 Steep valley, e^x - 2x + 1/(100x) - 1/(1000000x^2). 0 X: 2.000000e-04 1.000100e+00 2.000000e+00 F: 2.599980e+01 3.394056e+00 7.283517e-01 1 X: 2.000000e-04 5.001500e-01 1.000100e+00 F: 2.599980e+01 6.686586e-01 3.394056e+00 2 X: 5.001500e-01 7.501250e-01 1.000100e+00 F: 6.686586e-01 6.303440e-01 3.394056e+00 3 X: 6.251375e-01 7.501250e-01 8.751125e-01 F: 6.342218e-01 6.303440e-01 6.603460e-01 4 X: 6.251375e-01 6.876312e-01 7.501250e-01 F: 6.342218e-01 6.282766e-01 6.303440e-01 5 X: 6.563844e-01 6.876312e-01 7.188781e-01 F: 6.302734e-01 6.282766e-01 6.282821e-01 6 X: 6.876312e-01 7.032547e-01 7.188781e-01 F: 6.282766e-01 6.280257e-01 6.282821e-01 7 X: 6.954430e-01 7.032547e-01 7.110664e-01 F: 6.280882e-01 6.280257e-01 6.280901e-01 8 X: 6.993488e-01 7.032547e-01 7.071605e-01 F: 6.280412e-01 6.280257e-01 6.280420e-01 9 X: 7.013018e-01 7.032547e-01 7.052076e-01 F: 6.280295e-01 6.280257e-01 6.280299e-01 10 X: 7.022782e-01 7.032547e-01 7.042312e-01 F: 6.280266e-01 6.280257e-01 6.280268e-01 Problem 6 line, 2 - x. 0 X: 7.000000e+00 8.000000e+00 9.000000e+00 F: -5.000000e+00 -7.000000e+00 -6.000000e+00 1 X: 7.500000e+00 8.000000e+00 8.500000e+00 F: -5.500000e+00 -7.000000e+00 -6.500000e+00 2 X: 7.750000e+00 8.000000e+00 8.250000e+00 F: -5.750000e+00 -7.000000e+00 -6.250000e+00 3 X: 7.875000e+00 8.000000e+00 8.125000e+00 F: -5.875000e+00 -7.000000e+00 -6.125000e+00 4 X: 7.937500e+00 8.000000e+00 8.062500e+00 F: -5.937500e+00 -7.000000e+00 -6.062500e+00 5 X: 7.968750e+00 8.000000e+00 8.031250e+00 F: -5.968750e+00 -7.000000e+00 -6.031250e+00 6 X: 7.984375e+00 8.000000e+00 8.015625e+00 F: -5.984375e+00 -7.000000e+00 -6.015625e+00 7 X: 7.992188e+00 8.000000e+00 8.007812e+00 F: -5.992188e+00 -7.000000e+00 -6.007812e+00 8 X: 7.996094e+00 8.000000e+00 8.003906e+00 F: -5.996094e+00 -7.000000e+00 -6.003906e+00 9 X: 7.998047e+00 8.000000e+00 8.001953e+00 F: -5.998047e+00 -7.000000e+00 -6.001953e+00 10 X: 7.999023e+00 8.000000e+00 8.000977e+00 F: -5.999023e+00 -7.000000e+00 -6.000977e+00 Problem 7 The dying snake, ( x + sin(x) ) * e^(-x^2). 0 X: -1.000000e+01 0.000000e+00 1.000000e+01 F: -3.517696e-43 3.517696e-43 0.000000e+00 1 X: -1.000000e+01 -5.000000e+00 0.000000e+00 F: -3.517696e-43 -5.612223e-11 3.517696e-43 2 X: -5.000000e+00 -2.500000e+00 0.000000e+00 F: -5.612223e-11 -5.981458e-03 3.517696e-43 3 X: -2.500000e+00 -1.250000e+00 0.000000e+00 F: -5.981458e-03 -4.609322e-01 3.517696e-43 4 X: -1.250000e+00 -6.250000e-01 0.000000e+00 F: -4.609322e-01 -8.187928e-01 3.517696e-43 5 X: -9.375000e-01 -6.250000e-01 -3.125000e-01 F: -7.239991e-01 -8.187928e-01 -5.622598e-01 6 X: -7.812500e-01 -6.250000e-01 -4.687500e-01 F: -8.068192e-01 -8.187928e-01 -7.389378e-01 7 X: -7.812500e-01 -7.031250e-01 -6.250000e-01 F: -8.068192e-01 -8.232623e-01 -8.187928e-01 8 X: -7.031250e-01 -6.640625e-01 -6.250000e-01 F: -8.232623e-01 -8.238068e-01 -8.187928e-01 9 X: -7.031250e-01 -6.835938e-01 -6.640625e-01 F: -8.232623e-01 -8.242107e-01 -8.238068e-01 10 X: -6.933594e-01 -6.835938e-01 -6.738281e-01 F: -8.239030e-01 -8.242107e-01 -8.241803e-01 Problem 8 The "Thin Pole", x^2+1+log((pi-x)^2)/pi^4 0 X: 2.000000e+00 3.000000e+00 4.000000e+00 F: 1.300272e+01 4.899687e+01 2.795986e+01 1 X: 2.000000e+00 2.500000e+00 3.000000e+00 F: 1.300272e+01 1.974089e+01 4.899687e+01 2 X: 2.000000e+00 2.250000e+00 2.500000e+00 F: 1.300272e+01 1.618514e+01 1.974089e+01 3 X: 2.000000e+00 2.125000e+00 2.250000e+00 F: 1.300272e+01 1.454721e+01 1.618514e+01 4 X: 2.000000e+00 2.062500e+00 2.125000e+00 F: 1.300272e+01 1.376328e+01 1.454721e+01 5 X: 2.000000e+00 2.031250e+00 2.062500e+00 F: 1.300272e+01 1.338008e+01 1.376328e+01 6 X: 2.000000e+00 2.015625e+00 2.031250e+00 F: 1.300272e+01 1.319067e+01 1.338008e+01 7 X: 2.000000e+00 2.007812e+00 2.015625e+00 F: 1.300272e+01 1.309651e+01 1.319067e+01 8 X: 2.000000e+00 2.003906e+00 2.007812e+00 F: 1.300272e+01 1.304957e+01 1.309651e+01 9 X: 2.000000e+00 2.001953e+00 2.003906e+00 F: 1.300272e+01 1.302613e+01 1.304957e+01 10 X: 2.000000e+00 2.000977e+00 2.001953e+00 F: 1.300272e+01 1.301442e+01 1.302613e+01 Problem 9 The oscillatory parabola 0 X: -5.000000e+00 0.000000e+00 5.000000e+00 F: 3.416522e+01 3.036573e+01 -9.092974e+00 1 X: -5.000000e+00 -2.500000e+00 0.000000e+00 F: 3.416522e+01 6.670244e+00 3.036573e+01 2 X: -5.000000e+00 -3.750000e+00 -2.500000e+00 F: 3.416522e+01 5.860080e+00 6.670244e+00 3 X: -3.750000e+00 -3.125000e+00 -2.500000e+00 F: 5.860080e+00 2.249366e+00 6.670244e+00 4 X: -3.437500e+00 -3.125000e+00 -2.812500e+00 F: 2.025177e+01 2.249366e+00 1.272107e+01 5 X: -3.125000e+00 -2.968750e+00 -2.812500e+00 F: 2.249366e+00 1.169087e+00 1.272107e+01 6 X: -3.125000e+00 -3.046875e+00 -2.968750e+00 F: 2.249366e+00 -7.164835e-01 1.169087e+00 7 X: -3.085938e+00 -3.046875e+00 -3.007812e+00 F: 1.657005e-01 -7.164835e-01 -3.468641e-01 8 X: -3.066406e+00 -3.046875e+00 -3.027344e+00 F: -4.325070e-01 -7.164835e-01 -6.850371e-01 9 X: -3.046875e+00 -3.037109e+00 -3.027344e+00 F: -7.164835e-01 -7.398712e-01 -6.850371e-01 10 X: -3.041992e+00 -3.037109e+00 -3.032227e+00 F: -7.380188e-01 -7.398712e-01 -7.221587e-01 Problem 10 The cosine combo 0 X: 0.000000e+00 3.500000e+00 7.000000e+00 F: 1.600000e+01 1.337907e+01 3.413261e+00 1 X: 0.000000e+00 1.750000e+00 3.500000e+00 F: 1.600000e+01 -1.011534e+01 1.337907e+01 2 X: 8.750000e-01 1.750000e+00 2.625000e+00 F: -1.797977e+00 -1.011534e+01 -2.586638e-01 3 X: 1.312500e+00 1.750000e+00 2.187500e+00 F: 9.222518e+00 -1.011534e+01 -4.483176e+00 4 X: 1.531250e+00 1.750000e+00 1.968750e+00 F: 4.726837e+00 -1.011534e+01 -5.228431e+00 5 X: 1.640625e+00 1.750000e+00 1.859375e+00 F: -4.282426e+00 -1.011534e+01 -9.619439e+00 6 X: 1.750000e+00 1.804688e+00 1.859375e+00 F: -1.011534e+01 -1.063047e+01 -9.619439e+00 7 X: 1.777344e+00 1.804688e+00 1.832031e+00 F: -1.058245e+01 -1.063047e+01 -1.029140e+01 8 X: 1.777344e+00 1.791016e+00 1.804688e+00 F: -1.058245e+01 -1.065740e+01 -1.063047e+01 9 X: 1.784180e+00 1.791016e+00 1.797852e+00 F: -1.063290e+01 -1.065740e+01 -1.065640e+01 10 X: 1.791016e+00 1.794434e+00 1.797852e+00 F: -1.065740e+01 -1.066005e+01 -1.065640e+01 Problem 11 1 + |3x-1| 0 X: 0.000000e+00 5.000000e-01 1.000000e+00 F: 2.000000e+00 3.000000e+00 1.500000e+00 1 X: 0.000000e+00 2.500000e-01 5.000000e-01 F: 2.000000e+00 1.250000e+00 3.000000e+00 2 X: 2.500000e-01 3.750000e-01 5.000000e-01 F: 1.250000e+00 1.125000e+00 3.000000e+00 3 X: 2.500000e-01 3.125000e-01 3.750000e-01 F: 1.250000e+00 1.062500e+00 1.125000e+00 4 X: 3.125000e-01 3.437500e-01 3.750000e-01 F: 1.062500e+00 1.031250e+00 1.125000e+00 5 X: 3.125000e-01 3.281250e-01 3.437500e-01 F: 1.062500e+00 1.015625e+00 1.031250e+00 6 X: 3.281250e-01 3.359375e-01 3.437500e-01 F: 1.015625e+00 1.007812e+00 1.031250e+00 7 X: 3.281250e-01 3.320312e-01 3.359375e-01 F: 1.015625e+00 1.003906e+00 1.007812e+00 8 X: 3.320312e-01 3.339844e-01 3.359375e-01 F: 1.003906e+00 1.001953e+00 1.007812e+00 9 X: 3.320312e-01 3.330078e-01 3.339844e-01 F: 1.003906e+00 1.000977e+00 1.001953e+00 10 X: 3.330078e-01 3.334961e-01 3.339844e-01 F: 1.000977e+00 1.000488e+00 1.001953e+00 Problem 12 The fuzzy parabola 0 X: -2.000000e+00 0.000000e+00 2.000000e+00 F: 4.727143e+00 3.272857e+00 0.000000e+00 1 X: -2.000000e+00 -1.000000e+00 0.000000e+00 F: 4.727143e+00 6.040748e-01 3.272857e+00 2 X: -1.000000e+00 -5.000000e-01 0.000000e+00 F: 6.040748e-01 -7.293576e-01 3.272857e+00 3 X: -7.500000e-01 -5.000000e-01 -2.500000e-01 F: -3.244525e-01 -7.293576e-01 -5.691110e-01 4 X: -6.250000e-01 -5.000000e-01 -3.750000e-01 F: -5.998299e-01 -7.293576e-01 -7.143196e-01 5 X: -5.625000e-01 -5.000000e-01 -4.375000e-01 F: 1.315874e+00 -7.293576e-01 1.122117e+00 6 X: -5.312500e-01 -5.000000e-01 -4.687500e-01 F: 1.644169e-01 -7.293576e-01 5.047120e-01 7 X: -5.156250e-01 -5.000000e-01 -4.843750e-01 F: -5.453353e-01 -7.293576e-01 -2.787737e-01 8 X: -5.078125e-01 -5.000000e-01 -4.921875e-01 F: -7.200478e-01 -7.293576e-01 -5.730220e-01 9 X: -5.078125e-01 -5.039062e-01 -5.000000e-01 F: -7.200478e-01 -7.460724e-01 -7.293576e-01 10 X: -5.058594e-01 -5.039062e-01 -5.019531e-01 F: -7.383863e-01 -7.460724e-01 -7.430450e-01 Problem 13 The lazy W 0 X: -2.000000e+00 0.000000e+00 2.000000e+00 F: 3.000000e+00 1.500000e+01 5.000000e+00 1 X: -2.000000e+00 -1.000000e+00 0.000000e+00 F: 3.000000e+00 -3.000000e+00 1.500000e+01 2 X: -2.000000e+00 -1.500000e+00 -1.000000e+00 F: 3.000000e+00 -5.125000e+00 -3.000000e+00 3 X: -1.750000e+00 -1.500000e+00 -1.250000e+00 F: -2.929688e+00 -5.125000e+00 -4.804688e+00 4 X: -1.500000e+00 -1.375000e+00 -1.250000e+00 F: -5.125000e+00 -5.210449e+00 -4.804688e+00 5 X: -1.500000e+00 -1.437500e+00 -1.375000e+00 F: -5.125000e+00 -5.237274e+00 -5.210449e+00 6 X: -1.437500e+00 -1.406250e+00 -1.375000e+00 F: -5.237274e+00 -5.240202e+00 -5.210449e+00 7 X: -1.437500e+00 -1.421875e+00 -1.406250e+00 F: -5.237274e+00 -5.242952e+00 -5.240202e+00 8 X: -1.429688e+00 -1.421875e+00 -1.414062e+00 F: -5.241183e+00 -5.242952e+00 -5.242614e+00 9 X: -1.421875e+00 -1.417969e+00 -1.414062e+00 F: -5.242952e+00 -5.243045e+00 -5.242614e+00 10 X: -1.421875e+00 -1.419922e+00 -1.417969e+00 F: -5.242952e+00 -5.243064e+00 -5.243045e+00 Problem 14 Humps 0 X: 3.000000e-01 5.500000e-01 8.000000e-01 F: 9.650000e+01 1.784615e+01 1.394695e+01 1 X: 5.500000e-01 6.750000e-01 8.000000e-01 F: 1.784615e+01 1.167349e+01 1.394695e+01 2 X: 5.500000e-01 6.125000e-01 6.750000e-01 F: 1.784615e+01 1.144169e+01 1.167349e+01 3 X: 6.125000e-01 6.437500e-01 6.750000e-01 F: 1.144169e+01 1.126645e+01 1.167349e+01 4 X: 6.281250e-01 6.437500e-01 6.593750e-01 F: 1.127703e+01 1.126645e+01 1.140093e+01 5 X: 6.281250e-01 6.359375e-01 6.437500e-01 F: 1.127703e+01 1.125310e+01 1.126645e+01 6 X: 6.320313e-01 6.359375e-01 6.398438e-01 F: 1.126034e+01 1.125310e+01 1.125519e+01 7 X: 6.359375e-01 6.378906e-01 6.398438e-01 F: 1.125310e+01 1.125299e+01 1.125519e+01 8 X: 6.359375e-01 6.369141e-01 6.378906e-01 F: 1.125310e+01 1.125276e+01 1.125299e+01 9 X: 6.364258e-01 6.369141e-01 6.374023e-01 F: 1.125286e+01 1.125276e+01 1.125280e+01 10 X: 6.366699e-01 6.369141e-01 6.371582e-01 F: 1.125279e+01 1.125276e+01 1.125276e+01 P00_FMIN_TEST For each problem, use Brent's method. Problem 1 Simple quadratic, (x-2)^2+1. Initial interval [A,B]: A, B: 0.0000000000000000e+00 3.1415926535897931e+00 FA, FB: 5.0000000000000000e+00 2.3032337867301855e+00 Final interval [A,X*,B]: A, X*, B: 1.9999999668643442e+00 2.0000000000000000e+00 2.0000000331356556e+00 FA, FX*, FB: 1.0000000000000011e+00 1.0000000000000000e+00 1.0000000000000011e+00 Problem 2 Quadratic plus exponential, x^2 + e^(-x). Initial interval [A,B]: A, B: 0.0000000000000000e+00 1.0000000000000000e+00 FA, FB: 1.0000000000000000e+00 1.3678794411714423e+00 Final interval [A,X*,B]: A, X*, B: 3.5173370369581974e-01 3.5173371227039368e-01 3.5173372084496773e-01 FA, FX*, FB: 8.2718402612752440e-01 8.2718402612752429e-01 8.2718402612752440e-01 Problem 3 Quartic, x^4 + 2x^2 + x + 3. Initial interval [A,B]: A, B: -2.0000000000000000e+00 2.0000000000000000e+00 FA, FB: 2.5000000000000000e+01 2.9000000000000000e+01 Final interval [A,X*,B]: A, X*, B: -2.3673290466844016e-01 -2.3673289780751167e-01 -2.3673289094658326e-01 FA, FX*, FB: 2.8784927898737260e+00 2.8784927898737260e+00 2.8784927898737265e+00 Problem 4 Steep valley, e^x + 1/(100x). Initial interval [A,B]: A, B: 1.0000000000000000e-04 1.0000000000000000e+00 FA, FB: 1.0100010000500016e+02 2.7282818284590453e+00 Final interval [A,X*,B]: A, X*, B: 9.5344612481347735e-02 9.5344617235426574e-02 9.5344621989505413e-02 FA, FX*, FB: 1.2049205725326400e+00 1.2049205725326397e+00 1.2049205725326400e+00 Problem 5 Steep valley, e^x - 2x + 1/(100x) - 1/(1000000x^2). Initial interval [A,B]: A, B: 2.0000000000000001e-04 2.0000000000000000e+00 FA, FB: 2.5999800020001334e+01 3.3940558489306505e+00 Final interval [A,X*,B]: A, X*, B: 7.0320482653529015e-01 7.0320484034719222e-01 7.0320485415909428e-01 FA, FX*, FB: 6.2802572059286355e-01 6.2802572059286299e-01 6.2802572059286343e-01 Problem 6 line, 2 - x. Initial interval [A,B]: A, B: 7.0000000000000000e+00 9.0000000000000000e+00 FA, FB: -5.0000000000000000e+00 -7.0000000000000000e+00 Final interval [A,X*,B]: A, X*, B: 8.9999995893937950e+00 8.9999997462314099e+00 9.0000000000000000e+00 FA, FX*, FB: -6.9999995893937950e+00 -6.9999997462314099e+00 -7.0000000000000000e+00 Problem 7 The dying snake, ( x + sin(x) ) * e^(-x^2). Initial interval [A,B]: A, B: -1.0000000000000000e+01 1.0000000000000000e+01 FA, FB: -3.5176959895140651e-43 3.5176959895140651e-43 Final interval [A,X*,B]: A, X*, B: -6.7957867304942154e-01 -6.7957865958957708e-01 -6.7957864612973262e-01 FA, FX*, FB: -8.2423939847607630e-01 -8.2423939847607675e-01 -8.2423939847607630e-01 Problem 8 The "Thin Pole", x^2+1+log((pi-x)^2)/pi^4 Initial interval [A,B]: A, B: 2.0000000000000000e+00 4.0000000000000000e+00 FA, FB: 1.3002718932094869e+01 4.8996865250916073e+01 Final interval [A,X*,B]: A, X*, B: 2.0000000000000000e+00 2.0000000599066379e+00 2.0000000969309766e+00 FA, FX*, FB: 1.3002718932094869e+01 1.3002719649897090e+01 1.3002720093523275e+01 Problem 9 The oscillatory parabola Initial interval [A,B]: A, B: -5.0000000000000000e+00 5.0000000000000000e+00 FA, FB: 3.4165215479156338e+01 3.0365729180004351e+01 Final interval [A,X*,B]: A, X*, B: -1.3384520553929524e+00 -1.3384520160007143e+00 -1.3384519927228917e+00 FA, FX*, FB: -8.1974223764333605e+00 -8.1974223764336109e+00 -8.1974223764335257e+00 Problem 10 The cosine combo Initial interval [A,B]: A, B: 0.0000000000000000e+00 7.0000000000000000e+00 FA, FB: 1.6000000000000000e+01 1.3379067745884871e+01 Final interval [A,X*,B]: A, X*, B: 1.0167820467101301e+00 1.0167820651946968e+00 1.0167820836792636e+00 FA, FX*, FB: -6.2827508800684218e+00 -6.2827508800685541e+00 -6.2827508800684964e+00 Problem 11 1 + |3x-1| Initial interval [A,B]: A, B: 0.0000000000000000e+00 1.0000000000000000e+00 FA, FB: 2.0000000000000000e+00 3.0000000000000000e+00 Final interval [A,X*,B]: A, X*, B: 3.3333332525173992e-01 3.3333333784569286e-01 3.3333334614608012e-01 FA, FX*, FB: 1.0000000242447802e+00 1.0000000135370786e+00 1.0000000384382404e+00 Problem 12 The fuzzy parabola Initial interval [A,B]: A, B: -2.0000000000000000e+00 2.0000000000000000e+00 FA, FB: 4.7271425000808529e+00 3.2728574999191475e+00 Final interval [A,X*,B]: A, X*, B: 8.8849734899528243e-02 8.8849739556825874e-02 8.8849744214123505e-02 FA, FX*, FB: -9.9210010320608011e-01 -9.9210010320610009e-01 -9.9210010320605913e-01 Problem 13 The lazy W Initial interval [A,B]: A, B: -2.0000000000000000e+00 2.0000000000000000e+00 FA, FB: 3.0000000000000000e+00 1.5000000000000000e+01 Final interval [A,X*,B]: A, X*, B: -1.4192346736007804e+00 -1.4192346262824000e+00 -1.4192346018008228e+00 FA, FX*, FB: -5.2430721436502363e+00 -5.2430721436502754e+00 -5.2430721436502630e+00 Problem 14 Humps Initial interval [A,B]: A, B: 2.9999999999999999e-01 8.0000000000000004e-01 FA, FB: 9.6500000000000000e+01 1.7846153846153847e+01 Final interval [A,X*,B]: A, X*, B: 6.3700897195758444e-01 6.3700898478309131e-01 6.3700899760859819e-01 FA, FX*, FB: 1.1252754125696207e+01 1.1252754125696157e+01 1.1252754125696207e+01 test_min_test Normal end of execution. 03-Feb-2021 09:17:36