Answers.Body: <p>You may underestimate the number of games you need to determine the "best" opening by simulation. The differences between different openings are very small and to get a solid statistical judgment a few thousand games for each opening may be insufficient.</p>
  
  <p>Then comes the question of the best response: There is an opponent, after all, and to build an opening book you must test for the strongest responses.</p>
  
  <p>Still, this is all statistical and we know that it is not possible to solve chess computationally at the time being. A deep analysis may find a flaw in the "best" opening that is out of sight for current chess engines.</p>
  
  <p>To your last question: For the chess variant "Schoolbook" (a variant of the Carrera-Capablanca type with rook-knight and bishop-knight compounds) its author Sam Trenholme has started to build an opening book using the method you propose, see <a href="http://www.chessvariants.org/index/msdisplay.php?itemid=MSschoolbook" rel="nofollow">http://www.chessvariants.org/index/msdisplay.php?itemid=MSschoolbook</a> (comment at the bottom of the page).</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-11-20T10:56:16.640Z
Answers.Text: +1; _"You may underestimate the number of games you need to determine the "best" opening by simulation."_ To give some Stetson-Harrison numbers: Assume no draws occur, and that opening A gives white a 54.5 % chance of winning and opening B gives white a 54 % chance of winning. Play 10,000 games with each opening. The probability that white has scored more with B than with A is 24 % - you're not able to deduce which one is better with only 10,000 games. With draws, the number of required games is even higher. And 54.5 % vs 54 % seems very high to be the difference of two "best" openings.
Answers.UserDisplayName: JiK
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-11-20T10:38:13.687Z
Answers.LastActivityDate: 2014-11-20T10:38:13.687Z
Answers.UserDisplayName: Sir Cornflakes
Answers.Body: <p>Such a process would only find out which opening works best against the current version of itself. Nobody cares how well a computer plays against itself.</p>
  
  <p>For some computer vs computer events (like TCEC), it is common practice to pick some opening position after 8 moves or so, and then play without opening book.</p>
  
  <p>For <em>customers</em>, people who buy engines to play games against it, it is most important that it plays a wide variety of openings (variety is more fun), and that it is very up to date with current theory, for practice reasons.</p>
  
  <p>So the main people interested in really great opening books for computer vs computer play are the kind of people who run their engines 24/7 on sites like Playchess to play against other computers, trying to improve their computers' ratings. They basically do this process manually, by watching the results and updating the opening books by hand where needed.</p>
  
  <p>And on top of all that, remember that chess is most likely a draw. All the very theoretical, forced, deep lines that computers are great at analyzing out (like the Najdorf Poisoned Pawn, say) tend to lead to forced draws in all lines. Once everybody knows too much, they have to switch to something less well known.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-11-20T12:58:07.660Z
Answers.LastActivityDate: 2014-11-20T12:58:07.660Z
Answers.UserDisplayName: RemcoGerlich
Answers.Body: <p>If the question is asking why computer engines don't use much narrower opening books that could theoretically be analyzed deeper (and thus be objectively 'better'), the answer is simply that it actually makes the engine weaker because the chance of leaving the book becomes greater with a deep-but-narrow book (as suggested) instead of a shallow-but-broad one. </p>
  
  <p>You could come up with an incredibly detailed book for one specific mainline opening (and some people have tried this, a notable example being for the Halloween Gambit), but there are several problems:</p>
  
  <ul>
  <li>If the opening your engine will play is known because there's really only one line used, it's easier to research that and include a refuation in a competing engine's book.</li>
  <li>If your engine only has a very narrow book, then it's relatively easy to generate an opening book that is broader and using a small amount of randomness in the engine would provide a fair chance of deviating and staying in book long after your engine is thinking for itself (which is generally a bad idea for an engine in the opening).</li>
  <li>If your engine knows a certain opening up to move 50, then it's not difficult for a competitor to take that book and expand that one opening up to move 55, thereby having a decent advantage. It's a real problem when your book contains thousands of different lines, though.</li>
  </ul>
  
  <p>As a result of these, having a broader book is a benefit both offensively (you might be in book longer) and defensively (less likely to be brought out of book quickly), and requires only a small sacrifice in depth.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-11-20T11:39:46.873Z
