Testing the Domino Method of General Integer/Continuous/Mixed Nonlinear Programming with Brown’s Barely Nonlinear System of 32500 Equations/Unknowns, Second Edition

Jsun Yui Wong

Based on the computer program in Wong [9], the following computer program seeks to solve simultaneously Brown’s almost linear system of 32500 variables and equations; see Morgan [5, page 15], Floudas [2, page 660], and Han and Han [3, page 227, Example 3].

0 DEFDBL A-Z

3 DEFINT J, K

4 DIM X(32503), A(32503), L(32503), K(32503)

5 FOR JJJJ = -32000 TO -32000

14 RANDOMIZE JJJJ

16 M = -1D+50

91 FOR KK = 1 TO 32500

94 A(KK) = RND * 2.75

95 NEXT KK

128 FOR I = 1 TO 20000000 STEP 1

129 FOR K = 1 TO 32500

131 X(K) = A(K)

132 NEXT K

155 FOR IPP = 1 TO FIX(1 + RND * 3)

181 B = 1 + FIX(RND * 32503)

183 R = (1 - RND * 2) * A(B)

187 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))

191 NEXT IPP

301 prodd = 1

305 FOR j55 = 2 TO 32500

311 prodd = prodd * X(j55)

321 NEXT j55

371 IF prodd < .00001 THEN 1670

389 X(1) = (1) / prodd

501 summ = 0

505 FOR j27 = 1 TO 32500

511 summ = summ + X(j27)

521 NEXT j27

901 DIFF = 0

905 FOR J77 = 1 TO 32499

911 DIFF = DIFF - ABS(X(J77) + summ - 32501)

921 NEXT J77

995 P = DIFF

1451 IF P <= M THEN 1670

1657 FOR KEW = 1 TO 32500

1658 A(KEW) = X(KEW)

1659 NEXT KEW

1661 M = P

1663 II = I

1666 PRINT A(1), A(32500), M, JJJJ, II

1670 NEXT I

1890 REM

1912 PRINT A(1), A(2), A(3)

1915 PRINT A(4), A(5), A(6)

1917 PRINT A(7), A(8), A(9)

1919 PRINT A(10), A(11), A(12)

1922 PRINT A(22485), A(22488), A(22490)

1923 PRINT A(22492), A(22494), A(22497)

1924 PRINT A(23493), A(23496), A(23499)

1928 PRINT A(32488), A(32489), A(32490)

1930 PRINT A(32491), A(32492), A(32493)

1931 PRINT A(32494), A(32495), A(32496)

1933 PRINT A(32497), A(32498), A(32499)

1939 PRINT A(32500), M, JJJJ

1999 NEXT JJJJ

This computer program was run with qb64v1000-win [8]. Copied by hand from the screen, the computer program’s output due to line 1912 through line 1939 is shown below.

1.000000225207885 1 1.000000046947952

1 1 1

1 1.000000511925313 1

1 1.000000001632073 1

1 1.000000005045558 1

1 1 1

1 1 1

1.000000985060877 1 .9999999992260287

1 1 1

1 1 1.000000001638765

1.000000000005344 .999999512253733 1

1 -.145978558468375 -32000

Above there is no rounding by hand; it is just straight copying by hand from the screen.

One notes that of the 32500 values for the 32500 unknowns, only the 34 A’s of line 1912 through line 1939 of the computer program above are shown above and that the M of line 1939 is essentially defined in line 911, line 995, and line 1661, which are 911 DIFF = DIFF – ABS(X(J77) + summ – 32501), 995 P = DIFF, and 1661 M = P, respectively. This M includes 32499 absolutes values.

The system properties of the computer system used include Intel Core 2 Duo CPU E8400 @ 3.00GHz 3.00GHz, 4.00GB of RAM, and qb64v1000-win [8]. The **wall-clock time** (not CPU time) for obtaining the output shown above was 13.5 hours, counting from “Starting program…”.

**Acknowledgment**

I would like to acknowledge the encouragement of Roberta Clark and Tom Clark.

References

[1] R. L. Burden, J. D. Faires, Annette M. Burden. *Numerical Analysis*, Tenth Edition. Cengage Learning, 2016.

[2] C. A. Floudas, *Deterministic Global Optimization*. Kluwer Academic Publishers, 2000.

[3] Tianmin Han, Yuhuan Han, Solving Large Scale Nonlinear Equations by a New ODE Numerical Integration Method, *Applied Mathematics*, 2010, 1, 222-229.

http://www.SciRP.org/journal/am

[4] 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.

[5] Alexander P. Morgan, A Method for Computing All Solutions to Systems of Polynomial Equations, *ACM Transactions on Mathematical Software*, Vol. 9, No. 1, March 1983, Pages 1-17. https://folk.uib.no/ssu029/pdf_file/Morgan83.pdf

[6] W. H. Press, S. A. Teukolsky, W. T. Vetterling, B. P. Flannery. *Numerical recipes: the art of* *scientific computing*, third ed. Cambridge University Press, 2007.

[7] J. Rice. *Numerical Methods, Software, and Analysi*s, Second Edition. Academic Press, 1993.

[8] Wikipedia, QB64, https://en.wikipedia.org/wiki/QB64

[9] J. Y. Wong (November 11, 2015), Testing the Domino Method of General Integer/Continuous/Mixed Nonlinear Programming with Brown’s Barely Nonlinear System of 32500 Equations/Unknowns

https://computerprogramsandresults.wordpress.com/2015/11/11/testing...