Jsun Yui Wong
The computer program listed below seeks one or more integer solutions to the following problem:
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
1<= Integers X(i)<= 100 for i=1 through 17.
Equations 1, 2, and 3 above are based on page 147 of Asaadi [1]. Equation 4 is based on page 122 of Hock and Schittkowski [7], equations 7, 8, and 9 are based on page 112 of the same book, and equation 10 is based on page 117 of the same book, as well.
The starting vector is 94 A(KK) = 3 + FIX(RND * 9.98). The difference between each element of the vector and its optimal value--whatever the optimal number is--is less than the difference between 1 and 100 (or 99). Thus, starting vectors like this starting vector are generally usable. One also notes lines 256, 257, 266, and 267.
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
14 RANDOMIZE JJJJ
16 M = -1D+17
91 FOR KK = 1 TO 17
94 A(KK) = 3 + FIX(RND * 9.98)
95 NEXT KK
128 FOR I = 1 TO 2000000
129 FOR K = 1 TO 17
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 17)
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 17
256 IF X(J45) < 1 THEN X(J45) = A(J45)
257 IF X(J45) > 100 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) < 1 THEN 1670
267 IF X(13) > 100 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
287 P = -ABS(N11) - ABS(N12) - ABS(N13) - ABS(N14) - ABS(N15) - ABS(N16) - ABS(N17) - ABS(N18) - ABS(N19)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 17
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1670 NEXT I
1888 IF M < -5 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), 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=-31662 is shown below:
6 6 6 6 6
6 6 6 6 6
6 6 6 6 6
6 6 -9.020425E-04 -31717
6 6 6 6 6
6 6 6 6 6
6 6 6 22 6
6 6 -9.020425E-04 -31662
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=-31662 was 45 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/
Tuesday, November 22, 2016
Saturday, November 19, 2016
Simultaneously Solving in General Integers a Nonlinear System of Seven Simultaneous Nonlinear Equations
Jsun Yui Wong
The computer program listed below seeks one or more integer solutions to the following problem:
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
1<= X(i)<= 100 for i=1 through 13.
Equation 1 above is based on page 122 of Hock and Schittkowski [6]. Equations 4, 5, and 6 are based on page 112 of the same book, and equation 7 is based on page 117 of the same book, as well.
The starting vector is 94 A(KK) = 3 + FIX(RND * 9.98). The difference between each element of the vector and its optimal value--whatever the optimal number is--is less than the difference between 1 and 100 (or 99). Thus, starting vectors like this starting vector are generally usable. One also notes lines 256, 257, 266, and 267.
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
14 RANDOMIZE JJJJ
16 M = -1D+17
91 FOR KK = 1 TO 13
94 A(KK) = 3 + FIX(RND * 9.98)
95 NEXT KK
128 FOR I = 1 TO 1200000
129 FOR K = 1 TO 13
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 13)
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 13
256 IF X(J45) < 1 THEN X(J45) = A(J45)
257 IF X(J45) > 100 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) < 1 THEN 1670
267 IF X(13) > 100 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
277 P = -ABS(N11) - ABS(N12) - ABS(N13) - ABS(N14) - ABS(N15) - ABS(N16)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 13
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1670 NEXT I
1888 IF M < -3 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), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [13]. Copied by hand from the screen, the computer program’s complete output through JJJJ=-27959 is shown below:
4 5 6 3 7
4 8 8 7 9
3 7 1 -2.535553 -31976
6 6 6 6 6
6 6 6 6 6
6 6 6 -9.020425E-04
-28865
3 5 6 2 7
3 8 8 8 6
6 6 6 -1.685219 -28260
3 5 6 2 7
3 8 8 8 6
6 6 6 -1.685219 -28208
4 5 6 3 7
4 8 8 7 9
3 7 1 -2.535553 -27987
6 6 6 6 6
6 6 6 6 6
6 6 6 -9.020425E-04
-27959
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 [13], the wall-clock time through JJJJ=-27959 was four hours.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] 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.
[6] W. Hock, K. Schittkowski, Test Examples for Nonlinear Programming Codes. Springer-Verlag, 1981.
[7] 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.
[8] 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.
[9] 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.
[10] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[11] 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.
[12] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[13] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[14] Wolfram Research, Inc., Diophantine Polynomial Systems.
https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[15] 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.
[16] 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/
The computer program listed below seeks one or more integer solutions to the following problem:
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
1<= X(i)<= 100 for i=1 through 13.
Equation 1 above is based on page 122 of Hock and Schittkowski [6]. Equations 4, 5, and 6 are based on page 112 of the same book, and equation 7 is based on page 117 of the same book, as well.
The starting vector is 94 A(KK) = 3 + FIX(RND * 9.98). The difference between each element of the vector and its optimal value--whatever the optimal number is--is less than the difference between 1 and 100 (or 99). Thus, starting vectors like this starting vector are generally usable. One also notes lines 256, 257, 266, and 267.
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
14 RANDOMIZE JJJJ
16 M = -1D+17
91 FOR KK = 1 TO 13
94 A(KK) = 3 + FIX(RND * 9.98)
95 NEXT KK
128 FOR I = 1 TO 1200000
129 FOR K = 1 TO 13
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 13)
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 13
256 IF X(J45) < 1 THEN X(J45) = A(J45)
257 IF X(J45) > 100 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) < 1 THEN 1670
267 IF X(13) > 100 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
277 P = -ABS(N11) - ABS(N12) - ABS(N13) - ABS(N14) - ABS(N15) - ABS(N16)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 13
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1670 NEXT I
1888 IF M < -3 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), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [13]. Copied by hand from the screen, the computer program’s complete output through JJJJ=-27959 is shown below:
4 5 6 3 7
4 8 8 7 9
3 7 1 -2.535553 -31976
6 6 6 6 6
6 6 6 6 6
6 6 6 -9.020425E-04
-28865
3 5 6 2 7
3 8 8 8 6
6 6 6 -1.685219 -28260
3 5 6 2 7
3 8 8 8 6
6 6 6 -1.685219 -28208
4 5 6 3 7
4 8 8 7 9
3 7 1 -2.535553 -27987
6 6 6 6 6
6 6 6 6 6
6 6 6 -9.020425E-04
-27959
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 [13], the wall-clock time through JJJJ=-27959 was four hours.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] 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.
[6] W. Hock, K. Schittkowski, Test Examples for Nonlinear Programming Codes. Springer-Verlag, 1981.
[7] 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.
[8] 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.
[9] 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.
[10] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[11] 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.
[12] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[13] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[14] Wolfram Research, Inc., Diophantine Polynomial Systems.
https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[15] 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.
[16] 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/
Thursday, November 3, 2016
Solving in General Integers a Nonlinear System of Six Simultaneous Nonlinear Equations
Jsun Yui Wong
The computer program listed below seeks one or more integer solutions to the following problem:
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
1<= X(i)<= 11 for i=1 through 13.
Equations 3, 4, and 5 above are based on page 112 of Hock and Schittkowski [6]. Equation 6 is based on page 117 of Hock and Schittkowski [6].
One notes lines 94, 256, 257, 264, 266, and 267.
0 REM DEFDBL A-Z
3 DEFINT J, K, X
4 DIM X(342), A(342), L(333), K(333)
5 FOR JJJJ = -32000 TO 32000
14 RANDOMIZE JJJJ
16 M = -1D+17
91 FOR KK = 1 TO 13
94 A(KK) = 1 + FIX(RND * 11)
95 NEXT KK
128 FOR I = 1 TO 200000
129 FOR K = 1 TO 13
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 13)
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 13
256 IF X(J45) < 1 THEN X(J45) = A(J45)
257 IF X(J45) > 11 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) < 1 THEN 1670
267 IF X(13) > 11 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 = 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
277 P = -ABS(N11) - ABS(N12) - ABS(N13) - ABS(N14) - ABS(N15)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 13
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1670 NEXT I
1888 IF M < -.8 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), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [13]. Copied by hand from the screen, the computer program’s complete output through JJJJ=-30440 is shown below:
6 4 2 7 6
8 8 7 3 8
8 2 3 -.6467603 -31890
4 5 3 6 7
6 9 8 3 3
7 6 7 -.7975526 -31562
6 6 6 6 6
6 6 6 6 6
6 6 6 -9.020425E-04
-30834
6 6 6 6 6
6 6 6 6 6
6 6 6 -9.020425E-04
-30440
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 [13], the wall-clock time through JJJJ=-30440 was twenty minutes.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] 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.
[6] W. Hock, K. Schittkowski, Test Examples for Nonlinear Programming Codes. Springer-Verlag, 1981.
[7] 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.
[8] 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.
[9] 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.
[10] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[11] 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.
[12] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[13] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[14] Wolfram Research, Inc., Diophantine Polynomial Systems. https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[15] 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.
[16] 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/
The computer program listed below seeks one or more integer solutions to the following problem:
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
1<= X(i)<= 11 for i=1 through 13.
Equations 3, 4, and 5 above are based on page 112 of Hock and Schittkowski [6]. Equation 6 is based on page 117 of Hock and Schittkowski [6].
One notes lines 94, 256, 257, 264, 266, and 267.
0 REM DEFDBL A-Z
3 DEFINT J, K, X
4 DIM X(342), A(342), L(333), K(333)
5 FOR JJJJ = -32000 TO 32000
14 RANDOMIZE JJJJ
16 M = -1D+17
91 FOR KK = 1 TO 13
94 A(KK) = 1 + FIX(RND * 11)
95 NEXT KK
128 FOR I = 1 TO 200000
129 FOR K = 1 TO 13
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 13)
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 13
256 IF X(J45) < 1 THEN X(J45) = A(J45)
257 IF X(J45) > 11 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) < 1 THEN 1670
267 IF X(13) > 11 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 = 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
277 P = -ABS(N11) - ABS(N12) - ABS(N13) - ABS(N14) - ABS(N15)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 13
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1670 NEXT I
1888 IF M < -.8 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), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [13]. Copied by hand from the screen, the computer program’s complete output through JJJJ=-30440 is shown below:
6 4 2 7 6
8 8 7 3 8
8 2 3 -.6467603 -31890
4 5 3 6 7
6 9 8 3 3
7 6 7 -.7975526 -31562
6 6 6 6 6
6 6 6 6 6
6 6 6 -9.020425E-04
-30834
6 6 6 6 6
6 6 6 6 6
6 6 6 -9.020425E-04
-30440
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 [13], the wall-clock time through JJJJ=-30440 was twenty minutes.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] 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.
[6] W. Hock, K. Schittkowski, Test Examples for Nonlinear Programming Codes. Springer-Verlag, 1981.
[7] 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.
[8] 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.
[9] 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.
[10] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[11] 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.
[12] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[13] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[14] Wolfram Research, Inc., Diophantine Polynomial Systems. https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[15] 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.
[16] 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/
Sunday, October 30, 2016
Solving in General Integers a Nonlinear System of Five Simultaneous Nonlinear Equations
Jsun Yui Wong
The computer program listed below seeks one integer solution to the following given system of five nonlinear equations:
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.
Equations 2, 3, and 4 above are based on page 112 of Hock and Schittkowski [6]. The last is based on page 117 of Hock and Schittkowski [6].
One notes line 94, which is 94 A(KK) = 1 + FIX(RND * 10).
0 REM DEFDBL A-Z
3 DEFINT J, K, X
4 DIM X(342), A(342), L(333), K(333)
5 FOR JJJJ = -32000 TO 32000
14 RANDOMIZE JJJJ
16 M = -1D+17
91 FOR KK = 1 TO 13
94 A(KK) = 1 + FIX(RND * 10)
95 NEXT KK
128 FOR I = 1 TO 10000000
129 FOR K = 1 TO 13
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 13)
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
265 FOR J45 = 1 TO 13
266 IF X(J45) < 1 THEN X(J45) = A(J45)
267 NEXT J45
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
277 P = -ABS(N11) - ABS(N12) - ABS(N13) - ABS(N14) - ABS(N15)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 13
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1670 NEXT I
1888 IF M < -3 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), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [13]. Copied by hand from the screen, the computer program’s complete output through JJJJ=-31976 is shown below:
6 4 11 2 6
4 11 5 9 1
1 1 3 -2.742824 -32000
...
6 10 9 9 7
6 3 6 6 1
1 1 1 -1.651043 -31998
7 7 10 7 9
7 6 7 1 1
1 1 1 -2.003829 -31997
12 5 6 7 6
10 6 1 2 4
1 2 4 -2 406149 -31989
9 2 11 1 6
3 11 6 2 5
1 2 5 -1.766955 -31984
6 4 2 7 9
7 5 4 5 7
1 9 6 -.3914129 -31983
6 6 6 6 6
6 6 6 1 9
8 5 3 -9.020425E-04
-31976
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 [13], the wall-clock time through JJJJ=-31976 was 27 minutes.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] 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.
[6] W. Hock, K. Schittkowski, Test Examples for Nonlinear Programming Codes. Springer-Verlag, 1981.
[7] 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.
[8] 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.
[9] 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.
[10] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[11] 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.
[12] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[13] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[14] Wolfram Research, Inc., Diophantine Polynomial Systems.
https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[15] 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.
[16] 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/
The computer program listed below seeks one integer solution to the following given system of five nonlinear equations:
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.
Equations 2, 3, and 4 above are based on page 112 of Hock and Schittkowski [6]. The last is based on page 117 of Hock and Schittkowski [6].
One notes line 94, which is 94 A(KK) = 1 + FIX(RND * 10).
0 REM DEFDBL A-Z
3 DEFINT J, K, X
4 DIM X(342), A(342), L(333), K(333)
5 FOR JJJJ = -32000 TO 32000
14 RANDOMIZE JJJJ
16 M = -1D+17
91 FOR KK = 1 TO 13
94 A(KK) = 1 + FIX(RND * 10)
95 NEXT KK
128 FOR I = 1 TO 10000000
129 FOR K = 1 TO 13
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 13)
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
265 FOR J45 = 1 TO 13
266 IF X(J45) < 1 THEN X(J45) = A(J45)
267 NEXT J45
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
277 P = -ABS(N11) - ABS(N12) - ABS(N13) - ABS(N14) - ABS(N15)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 13
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1670 NEXT I
1888 IF M < -3 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), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [13]. Copied by hand from the screen, the computer program’s complete output through JJJJ=-31976 is shown below:
6 4 11 2 6
4 11 5 9 1
1 1 3 -2.742824 -32000
...
6 10 9 9 7
6 3 6 6 1
1 1 1 -1.651043 -31998
7 7 10 7 9
7 6 7 1 1
1 1 1 -2.003829 -31997
12 5 6 7 6
10 6 1 2 4
1 2 4 -2 406149 -31989
9 2 11 1 6
3 11 6 2 5
1 2 5 -1.766955 -31984
6 4 2 7 9
7 5 4 5 7
1 9 6 -.3914129 -31983
6 6 6 6 6
6 6 6 1 9
8 5 3 -9.020425E-04
-31976
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 [13], the wall-clock time through JJJJ=-31976 was 27 minutes.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] 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.
[6] W. Hock, K. Schittkowski, Test Examples for Nonlinear Programming Codes. Springer-Verlag, 1981.
[7] 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.
[8] 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.
[9] 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.
[10] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[11] 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.
[12] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[13] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[14] Wolfram Research, Inc., Diophantine Polynomial Systems.
https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[15] 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.
[16] 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/
Tuesday, October 25, 2016
ERRATUM: The General Mixed Integer Nonlinear Programming (MINLP) Computer Program/Solver Solving Simultaneously a Nonlinear System of Two Simultaneous Nonlinear Equations Involving 100,000 General Integer Variables
Jsun Yui Wong
The last paragraph should read as follows:
On a personal computer with a Pentium Dual-Core CPU E5200 @2.50GHz, 2.50 GHz, 960 MB of RAM and with qb64v1000-win [12], the wall-clock time for reaching M=0 was 6 hours.
The last paragraph should read as follows:
On a personal computer with a Pentium Dual-Core CPU E5200 @2.50GHz, 2.50 GHz, 960 MB of RAM and with qb64v1000-win [12], the wall-clock time for reaching M=0 was 6 hours.
Monday, October 24, 2016
The General Mixed Integer Nonlinear Programming (MINLP) Computer Program/Solver Solving Simultaneously a Nonlinear System of Two Simultaneous Nonlinear Equations Involving 100,000 General Integer Variables
Jsun Yui Wong
The computer program listed below seeks one integer solution to the following problem:
X(1) * X(2) * X(3) * X(4) * ...* X(100000) - 1 = 0,
99999
sigma [ 100 * (X(k + 1) - X(k) ^ 2) ^ 2 + (1 - X(k)) ^ 2 ] = 0,
k=1
and each unknown = 0, 1, or 2.
The first equation above is a part of the Brown almost linear function [1, p. 660]. The second is based on the Rosenbrock function in Schitkowski [11, pp. 118-123].
One notes line 88, line 94, line 189, line 195, and line 196.
0 REM DEFDBL A-Z
3 DEFINT X
4 DIM X(100042), A(100042), K(100033)
5 FOR JJJJ = -32000 TO 32000
14 RANDOMIZE JJJJ
16 M = -1D+57
88 A(1) = 2
91 FOR KK = 2 TO 100000
94 A(KK) = 1
95 NEXT KK
128 FOR I = 1 TO 30000000
129 FOR K = 1 TO 100000
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
171 REM B = 1 + FIX(RND * 100003)
175 REM GOTO 190
181 B = 1 + FIX(RND * 100003)
182 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) - 1 ELSE X(B) = A(B) + 1
190 REM IF A(B) = 0 THEN X(B) = 1 ELSE X(B) = 0
191 NEXT IPP
193 REM GOTO 201
194 FOR J49 = 1 TO 100000
195 IF X(J49) < 0 THEN GOTO 1670
196 IF X(J49) > 2 THEN GOTO 1670
197 NEXT J49
201 PRODBROWN = 1
203 FOR J33 = 1 TO 100000
206 PRODBROWN = PRODBROWN * X(J33)
209 NEXT J33
222 N1 = PRODBROWN - 1
225 GOTO 257
231 SUMSCHI = 0
236 FOR J22 = 1 TO 100000
239 SUMSCHI = SUMSCHI + X(J22) ^ 2
241 NEXT J22
244 N9 = -SUMSCHI + 100000
246 REM N5 = -(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(1) ^ 4 + X(2) ^ 4 + X(3) ^ 4 + X(4) ^ 4 + X(5) ^ 4 + X(6) ^ 4 + X(7) ^ 4 + X(8) ^ 4) + (X(1) ^ 3 + X(2) ^ 3 + X(3) ^ 3 + X(4) ^ 3 + X(5) ^ 3 + X(6) ^ 3 + X(7) ^ 3 + X(8) ^ 3) ^ 2
257 sumrose = 0
259 FOR j44 = 1 TO 99999
261 sumrose = sumrose + 100 * (X(j44 + 1) - X(j44) ^ 2) ^ 2 + (1 - X(j44)) ^ 2
263 NEXT j44
265 N6 = sumrose - 0
277 P = -ABS(N1) - ABS(N6)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 100000
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1666 REM PRINT A(1), A(49999), A(50000), M, JJJJ
1667 PRINT A(1), A(2), A(3), A(4), A(5), A(6), A(7), A(8), A(99994), A(99995), A(99996), A(99997), A(99998), A(99999), A(100000), M, JJJJ
1670 NEXT I
1888 IF M < -100 THEN 1999
1910 PRINT A(1), A(2), A(3), A(4), A(5), A(6), A(7), A(8), A(9), A(10), A(29996), A(29997), A(49998), A(49999), A(50000)
1912 PRINT A(1111), A(1112), A(1113), A(1114), A(1115), A(3336), A(3337), A(3338), A(3339), A(3340), A(5996), A(5997), A(25998), A(25999), A(50000), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [12]. Copied by hand from the screen, the computer program’s output through M=0 is shown below:
2 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-2910 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-2005 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-1203 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-403 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-202 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
0 -32000
Above there is no rounding by hand; it is just straight copying by hand from the screen.
Of the 100,000 A's, only the 15 A's of line 1667 are shown above.
On a personal computer with a Pentium Dual-Core CPU E5200 @2.50GHz, 2.50 GHz, 960 MB of RAM and with qb64v1000-win [12], the wall-clock time for reaching M=0 was 10 hours.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] Tianmin Han, Yuhuan Han, Solving large scale nonlinear equations by a new ODE numerical integration method, Applied Mathematics, 2010, 1, pp. 222-229. www.SciRP.org/journal/am.
[6] 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.
[7] 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.
[8] 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.
[9] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[10] 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.
[11] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[12] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[13] Wolfram Research, Inc., Diophantine Polynomial Systems. https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[14] 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.
[15] 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/
The computer program listed below seeks one integer solution to the following problem:
X(1) * X(2) * X(3) * X(4) * ...* X(100000) - 1 = 0,
99999
sigma [ 100 * (X(k + 1) - X(k) ^ 2) ^ 2 + (1 - X(k)) ^ 2 ] = 0,
k=1
and each unknown = 0, 1, or 2.
The first equation above is a part of the Brown almost linear function [1, p. 660]. The second is based on the Rosenbrock function in Schitkowski [11, pp. 118-123].
One notes line 88, line 94, line 189, line 195, and line 196.
0 REM DEFDBL A-Z
3 DEFINT X
4 DIM X(100042), A(100042), K(100033)
5 FOR JJJJ = -32000 TO 32000
14 RANDOMIZE JJJJ
16 M = -1D+57
88 A(1) = 2
91 FOR KK = 2 TO 100000
94 A(KK) = 1
95 NEXT KK
128 FOR I = 1 TO 30000000
129 FOR K = 1 TO 100000
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
171 REM B = 1 + FIX(RND * 100003)
175 REM GOTO 190
181 B = 1 + FIX(RND * 100003)
182 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) - 1 ELSE X(B) = A(B) + 1
190 REM IF A(B) = 0 THEN X(B) = 1 ELSE X(B) = 0
191 NEXT IPP
193 REM GOTO 201
194 FOR J49 = 1 TO 100000
195 IF X(J49) < 0 THEN GOTO 1670
196 IF X(J49) > 2 THEN GOTO 1670
197 NEXT J49
201 PRODBROWN = 1
203 FOR J33 = 1 TO 100000
206 PRODBROWN = PRODBROWN * X(J33)
209 NEXT J33
222 N1 = PRODBROWN - 1
225 GOTO 257
231 SUMSCHI = 0
236 FOR J22 = 1 TO 100000
239 SUMSCHI = SUMSCHI + X(J22) ^ 2
241 NEXT J22
244 N9 = -SUMSCHI + 100000
246 REM N5 = -(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(1) ^ 4 + X(2) ^ 4 + X(3) ^ 4 + X(4) ^ 4 + X(5) ^ 4 + X(6) ^ 4 + X(7) ^ 4 + X(8) ^ 4) + (X(1) ^ 3 + X(2) ^ 3 + X(3) ^ 3 + X(4) ^ 3 + X(5) ^ 3 + X(6) ^ 3 + X(7) ^ 3 + X(8) ^ 3) ^ 2
257 sumrose = 0
259 FOR j44 = 1 TO 99999
261 sumrose = sumrose + 100 * (X(j44 + 1) - X(j44) ^ 2) ^ 2 + (1 - X(j44)) ^ 2
263 NEXT j44
265 N6 = sumrose - 0
277 P = -ABS(N1) - ABS(N6)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 100000
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1666 REM PRINT A(1), A(49999), A(50000), M, JJJJ
1667 PRINT A(1), A(2), A(3), A(4), A(5), A(6), A(7), A(8), A(99994), A(99995), A(99996), A(99997), A(99998), A(99999), A(100000), M, JJJJ
1670 NEXT I
1888 IF M < -100 THEN 1999
1910 PRINT A(1), A(2), A(3), A(4), A(5), A(6), A(7), A(8), A(9), A(10), A(29996), A(29997), A(49998), A(49999), A(50000)
1912 PRINT A(1111), A(1112), A(1113), A(1114), A(1115), A(3336), A(3337), A(3338), A(3339), A(3340), A(5996), A(5997), A(25998), A(25999), A(50000), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [12]. Copied by hand from the screen, the computer program’s output through M=0 is shown below:
2 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-2910 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-2005 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-1203 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-403 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
-202 -32000
1 1 1 1 1
1 1 1 1 1
1 1 1 1 1
0 -32000
Above there is no rounding by hand; it is just straight copying by hand from the screen.
Of the 100,000 A's, only the 15 A's of line 1667 are shown above.
On a personal computer with a Pentium Dual-Core CPU E5200 @2.50GHz, 2.50 GHz, 960 MB of RAM and with qb64v1000-win [12], the wall-clock time for reaching M=0 was 10 hours.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] Tianmin Han, Yuhuan Han, Solving large scale nonlinear equations by a new ODE numerical integration method, Applied Mathematics, 2010, 1, pp. 222-229. www.SciRP.org/journal/am.
[6] 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.
[7] 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.
[8] 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.
[9] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[10] 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.
[11] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[12] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[13] Wolfram Research, Inc., Diophantine Polynomial Systems. https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[14] 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.
[15] 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/
Sunday, October 9, 2016
Solving in General Integers a Nonlinear System of Two Simultaneous Nonlinear Equations with Cold Starts A(KK) = -300000 + FIX(RND * 600001)
Jsun Yui Wong
The computer program listed below seeks one or more integer solutions to the following given system of two nonlinear equations:
(X(1) - 1) ^ 2 + (X(1) - X(2)) ^ 2 + (X(3) - 1) ^ 2 + (X(4) - 1) ^ 4 + (X(5) - 1) ^ 6 = 4
(X(1) - 1) ^ 2 + (X(1) - X(2)) ^ 2 + (X(2) - X(3)) ^ 2 + (X(3) - X(4)) ^ 4 + (X(4) - X(5)) ^ 4 = 1.
The two equation are based on page 97 and page 99 of Hock and Schittkowski [6], respectively.
One notes the starting vectors of line 94, which is 94 A(KK) = -300000 + FIX(RND * 600001).
0 REM DEFDBL A-Z
3 DEFINT X
4 DIM X(100042), A(100042), K(100033)
5 FOR JJJJ = -32000 TO 32000
14 RANDOMIZE JJJJ
16 M = -1D+57
91 FOR KK = 1 TO 5
94 A(KK) = -300000 + FIX(RND * 600001)
95 NEXT KK
128 FOR I = 1 TO 1000
129 FOR K = 1 TO 5
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 5)
182 IF RND < .5 THEN 183 ELSE GOTO 189
183 R = (1 - RND * 2) * A(B)
186 X(B) = A(B) + (RND ^ 3) * R
188 GOTO 191
189 IF RND < .5 THEN X(B) = A(B) - 1 ELSE X(B) = A(B) + 1
190 REM IF A(B) = 0 THEN X(B) = 1 ELSE X(B) = 0
191 NEXT IPP
224 N1 = (X(1) - 1) ^ 2 + (X(1) - X(2)) ^ 2 + (X(3) - 1) ^ 2 + (X(4) - 1) ^ 4 + (X(5) - 1) ^ 6 - 4
276 N2 = (X(1) - 1) ^ 2 + (X(1) - X(2)) ^ 2 + (X(2) - X(3)) ^ 2 + (X(3) - X(4)) ^ 4 + (X(4) - X(5)) ^ 4 - 1
277 P = -ABS(N1) - ABS(N2)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 5
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1670 NEXT I
1888 IF M < -10 THEN 1999
1910 PRINT A(1), A(2), A(3), A(4), A(5), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [13]. Copied by hand from the screen, the computer program’s output through JJJJ=-27005 is summarized below:
.
.
.
0 0 0 0 1
-2 -27070
0 0 0 0 1
-2 -27058
0 0 0 0 0
0 -27046
0 0 0 0 0
0 -27037
2 2 2 2 2
0 -27036
1 0 0 0 0
0 -27033
0 0 0 0 0
0 -27019
0 -1 0 0 1
-3 -27016
1 2 2 2 2
0 -27013
0 0 0 0 0
0 -27006
1 0 0 0 0
0 -27005
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 [13], the wall-clock time through JJJJ=-27005 was 20 seconds.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] Tianmin Han, Yuhuan Han, Solving large scale nonlinear equations by a new ODE numerical integration method, Applied Mathematics, 2010, 1, pp. 222-229. www.SciRP.org/journal/am.
[6] W. Hock, K. Schittkowski, Test Examples for Nonlinear Programming Codes. Springer-Verlag, 1981.
[7] 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.
[8] 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.
[9] 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.
[10] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[11] 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.
[12] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[13] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[14] Wolfram Research, Inc., Diophantine Polynomial Systems. https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[15] 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.
[16] 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/
The computer program listed below seeks one or more integer solutions to the following given system of two nonlinear equations:
(X(1) - 1) ^ 2 + (X(1) - X(2)) ^ 2 + (X(3) - 1) ^ 2 + (X(4) - 1) ^ 4 + (X(5) - 1) ^ 6 = 4
(X(1) - 1) ^ 2 + (X(1) - X(2)) ^ 2 + (X(2) - X(3)) ^ 2 + (X(3) - X(4)) ^ 4 + (X(4) - X(5)) ^ 4 = 1.
The two equation are based on page 97 and page 99 of Hock and Schittkowski [6], respectively.
One notes the starting vectors of line 94, which is 94 A(KK) = -300000 + FIX(RND * 600001).
0 REM DEFDBL A-Z
3 DEFINT X
4 DIM X(100042), A(100042), K(100033)
5 FOR JJJJ = -32000 TO 32000
14 RANDOMIZE JJJJ
16 M = -1D+57
91 FOR KK = 1 TO 5
94 A(KK) = -300000 + FIX(RND * 600001)
95 NEXT KK
128 FOR I = 1 TO 1000
129 FOR K = 1 TO 5
131 X(K) = A(K)
132 NEXT K
155 FOR IPP = 1 TO FIX(1 + RND * 3)
181 B = 1 + FIX(RND * 5)
182 IF RND < .5 THEN 183 ELSE GOTO 189
183 R = (1 - RND * 2) * A(B)
186 X(B) = A(B) + (RND ^ 3) * R
188 GOTO 191
189 IF RND < .5 THEN X(B) = A(B) - 1 ELSE X(B) = A(B) + 1
190 REM IF A(B) = 0 THEN X(B) = 1 ELSE X(B) = 0
191 NEXT IPP
224 N1 = (X(1) - 1) ^ 2 + (X(1) - X(2)) ^ 2 + (X(3) - 1) ^ 2 + (X(4) - 1) ^ 4 + (X(5) - 1) ^ 6 - 4
276 N2 = (X(1) - 1) ^ 2 + (X(1) - X(2)) ^ 2 + (X(2) - X(3)) ^ 2 + (X(3) - X(4)) ^ 4 + (X(4) - X(5)) ^ 4 - 1
277 P = -ABS(N1) - ABS(N2)
1451 IF P <= M THEN 1670
1657 FOR KEW = 1 TO 5
1658 A(KEW) = X(KEW)
1659 NEXT KEW
1661 M = P
1670 NEXT I
1888 IF M < -10 THEN 1999
1910 PRINT A(1), A(2), A(3), A(4), A(5), M, JJJJ
1999 NEXT JJJJ
This computer program was run with qb64v1000-win [13]. Copied by hand from the screen, the computer program’s output through JJJJ=-27005 is summarized below:
.
.
.
0 0 0 0 1
-2 -27070
0 0 0 0 1
-2 -27058
0 0 0 0 0
0 -27046
0 0 0 0 0
0 -27037
2 2 2 2 2
0 -27036
1 0 0 0 0
0 -27033
0 0 0 0 0
0 -27019
0 -1 0 0 1
-3 -27016
1 2 2 2 2
0 -27013
0 0 0 0 0
0 -27006
1 0 0 0 0
0 -27005
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 [13], the wall-clock time through JJJJ=-27005 was 20 seconds.
Acknowledgment
I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.
References
[1] C. A. Floudas, Deterministic Global Optimization. Kluwer Academic Publishers, 2000.
[2] F. Glover, 1986. Future Paths for Integer Programming and Links to Artificial Intelligence. Computers and Operations Research, vol. 13, 5, 533-549
[3] F. Glover, 1989. Tabu Search, Part 1. ORSA Journal on Computing, vol. 1, number 3, 190-206.
[4] F. Glover, 1989. Tabu Search, Part 2. ORSA Journal on Computing, vol. 2, number 1, 4-32.
[5] Tianmin Han, Yuhuan Han, Solving large scale nonlinear equations by a new ODE numerical integration method, Applied Mathematics, 2010, 1, pp. 222-229. www.SciRP.org/journal/am.
[6] W. Hock, K. Schittkowski, Test Examples for Nonlinear Programming Codes. Springer-Verlag, 1981.
[7] 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.
[8] 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.
[9] 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.
[10] William H. Mills, A System of Quadratic Diophantine Equations, Pacific Journal of Mathematics, 3 (1953), pp. 209-220.
[11] 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.
[12] K. Schittkowski, More Test Examples for Nonlinear Programming Codes. Springer, 1987.
[13] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64.
[14] Wolfram Research, Inc., Diophantine Polynomial Systems. https:/reference.wolfram.com/language/tutorial/DiophantineReduce.html.
[15] 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.
[16] 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/
Subscribe to:
Posts (Atom)