Answers.LastActivityDate: 2014-11-20T11:49:51.903Z
Answers.LastEditDate: 2014-11-20T11:49:51.903Z
Answers.UserDisplayName: DTR
Answers.Body: <p>Yes, there's a flaw, and it's that the opponent also has a move. At best, you can only choose your first move (and only then if you are White). After the first move, because the opponent is also trying to maximize his chances of winning, he's not going to pick an opening which you win more often than not. Therefore you can't just find the opening that gives you the best result when you play against yourself, and play only that opening - the opponent will not allow it. </p>
  
  <p>At best, you might be able to say "with 1. e4 I maximize my chances of winning", but that's already done by all computers.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-12-19T06:02:04.553Z
Answers.LastActivityDate: 2018-12-19T06:02:04.553Z
Answers.UserDisplayName: Allure
Answers.Body: <p>Time, availability of faster computers, and progress in Artificial Intelligence have invalidated my previous answer.</p>
  
  <p>With Alpha Zero and Leela Zero we now have programs learning Chess strategy and openings from intensive self-play and giving winning percentages for moves and positions.</p>
  
  <p>It is possible <strong>now</strong> (i.e., in 2018).</p>
  
  <p>EDIT: However, even the above-mentioned engines have not yet solved Chess. They also produce quite a variety of opening lines and do not slavishly play one and the same line every time.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-12-19T05:55:53.497Z
Answers.Text: I disagree with this answer. Your opponent has a hand in the openings as well; if you only ever play one opening you can expect the opponent to counter.
Answers.UserDisplayName: Allure
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-12-18T10:00:25.420Z
Answers.LastActivityDate: 2018-12-18T17:15:33.397Z
Answers.LastEditDate: 2018-12-18T17:15:33.397Z
Answers.UserDisplayName: Sir Cornflakes
Body: <p>If few best computer players would be playing against themselves, chances of white winning would depend on the opening used. That way after simulating thousands of games the best opening would be found that is strictly better than the others. 
  Is there a flaw in this procedure? Has this ever been done before?</p>
  
