Athi_2048_Game_AI_Solver_01-05-2014

所属分类:matlab编程
开发工具:matlab
文件大小:22KB
下载次数:9
上传日期:2015-01-25 10:37:55
上 传 者丁小
说明:  详细说明:包含alphaBeta剪枝智能算法的matlab源程序,能很好解决2048小游戏的搜索功能
(alphaBeta Pruning intelligent algorithm matlab source code, can achieve a good search function and other games 2048)

文件列表:
Athi_2048_Game_AI_Solver_01-05-2014 (0, 2014-07-18)
Athi_2048_Game_AI_Solver_01-05-2014\Evaluation_Report.docx (14674, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\Evaluation_Script.txt (613, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\alphaBeta.m (3076, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\calculateClusteringScore.m (1559, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\findBestMove.m (745, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\getEmptyCellIds.m (667, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\getNumberOfEmptyCells.m (568, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\heuristicScore.asv (739, 2014-07-15)
Athi_2048_Game_AI_Solver_01-05-2014\heuristicScore.m (773, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\isGameTerminated.m (1013, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\move.m (2702, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\myAI.m (1405, 2014-07-16)
Athi_2048_Game_AI_Solver_01-05-2014\rotateLeft.m (714, 2014-05-05)
Athi_2048_Game_AI_Solver_01-05-2014\rotateRight.m (708, 2014-05-05)

============================= Game-2048-AI-Solver in MATLAB ============================= Implementation of an Artificial Intelligence Solver for Game 2048, written in MATLAB. This code has won the 2nd place, in the algorithm submission contest conducted in Matlab Central exchange. Details of the competition results can be found at http://blogs.mathworks.com/pick/2014/05/02/2048-algorithms/ This implementation is based on the JAVA code shared at. http://blog.datumbox.com/using-artificial-intelligence-to-solve-the-2048-game-java-code/ 1. In this MATLAB code, a bug present in the Java code is carefully fixed. 2. This MATLAB code is generic, in the sense, the Game continues even after 2048 is reached. Author: Athi Narayanan S PhD Scholar, Senior Research Associate, Amrita E-learning Research Lab, Computer Science Department, Amrita Vishwa Vidyapeetham, India. mail2athi@gmail.com http://sites.google.com/site/athisnarayanan/ Details of the Bug in the Java code ----------------------------------- There is a bug in the Java code, Board.action method. Random cell can only be added after a valid move. But in the Board.action method, random cell is added even for an invalid move. For example, Let the board be 0 0 0 4 0 0 0 0 0 0 0 0 0 0 0 0 AIsolver.findBestMove gives "Up" as the result, which is an invalid move, as the board does not change because of this movement. In the Board.action method, for this invalid move, random cell is further added. So, if we put the restriction for adding random cell only after a valid move, the present Java code will stuck on a board resulting in an invalid move (as given in the above example).

近期下载者

相关文件


收藏者