Class BstarSquaredSimple.L1Position<P extends IGamePosition<P>>
java.lang.Object
algorithm.BstarSquaredSimple.L1Position<P>
- All Implemented Interfaces:
IGamePosition<BstarSquaredSimple.L1Position<P>>
- Enclosing class:
BstarSquaredSimple
public static class BstarSquaredSimple.L1Position<P extends IGamePosition<P>>
extends Object
implements IGamePosition<BstarSquaredSimple.L1Position<P>>
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescription(package private) final P(package private) final BstarSquaredSimple.L1Position.Settings -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlonglongvoidevaluate()(package private) longgetLimit()longhash()This method should be implemented with a hash that still remains different from similar states if a mask is applied to the hash.doubleThe lower-bound value is the lower bound on the game-theoretical mini-max value of this game position.booleannext()voidtoString()doubleThe upper-bound value is the upper bound on the game-theoretical mini-max value of this game position.
-
Field Details
-
original
-
s
-
-
Constructor Details
-
L1Position
-
-
Method Details
-
getLimit
long getLimit() -
setTree
-
evaluate
public void evaluate() -
next
- Specified by:
nextin interfaceIGamePosition<P extends IGamePosition<P>>- Returns:
- The collection of game positions directly reachable by moves from the current player to move in this game position.
-
upperbound
public double upperbound()Description copied from interface:IGamePositionThe upper-bound value is the upper bound on the game-theoretical mini-max value of this game position.For the maximising player this is the best value achievable under perfect play.
For the minimising player this is the worst-case value achievable under perfect play.
- Specified by:
upperboundin interfaceIGamePosition<P extends IGamePosition<P>>- Returns:
- The upper-bound value for this game position
-
lowerbound
public double lowerbound()Description copied from interface:IGamePositionThe lower-bound value is the lower bound on the game-theoretical mini-max value of this game position.For the maximising player this is the minimum value that can be guaranteed under perfect play.
For the minimising player this is the best value achievable under perfect play.
- Specified by:
lowerboundin interfaceIGamePosition<P extends IGamePosition<P>>- Returns:
- The lower-bound value for this game position
-
depthOfUpper
public long depthOfUpper() -
depthOfLower
public long depthOfLower() -
maximising
public boolean maximising()- Specified by:
maximisingin interfaceIGamePosition<P extends IGamePosition<P>>- Returns:
trueif the current player-to-move is maximising the score, orfalseif it is minimising the score.
-
hash
public long hash()Description copied from interface:IGamePositionThis method should be implemented with a hash that still remains different from similar states if a mask is applied to the hash. Commonly, a transposition table implementation may only use the first 20 to 26 bits of the hash to use as an index, so the hash should try to minimise collisions regardless of how many bits are included for the index.- Specified by:
hashin interfaceIGamePosition<P extends IGamePosition<P>>- Returns:
- a 64-bit zobrist hash or other kind of game-state hash that represents this state.
-
toString
-