Author: Sune Fischer
Date: 09:47:00 02/21/04
Go up one level in this thread
On February 21, 2004 at 09:22:59, Maurizio Di Vitto wrote: >Hi, >now I am writing a very simple search engine in according with your crbmg.cpp >code, I simply mean that I would like to improve a search function that work >with your basic engine, just to understand better how a search function should >work, but before I begin i need to understand something about your code. You use >the Perft function member to explore the tree but in the main function you >wrote: >for (int depth=1;depth<=max_depth;depth++) > >so you execute the Perft(depth) max_depth time, so what would happen if you just >execute Perft(5), so does it explore correctly the tree to find a best move. That would produce perft 5. Forget the loop, the loop is just for show (iterated perfting). >So >after I tried many times, the main question is how could I modify the Perf to >find a move as result? I think the first think could be to declare that function >as int and not void, then I'll sobstitute ++movesfound with >score=-Perft(depth-1) then at the begin I cold write something like if You should take a look at some alpha-beta tutorials, e.g. http://www.seanet.com/~brucemo/topics/alphabeta.htm has a nice little pseudo code example. -S.
This page took 0 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.