| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
BishBosh.Search.Transpositions
Description
AUTHOR- Dr. Alistair Ward
DESCRIPTION
- https://www.chessprogramming.org/Transposition_Table.
- https://en.wikipedia.org/wiki/Transposition_table.
- Valid qualifiedMove-sequences can be recorded against the hash of the position from which they start.
Synopsis
- type Transformation qualifiedMove positionHash = Transpositions qualifiedMove positionHash -> Transpositions qualifiedMove positionHash
- data Transpositions qualifiedMove positionHash
- find :: Ord positionHash => positionHash -> Transpositions qualifiedMove positionHash -> Maybe (TranspositionValue qualifiedMove)
- insert :: Ord positionHash => FindFitness qualifiedMove -> positionHash -> TranspositionValue qualifiedMove -> Transformation qualifiedMove positionHash
Types
Type-synonyms
type Transformation qualifiedMove positionHash = Transpositions qualifiedMove positionHash -> Transpositions qualifiedMove positionHash Source #
The type of a function which transforms Transpositions.
Data-types
data Transpositions qualifiedMove positionHash Source #
Stores the result of an alpha-beta search from a position.
Instances
| Empty (Transpositions qualifiedMove positionHash) Source # | |
Defined in BishBosh.Search.Transpositions Methods empty :: Transpositions qualifiedMove positionHash Source # | |
| EphemeralData (Transpositions qualifiedMove positionHash) Source # | |
Defined in BishBosh.Search.Transpositions Methods getSize :: Transpositions qualifiedMove positionHash -> Int Source # euthanise :: NPlies -> Transpositions qualifiedMove positionHash -> Transpositions qualifiedMove positionHash Source # | |
Functions
find :: Ord positionHash => positionHash -> Transpositions qualifiedMove positionHash -> Maybe (TranspositionValue qualifiedMove) Source #
Returns any value previously recorded when searching from the specified position.
Mutators
Arguments
| :: Ord positionHash | |
| => FindFitness qualifiedMove | |
| -> positionHash | Represents the game from which the sequence of qualifiedMoves starts. |
| -> TranspositionValue qualifiedMove | The value to record. |
| -> Transformation qualifiedMove positionHash |
- Optionally record a value found while searching for the optimal move from a position, against the position's hash.
- If a matching key already exists, it's replaced if the new value is considered to be better.