QGame++ is based on QGAME, which was developed in Common Lisp by Lee Spector (email@example.com). The QGAME homepage can be found at http://hampshire.edu/lspector/qgame.html . For performance reasons, a C++ version of QGAME seemed to be useful, which is why QGame++ was developed. Both QGAME and QGame++ were developed for use in conjunction with a genetic programming system, to allow for the evolution of new quantum algorithms, but can be useful for testing quantum algorithms regardless of their origin.
QGame++ is based on the "quantum gate array" model of quantum computation, in which quantum "gates" (represented as square matrices) are applied to a register of qubits (via tensor product formation and matrix multiplication). QGame++ always starts with all qubits having the value zero (in the state |00...0>), applies a sequence of gates, and returns values about the resulting state. Measurement gates cause the system to branch, following one execution path (with the appropriate quantum state collapse) for each possible value. Final measurements are made across the end-states of all of the resulting branches.
Most interesting quantum algorithms involve calling an "oracle" or "black box" function of which one is trying to determine some property. QGame++ supports only boolean oracles (that is, with single qubit output), but it allows the user to specify any such oracle and to indicate the desired system output for each specified oracle. Oracles are implemented in the standard way, by applying a (unitary) quantum "NOT" gate on the output qubit wherever the oracle's truth table indicates a "1".
More extensive documentation concerning quantum programs and the quantum gate array model, as well as general information concerning the QGAME system and its uses in genetic programming can be found in Lee Spector's soon-to-appear book:
Spector, Lee. (2004). Automatic Quantum Computer Programming: A Genetic Programming Approach. Kluwer Academic Publishers.
qgame parses text files containing QGAME programs in the syntax defined by Lee Spector as described in the QGAME Language Description, or in the book on automatic quantum programming cited above. Use 'qgame --help' or 'man qgame' for acceptable command line options.
You might also want to look in the qgame code to see how libqgame++ is used, which should help you getting started with your own libqgame++ project. Note that the focus of this project has been to provide a robust libqgame++ library that can be used in client applications, not to provide a polished command-line interface. The qgame command-line interface provided here serves as a simple demonstration of the use of the libqgame++ library, and may also be useful as-is, but it is fairly simple and has not been extensively documented.
Installation instructions can be found in INSTALL. If you are familiar with the standard autoconf/automake style of configuration and installation, you probably won't need to look there at all and can just go ahead using './configure', 'make' and 'make install' as usual. This will install libqgame++, its header files, the command line client and a man page for qgame in the standard locations on your system.
If you find any bugs or problems in this program, or if you want to discuss new features or modifications to existing features, feel free to send a message to firstname.lastname@example.org. I would also like to hear from you if you successfully use QGame++ in a project. In general, any comment is welcomed.
The QGame++ system is licensed under the GPL, and you can find the licensing conditions implied by the GPL in the file COPYING supplied with the source code. There is no warranty; not even for merchantibility or fitness for a particular purpose.
This work was also funded by Lee, who therefore helped me survive in a foreign country ;-), and gave me the opportunity to be involved in research in the U.S., in spite of the numerous difficulties arising from my status as an exchange student. Many thanks for that.
-- Manuel Nickschas <email@example.com>