The computer program listed below seeks to solve simultaneously the following problem:
3000 * X(28) + 1000 * X(28) ^ 3 + 2000 * X(29) + 666.6666666 * X(29) ^ 3 = 6666.6666666,
(X(21) - 10) ^ 2 + 5 * (X(22) - 12) ^ 2 + X(23) ^ 4 + 3 * (X(24) - 11) ^ 2 + 10 * X(25) ^ 6 + 7 * X(26) ^ 2 + X(27) ^ 4 - 4 * X(26) * X(27) - 10 * X(26) - 8 * X(27) = 714,
X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2 + 4 * (X(14) - 14) ^ 2 + 27 * (X(15) - 1) ^ 2 + X(16) ^ 4 + (X(17) - 2) ^ 2 + 13 * (X(18) - 2) ^ 2 + (X(19) - 3) ^ 2 + X(20) ^ 2 = 3155,
X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2 + 4 * (X(14) - 14) ^ 2 + 27 * (X(15) - 1) ^ 2 + X(16) ^ 4 + (X(17) - 2) ^ 2 + 13 * (X(18) - 2) ^ 2 + (X(19) - 3) ^ 2 = 3119,
X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2 + 4 * (X(14) - 14) ^ 2 + 27 * (X(15) - 1) ^ 2 + X(16) ^ 4 + (X(17) - 2) ^ 2
= 2902,
X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2 + 4 * (X(14) - 14) ^ 2 + 27 * (X(15) - 1) ^ 2 = 1590,
X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2 = 659,
X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 = 395,
X(1) ^ 2 + X(2) ^ 2 + X(3) ^ 2 + X(4) ^ 2 + X(5) ^ 2 + X(6) ^ 2 + X(7) ^ 2 + X(8) ^ 2 + X(9) ^ 2 + X(10) ^ 1 + X(11) ^ 1 + X(12) ^ 1 + X(13) ^ 1 = 348,
X(1) ^ 2 + X(2) ^ 2 + X(3) ^ 2 + X(4) ^ 2 + X(5) ^ 2 + X(6) ^ 2 + X(7) ^ 2 + X(8) ^ 2 + X(9) ^ 2 + X(10) ^ 2 + X(11) ^ 2 + X(12) ^ 2 + X(13) ^ 2 = 468,
10 * X(1) * X(2) ^ (-1) * X(4) ^ 2 * X(6) ^ (-3) * X(7) ^ (-.25) + 15 * X(1) ^ (-1) * X(2) ^ (-2) * X(3) * X(4) * X(5) ^ (-1) * X(7) ^ (-.5) + 20 * X(1) ^ (-2) * X(2) * X(4) ^ (-1) * X(5) ^ (-2) * X(6) + 25 * X(1) ^ 2 * X(2) ^ 2 * X(3) ^ (-1) * X(5) ^ .5 * X(6) ^ (-2) * X(7) = 2205.868,
10 * X(1) * X(2) ^ (-1) * X(4) ^ 2 * X(6) ^ (-3) * X(7) ^ .125 + 15 * X(1) ^ (-1) * X(2) ^ (-2) * X(3) * X(4) * X(5) ^ (-1) * X(7) ^ (-.5) + 20 * X(1) ^ (-2) * X(2) * X(4) ^ (-1) * X(5) ^ (-2) * X(6) + 25 * X(1) ^ 2 * X(2) ^ 2* X(3) ^ (-1) * X(5) ^ .5 * X(6) ^ (-2) * X(7) = 2206.889,
10 * X(1) * X(2) ^ (-1) * X(4) ^ 2 * X(6) ^ (-3) * X(7) ^ .5 + 15 * X(1) ^ (-1) * X(2) ^ (-2) * X(3) * X(4) * X(5) ^ (-1) * X(7) ^ (-.5) + 20 * X(1) ^ (-2) * X(2) * X(4) ^ (-1) * X(5) ^ (-2) * X(6) + 25 * X(1) ^ 2 * X(2) ^ 2 * X(3) ^ (-1) * X(5) ^ .5 * X(6) ^ (-2) * X(7) = 2208.886,
-.5 * (X(1) * X(4) – X(2) * X(3) + X(3) * X(9) – X(5) * X(9) + X(5) * X(8) – X(6) * X(7)) = 0,
and
0<= Integers X(i)<= 10 for i=1 through 29.
Equation 1 and equation 2 above are based on page 116 and page 111 of Hock and Schittkowski [7], respectively. Equations 3, 4, 5, 6, and 7 are based on page 147 of Asaadi [1]. Equation 8 is based on page 122 of Hock and Schittkowski [7], equations 11, 12, and 13 are based on page 112 of the same book, and equation 14 is based on page 117 of the same book, as well.
One notes line 13, which is 13 A(KNEW) = FIX(RND * 11).
0 REM DEFDBL A-Z
3 DEFINT J, K, X
4 DIM X(342), A(342), L(333), K(333)
12 FOR JJJJ = -32000 TO 32000
13 A(KNEW) = FIX(RND * 11)
14 RANDOMIZE JJJJ
16 M = -1D+317
22 REM
91 FOR KK = 1 TO 29
94 A(KK) = A(KNEW)
95 NEXT KK
128 FOR I = 1 TO 1000000
129 FOR K = 1 TO 29
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 29)
182 IF RND < -.1 THEN 183 ELSE GOTO 189
183 R = (1 - RND * 2) * A(B)
186 X(B) = A(B) + (RND ^ 3) * R
187 REM IF RND < .25 THEN X(B) = A(B) + RND * R ELSE IF RND < .333 THEN X(B) = A(B) + RND ^ 4 * R ELSE IF RND < .5 THEN X(B) = A(B) + RND ^ 7 * R ELSE X(B) = CINT(A(B))
188 GOTO 191
189 IF RND < .5 THEN X(B) = A(B) - FIX(1 + RND * 2.99) ELSE X(B) = A(B) + FIX(1 + RND * 2.99)
191 NEXT IPP
255 FOR J45 = 1 TO 29
256 IF X(J45) < 0 THEN X(J45) = A(J45)
257 IF X(J45) > 10 THEN X(J45) = A(J45)
259 NEXT J45
264 X(13) = 348 - (X(1) ^ 2 + X(2) ^ 2 + X(3) ^ 2 + X(4) ^ 2 + X(5) ^ 2 + X(6) ^ 2 + X(7) ^ 2 + X(8) ^ 2 + X(9) ^ 2 + X(10) ^ 1 + X(11) ^ 1 + X(12) ^ 1)
266 IF X(13) < 0 THEN 1670
267 IF X(13) > 10 THEN 1670
268 N11 = 10 * X(1) * X(2) ^ (-1) * X(4) ^ 2 * X(6) ^ (-3) * X(7) ^ (-.25) + 15 * X(1) ^ (-1) * X(2) ^ (-2) * X(3) * X(4) * X(5) ^ (-1) * X(7) ^ (-.5) + 20 * X(1) ^ (-2) * X(2) * X(4) ^ (-1) * X(5) ^ (-2) * X(6) + 25 * X(1) ^ 2 * X(2) ^ 2 * X(3) ^ (-1) * X(5) ^ .5 * X(6) ^ (-2) * X(7) - 2205.868
269 N12 = 10 * X(1) * X(2) ^ (-1) * X(4) ^ 2 * X(6) ^ (-3) * X(7) ^ .125 + 15 * X(1) ^ (-1) * X(2) ^ (-2) * X(3) * X(4) * X(5) ^ (-1) * X(7) ^ (-.5) + 20 * X(1) ^ (-2) * X(2) * X(4) ^ (-1) * X(5) ^ (-2) * X(6) + 25 * X(1) ^ 2 * X(2) ^ 2 * X(3) ^ (-1) * X(5) ^ .5 * X(6) ^ (-2) * X(7) - 2206.889
270 N13 = 10 * X(1) * X(2) ^ (-1) * X(4) ^ 2 * X(6) ^ (-3) * X(7) ^ .5 + 15 * X(1) ^ (-1) * X(2) ^ (-2) * X(3) * X(4) * X(5) ^ (-1) * X(7) ^ (-.5) + 20 * X(1) ^ (-2) * X(2) * X(4) ^ (-1) * X(5) ^ (-2) * X(6) + 25 * X(1) ^ 2 * X(2) ^ 2 * X(3) ^ (-1) * X(5) ^ .5 * X(6) ^ (-2) * X(7) - 2208.886
273 N14 = -.5 * (X(1) * X(4) - X(2) * X(3) + X(3) * X(9) - X(5) * X(9) + X(5) * X(8) - X(6) * X(7)) - 0
275 N15 = X(1) ^ 2 + X(2) ^ 2 + X(3) ^ 2 + X(4) ^ 2 + X(5) ^ 2 + X(6) ^ 2 + X(7) ^ 2 + X(8) ^ 2 + X(9) ^ 2 + X(10) ^ 2 + X(11) ^ 2 + X(12) ^ 2 + X(13) ^ 2 - 468
276 N16 = -395 + X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2
278 N17 = -659 + X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2
279 N18 = -1590 + X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2 + 4 * (X(14) - 14) ^ 2 + 27 * (X(15) - 1) ^ 2
280 N19 = -2902 + X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2 + 4 * (X(14) - 14) ^ 2 + 27 * (X(15) - 1) ^ 2 + X(16) ^ 4 + (X(17) - 2) ^ 2
281 N20 = -3119 + X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2 + 4 * (X(14) - 14) ^ 2 + 27 * (X(15) - 1) ^ 2 + X(16) ^ 4 + (X(17) - 2) ^ 2 + 13 * (X(18) - 2) ^ 2 + (X(19) - 3) ^ 2
282 N21 = -3155 + X(1) ^ 2 + X(2) ^ 2 + X(1) * X(2) - 14 * X(1) - 16 * X(2) + (X(3) - 10) ^ 2 + 4 * (X(4) - 5) ^ 2 + (X(5) - 3) ^ 2 + 2 * (X(6) - 1) ^ 2 + 5 * X(7) ^ 2 + 7 * (X(8) - 11) ^ 2 + 2 * (X(9) - 10) ^ 2 + (X(10) - 7) ^ 2 + (X(11) - 9) ^ 2 + 10 * (X(12) - 1) ^ 2 + 5 * (X(13) - 7) ^ 2 + 4 * (X(14) - 14) ^ 2 + 27 * (X(15) - 1) ^ 2 + X(16) ^ 4 + (X(17) - 2) ^ 2 + 13 * (X(18) - 2) ^ 2 + (X(19) - 3) ^ 2 + X(20) ^ 2
283 N22 = -714 + (X(21) - 10) ^ 2 + 5 * (X(22) - 12) ^ 2 + X(23) ^ 4 + 3 * (X(24) - 11) ^ 2 + 10 * X(25) ^ 6 + 7 * X(26) ^ 2 + X(27) ^ 4 - 4 * X(26) * X(27) - 10 * X(26) - 8 * X(27)
284 N23 = -6666.6666666 + 3000 * X(28) + 1000 * X(28) ^ 3 + 2000 * X(29) + 666.6666666 * X(29) ^ 3
287 P = -ABS(N11) - ABS(N12) - ABS(N13) - ABS(N14) - ABS(N15) - ABS(N16) - ABS(N17) - ABS(N18) - ABS(N19) - ABS(N20) - ABS(N21) - ABS(N22) - ABS(N23)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 29
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1666 REM PRINT A(21), A(22), A(23), A(24), A(25), A(26), A(27), a(28),a(29),M, JJJJ
1670 NEXT I
1888 IF M < -10 THEN 1999
1910 PRINT A(1), A(2), A(3), A(4), A(5), A(6), A(7), A(8), A(9), A(10)
1912 PRINT A(11), A(12), A(13), A(14), A(15), A(16), A(17), A(18), A(19), A(20)
1914 PRINT A(21), A(22), A(23), A(24), A(25), A(26), A(27), A(28), A(29), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [14]. Copied by hand from the screen, the computer program’s complete output through JJJJ=-31868 is shown below:
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
7 6 4 4 0
5 3 1 1 -9.020425E-04
-31964
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
10 4 3 6 0
7 1 1 1 -9.020425E-04
-31895
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
8 8 1 10 2
1 1 1 1 -9.020425E-04
-31869
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
5 6 4 7 0
1 4 1 1 -9.020425E-04
-31868
Above there is no rounding by hand; it is just straight copying by hand from the screen.
On a personal computer with a Pentium Dual-Core CPU E5200 @2.50GHz, 2.50 GHz, 960 MB of RAM and with qb64v1000-win [14], the wall-clock time through JJJJ=-31868 was 12 minutes.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] J. Asaadi, A Computational Comparison of Some Nonlinear Programs, Mathematical Programming, Vol. 4 (1973), pp. 144-154.
[2] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[3] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[4] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[5] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[6] Tianmin Han, Yuhuan Han, Solving large scale nonlinear equations by a new ODE numerical integration method, Applied Mathematics, 2010, 1, pp. 222-229. http://www.SciRP.org/journal/am.
[7] W. Hock, K. Schittkowski, Test Examples for Nonlinear Programming Codes. Springer-Verlag, 1981.
[8] William La Cruz, Jose Mario Martinez, Marcos Raydan, Spectral residual method without gradient information for solving large-scale nonlinear systems of equations: Theory and experiments. Technical Report RT-04-08, July 2004.
http://www.ime.unicamp.br/~martinez/lmrreport.pdf.
[9] William La Cruz, Jose Mario Martinez, Marcos Raydan, Spectral residual method without gradient information for solving large-scale nonlinear systems of equations, Mathematics of Computation, vol. 75, no. 255, pp.1429-1448, 2006.
[10] Microsoft Corp. BASIC, second edition (May 1982), Version 1.10. Boca Raton, Florida: IBM Corp., Personal Computer, P. O. Box 1328-C, Boca Raton, Florida 33432, 1981.
[11] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[12] O. Perez, I. Amaya, R. Correa (2013), Numerical Solution of Certain Exponential and Non-linear Diophantine Systems of Equations by Using a Discrete Particles Swarm Optimization Algorithm. Applied Mathematics and Computation, Volume 225, 1 December 2013, Pages 737-746.
[13] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[14] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[15] Wolfram Research, Inc., Diophantine Polynomial Systems. https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[16] Jsun Yui Wong (2013, November 11). Solving Nonlinear Systems of Equations with the Domino Method, Second Edition. http://myblogsubstance.typepad.com/substance/2013/11/solving-nonlinear-systems-of-equations-with-the-domino-method-second-edition.html.
[17] Jsun Yui Wong (2015, October 26). Testing the Domino Method of General Integer Nonlinear Programming with Brown’s Almost Linear System of Fifteen Equations, Second Edition. http://myblogsubstance.typepad.com/substance/2015/10/
No comments:
Post a Comment