本論文利用統計與證明兩種不同的實驗方法去驗證新棋規的可行性。在統計 方面的實驗結果稍微可以看出新棋規的理念是對的,由於只使用五子棋軟體黑石 來實驗,雖然此軟體的棋力有三段之高,但仍會令人感到不客觀;再者此實驗的 樣本數量太少,這也是會讓人懷疑其正確率,故此研究的下一個步驟為蒐集更多 棋力不差的五子棋軟體,並利用它們來統計棋盤上各位置的勝負結果,以求得更 準確的公平邊界。
然而在證明方面的實驗結果與新棋規可以說是相差甚遠。從對 5×5、6×6 與 7
×7 盤面做實驗之結果皆為和來看,並沒有辦法驗證新棋規的概念正確與否,不過 我們考量到由於盤面過小而導致死點於前中局數量過多,因此造成黑白雙方和棋 的機率大幅提高,也導致 Df-pn 在破解小盤面所需的時間較長(對五子棋而言),
所以在未來課題方面,便是想辦法克服 bitboard 應用到 15×15 或 19×19 五子棋盤 面上,也可以與統計方面的實驗結果相互對照。
參考文獻
[1] 六子棋首頁,http://www.connect6.org/。
[2] 向祚雲,介紹五子棋的一種新規定——優連五子棋棋規,
http://www.wuzi8.com/Article/HTML/ 2256.html。
[3] 李睿凡,關於五子棋的常見誤解,
http://122.225.62.170:8080/viewthread.php?tid=16&from=indexheats。
[4] 技術深研 http://chessprograming.wikispaces.com。
[5] 林氏五子棋新棋規首頁,
[9] L. V. Allis, “Searching for Solutions in Games and Artificial Intelligence,” Ph.D.
Thesis, University of Limburg, Maastricht, 1994.
[10] L. V. Allis, “A Knowledge-Based Approach of Connect-Four: The game is over, White to move wins,” M.Sc. thesis, Vrije Universiteit, Amsterdam, 1988.
[11] L. V. Allis, H. J. van den Herik, and M. P. H. Huntjens, “Go-Moku Solved by New Search Techniques,” Computational Intelligence, Vol. 12, 1996, pp. 7–23.
[12] L. V. Allis, M. van der Meulen, H. J. van den Herik, “Proof-number search,”
Artificial Intelligence, Vol. 66 (1), 1994, pp. 91–124.
[13] L. V. Allis and P. N. A. Schoo, “Qubic Solved Again,” In H. J. van den Herik and L.V. Allis (eds.), Heuristic Programming in Artificial Intelligence 3: The Third Computer Olympiad, Ellis Horwood, Chichester, 1992, pp. 192–204.
[14] A. Nagai, "Df-pn algorithm for searching AND/OR trees and its applications", Ph.D. Thesis, Gunma University, 2002.
[15] D. M. Breuker, J. W. H. M. Uiterwijk, and H. J. van den Herik, “Solving 8×8 Domineering,” Theoret. Comp. Sci., Vol. 230, 2000, pp. 196–206.
[16] H. J. van den Herik, J.W.H.M. Uiterwijk, and J.V. Rijswijck, “Games solved:
Now and in the future,” Artificial Intelligence, Vol. 134, 2002, pp. 277–311.
[17] P. Kannan, “Magic Move-Bitboard Generation in Computer Chess,” April 30, 2007.
[18] A. Kishimoto, “Correct and Efficient Search Algorithms in the Presence of Repetitions”, Department of Computer Science, Univerity of Alberta, 2005.
[19] Ogemust
http://code.google.com/p/ogemust/source/browse/src/?r=30485314b5f7b532faa1a 63c7b98808371286edb.
[20] P. S. Segundo, R. Galán, F. Matía, D. R.-Losada, A. Jiménez, "EFFICIENT SEARCH USING BITBOARD MODELS", Intelligent Control Group, Universidad Politécnica de Madrid, 2006.
[21] Renju International Federation, The International Rules of Renju, http://www.renju.nu/ rifrules.htm.
[22] G. Sakata and W. Ikawa, Five-In-A-Row. Renju. The Ishi Press, Inc., Tokyo,
Japan.
[23] M. P. D. Schadd, M. H. M. Winands, M. H. J. Bergsma, J. W. H. M. Uiterwijk, and H. J. van den Herik, “Fanorona is a Draw,” ICGA Journal, Vol. 30(1), 2007, pp. 43–44.
[24] J. Wágner and I. Virág, “Solving Renju,” ICGA Journal, Vol. 24(1), 2001, pp.
30–34.
[25] I-C. Wu and D.-Y. Huang, “A New Family of k-in-a-row Games, ” ACG11, September 2005.
附錄 A 測試盤面
Test1
Test2
Test3
Test4
Test5
Test6
Test7
Test8
附錄 B Magic Number(一)
垂直水平方向的 Magic Numbers
位置 方向 連五範圍(位置) 連五範圍(hex) Magic Number(hex)
0 + 1,2,3,4,8,16,24,32 10101011e 00fffffff00807ff
1 + 0,2,3,4,5,9,17,25,33 20202023d 00fffffffdfa07ff
2 + 0,1,3,4,5,6,10,18,26,34 40404047b 00fffffffdfe03ff
3 + 0,1,2,4,5,6,7,11,19,27,35 8080808f7 00fffffffe0100ff
4 + 0,1,2,3,5,6,7,12,20,28,36 10101010ef 00fffffffef0907f
5 + 1,2,3,4,6,7,13,21,29,37 20202020de 00fffffffef927df
6 + 2,3,4,5,7,14,22,30,38 40404040bc 00fffffffefd23df
7 + 3,4,5,6,15,23,31,39 8080808078 00fffffffefdab57
8 + 9,10,11,12,0,16,24,32,40 10101011e01 00003ffffbf40ffb
9 + 8,10,11,12,13,1,17,25,33,41 20202023d02 00003ffffc33cffc
10 + 8,9,11,12,13,14,2,18,26,34,42 40404047b04 00003ffeddc75aa5
11 + 8,9,10,12,13,14,15,3,19,27,35,43 8080808f708 00003fff6ebf51b0 12 + 8,9,10,11,13,14,15,4,20,28,36,44 10101010ef10 00003fffbb3b4940 13 + 9,10,11,12,14,15,5,21,29,37,45 20202020de20 00003ffffb9fc480
14 + 10,11,12,13,15,6,22,30,38,46 40404040bc40 00003ffffc2f3440
15 + 11,12,13,14,7,23,31,39,47 808080807880 00003ffffc345770
16 + 17,18,19,20,0,8,24,32,40,48 10101011e0101 000000fc0006fc40
17 + 16,18,19,20,21,1,9,25,33,41,49 20202023d0202 000000fc0006fc3c 18 + 16,17,19,20,21,22,2,10,26,34,42,50 40404047b0404 000000fc0007fb1e 19 + 16,17,18,20,21,22,23,3,11,27,35,43,51 8080808f70808 01fffffc00142d40 20 + 16,17,18,19,21,22,23,4,12,28,36,44,52 10101010ef1010 01fffffc003d8300 21 + 17,18,19,20,22,23,5,13,29,37,45,53 20202020de2020 000000fc001e0502 22 + 18,19,20,21,23,6,14,30,38,46,54 40404040bc4040 000000fc005959aa 23 + 19,20,21,22,7,15,31,39,47,55 80808080788080 000000fc007dbdd3 24 + 25,26,27,28,0,8,16,32,40,48,56 10101011e010101 007fffffee000804 25 + 24,26,27,28,29,1,9,17,33,41,49,57 20202023d020202 007ffffc13ffeeff 26 + 24,25,27,28,29,30,2,10,18,34,42,50,58 40404047b040404 007ffffc13ffee81 27 + 24,25,26,28,29,30,31,3,11,19,35,43,51,59 8080808f7080808 007ffff8f8000881 28 + 24,25,26,27,29,30,31,4,12,20,36,44,52,60 10101010ef101010 007ffffafe0005ff 29 + 25,26,27,28,30,31,5,13,21,37,45,53,61 20202020de202020 007ffffc14002c81 30 + 26,27,28,29,31,6,14,22,38,46,54,62 40404040bc404040 007ffffc14010507 31 + 27,28,29,30,7,15,23,39,47,55,63 8080808078808080 007ffffefdbfff43 32 + 33,34,35,36,0,8,16,24,40,48,56 101011e01010101 00fffff4b553fffc 33 + 32,34,35,36,37,1,9,17,25,41,49,57 202023d02020202 00fffff4b553fffe 34 + 32,33,35,36,37,38,2,10,18,26,42,50,58 404047b04040404 00fffff4b4500002 35 + 32,33,34,36,37,38,39,3,11,19,27,43,51,59 80808f708080808 00fffff3f553fffe 36 + 32,33,34,35,37,38,39,4,12,20,28,44,52,60 101010ef10101010 00fffff44c74000a 37 + 33,34,35,36,38,39,5,13,21,29,45,53,61 202020de20202020 00fffff4b5e3fffe 38 + 34,35,36,37,39,6,14,22,30,46,54,62 404040bc40404040 00fffff4b5e4ef72 39 + 35,36,37,38,7,15,23,31,47,55,63 8080807880808000 00fffff403010007 40 + 41,42,43,44,8,16,24,32,48,56 1011e0101010100 003fffffc6fb3cfe
41 + 40,42,43,44,45,9,17,25,33,49,57 2023d0202020200 003fffffe2e21e01 42 + 40,41,43,44,45,46,10,18,26,34,50,58 4047b0404040400 01ffffe300f30c01 43 + 40,41,42,44,45,46,47,11,19,27,35,51,59 808f70808080800 01ffffe300dd2201 44 + 40,41,42,43,45,46,47,12,20,28,36,52,60 1010ef1010101000 01ffffe301ae27f8 45 + 41,42,43,44,46,47,13,21,29,37,53,61 2020de2020202000 01ffffe301ae3b7c 46 + 42,43,44,45,47,14,22,30,38,54,62 4040bc4040404000 001ffffc9f733581 47 + 43,44,45,46,15,23,31,39,55,63 8080788080808000 003fffff1fde827f 48 + 49,50,51,52,16,24,32,40,56 11e010101010000 007fffff9a2346fa 49 + 48,50,51,52,53,17,25,33,41,57 23d020202020000 007fffff9a2346f4 50 + 48,49,51,52,53,54,18,26,34,42,58 47b040404040000 007fffff9a2346f0 51 + 48,49,50,52,53,54,55,19,27,35,43,59 8f7080808080000 007fffff9a234730 52 + 48,49,50,51,53,54,55,20,28,36,44,60 10ef101010100000 007fffff9a233618 53 + 49,50,51,52,54,55,21,29,37,45,61 20de202020200000 007fffff9a23477c 54 + 50,51,52,53,55,22,30,38,46,62 40bc404040400000 007fffff9a23477d 55 + 51,52,53,54,23,31,39,47,63 8078808080800000 007fffff9a23477f
56 + 57,58,59,60,24,32,40,48 1e01010101000000 007fffff9a23477f
57 + 56,58,59,60,61,25,33,41,49 3d02020202000000 007fffff9a23477e 58 + 56,57,59,60,61,62,26,34,42,50 7b04040404000000 007fffff9a23477f 59 + 56,57,58,60,61,62,63,27,35,43,51 f708080808000000 007fffff9a23477f 60 + 56,57,58,59,61,62,63,28,36,44,52 ef10101010000000 007fffff9a23477f 61 + 57,58,59,60,62,63,29,37,45,53 de20202020000000 007fffff9a23477f 62 + 58,59,60,61,63,30,38,46,54 bc40404040000000 007fffff9a23477f
63 + 59,60,61,62,31,39,47,55 7880808080000000 007fffff9a23477f
附錄 C Magic Number(二)
斜線方向的 Magic Numbers
位置 方向 連五範圍(位置) 連五範圍(hex) Magic Number(hex)
0 × 9,18,27,36 1008040200 00fffffff7ffc21f
1 × 10,19,28,37 2010080400 00fffffff7ffe20f
2 × 11,20,29,38 4020100800 00fffffff7fff207
3 × 12,21,30,39 8040201000 00fffffff7fffa03
4 × 11,18,25,32 102040800 00fffffff80fffff
5 × 12,19,26,33 204081000 00fffffff811fbff
6 × 13,20,27,34 408102000 00fffffff812f9ff
7 × 14,21,28,35 810204000 00fffffff81378ff
8 × 17,26,35,44 100804020000 00fffffff813ade5
9 × 0,18,27,36,45 201008040001 00fffffff8137820
10 × 1,19,28,37,46 402010080002 00fffffff8139820
11 × 2,20,29,38,47,4,18,25,32 804122140014 007fffff983f9028
12 × 3,21,30,39,5,19,26,33,40 18244280028 007fffff98f18800
13 × 6,20,27,34,41 20408100040 007fffff98f21a80
14 × 7,21,28,35,42 40810200080 007fffff98f21a80
15 × 22,29,36,43 81020400000 00ffffffffdfff81
16 × 25,34,43,52 10080402000000 01000000000117f4
17 × 8,26,35,44,53 20100804000100 007fffff98f21a80
18 × 0,9,27,36,45,54,4,11,25,32 4020110a000a11 001ffffc9f3d9ff0
19 × 1,10,28,37,46,55,5,12,26,33,40 80412214001422 001ffffc9f408ff0 20 × 2,11,29,38,47,6,13,27,34,41,48 1824428002844 000fffff258f6800 21 × 3,12,30,39,7,14,28,35,42,49 2048850005088 003ffff2f7a03ffe
22 × 15,29,36,43,50 4081020008000 007fffff98f21a09
23 × 30,37,44,51 8102040000000 010000000001194d
24 × 33,42,51,60 1008040200000000 010000000001197f
25 × 16,34,43,52,61,4,11,18,32 2010080500050810 007ffffc0731fbff 26 × 8,17,35,44,53,62,5,12,19,33,40 4020110a000a1120 007ffffc04d5ffe1 27 × 0,9,18,36,45,54,63,6,13,20,34,41,48 8041221400142240 001ffff5ffff0fff 28 × 1,10,19,37,46,55,7,14,21,35,42,49,56 182442800284482 007fffeffff84178 29 × 2,11,20,38,47,15,22,36,43,50,57 204885000508804 003ffff827ae7ec0
30 × 3,12,21,39,23,37,44,51,58 40810a000a01008 001ffffd302d8001
31 × 38,45,52,59 810204000000000 010000000001197f
32 × 4,11,18,25 2040810 00fffffffe03ffff
33 × 24,42,51,60,5,12,19,26,40 1008050005081020 007ffffc13e7fdfe 34 × 16,25,43,52,61,6,13,20,27,41,48 20110a000a112040 007ffffc13e586fc 35 × 8,17,26,44,53,62,7,14,21,28,42,49,56 4122140014224180 001ffffd27f51c7f 36 × 0,9,18,27,45,54,63,15,22,29,43,50,57 8244280028448200 001ffffd329d5181 37 × 1,10,19,28,46,55,23,30,44,51,58 488500050880402 001ffffd32ac6cfe
38 × 2,11,20,29,47,31,45,52,59 810a000a0100804 001ffffd31b7d790
39 × 3,12,21,30 40201008 00fffffffef087ff
40 × 12,19,26,33 204081000 00fffffffefc0bff
41 × 13,20,27,34,48 1000408102000 007fffff98f1bbf9 42 × 24,33,51,60,14,21,28,35,49,56 110a000a11204000 007ffffc1405696d 43 × 16,25,34,52,61,15,22,29,36,50,57 2214001422418000 007ffffc140581bf 44 × 8,17,26,35,53,62,23,30,37,51,58 4428002844820100 007ffffc140581bd 45 × 9,18,27,36,54,63,31,38,52,59 8850005088040200 007ffffc1237ffef
46 × 10,19,28,37,55 80002010080400 007ffffe5ed43e5f
47 × 11,20,29,38 4020100800 00fffffff7fff207
48 × 20,27,34,41 20408100000 00fffffff813ac97
49 × 21,28,35,42,56 100040810200000 007ffffe5ed448ff
50 × 22,29,36,43,57 200081020400000 007ffffe5ed448ff
51 × 24,33,42,60,23,30,37,44,58 1400142241800000 007fffff9a234764 52 × 16,25,34,43,61,31,38,45,59 2800284482010000 007fffff9a202fe1
53 × 17,26,35,44,62 4000100804020000 007ffffe5ed448ff
54 × 18,27,36,45,63 8000201008040000 007ffffe5ed448ff
55 × 19,28,37,46 402010080000 00fffffff813ae34
56 × 28,35,42,49 2040810000000 00fffffff813ae40
57 × 29,36,43,50 4081020000000 00fffffff813ae40
58 × 30,37,44,51 8102040000000 00fffffff813ae40
59 × 31,38,45,52 10204080000000 00fffffff813ae40
60 × 24,33,42,51 8040201000000 00fffffff813ae40
61 × 25,34,43,52 10080402000000 00fffffff813ae40
62 × 26,35,44,53 20100804000000 00fffffff813ae40
63 × 27,36,45,54 40201008000000 00fffffff813ae40