[eb2794]: mainpage.txt  Maximize  Restore  History

Download this file

75 lines (74 with data), 4.9 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
/**
* \mainpage Qubist Project
* This is documentation of the Qubist project, comprising the libqubist library of functions, and the qubist-gtk2
* program to play the game.
*
* <h2>About the Game</h2>
* The project focuses on the 3-dimensional version of the game Tic-Tac-Toe (as it is known in the USA). This game
* is also known by other names in other places. One of these is naughts-and-crosses. There may be others.
*
* The Parker Brothers company sold a version of this game by the name Qubic around 1965. It consisted of 4
* transparent playing surfaces stacked one above another with spacing rods that created enough space for players
* to place markers on the surfaces. Each surface was ruled into a 4x4 grid of playing cells, so the 4 surfaces
* together contained 64 playing cells. Around that time, there was a program for the IBM 1620 to play the game.
* One of our authors (O'Gorman) encountered it then and wanted to know how a computer could do that; now he knows.
*
* Around the time of Microsoft Windows 98, Microsoft released Windows Entertainment Pack #1 (was there ever a #2?)
* which contained TIC.EXE, which named itself TicTactics on the title bar, and which had the same rules as Qubic
* and that game on the IBM 1620.
*
* With best play, it is known that the first player should win. In the 1970's, Oren Patashnik discovered a
* complete strategy for the first player to accomplish this, and published his result in Mathematics Magazine.
* In 2002, he gave us a text file containing his solution, and we made it available on Google Drive.
* Place it in your working directory and start this program and Qubist will use the data in this file when it's
* in Expert mode. You can't beat that. Literally.
*
* Since the game is essentially 3-dimensional, it's a bit awkward to call it a board. Instead we'll call it a qube,
* or even "the Qube."
*
* This document is 2-dimensional and text-based (limited use of pictures), so we will make do with this sort
* of representation:
* <pre>
* xo-x ---- ---- x---
* ---- ---- ---- ----
* ---- --o- o--- ----
* ---- -o-- ---- x---
* </pre>
* Here we have a game position with 4 plays already made by each player. It represents the position with the
* playing surfaces side-by-side, so the leftmost 4 characters of the 4 lines depict a single surface, and so
* on for each of the 4 groups. Each group can also be thought of as a section
* of the qube formed by slicing it with a plane. There are other ways to slice the cube to form a 4x4 plane,
* including some diagonal slices. There are 18 such possible slices in all, and the game displays them all
* in its "planes view". We refer to the 4x4 set of
* playing cells formed by such a slice as a "plane", although that will probably make you cringe if you're
* mathematically inclined.
*
* Players have markers of two kinds, represented here by x and o. Each
* player uses just one of the kinds. The game begins on an empty board, and players take turns placing one
* marker on an empty cell. Markers are never moved once placed.
*
* To win, a player must have 4 markers in a straight line in any direction: across, down, diagonal, or through
* the surfaces. Such a winning line will either be entirely on one surface, or will have one marker on each
* of the surfaces. The winning line can even be through opposite corners, in what is called the major diagonal.
* There are 72 different lines on which the game can be won. These are examples of winning lines for the X player:
* <pre>
* ---- ---- ---- ---- ---- x--- ---- ---- --x- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- x---
* xxxx ---- ---- ---- ---- -x-- ---- ---- ---- --x- ---- ---- ---- ---- ---- ---- ---- ---- -x-- ----
* ---- ---- ---- ---- ---- --x- ---- ---- ---- ---- --x- ---- --x- --x- --x- --x- ---- --x- ---- ----
* ---- ---- ---- ---- ---- ---x ---- ---- ---- ---- ---- --x- ---- ---- ---- ---- ---x ---- ---- ----</pre>
*
* <h2>About the Project</h2>
* There project comprises three parts:
* <ul>
* <li><p><strong>Qubist Game Library <tt>libqubist</tt>.</strong> The <tt>libqubist</tt> library includes code to do all the necessary computations to play the
* game.
* The Qubist library does not contain any human-interface code, so that it can be used to create other programs to play
* the game that may use completely different interfaces. Hopefully, there will soon be a text-gased version of the game, and
* perhaps one that runs on Windows.
</p></li>
* <li><p><strong>GUI Game Program <tt>qubist-gtk2</tt>.</strong> The human interface code to use the GTK+ graphical library and the Qubist library to form a program to play Qubic.</p></li>
* <li><p><strong>Documentation</strong>. You are reading some of it now.</p></li>
* </ul>
*
*
*/

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks