================================
Rival for Windows version 1.8.28
================================
May 2001

http://www.redhotpawn.com/rival

--------------------------------------------
Updates in version 1.8.28
----------------------------------------=---
Added "Invert Board" option.

--------------------------------------------
Updates in version 1.8.272 - April 24th 2001
----------------------------------------=---
Stopped bishops moving horizontally. Ahem.

-------------------------------------------
Updates in version 1.8.272 - April 2nd 2001
-------------------------------------------
Playing strength much improved by use of Fail-High Reductions in place of Null-Move.
Corrected bug which made the Kinglet variation practically unplayable.
Corrected bug which caused Black Elephant moves in Shatranj to be shown incorrectly in Algebraic notation.

------------------------------------------
Updates in version 1.8.26 - March 9th 2001
------------------------------------------
- Queen was suffering from same problem as the bishop prior to version 1.8.2
- Corrected the Queen and Bishop problem for Kinglet and Self-take variations
- Null move is now on by default

------------------------------------------
Updates in version 1.8.22 - March 6th 2001
------------------------------------------
- When entering a position as a FEN, Rival did not correctly read the en passant
element.

--------------------------------------
Updates in version 1.8.21 - March 2001
--------------------------------------
For some reason, 1.8.2 didn't work with Winboard - very strange.
Backed up to 1.8.17 and re-added changes... now it works.  Some odd
compiler option switched on somewhere I guess.

-------------------------------------
Updates in version 1.8.2 - March 2001
-------------------------------------
Corrected a bug that allowed a user to move a bishop to an illegal square in
certain situations.
Moved Help file to an HTML file which is included on the program group along with the
Rival executable.
Changed all references to my old email and web addresses - they now should now all point
to redhotpawn.com
About box changed

-------------------------
Updates in version 1.8.09
-------------------------
Added the test suite functionality.  Rival will read a text file of FEN positions that also
includes information about the maximum depth, time, minimum score and best move.
Two example test suite files are included, valentin.txt and valentin2.txt which contain
the first 10 test positions from Valentin Albillo's web site.

-------------------------
Updates in version 1.8.07
-------------------------
Now stops looking in opening book after it fails to find a position for the first time 
in a game.  This saves a few hundreths of second which may be useful in fixed time games.
Added an option that allows the specification of the number of pieces (not pawns) that must
remain for the side to move in order for the null move to be used in the full-width search.
If the value is set at "x", then the null move will be used when the number of pieces
for the side to move is "x+1".  If "x" is -1 then the null move will always be used.
Another two search variables are HashReadReduce and HashWriteReduce.  These specify the
number of ply prior to the leaf nodes at which to stop reading and writing to the hash
table respectively.
The final search variable added in used to switch the usage of killer moves on and off.
The printing of the principal variation to a log file has been improved so that it
prints every change in the PV throughout the search rather than its previous implementation
of monitoring every 500 milliseconds.

-------------------------
Updates in version 1.8.08
-------------------------
Added the help file.
You can now resign and offer draws.
Fixed a problem where the results were not always getting written correctly when 
saving PGN files.

-------------------------
Updates in version 1.8.06
-------------------------
Now flags when a side runs out of time.

-------------------------
Updates in version 1.8.05
-------------------------
New menu option to save positions in FEN format.
Added several new advanced computer play options.
Removed command line options for log files.  These are now specified in the newrival.opt
file either manually or via the GUI.
Found an enormous bug with passed pawn evaluation which caused positions such as
8/k7/3p4/p2P1p2/P2P1P2/8/8/K7 w - - 0 1 
to be evaluated very incorrectly.  Basically, blocked pawns where being evaluated
as passed pawns.  In the position here, this caused huge problems!!!

-------------------------
Updates in version 1.8.04
-------------------------
Can now use multiple PGN files to create the opening book.
Can save games in PGN format.  This can either be by creating a new file or by appending
to an existing file.

-------------------------
Updates in version 1.8.03
-------------------------
Added an application icon.

-------------------------
Updates in version 1.8.02
-------------------------
Added a new chess set.

-------------------------
Updates in version 1.8.01
-------------------------
Rival underpromoted in an engine v engine game but did not tell Winboard of the 
underpromotion so it was assumed to be a queen.  The underpromotion to a knight (in
to prolong an inevitable loss) put the opponent's king in check but the opponent moved
as if the promotion was a king.  I have fixed this now so that Winboard gets all the
promotion information!
Rival will now reject illegal moves from Winboard.  Games were lost where an illegal move
simply was ignored by Rival and it was left waiting.  I'm not sure what to do about the
situation where Rival has made a legal move and had it rejected by the other engine!

I'm gradually building up a number of PGN opening databases.  For now, however, the opening
book has been built from the eco.pgn file which is included with Rival.  It contains
2024 ECO lines.  This file was downloaded from ftp://caissa.onenet.net.

Rival can now modify its opening book based on the result of the games it plays.  Three 
new computer play options can be set.  These are

White & Black Opening Position Percentages
------------------------------------------
These are similar to the parameters used when creating the opening book except that these
are used during play rather than during creation.  Opening moves are only used if they
lead to positions that have the minimum percentage of wins for the relevant side.

Minimum Opening Results
-----------------------
This specifies the minumum number of results that an opening position must have recorded
against it before applying the white and black percentages.  This allows positions that
have only a few, or no, results recorded against them to be considered by Rival until they
meet the minumum threshold set by this value.  The default opening book provided with Rival
is created from a PGN file that contains no game results, it is created purely from 
a list of the A, B and C ECO openings.

The options file is now plain text and can be editted manually.

-------------------------
Updates in version 1.7.73
-------------------------
I just noticed that the version numbers were sent a bit wild on 1.7.71!
Have changed the opening book creator.  It now includes both white and black percentage
thresholds.  If the white win percentage, is 40, for example, then black positions will only
be stored in the opening book if white has won at least 40 percent of the games that
reached that position.  It also includes an option to write errors to a log file or to
report and abort if an error occurs.  Errors would be when an illegal move is encountered in
a PGN file.  When the log option is set, any illegal moves are ignored and all future moves
in the game being are also ignored.

-------------------------
Updates in version 1.7.71
-------------------------
New opening book and the ability to create a new opening book from the interface using
a PGN file.  The book is a text file that is a list of FEN positions followed by the number
of white wins, black wins, and draws.  The parameters that can be adjusted are:

Maximum ply
-----------
This is the maximum number of half moves that will be considered in each game.

Maximum number of positions
---------------------------
This is the maximum number of unique positions that can be stored during the creation
of the book.  Once this figure is reached, the creation of the book is terminated even
if, using the filters discussed below, the number of positions stored in the book is
fewer than this figure.

Minimum results per position
----------------------------
Only positions that occur at least this many times will be stored in the book.

Win percentage
--------------
For each position, this is the minimum percentage of games that the player not on the
move has won from the position.  For example, if, in a given position, white has won 6 games,
black has won 3 games and 3 games have been drawn, and it is white to move then the win
percentage for this position is 25%.  Black has won 25% of all games where a move was made
that lead to this position.

Include unknown results
-----------------------
This will allow games to be used even if the result is unknown.

Count games before generating
-----------------------------
This simply counts the number of games in the PGN file prior to creating the book.

-------------------------
Updates in version 1.7.61
-------------------------
Improved king safety evaluation.  This is based largely on a number of pawn and piece 
patterns that occur around the king.  Improved passed pawn evaluation which includes the
rule of the square.  Added knowledge of the "opposition" in pawn endings.

-------------------------
Updates in version 1.7.54
-------------------------
Castling notation wasn't being written correctly!

-------------------------
Updates in version 1.7.53
-------------------------
Moves are now written in algebraic notation.
Rival now accepts PGN files from the command line.

-------------------------
Updates in version 1.7.51
-------------------------
Reads PGN files.  If multiple games exist in a PGN file, only the first one is considered.
I think the PGN standard is fairly well covered.  I used a lot of code from Crafty for this.
The file trythis.pgn is quite a good tester.  I also used the anno.pgn file from Dann Corbitt's
ftp site which is crammed full with annotations.
I removed the null-move code so this menu option now has no effect.

-------------------------
Updates in version 1.7.04
-------------------------
Much needed King Safety evaluation added.  This is basically just pattern matching
against pawn structures and the location of knights and bishops near the king.  Where
no pattern is matched, a count is made of friendly pieces near the king.  All this only
happens if the king is castled and on the first two ranks, otherwise no scoring is
given.  This still needs big improvement but it's a start.

The advanced computer options dialog box now allows the selection of whether or not
the search routing uses the null-move.  I am still not comfortably convinved of how
effective Rival's null-move code is.

The setup dialog box now selects the FEN text when it opens so that clipboard positions
can be entered more easily.

-------------------------
Updates in version 1.7.02
-------------------------
The moves are now printed in the analysis box from left to right then top to bottom.
The hash table now attempts to use all the requested hash memory, for example

Requested Hash Size: 8192000
Hash Power: 20 2^20=1048576 (*13)=13631488
Number of Hash Entries: 630153
Hash Size: 630153*13=8191989

-------------------------
Updates in version 1.7.01
-------------------------
The size of the hash table can now be specified.  This can be done on the Advanced Computer
Options dialog, or via the command line.  On the command line enter the size of the hash table
in Kilobytes.  Any number on the command line is assumed to be the hash size.  
For example "newrival.exe -winboard 8000" or "newrival.exe 8000".  You must have enough
memory otherwise the program will exit.  The amount of memory assigned to the hash table will
not exceed the number of kilobytes specified but also may not use all of the requested memory.
The number of entries in the hash table will be a power of 2.  Each entry is 13 bytes.  So, for
an 8000K hash table, the size will be just under 5 megabytes as shown below.

Requested Hash Size: 8192000
Hash Power: 19
Max Hash Entry: 524288
Hash Size: 4718596

-------------------------
Updates in version 1.6.61
-------------------------
Improved all the dialog boxes.  I couldn't get the Borland C++ 4.52 resource editor 
to do what I needed previously so I've had to use a different resource editor.
Added Exit option to File menu.
Added Help Contents option although it doesn't do much in this version.

------------------------
Updates in version 1.6.4
------------------------
Passing upper and lower bounds to evaluate function to determine if it can exit before
wasting time calculating a score that will never be used.
Extensions within full-width search now include pawns close to promotion and positions where
there is only one move.  Previously extensions were only added when the side to move was in
check.

------------------------
Updates in version 1.6.3
------------------------
Solve for mate option.
Under-promotion.
Null-move in full-width search.
Reduced evaluation knowledge, improved search speed.

------------------------
Updates in version 1.6.1
------------------------
You may now enter positions in FEN format.  Also, the same menu option can be used to export
positions.
The variants menu is new.    
An infinite time control has been added.
After a position has been set up, the clocks will reset to the initial time according to the
time control.  Also, the clocks do not change during setup.
The options now save to the working directory rather than to the current directory.

--------------------------
Updates in version 1.6.004
--------------------------
Only the principal path, not the current search path is not shown now when the computer is 
searching.  Showing the current search path was rather useless.
A great deal of the code has been overhauled to remove some redundancies and to tidy a few
things up.
The graphics used for the numbers and letters that are used for the moves and nodes have
been made much easier to look at.

