Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dlyongemallo/zx-anki-deck
An Anki deck for studying the ZX-calculus.
https://github.com/dlyongemallo/zx-anki-deck
Last synced: about 1 month ago
JSON representation
An Anki deck for studying the ZX-calculus.
- Host: GitHub
- URL: https://github.com/dlyongemallo/zx-anki-deck
- Owner: dlyongemallo
- License: apache-2.0
- Created: 2023-11-06T09:48:40.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-01-25T21:29:01.000Z (11 months ago)
- Last Synced: 2024-01-25T22:33:31.698Z (11 months ago)
- Size: 44.9 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ZX-calculus Anki deck
An Anki deck for studying the ZX-calculus.
Download it [from Ankiweb](https://ankiweb.net/shared/info/132121405).
## Setup
To (re)create the deck using the desktop Anki app,
first download the [Edit LaTeX build process add-on](https://ankiweb.net/shared/info/937148547).
Then configure the add-on to use [`convert` from ImageMagick](https://imagemagick.org/script/convert.php) as follows on Linux and Windows:```
{
"pngCommands": [
[
"pdflatex",
"-interaction=nonstopmode",
"--shell-escape",
"tmp.tex"
],
[
"convert",
"-density",
"200",
"-trim",
"tmp.pdf",
"tmp.png"
]
],
[ ... other stuff... ]
}```
On MacOS, use `sips` instead:
```
{
"pngCommands": [
[
"pdflatex",
"-interaction=nonstopmode",
"--shell-escape",
"tmp.tex"
],
[
"sips",
"-s",
"format",
"png",
"tmp.pdf",
"--out",
"tmp.png"
]
],
[ ... other stuff... ]
}```
In Anki, under "Tools|Manage Note Types", for the `ZX-Calculus` note type, enter the following for the header:
```
\providecommand{\pgfsyspdfmark}[3]{}
\documentclass[convert={convertexe={convert}},border=2]{standalone}
\usepackage{amsmath}
\usepackage{tikz}
\usetikzlibrary{quantikz}
\usetikzlibrary{zx-calculus}
\pagestyle{empty}
\setlength{\parindent}{0in}\newcommand{\ketbra}[2]{\ensuremath{\ket{#1}\!\bra{#2}}}
\begin{document}
```And then this for the footer:
```
\end{document}
```The notes should be processed by LaTeX automatically to produce the cards.