
Lista de comandos do programa Matheus (verso 2.3)
--------------------------------------------------
Note: Please find below an English version of this text.



Tela de jogo ('Game Menu'):
------------

Observao:

Para executar um commando nesta tela, basta digitar a letra inicial do
referido comando e pressionar 'enter'.
Exemplo: Tecle 'B' e pressione 'enter' para executar o comando 'Both sides'. 

Para executar uma jogada, basta digitar a coordenada da pea que se quer
mover e a coordenada da casa de destino, pressionando 'enter'.
As casas so representadas pelas coordenadas das linhas e colunas
do tabuleiro (a1...h8).
Exemplo: e2e4


	Os comandos disponveis nessa tela so os seguintes:

1)	B - Both sides
	Matheus ir jogar como Brancas e Pretas, automaticamente.
	Tecle 'B' a qualquer momento para desativar esta opo.

2)	C - Create Opening Book
	Esse comando ir criar os livros de abertura, em formato binrio, que
	sero utilizados pelo Matheus durante os jogos. Ser necessrio criar
	um livro de abertura para as Brancas e outro para as Pretas.
	O arquivo fonte dever estar no formato 'PGN'.
	O processo de criao de um livro  bastante simples e  composto por
	quatro passos:

		a) Definir o nome do arquivo fonte no formato 'PGN'.
		Exemplo: livro.pgn

		b) Definir a cor do livro a ser criado.
		Exemplo: w

		c) Definir o nmero mximo de jogadas a serem importadas de
		cada jogo do arquivo fonte. (de 0 a 512)
		Exemplo: 60

		d) Definir qual a ocorrncia mnima que cada jogada importada
		do arquivo fonte deve ter. (de 1 a 512)
		Exemplo: 1 
	
	No exemplo acima, Matheus ir compilar os dados contidos no arquivo
	fonte 'livro.pgn' e criar um arquivo em formato binrio chamado
	'matheus_white.book'.
	Cada abertura ter no mximo 60 jogadas.
	Todas as jogadas includas no arquivo binrio devero ter ocorrido
	pelo menos uma vez no arquivo fonte (PGN).
	Quando o processo de compilao terminar, ser mostrado na tela um
	relatrio com a	estatstica de criao do livro.
	Importante: Os livros de abertura em formato binrio devero estar
	no mesmo diretrio onde estiver 'Matheus.exe'.

3)	D - Depth of Search Setup
	Permite alterar a profundidade de pesquisa do programa.
	Essa varivel poder ser ajustada com valores entre 1 a 32 jogadas.

4)	F - Force
	Permite ao Usurio jogar como Brancas e Pretas. Matheus no ir
	processar qualquer jogada enquanto essa opo estiver ativada.
	Para desativa-la, basta teclar 'F' novamente.
	Veja o estado desta opo (on / off) na tela do jogo.

5)	H - Hashtable
	Permite ao Usurio ajustar o tamanho da tabela 'hash', em mega byte (MB).
	Os valores vlidos esto na faixa de 0 a 256 MB.
	O tamanho da tablela 'hash' tambm poder ser ajustado automaticamente
	atravs do arquivo de inicializao chamado 'matheus.ini'.
	Esse arquivo  auto-explicativo. Consulte-o para maiores detalhes.
	Caso Matheus no encontre o arquivo 'matheus.ini', a tabela 'hash'
	ser ajustada em 8 MB, por padro.

6)	I - Information
	Esse comando mostra algumas informaes sobre o Matheus assim como um
	resumo de todos os comandos do 'Game Menu', contidos nesse manual.

7)	L - Load
	Possibilita ao Usurio carregar uma posio no formato 'FEN'.

8)	M - Move now
	Fora o Matheus a jogar imediatamente, se ele estiver processando
	uma jogada. Caso contrrio, instrui o Matheus a iniciar imediatamente
	o processamento de uma jogada.

9)	N - New game
	Usado para iniciar um novo jogo. O Usurio sempre ter a vez de
	jogar como Brancas.

10)	P - Position Setup
	Possibilita ao Usurio ajustar qualquer posio vlida no tabuleiro.
	Quando essa opo  utilizada, o Usurio ter acesso a uma outra tela de
	opes chamada 'Setup Menu'. Para mais detalhes sobre esse comando,
	consulte 'Tela de ajuste de posies no tabuleiro' ('Setup Menu'),
	mais adiante.

11)	S - Show Book Moves
	Mostra as jogadas disponveis no livro de aberturas e a estatstica de
	ocorrncia de cada uma delas.

12)	T - Time setup
	Ajusta o tempo de processamento (em segundos) para o Matheus executar
	uma jogada. Valores negativos ajustaro esse tempo para infinito.
	Obs.: No modo console, Matheus suportar apenas o controle de tempo
	X segundos/jogada. Para outros controles de tempo, sugiro utilizar
	uma interface compatvel com 'Winboard'.

13)	U - Undo move
	Desfaz a ltima jogada executada no tabuleiro.

14)	Q - Quit
	Encerra a sesso do Matheus.



Tela de ajuste de posies no tabuleiro ('Setup Menu')
---------------------------------------

Observao:

Para inserir uma pea no tabuleiro, basta digitar o cdigo da pea e a
casa onde ela ficar. Os cdigos das peas so os seguintes:

P - Peo
N - cavalo
B - Bispo
R - Torre
Q - Rainha
K - Rei

As casas so representadas pelas coordenadas das linhas e colunas
do tabuleiro (a1...h8).

Exemplo: Pe4
Esse comando insere um peo, com a cor de quem tiver a vez de jogar,
na casa 'e4'.

Para remover uma pea do tabuleiro basta digitar '0' (zero) e a coordenada
da casa onde a pea que se quer remover estiver localizada.
Exemplo: 0d7
Esse comando ir remover a pea que estiver na casa 'd7'.


	Os comandos disponveis nessa tela so os seguintes:

1)	C - Change color to move
	Utilize essa opo para alterar a cor de quem tem a vez de jogar.
	As peas inseridas no tabuleiro, num dado momento, tero a mesma
	cor de quem tem a vez de jogar.

2)	E - Empty board
	Remove todas as peas do tabuleiro.

3)	H - Help
	Mostra algumas informaes sobre o Matheus e tambm um resumo dos
	comandos da tela de ajuste de posies no tabuleiro ('Setup Menu').

4)	I - Initial position
	Insere todas as peas do tabuleiro na posio inicial de jogo, com as
	Brancas tendo a vez de jogar.

5)	L - Load position
	Carrega uma posio, em formato 'FEN', de um arquivo.

6)	T - Turn Matheus color
	Utilize essa opo para ajustar a cor com a qual o Matheus ir jogar.

7)	X - Exit setup
	Sai do 'Setup Menu' ajustando a posio do tabuleiro de acordo com as
	instrues do Usurio.
	Caso a posio seja invlida, Matheus ir emitir uma mensagem de erro. 


********************************************************************************


Matheus chess engine (version 2.3) - listing of commands
--------------------------------------------------------


Game Menu
---------

To run a command, you need to type the first command letter and press 'enter'. 
Example: Type 'B' and press 'enter' to run 'Both sides' command.

To make a move, you need to type the 'from' square coordenates, where the piece
you want to move is located, and the 'to' square coordenates. Then you press 'enter'.
All board squares are represented by their files and ranks coordenates (a1...h8).
Example: e2e4


	Game Commands:

1)	B - Both sides
	Force Matheus to play both sides (White and Black).
	To turn this option off just press 'B' again at any time.


2)	C - Create Opening Book
	This command will create an opening book, in binary format, that will
	be used by Matheus in the games. You should create one book for White and
	another one for Black. The source file must be in 'PGN' format.
	Creating an opening book for Matheus is very simple. There are four steps
	to follow. 

		a) Enter PGN file name.    (file.pgn)  Example: book.pgn
		b) Enter book color.       ( w / b  )  Example: w
		c) Enter maximum ply.      (0 to 512)  Exanple: 60
		d) Enter minimum played.   (1 to 512)  Exanple: 1

	In the example above, Matheus will compile the data from 'book.pgn' and
	will create a file, in binary format, called 'matheus_white.book'.
	Each opening line in this file will have 60 plies, at maximum.
	All the moves included in the binary file will have, at least, a frequency
	of one ocurrence.
	When the book compilation process finish, Matheus will show a report with
	the book creation statistic.
	Important: Binary opening book files must be in the same directory where
	'Matheus.exe' is located.

3)	D - Depth of Search Setup
	You can modify Matheus search depth using this command.
	Valid values: from 1 to 32 plies.

4)	F - Force
	With 'F' command, User can play both sides (White/Black).
	Matheus will not play any move while force is on.
	To disable force, you need to press 'F' again.
	See force status on the Game Menu.

5)	H - Hashtable
	This command sets hashtable size in mega bytes (MB).
	Valid values: from 0 to 256 MB.
	You can also set hashtable size using 'matheus.ini' file.
	You will find all information you need about Matheus ini file in
	'matheus.ini'. 
	If Matheus did not find 'matheus.ini', it will allocate 8 MB for
	hastable, as default.

6)	I - Information
	This command will show some information about Matheus as well as a
	summary of all 'Game Menu" commands.

7)	L - Load
	Load a 'fen' position from a file.

8)	M - Move now
	Force Matheus to play immediatly if it is 'thinking'.
	Otherwise force Matheus to play on opponent's turn to move.

9)	N - New game
	Set a new game with White to move.

10)	P - Position Setup
	This option makes possible to the User making a special position setup.
	When this command is invoked, Matheus will show the 'Setup Menu'.
	For more details about this command, please see 'Setup Menu'
	informations, below.

11)	S - Show Book Moves
	Show all available book moves and a frequency report.

12)	T - Time setup
	Set time control (in seconds). Negative values will set time to infinite.
	In console mode, only X seconds/move is supported.
	For different time controls, is necessary to run Matheus under a GUI.

13)	U - Undo move
	Unmake the last performed move on the board.

14)	Q - Quit
	Quit Matheus.



	Setup Menu:
	----------

To insert a piece on the board, you just need to type the piece code
and the square coordenates where the piece will stay.
These are the piece codes:

P - Pawn
N - Knight
B - Bishop
R - Rook
Q - Queen
K - King

Squares are represented by their coordenates (files and ranks) in the
chess board (a1...h8).
Example: Pe4
This command will insert a pawn, with a color that is to move,
on 'e4' square.

To remove a piece from the board, you just need to type '0' (zero) and
the square coordenates where the piece is located.
Example: 0d7
This command will remove a piece from 'd7' square.


	Setup commands:

1)	C - Change color to move
	This command will change the color that is to move.
	When you insert a piece on the board, its color will be that one.

2)	E - Empty board
	Remove all pieces from the board.

3)	H - Help
	This command will show some informations about Matheus as well as a
	summary of all 'Setup Menu" commands.

4)	I - Initial position
	Set initial board position with White to move.

5)	L - Load position
	Load a 'fen' position from a file (file_name.fen).

6)	T - Turn Matheus color
	This command will set Matheus color.

7)	X - Exit setup
	Set current board position and exit setup.
	If the board position is illegal, Matheus will show a warning
	message and will not exit 'Setup Menu'.