


gnuchess(6)              GAMES AND DEMOS              gnuchess(6)



NAME
     gnuchess - Chess

SYNOPSIS
     gnuchess [ [[-]a] [-b bookfile] [-B binbookfile] [[-]h ] [-L
     language]  [-r  length] [-s pathname] [-l pathname] [-S bin-
     booksize] [-t] [-c size] [-T size] [-v] [-x] arg1 arg2 ]

DESCRIPTION
     _G_n_u_c_h_e_s_s plays a game of chess against the user or it  plays
     against itself.

     _G_n_u_c_h_e_s_s is an updated version of the GNU chess playing pro-
     gram.   It  has a simple alpha-numeric board display, an IBM
     PC compatible interface, or it can be compiled for use  with
     the  chesstool  program  on  a  SUN  workstation or with the
     xboard program under X-windows.  To invoke the program type:

     gnuchess
          - simple curses based version

     gnuchessn
          - fancy version using curses and inverse video on UNIX,
          or IBM PC cursor controls and characters on MSDOS

     gnuchessr
          - ASCII based version

     gnuchessc
          - chesstool compatible version

     gnuchessx
          - xboard compatible version

TIME CONTROLS
     If one argument is given, it is the search time per move  in
     [minutes:]seconds.   So  gnuchess  30 will generate one move
     every 30 seconds, while gnuchess 5:00 will generate one move
     every 5 minutes.

     If two or more arguments are given, they will be used to set
     tournament  time  controls  with  the first argument of each
     pair being the number of moves  and  the  second  being  the
     total  clock time in minutes[:seconds].  Thus, entering gnu-
     chess 60 5 will set the clocks for 5 minutes  (300  seconds)
     for  the  first  60 moves, and gnuchess 30 3:30 will allow 3
     minutes and 30 seconds for 30 moves.

     gnuchess 30 5 1 :30 will allow 5 minutes for  the  first  30
     moves  and  30  seconds  for  each move after that.  Up to 4
     pairs of controls may be specified.




Sun Release 4.1           Last change:                          1






gnuchess(6)              GAMES AND DEMOS              gnuchess(6)



     If no argument is given the program will prompt the user for
     level of play.

     For use with chesstool or xboard, see the  documentation  on
     those programs.

BOOK
     At startup _G_n_u_c_h_e_s_s reads the _b_i_n_b_o_o_k file if it is present.
     It  then looks for a _b_o_o_k file. If it is present it adds its
     contents to the _b_i_n_b_o_o_k data. If the _b_i_n_b_o_o_k file  is  writ-
     able a new combined _b_i_n_b_o_o_k file is written.

     The book _g_n_u_c_h_e_s_s._b_o_o_k consists of a sequence  of  openings.
     An  opening  begins with a line starting with a ! , the rest
     of the line is comments.  Following  this  is  a  series  of
     moves  in  algebraic  notation  alternating  white and black
     separated by white space. A move may have a ? after it indi-
     cating  this  move  should  never  be made in this position.
     Moves are stored as position:move so transpositions  between
     openings can take place.

HASHFILE
     The hashfile if created should be on the order  of  4  mega-
     bytes  or  gnuchess  -c 22. This file contains positions and
     moves learned from previous games. If a hashfile is used the
     computer  makes  use  of  the  experience  it gained in past
     games. Tests run so far show that it plays no worse with the
     hashfile  than  without,  but it is not clear yet whether it
     provides a real advantage.

LEGAL MOVES
     Note: Piece letters and legal castling  notation  is  deter-
     mined  by  the language file.  What is specified here is the
     default English.

     Once _g_n_u_c_h_e_s_s is invoked, the program will display the board
     and  prompt  the  user  for a move. To enter a move, use the
     notation e2e4 where the first letter-number  pair  indicates
     the  origination  square  and  the second letter-number pair
     indicates the destination square.  An alternative is to  use
     the  notation nf3 where the first letter indicates the piece
     type (p,n,b,r,q,k).  To castle, type the origin and destina-
     tion  squares of the king just as you would do for a regular
     move, or type o-o or 0-0 for kingside castling and o-o-o  or
     0-0-0  for  queenside.  To promote a pawn append the type of
     the new piece to the move, as in e7e8q or c7c8r.

