123456789101112131415161718192021222324252627282930313233343536373839 |
- #ifndef CHESSY_MINIMAX_H
- #define CHESSY_MINIMAX_H
- #include <iostream>
- #include <utility>
- #include "MoveGeneration.h"
- namespace chessy
- {
- using MoveValue = float;
- /*!
- * \brief conducts a performance test iterating through all positions
- * up to a specified depth.
- *
- * \param out the stream to write info to
- * \param chessGame the game to iterate through the positions
- * \param depth how deep to search (in halfmoves)
- *
- * \return the number of nodes visited
- */
- size_t perft(std::ostream& out, ChessGame& chessGame, int depth);
- std::pair<Move, MoveValue> miniMax(ChessGame& chessGame, int depth);
- MoveValue negamaxImplementation(ChessGame& cg, int depth,
- MoveValue alpha, MoveValue beta);
- template<Side side>
- MoveValue evaluatePositives(const ChessGame& game);
- MoveValue evaluate(Side side, const ChessGame& game);
- }
- #endif // CHESSY_MIrIMAX_H
|