Testing the Present Algorithm with a Test Problem Based on the Rosenbrock Function and with 10,000 General Integer Variables

Jsun Yui Wong

Similar to the computer program of the preceding paper, the following computer program seeks to solve Li and Sun’s Problem 14.4, [5, p. 415], but with 10,000 unknowns.

While line 128 of the preceding paper is 128 FOR I=1 TO 3000, line 128 here is
is 128 FOR I=1 TO 32000 STEP .5; while line 144 there is 144 REM GOTO 167, line 144 here is 144 GOTO 167.

0 REM DEFDBL A-Z
1 DEFINT J,K,X
2 DIM A(10001),X(10001)
88 FOR JJJJ=-32000 TO 32000
89 RANDOMIZE JJJJ
90 M=-3D+30
110 FOR J44=1 TO 10000
112 A(J44)=-5+FIX( RND*11)
113 NEXT J44
128 FOR I=1 TO 32000 STEP .5
129 FOR KKQQ=1 TO 10000
130 X(KKQQ)=A(KKQQ)
131 NEXT KKQQ
139 FOR IPP=1 TO FIX(1+RND*3)
140 B=1+FIX(RND*10001)
144 GOTO 167
150 R=(1-RND*2)*A(B)
155 IF RND<.5 THEN 160 ELSE 167
160 X(B)=(A(B) +RND^3*R)
165 GOTO 168
167 IF RND<.5 THEN X(B)=A(B)-1 ELSE X(B)=A(B) +1
168 REM IF A(B)=0 THEN X(B)=1 ELSE X(B)=0
169 NEXT IPP
182 FOR J44=1 TO 10000
183 IF X(J44)<-5 THEN X(J44)=A(J44)
184 IF X(J44)>5 THEN X(J44)=A(J44)
185 NEXT J44
220 SUMM=0
222 FOR J44=1 TO 9999
223 SUMM=SUMM+ 100*( X( J44 +1 ) -X(J44)^2 )^2+(1-X( J44))^2
226 NEXT J44
333 PD1=-SUMM
1111 IF PD1<=M THEN 1670
1452 M=PD1
1454 FOR KLX=1 TO 10000
1455 A(KLX)=X(KLX)
1456 NEXT KLX
1557 GOTO 128
1670 NEXT I
1889 IF M<-99999! THEN 2999
2223 FOR J44=1 TO 10000
2224 PRINT A(J44) ” =A(J44) where J44 is ” J44
2225 NEXT J44
2227 PRINT “M=” M ” JJJJ=” JJJJ
2999 NEXT JJJJ

This BASIC computer program was run via basica/D of Microsoft’s GW-BASIC 3.11 interpreter for DOS. Only a small part of the printout through JJJJ=-32000 is copied by hand from the screen and shown below. Immediately below there is no rounding by hand.

.
.
.
1 =A(J44) where J44 is 9979
1 =A(J44) where J44 is 9980
1 =A(J44) where J44 is 9981
1 =A(J44) where J44 is 9982
1 =A(J44) where J44 is 9983
1 =A(J44) where J44 is 9984
1 =A(J44) where J44 is 9985
1 =A(J44) where J44 is 9986
1 =A(J44) where J44 is 9987
1 =A(J44) where J44 is 9988
1 =A(J44) where J44 is 9989
1 =A(J44) where J44 is 9990
1 =A(J44) where J44 is 9991
1 =A(J44) where J44 is 9992
1 =A(J44) where J44 is 9993
1 =A(J44) where J44 is 9994
1 =A(J44) where J44 is 9995
1 =A(J44) where J44 is 9996
1 =A(J44) where J44 is 9997
1 =A(J44) where J44 is 9998
1 =A(J44) where J44 is 9999
1 =A(J44) where J44 is 10000
M= 0      JJJJ=-32000

Only 22 of the 10,000 A’s are shown above.

In the computer program above the word PRINT to print on the screen can be replaced by the word LPRINT to print on the printer.

On a personal computer with a Pentium Dual-Core CPU E5200 @2.50GHz, 2.50 GHz, 960 MB of RAM, and the IBM basica/D interpreter, version GW BASIC 3.11, the wall-clock time for obtaining the output through JJJJ=-32000 was thirteen hours and a half.

Acknowledgment

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

References

[1] E. Balas, An Additive Algorithm for Solving Linear Programs with Zero-One Variables. Operations Research, Vol. 13, No. 4 (1965), pp. 517-548.

[2] E. Balas, Discrete Programming by the Filter Method. Operations Research, Vol. 15, No. 5 (Sep. – Oct., 1967), pp. 915-957.

[3] E. L. Lawler, M. D. Bell, A Method for Solving Discrete Optimization Problems. Operations Research, Vol. 14, No. 6 (Nov. – Dec., 1966), pp. 1098-1112.

[4] E. L. Lawler, M. D. Bell, Errata: A Method for Solving Discrete Optimization Problems. Operations Research, Vol. 15, No. 3 (May – June, 1967), p. 578.

[5] Duan Li, Xiaoling Sun, Nonlinear Integer Programming. Publisher: Springer Science+Business Media,LLC (2006).

[6] Harvey M. Salkin, Integer Programming. Menlo Park, California: Addison-Wesley Publishing Company (1975).

[7] Harvey M. Salkin, Kamlesh Mathur, Foundations of Integer Programming. Publisher: Elsevier Science Ltd (1989).

[8] Jsun Yui Wong (2012, April 23). The Domino Method of General Integer Nonlinear Programming Applied to Problem 2 of Lawler and Bell. http://computationalresultsfromcomputerprograms.wordpress.com/2012/04/23/

[9] Jsun Yui Wong (2013, September 4). A Nonlinear Integer/Discrete/Continuous Programming Solver Applied to a Literature Problem with Twenty Binary Variables and Three Constraints, Third Edition. http://myblogsubstance.typepad.com/substance/2013/09/