FUNCTION LETTERS
     -L lang
          Use language _l_a_n_g _f_r_o_m _t_h_e _f_i_l_e gnuchess.lang. If -L is
          not  specified  it defaults to the language used in the
          first line in the file. gnuchessr -L ger will  use  the



Sun Release 4.1           Last change:                          2






gnuchess(6)              GAMES AND DEMOS              gnuchess(6)



          german language.

     -a   Do not search on opponents time.

     a    Do search on opponents time.

     -b bookfile
          Use bookfile for opening book.

     -B binbookfile
          Use binbookfile for binary opening book.

     -S size
          Size of binbookfile for memory based and GDX books. For
          creating a binbookfile.

     -P plylevels
          Number of plys to include in the binbookfile. For  gen-
          erating a binbookfile.

     -c size
          Create a new HASHFILE. File size is 2^size  entries  of
          approximately 65 bytes.

     -h   Do not use hashfile.

     h    Do use hashfile.

     -l pathname
          Pathname of the loadfile use with the get or xget.

     -r length
          Rehash length times in searching  entries for  position
          in transposition table.

     -s pathname
          Pathname of the save file to use with the save command.

     -t   Show statistics for HASHFILE

     -T size
          Set the  transposition  table  size  to  size  entries.
          (minimum is MINTTABLE)

     -v   Show version and patchlevel.

     -x value
          Use value as the evaluation window xwndw.

COMMANDS
     In addition to  legal  moves,  the  following  commands  are
     available  as responses.  Note: command names are determined



Sun Release 4.1           Last change:                          3






gnuchess(6)              GAMES AND DEMOS              gnuchess(6)



     by the _l_a_n_g_u_a_g_e file and may vary with  the  implementation.
     This is default English.

     alg -- allow algebraic input (not implemented)

     Awindow -- change Alpha window (default score + 90)

     Bwindow -- change Beta window (default score - 90)

     beep -- causes the program to beep after each move.

     bd -- updates the current board position on the display.

     book -- turns off use of the opening library.

     both -- causes the computer to play both sides  of  a  chess
     game.

     black -- causes the computer to take the black  pieces.   If
     the computer is to move first the go command must be given.

     coords -- show coordinates on the display (visual only)

     contempt -- allows the value of _c_o_n_t_e_m_p_t to be modified.

     debug --  asks for a piece as color piece, as wb or bn,  and
     shows its calculated value on each square.

     debuglevel --  sets level of debugging  output  if  compiled
     with debug options.

     depth -- allows the user to change the search depth  of  the
     program.   The  maximum depth is 29 ply.  Normally the depth
     is set to 29 and the computer terminates its search based on
     elapsed  time rather than depth.  If depth is set to (say) 4
     ply, the program will search until all moves have been exam-
     ined  to  a  depth  of 4 ply (with extensions up to 11 addi-
     tional ply for sequences of checks and captures). If you set
     a  maximum time per move and also use the depth command, the
     search will stop at the  specified  time  or  the  specified
     depth, whichever comes first.

     easy -- toggles easy mode (thinking on  opponents  time)  on
     and  off. The default is easy mode ON.  If easy mode is dis-
     abled, the keyboard is polled for input every so  often  and
     when  input is seen the search is terminated. It may also be
     terminated with a _s_i_g_i_n_t.

     edit -- allows the user to set up a board position.

          # - command will clear the board.




Sun Release 4.1           Last change:                          4