Tags: <opening><engines>
Title: Why different openings are used by computer players?
ThreadText: # Why different openings are used by computer players?
  
  (Asked by: username_0 on 2014-11-20)
  
  If few best computer players would be playing against themselves, chances of white winning would depend on the opening used. That way after simulating thousands of games the best opening would be found that is strictly better than the others.
  Is there a flaw in this procedure? Has this ever been done before?
  
  **Tags:** opening, engines
  
  
  ---
  
  ## 5 answers
  
  ### Answer by username_1 on 2014-11-20. Score: 2
  
  You may underestimate the number of games you need to determine the "best" opening by simulation. The differences between different openings are very small and to get a solid statistical judgment a few thousand games for each opening may be insufficient.
  
  Then comes the question of the best response: There is an opponent, after all, and to build an opening book you must test for the strongest responses.
  
  Still, this is all statistical and we know that it is not possible to solve chess computationally at the time being. A deep analysis may find a flaw in the "best" opening that is out of sight for current chess engines.
  
  To your last question: For the chess variant "Schoolbook" (a variant of the Carrera-Capablanca type with rook-knight and bishop-knight compounds) its author Sam Trenholme has started to build an opening book using the method you propose, see <http://www.chessvariants.org/index/msdisplay.php?itemid=MSschoolbook> (comment at the bottom of the page).
  
  > **Comments:**
  > **username_2**: +1; _"You may underestimate the number of games you need to determine the "best" opening by simulation."_ To give some Stetson-Harrison numbers: Assume no draws occur, and that opening A gives white a 54.5 % chance of winning and opening B gives white a 54 % chance of winning. Play 10,000 games with each opening. The probability that white has scored more with B than with A is 24 % - you're not able to deduce which one is better with only 10,000 games. With draws, the number of required games is even higher. And 54.5 % vs 54 % seems very high to be the difference of two "best" openings.  
  
  ---
  
  ### Answer by username_3 on 2014-11-20. Score: 1
  
  Such a process would only find out which opening works best against the current version of itself. Nobody cares how well a computer plays against itself.
  
  For some computer vs computer events (like TCEC), it is common practice to pick some opening position after 8 moves or so, and then play without opening book.
  
  For *customers*, people who buy engines to play games against it, it is most important that it plays a wide variety of openings (variety is more fun), and that it is very up to date with current theory, for practice reasons.
  
  So the main people interested in really great opening books for computer vs computer play are the kind of people who run their engines 24/7 on sites like Playchess to play against other computers, trying to improve their computers' ratings. They basically do this process manually, by watching the results and updating the opening books by hand where needed.
  
  And on top of all that, remember that chess is most likely a draw. All the very theoretical, forced, deep lines that computers are great at analyzing out (like the Najdorf Poisoned Pawn, say) tend to lead to forced draws in all lines. Once everybody knows too much, they have to switch to something less well known.
  
  
  ---
  
  ### Answer by username_4 on 2014-11-20. Score: 0
  
  If the question is asking why computer engines don't use much narrower opening books that could theoretically be analyzed deeper (and thus be objectively 'better'), the answer is simply that it actually makes the engine weaker because the chance of leaving the book becomes greater with a deep-but-narrow book (as suggested) instead of a shallow-but-broad one.
  
  You could come up with an incredibly detailed book for one specific mainline opening (and some people have tried this, a notable example being for the Halloween Gambit), but there are several problems:
  
  * If the opening your engine will play is known because there's really only one line used, it's easier to research that and include a refuation in a competing engine's book.
  * If your engine only has a very narrow book, then it's relatively easy to generate an opening book that is broader and using a small amount of randomness in the engine would provide a fair chance of deviating and staying in book long after your engine is thinking for itself (which is generally a bad idea for an engine in the opening).
  * If your engine knows a certain opening up to move 50, then it's not difficult for a competitor to take that book and expand that one opening up to move 55, thereby having a decent advantage. It's a real problem when your book contains thousands of different lines, though.
  
  As a result of these, having a broader book is a benefit both offensively (you might be in book longer) and defensively (less likely to be brought out of book quickly), and requires only a small sacrifice in depth.
  
  
  ---
  
  ### Answer by username_5 on 2018-12-19. Score: 0
  
  Yes, there's a flaw, and it's that the opponent also has a move. At best, you can only choose your first move (and only then if you are White). After the first move, because the opponent is also trying to maximize his chances of winning, he's not going to pick an opening which you win more often than not. Therefore you can't just find the opening that gives you the best result when you play against yourself, and play only that opening - the opponent will not allow it.
  
  At best, you might be able to say "with 1. e4 I maximize my chances of winning", but that's already done by all computers.
  
  
  ---
  
  ### Answer by username_1 on 2018-12-18. Score: 0
  
  Time, availability of faster computers, and progress in Artificial Intelligence have invalidated my previous answer.
  
  With Alpha Zero and Leela Zero we now have programs learning Chess strategy and openings from intensive self-play and giving winning percentages for moves and positions.
  
  It is possible **now** (i.e., in 2018).
  
  EDIT: However, even the above-mentioned engines have not yet solved Chess. They also produce quite a variety of opening lines and do not slavishly play one and the same line every time.
  
  > **Comments:**
  > **username_5**: I disagree with this answer. Your opponent has a hand in the openings as well; if you only ever play one opening you can expect the opponent to counter.  
  
  ---
  
  