------------------------------
Updates in version 1.6.001.dev
------------------------------
Valentin Albillo suggested that I add a chess variant to Rival that allows a player to
take their own pieces (to escape a cramped position, for example).  All the other rules apply
and castling is as in regular chess.  I have added this variant to Rival which has allowed
me to promote the program to version 1.6.  Rival also plays the Kinglet and Shatranj variants.
In Kinglet, the loser is the first player to have no pawns on the board.  In Shatranj, the
main differences are the moves of the bishop (elephant), the queen (general) and the pawns.  
The elephant moves exactly two squares diagonally and may jump other pieces.  The general 
moves one square diagonally.  Pawns may not move two squares on their first move.  Rival
1.6.001.dev can be downloaded below (the .dev shows that I have not given it a decent testing

--------------------------
Updates in version 1.5.064
--------------------------
When running under Winboard, the main Rival window is now minimised.  This was implemented
in a previous version but I forgot to mention it.
Pondering works with Winboard now.  This requires reading from the Winboard pipe without 
blocking the search.

--------------------------
Updates in version 1.5.063
--------------------------
Speed improvement of about 15% as many nodes per second.

--------------------------
Updates in version 1.5.061
--------------------------
Increased understanding of certain endgames.
Fixed occasional problem when receiving custom positions from Winboard.
Now sends Principal Variation to Winboard when thinking if in "post" mode.

--------------------------
Updates in version 1.5.053
--------------------------
Great improvement in playing strength.  Improved history heuristic and corrected minor
flaw in Principal Variation search.

--------------------------
Updates in version 1.5.051
--------------------------
Understand editted positions received from Winboard and can also resume adjourned games
from an internet chess server when a list of previous moves is received.  This was a
problem with Rival's mis-interpretation of Winboard's "go" and "force" commands.

--------------------------
Updates in version 1.5.047
--------------------------
Improved selective extensions to the full width search which gives a noticeable improvement 
in playing strength.  Corrected a problem that occured when
loading games, particularly those saved that start from non-standard positions.

--------------------------
Updates in version 1.5.041
--------------------------
Now understands Winboard's "Conventional Chess Clock" timing method as well as the 
incremental method.  Many changes to evaluation function, no evidence of improvement!

-------------------------
Updates in version 1.5.03
-------------------------
Ability to read multimatch files has been removed.  Instead Rival can read
Winboard log files and determine the number of wins, losses and draws achieved
during the multimatch.

-----------------------
Updates in version 1.47
-----------------------
Can play if the increment of the time control is zero.

-----------------------
Updates in version 1.46
-----------------------
Added Psuedo-Pondering.  Very poor implementation of pondering.  The program
just executes a search on the opposition's time and relies on updates to the
hash table to improve the search on the program's move.

-----------------------
Updates in version 1.45
-----------------------
Yet another improvement to the timing mechanisms.
The bug I thought I fixed in 1.44 wasn't fixed.  It might be now.

-----------------------
Updates in version 1.44
-----------------------
There is a significant improvement in play in 1.44.  A few minor improvements to the
evaluation function which led to a few errors being corrected also.
Understands the fifty move rule.  This has been a long time coming for something so easy
to implement.
Will offer a draw with bare kings.  This was getting annoying!
Found and fixed a nasty bug which caused the program to write off some good moves 
as illegal.
Allow a choices of pieces on pawn promotion.

-----------------------
Updates in version 1.43
-----------------------
Fixed a memory leak.  
Fixed a problem writing to Winboard.  The program wasn't flushing stdout after writing
the result of a completed game.
A log file is no longer required as a command line argument following the -winboard flag.

-----------------------
Updates in version 1.42
-----------------------
Rival can now analyse a file that contains a list of FEN game positions.  Such
a file is output by Winboard during multi-matches between two computers.  By
choosing the menu option Special|Analyse PGN file, Rival will report the wins,
losses and draws totals.  Be aware that there is no error checking at the moment
so if an invalid file is given, the results are undefined.

Rival will report the number of white wins, the number of black wins and the number
of draws as well as the total number of games (in case some games were incomplete).
As Winboard alternates the colours of the players in a multi-match game, Rival will
report the number of wins for each of the players with Player 1 being the player
that was first to play as the white pieces.

v1.42 also fixed bug that caused Rival to sometimes run out of time in base & increment
timing method.

-----------------------
Updates in version 1.41
-----------------------
Understands Winboard's 'quit' command.  Previously needed to be closed manually
after Winboard finished.
Improved Time control handling for base & increment method.

----------------------
Updates in version 1.4
----------------------

Version 1.4 adds a new time control that is employed by Winboard and is used
to play on internet chess servers.  You can specify the number of minutes
to be set on the clocks at the beginning of a game and also the number of
seconds to be added to a player's clock after each move made by that player.

If the parameters for this timing method are alter while a game is in progress,
only the increment parameter will take effect.  Alterations to the base minutes
will take effect when a new game is started or if no moves have been made in the
game when the change is made.

-----------
version 1.3
-----------
Winboard support.  See winboard.txt.

A note on timings
-----------------
This answers a question I was asked recently regarding the timing accuracy.  Throughout the 
tree search, the various functions are measured with the time taken at the beginning and 
the end of each function.  The granularity of the time-taking function is not that important in
this case.  If the timing function measures in 0.001 second increments and a function takes 
an average 0.0005 seconds to execute, the average will still be calculated very accurately 
because on 100 calls to the function, about 50 will have been timed at 0.001 seconds and 
the others will have been timed at 0.000 seconds.  The average is then (50*0.001)/100 = 0.0005.  
If the average time of the function was 0.000001 seconds then we would need to take at 
least a few thousand samples to measure it with any degree of accuracy.