gnuchess(6)              GAMES AND DEMOS              gnuchess(6)



          c - toggle piece color.

          . - command will exit setup mode.

        pb3 - place a pawn on b3

     Pieces are entered by typing a letter (p,n,b,r,q,k) for  the
     piece followed by the coordinate.

     The usual warning about the _l_a_n_g_u_a_g_e _f_i_l_e applies.

     exit -- exits gnuchess.

     first -- tells the computer to move first.  Computer  begins
     searching for a move.  (same as "go").

     force -- allows the user to enter moves for both  sides.  To
     get  the  program to play after a sequence of moves has been
     entered use the 'white' or 'black' command followed by 'go'.

     gamein -- toggles game mode time control. Assumes  the  time
     specified  for time control is the time for a complete game.
     Input with the level command should be the game time and the
     expected number of moves in a game.

     get -- retrieves a game from disk.  The program will  prompt
     the user for a file name.

     hash -- use/don't use hashfile.

     hashdepth -- allows the user to change the minimum depth for
     using the hashfile and the number of moves from the begining
     of the game to use it.

     help -- displays a short description of the commands and the
     current status of options.

     go -- tells the computer  to  move  first.  Computer  begins
     searching for a move.  (same as "first").

     hint -- causes the program  to  supply  the  user  with  its
     predicted move.

     level -- allows the user to set time  controls  such  as  60
     moves  in  5  minutes  etc.  In tournament mode, the program
     will vary the time it takes for each move depending  on  the
     situation.   If easy mode is disabled (using the 'easy' com-
     mand), the program will often respond with its move  immedi-
     ately, saving time on its clock for use later on.

     list -- writes the game moves and some statistics on  search
     depth, nodes, and time to the file 'chess.lst'.



Sun Release 4.1           Last change:                          5






gnuchess(6)              GAMES AND DEMOS              gnuchess(6)



     material -- toggle material flag - draws  on  no  pawns  and
     both sides < rook

     Mwpawn, Mbpawn, Mwknight, Mbknight,  Mwbishop,  Mbbishop  --
     print out static position evaluation table

     new -- starts a new game.

     p -- evaluates the board and shows the point score for  each
     piece.  The  total  score for a position is the sum of these
     individual piece scores.

     post -- causes the program to display the  principle  varia-
     tion  and  the  score  during the search.  A score of 100 is
     equivalent to a 1 pawn advantage for the computer.

     quit -- exits the game.

     random -- causes the program to randomize its move selection
     slightly.

     rcptr -- set recapture mode.

     remove -- backout the last level for both sides. Equal to  2
     _u_n_d_o'_s.

     reverse -- causes the board display to  be  reversed.   That
     is,  the  white  pieces  will  now  appear at the top of the
     board.

     rv -- reverse board display.

     setup -- Compatibility with Unix chess and  the  nchesstool.
     Set  up  a  board position.  Eight lines of eight characters
     are used to setup the board. a8-h8 is the first line.  Black
     pieces are  represented  by  uppercase characters.

     stars -- (gnuchessn only) add stars (*) to black pieces.

     save -- saves a game to disk.  The program will  prompt  the
     user for a file name.

     switch -- causes the  program  to  switch  places  with  the
     opponent and begin searching.

     test -- performs some speed tests for MoveList and CaptureL-
     ist  generation,  and ScorePosition position scoring for the
     current board.

     time otim -- time set computers time remaining, intended for
     synchronizing  clocks  among  multiple players.  -- otim set
     opponents time remaining, intended for synchronizing  clocks



Sun Release 4.1           Last change:                          6






gnuchess(6)              GAMES AND DEMOS              gnuchess(6)



     among multiple players.

     undo -- undoes the last move whether it was  the  computer's
     or  the  human's.  You  may  also  type  "remove".  This  is
     equivalent to two "undo's" (e.g. retract one move  for  each
     side).

     white -- causes the computer to take the white  pieces.   If
     the computer is to move first the go command must be given.

     xget -- read an _x_b_o_a_r_d position file.

     xwndw -- change X window. The window around alpha/beta  used
     to  determine  whether the position should be scored or just
     estimated.

BUGS
SEE ALSO
     chesstool(6)
     xboard(6)



































Sun Release 4.1           Last change:                          7



