A C++ chess engine implementing minimax algorithm with alpha-beta pruning for intelligent move selection.
- Complete Chess Engine: Plays full games with legal move generation
- Advanced Evaluation: Multi-factor position assessment including material, pawn structure, mobility, and king safety
- Search Algorithm: Minimax with alpha-beta pruning for optimal move selection
- FEN Support: Standard chess notation for position input/output
- Interactive Play: Human vs computer gameplay mode
Piececlass with position tracking and pin detection
Board_FENclass for FEN notation parsing and board state management
Movesclass for legal move generation and square control analysis
- Position evaluation functions:
- Material balance
- Pawn structure and outposts
- Mobility and king safety
- Trapped/hanging piece detection
EvalBarclass implementing minimax search with alpha-beta pruning- Game phase-specific evaluation weights
- Piece-square tables for positional scoring
- Utility functions for board manipulation and coordinate conversion
- Interactive Game: Run
test.cppfor human vs computer play - Position Analysis: Use
positionTesting()for detailed evaluation breakdown - FEN Input: Provide positions in standard FEN notation
make
./test- Material balance (piece values)
- Pawn structure and outposts
- Piece mobility and control
- King safety assessment
- Trapped/hanging piece penalties
- Position-based piece-square tables
The engine automatically adjusts evaluation weights based on game phase (opening/middlegame/endgame) for optimal performance.