Based on the computer program of the older edition, the following computer program seeks to solve Problem S11 on page 3328 of Amaral [3].
0 REM DEFDBL A-Z
1 DEFINT I,J,K,X,A
2 DIM B(99),N(99),A(2002),H(99),L(99),U(99),X(2002),D(111),P(111),PS(33),J44(2002),J(99),AA(99),HR(32),HHR(32),C(22),CC(22),Y(22),A
3 DIM HS(49,49)
4 DIM PE(49,49)
5 DIM SD(49,49)
27 HR(1)=3:HR(2)=9:HR(3)=3:HR(4)=7:HR(5)=3
28 HR(6)=7:HR(7)=5:HR(8)=9:HR(9)=6:HR(10)=5 :HR(11)=10
31 FOR IL=1 TO 11
32 FOR JL=1 TO 11
33 READ HS(IL,JL)
34 NEXT JL
35 NEXT IL
61 DATA 999,20,2,8,0,9,5,7,0,20,3
62 DATA 20,999,8,9,13,17,16,1,8,6,7
63 DATA 2,8,999,18,0,10,4,18,5,8,0
64 DATA 8,9,18,999,6,16,10,4,2,14,6
66 DATA 0,13,0,6,999,6,0,11,0,8,2
67 DATA 9,17,10,16,6,999,6,13,2,7,18
68 DATA 5,16,4,10,0,6,999,1,11,15,7
69 DATA 7,1,18,4,11,13,1,999,1,7,2
70 DATA 0,8,5,2,0,2,11,1,999,12,0
71 DATA 20,6,8,14,8,7,15,7,12,999,3
72 DATA 3,7,0,6,2,18,7,2,0,3,999
78 FOR JJJJ=-32000 TO 32000
79 RANDOMIZE JJJJ
80 M=-1D+37
81 FOR J44=1 TO 11
83 A(J44)=J44
84 NEXT J44
126 REM IMAR=10+FIX(RND*1000)
128 FOR I=1 TO 500
129 FOR KKQQ=1 TO 11
130 X(KKQQ)=A(KKQQ)
131 NEXT KKQQ
133 III=1+FIX(RND*11)
134 JJJ=1+FIX(RND*11)
221 X(III)=A(JJJ)
223 X(JJJ)=A(III)
231 FOR J44=1 TO 11
232 IF X(J44)=1 THEN HHR(J44)=HR(J44) ELSE GOTO 234
233 Y(1)=J44
234 IF X(J44)=2 THEN HHR(J44)=HR(J44) ELSE GOTO 244
237 Y(2)=J44
244 IF X(J44)=3 THEN HHR(J44)=HR(J44) ELSE GOTO 254
247 Y(3)=J44
254 IF X(J44)=4 THEN HHR(J44)=HR(J44) ELSE GOTO 257
255 Y(4)=J44
257 IF X(J44)=5 THEN HHR(J44)=HR(J44) ELSE GOTO 259
258 Y(5)=J44
259 IF X(J44)=6 THEN HHR(J44)=HR(J44) ELSE GOTO 277
260 Y(6)=J44
277 IF X(J44)=7 THEN HHR(J44)=HR(J44) ELSE GOTO 279
278 Y(7)=J44
279 IF X(J44)=8 THEN HHR(J44)=HR(J44) ELSE GOTO 285
280 Y(8)=J44
285 IF X(J44)=9 THEN HHR(J44)=HR(J44) ELSE GOTO 289
287 Y(9)=J44
289 IF X(J44)=10 THEN HHR(J44)=HR(J44) ELSE GOTO 296
293 Y(10)=J44
296 IF X(J44)=11 THEN HHR(J44)=HR(J44) ELSE GOTO 307
298 Y(11)=J44
307 C(1)=.5*HHR(Y(1))+HHR(Y(2))+HHR(Y(3))+HHR(Y(4))+HHR(Y(5))+HHR(Y(6))
311 C(2)=.5*HHR(Y(2))+HHR(Y(3))+HHR(Y(4))+HHR(Y(5))+HHR(Y(6))
314 C(3)=.5*HHR(Y(3))+HHR(Y(4))+HHR(Y(5))+HHR(Y(6))
318 C(4)=.5*HHR(Y(4))+HHR(Y(5))+HHR(Y(6))
323 C(5)=.5*HHR(Y(5))+HHR(Y(6))
327 C(6)=.5*HHR(Y(6))
341 C(7 )=.5*HHR(Y(7))+HHR(Y(8))+HHR(Y(9))+HHR(Y(10))+HHR(Y(11))
345 C(8)=.5*HHR(Y(8))+HHR(Y(9))+HHR(Y(10))+HHR(Y(11))
349 C(9)=.5*HHR(Y(9))+HHR(Y(10))+HHR(Y(11))
353 C(10)=.5*HHR(Y(10))+HHR(Y(11))
355 C(11)=.5*HHR(Y(11))
356 NEXT J44
359 PROD=0
361 FOR J44=1 TO 11
368 FOR J45=J44+1 TO 11
371 PROD=PROD -HS(Y(J44),Y(J45))*ABS( C(J44)-C(J45) )
381 NEXT J45
388 NEXT J44
422 P=PROD
1111 IF P<=M THEN 1670
1452 M=P
1453 FOR KLX=1 TO 11
1454 CC(KLX)=C(KLX)
1455 A(KLX)=X(KLX)
1456 NEXT KLX
1557 GOTO 128
1670 NEXT I
1889 IF M<-3444 THEN 1999
1901 PRINT A(1),A(2),A(3),A(4),A(5)
1902 PRINT A(6),A(7),A(8),A(9),A(10),A(11)
1903 PRINT CC(1),CC(2),CC(3),CC(4),CC(5)
1904 PRINT CC(6),CC(7),CC(8),CC(9),CC(10),CC(11)
1919 PRINT M,JJJJ
1999 NEXT JJJJ
This BASIC computer program was run with Microsoft's GW BASIC 3.11 interpreter. The complete output through JJJJ=-31954 is shown below. What follows is a hand copy from the computer-monitor screen; immediately below there is no rounding by hand.
8 7 4 9 10
5 2 6 1 3
11
32 26.5 21.5 17.5 12.5
4.5 27.5 21.5 16.5 11.5
5
-3439.5 -31990
8 7 4 9 10
5 2 6 1 3
11
32 26.5 21.5 17.5 12.5
4.5 27.5 21.5 16.5 11.5
5
-3439.5 -31954
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 through JJJJ= -31954 was 21 seconds.
References
[1] Andre R. S. Amaral (2006), On the Exact Solution of a Facility Layout Problem. European Journal of Operational Research 173 (2006), pp. 508-518.
[2] Andre R. S. Amaral (2008), An Exact Approach to the One-Dimensional Facility Layout Problem. Operations Research, Vol. 56, No. 4 (July-August, 2008), pp. 1026-1033.
[3] Andre R. S. Amaral (2012), The Corridor Allocation Problem. Computers and Operations Research 39 (2012), pp. 3325-3330.
[4] Miguel F. Anjos, Anthony Vannelli, Computing Globally Optimal Solutions for Single-Row Layout Problems Using Semidefinite Programming and Cutting Planes. INFORMS Journal on Computing, Vol. 20, No. 4, Fall 2008, pp. 611-617.
[5] David L. Applegate, Robert E. Bixby, Vasek Chvatal, William J. Cook, The Traveling Salesman Problem: A Computational Study. Princeton and Oxford: Princeton University Press, 2006.
[6] L. L. Barachet (1957), Graphic Solution of the Travelling Salesman Problem. Operations Research,Vol. 5, pp. 841-845.
[7] T. Y. Chen, H. C. Chen (2009), Mixed-Discrete Structural Optimization Using a Rank-Niche Evolution Strategy, Engineering Optimization, 41:1, 39-58.
[8] Leon Cooper, U. N. Bhat, L. J. LeBlanc, Introduction to Operations Researach Models. W. B. Saunders Company, 1977.
[9] George B. Dantzig, Discrete-Variable Extremum Problems. Operations Research, Vol. 5, No. 2 (Apr., 1957), pp. 266-277.
[10] G. Dantzig, R. Fulkerson, S. Johnson, Solution of a Large-Scale Traveling-Salesman Problem.
Operations Research, Vol. 2, No. 4 (Nov., 1954), pp. 393-410.
[11] W. J. Fabrycky, P. M. Ghare, P. E. Torgersen, Applied Operations Research and Management Science. Englewood Cliffs, N. J. 07362: Prentice-Hall, Inc., 1984.
[12] Billy E. Gillett, Introduction to Operations Research: A Computer-Oriented Algorithmic Approach. McGraw-Hill, Inc., 1976.
[13] Martin Grotschel, Olaf Holland (1991), Solution of Large-Scale Symmetric Travelling Salesman Problems, Mathematical Programming 51, pp. 141-202.
[14] Sunderesh S. Heragu, Andrew Kusiak (1988), Machine Layout Problem in Flexible Manufacturing Systems. Operations Research, Vol. 36, No. 2, Operations Research in Manufacturing (Mar. - Apr., 1988), pp. 258-268.
[15] S. S. Heragu, A. Kusiak (1991), Efficient Models for the Facility Layout Problem. European Journal of Operational Research, Vol. 53 (1991), pp. 1-13.
[16] Michael Junger, Thomas M. Liebling, Dennis Naddef, George L. Nemhauser, William R. Pulleybank, Gerhart Reinelt, Giovanni Rinaldi, Lawrence A. Wolsey--Editors, 50 Years of Integer Programming 1958-2008. Berlin: Springer, 2010.
[17] R. L. Karg, G. L. Thompson (1964), A Heuristic Approach to Solving Travelling Salesman Problems. Management Science, Vol. 10, Number 2, pp. 225-248.
[18] K. Ravi Kumar, George C. Hadjinicola, Ting-li Lin (1995), A Heuristic Procedure for the Single-Row Facility Layout Problem. European Journal of Operational Research 87 (1995) 65-73.
[19] A. H. Land, A. G. Doig, An Automatic Method of Solving Discrete Programming Problems. Econometrica, Vol. 28, No. 3 (Jul., 1960), pp. 497-520.
[20] 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.
[21] Robert F. Love, Jsun Y. Wong (1976), On Solving a One-Dimensional Space Allocation Problem with Integer Programming. INFOR, Vol. 14, No. 2, June 1976, pp. 139-143.
[22] Harry M. Markowitz, Alan S. Manne, On the Solution of Discrete Programming Problems. Econometrica, Vol. 25, No. 1 (Jan., 1957), pp. 84-110.
[23] Ken McAloon, Carol Tretkoff, Optimization and Computational Logic. John Wiley and Sons, Inc., 1996.
[24] 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.
[25] Katta G. Murty, Opereations Research: Deterministic Optimization Models. Prentice Hall, Upper Saddle River, New Jersey 07458, 1994.
[26] C. E. Nugent, T. E. Vollmann, J. Ruml (1968), An Experimental Comparison of Techniques for the Assignment of Facilities to Locations, Operations Research 16 (1968), pp. 150-173.
[27] Christopher J. Picone, Wilbert E. Wilhelm (1986), "A Perturbation Scheme To Improve Hillier's Solution to the Facilities Layout Problem": a Clarification. Management Science Vol. 32, No. 2, February 1986, pp. 253-254.
[28] Cliff T. Ragsdale, Spreadsheet Modeling and Decision Analysis, Fifth Edition. South-Westen, Cengage Learning, 2008.
[29] H. H. Rosenbrock (1960), An Automatic Method for Finding the Greatest or Least Value of a Function, Computer Journal Vol. 3, pp. 175-184.
[30] Donald M. Simmons (1969), One-Dimensional Space Allocation: An Ordering Algorithm. Operations Research, Vol. 17, No. 5 (Sep. - Oct., 1969), pp. 812-826.
[31] Wayne L. Winston, Munirpallam Venkataramanan, Introduction to Mathematical Programming: Operations Research, Volume One, Fourth Edition. Pacific Grove, CA 93950: Brooks/Cole--Thomson Learning, 2003.
[32] Wayne L. Winston, S. Christian Albright, Practical Management Science, Third Edition. Thomson/South-Western, 2007.
[33] Jsun Yui Wong (2009, July 18). An Integer Programming Computer Program Applied to One-Dimensional Space Allocation. Retrieved from http://wongsllllblog.blogspot.com/2009/07/
[34] Jsun Yui Wong (2009, December 18). A Heuristic Nonlinear Integer Solver Applied to a Problem of Assignment of Facilities to Locations. Retrieved from http://wongsnewnewblog.blogspot.ca/2009/12/
[35] Jsun Yui Wong (2011, October 27). A Nonlinear Integer/Discrete/Continuous Programming Solver Applied to a New Formulation of a Twelve-City Traveling Salesman Problem, Sixth Edition. Retrieved from http://computationalresultsfromcomputerprograms.wordpress.com/2011/10/27/
[36] Ji-Hui Zhang, Xin-He Xu (1999), An Efficient Evolutionary Programming Algorithm. Computers and Operations Research 26, 645-663.