Answers.Body: <p>There are multiple latex packages to produce chess boards (diagrams)
  most comprehensive is <a href="https://ctan.org/pkg/chessboard?lang=en" rel="nofollow noreferrer">chessboard</a> by Ulrike Fischer with numerous options (but it doesn't work with RTL languages).
  Start from there, everything you've described is in that package.
  if not satisfied try <a href="https://ctan.org/pkg/mpchess" rel="nofollow noreferrer">mpchess</a> (works fine with RTL languages)
  Browse the documentation first the illustrations will show you what you need.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2023-11-26T16:05:31.207Z
Answers.LastActivityDate: 2023-11-26T22:46:28.767Z
Answers.LastEditDate: 2023-11-26T22:46:28.767Z
Answers.UserDisplayName: Wassim Saeed
Answers.Body: <p>One option is to use the <a href="https://ctan.org/pkg/xskak?lang=en" rel="nofollow noreferrer"><code>xskak</code></a> package which loads and extends the <a href="https://ctan.org/pkg/skak?lang=en" rel="nofollow noreferrer"><code>skak</code></a> package while also loading the <a href="https://ctan.org/pkg/chessboard?lang=en" rel="nofollow noreferrer"><code>chessboard</code></a> package.</p>
  <p>Overleaf has a <a href="https://www.overleaf.com/learn/latex/Chess_notation" rel="nofollow noreferrer">great tutorial</a> with examples, as well as links to examples in the documentation for the referenced packages. Works with both FEN and PGN notation.</p>
  <p>Replacing <code>\showboard</code> with <code>\chessboard</code> will add a marker to the right of the diagram indicating if it is White to move or Black to move. Turn this off with <code>\chessboard[showmover=false]</code>.</p>
  <p><strong>Additional features:</strong></p>
  <ul>
  <li>Highlight squares in color: See code below and also this answer, <a href="https://tex.stackexchange.com/a/215334/169506">Chess Notation with skak: How to highlight squares?</a></li>
  <li>Drawing colored squares and circles on specific coordinates along with colored arrows is also possible according to the documentation (see documentation dated 23 June 2019, Sections 5.4–5.5, pages 30–34). See also <a href="https://tex.stackexchange.com/a/170056/169506">this answer</a>.</li>
  <li>Create nonstandard boards (e.g. 4 x 16): <a href="https://tex.stackexchange.com/a/358041/169506">Different chess board using skak package</a></li>
  </ul>
  <h3>Example using <a href="https://ctan.org/pkg/xskak?lang=en" rel="nofollow noreferrer"><code>xskak</code></a>:</h3>
  <p>Be sure to include <code>\usepackage{xskak}</code> in the preamble.</p>
  <pre><code>% Example (works with both skak and xskak packages)
  % Preamble
  \documentclass{article}
  \usepackage[utf8]{inputenc}
  \usepackage[papersize={8.5in,11in},margin=1in]{geometry}
  \usepackage{xskak}
  
  % Document
  \begin{document}
  
  Figure~\ref{fig:startpos} shows the starting position.
  
  \begin{figure}[h!]   % example use with figure
      \centering
      \newgame
      \chessboard % instead of \showboard
      \caption{Starting position for a game of chess.}
      \label{fig:startpos}
  \end{figure}
  
  For example White may choose to lead with the King's pawn fighting for central squares with \mainline{1. e4}.  
  
  Black responds with \mainline{1...e5} also seeking to grab central space.
  
  Play proceeds with \mainline{2. Nf3 Nf6 3. Nxe5}.
  
  \begin{center}
      \chessboard  % no need for LaTeX figure 
  \end{center}
  
  % Showcase use of FEN
  \newpage
  \section*{Mate in 2}
  \noindent Notes:  White to move. 
  
  \section*{Galitsky A}
  \newgame
  \fenboard{6R1/2pk4/8/8/4QK2/8/8/8 w - - 0 1}
  \chessboard
  
  \section*{Kolodnas Z}
  \newgame
  \fenboard{8/4P1Q1/3k4/8/3K4/8/8/8 w - - 0 1}
  \chessboard[showmover=false]  % remove move indicator
  
  \newpage
  % Position source: https://lichess.org/wFLCholu
  \chessboard[setfen=2rq1r1k/pb3pp1/1p6/b2PP3/3pB3/P7/1PQ2PPP/R1B2RK1 w - - 0 18,
              pgfstyle=border,
              markfields={h7,a5},
              color=blue!50,
              colorbackfield=b2,
              pgfstyle=color,
              opacity=0.5,
              color=red,
              markfield={a5},
              color=green,
              markfield={c2}]
  \end{document}
  </code></pre>
  <h3>Output:</h3>
  <p><a href="https://i.sstatic.net/NSZxs.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/NSZxs.png" alt="Example xskak package output using LaTeX code." /></a></p>
  <p><a href="https://i.sstatic.net/SyY7G.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/SyY7G.png" alt="Example xskak package output using LaTeX code." /></a></p>
  <p><a href="https://i.sstatic.net/rmZuO.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/rmZuO.png" alt="enter image description here" /></a></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2023-11-26T22:45:37.847Z
Answers.LastActivityDate: 2023-11-27T22:41:03.960Z
Answers.LastEditDate: 2023-11-27T22:41:03.960Z
Answers.UserDisplayName: SecretAgentMan
Body: <p>Killer chess training gives out worksheets like <a href="https://p8e5c7t2.rocketcdn.me/wp-content/uploads/2021/03/Friendly-Homework-23-%E2%80%93-2021-03-23.pdf" rel="nofollow noreferrer">https://p8e5c7t2.rocketcdn.me/wp-content/uploads/2021/03/Friendly-Homework-23-%E2%80%93-2021-03-23.pdf</a> every week.</p>
  <p>They ask students to do three things:</p>
  <ol>
  <li>Mark weaknesses with green squares (alternate: mark with circle)</li>
  <li>Mark the worst placed piece(s) on both sides with yellow squares (alternate: mark with square)</li>
  <li>Indicate the opponent’s idea with red arrows</li>
  </ol>
  <p>Is there a latex package for marking up chess diagrams in this way?</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-05-16T22:58:40.397Z
Comments.Text: Did these posts answer your question?
Comments.UserDisplayName: SecretAgentMan
Tags: <learning><diagram>
Title: Using latex for Killer Chess Training homework club?
ThreadText: # Using latex for Killer Chess Training homework club?
  
  (Asked by: username_0 on 2023-11-24)
  
  Killer chess training gives out worksheets like <https://p8e5c7t2.rocketcdn.me/wp-content/uploads/2021/03/Friendly-Homework-23-%E2%80%93-2021-03-23.pdf> every week.
  
  They ask students to do three things:
  
  1. Mark weaknesses with green squares (alternate: mark with circle)
  2. Mark the worst placed piece(s) on both sides with yellow squares (alternate: mark with square)
  3. Indicate the opponent’s idea with red arrows
  
  Is there a latex package for marking up chess diagrams in this way?
  
  **Tags:** learning, diagram
  
  > **Comments:**
  > **username_1**: Did these posts answer your question?  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_2 on 2023-11-26. Score: 2
  
  There are multiple latex packages to produce chess boards (diagrams)
  most comprehensive is [chessboard](https://ctan.org/pkg/chessboard?lang=en) by Ulrike Fischer with numerous options (but it doesn't work with RTL languages).
  Start from there, everything you've described is in that package.
  if not satisfied try [mpchess](https://ctan.org/pkg/mpchess) (works fine with RTL languages)
  Browse the documentation first the illustrations will show you what you need.
  
  
  ---
  
  ### Answer by username_1 on 2023-11-26. Score: 2
  
  One option is to use the xskak package which loads and extends the skak package while also loading the chessboard package.
  Overleaf has a great tutorial with examples, as well as links to examples in the documentation for the referenced packages. Works with both FEN and PGN notation.
  Replacing \showboard with \chessboard will add a marker to the right of the diagram indicating if it is White to move or Black to move. Turn this off with \chessboard[showmover=false].
  Additional features:
  
  Highlight squares in color: See code below and also this answer, Chess Notation with skak: How to highlight squares?
  Drawing colored squares and circles on specific coordinates along with colored arrows is also possible according to the documentation (see documentation dated 23 June 2019, Sections 5.4–5.5, pages 30–34). See also this answer.
  Create nonstandard boards (e.g. 4 x 16): Different chess board using skak package
  
  Example using xskak:
  Be sure to include \usepackage{xskak} in the preamble.
  % Example (works with both skak and xskak packages)
  % Preamble
  \documentclass{article}
  \usepackage[utf8]{inputenc}
  \usepackage[papersize={8.5in,11in},margin=1in]{geometry}
  \usepackage{xskak}
  
  % Document
  \begin{document}
  
  Figure~\ref{fig:startpos} shows the starting position.
  
  \begin{figure}[h!]   % example use with figure
      \centering
      \newgame
      \chessboard % instead of \showboard
      \caption{Starting position for a game of chess.}
      \label{fig:startpos}
  \end{figure}
  
  For example White may choose to lead with the King's pawn fighting for central squares with \mainline{1. e4}.  
  
  Black responds with \mainline{1...e5} also seeking to grab central space.
  
  Play proceeds with \mainline{2. Nf3 Nf6 3. Nxe5}.
  
  \begin{center}
      \chessboard  % no need for LaTeX figure 
  \end{center}
  
  % Showcase use of FEN
  \newpage
  \section*{Mate in 2}
  \noindent Notes:  White to move. 
  
  \section*{Galitsky A}
  \newgame
  \fenboard{6R1/2pk4/8/8/4QK2/8/8/8 w - - 0 1}
  \chessboard
  
  \section*{Kolodnas Z}
  \newgame
  \fenboard{8/4P1Q1/3k4/8/3K4/8/8/8 w - - 0 1}
  \chessboard[showmover=false]  % remove move indicator
  
  \newpage
  % Position source: https://lichess.org/wFLCholu
  \chessboard[setfen=2rq1r1k/pb3pp1/1p6/b2PP3/3pB3/P7/1PQ2PPP/R1B2RK1 w - - 0 18,
              pgfstyle=border,
              markfields={h7,a5},
              color=blue!50,
              colorbackfield=b2,
              pgfstyle=color,
              opacity=0.5,
              color=red,
              markfield={a5},
              color=green,
              markfield={c2}]
  \end{document}
  
  Output:
  
  
  ---
  
  