{
"cells": [
{
"cell_type": "markdown",
"id": "5a86ee07",
"metadata": {},
"source": [
"(myst-content/proofs-algorithms)=\n",
"# Proofs, Theorems, and Algorithms\n",
"\n",
"Infrastructure to support items such as `proof` and `algorithm` style formatting is provided by the [sphinx-proof](https://github.com/executablebooks/sphinx-proof) extension.\n",
"\n",
"This extension supports the `html` and `pdflatex` builders.\n",
"\n",
"[sphinx-proof](https://github.com/executablebooks/sphinx-proof) includes support for the following `directives`:\n",
"\n",
"1. [Algorithms](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#algorithms)\n",
"2. [Axioms](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#axioms)\n",
"3. [Conjectures](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#conjectures)\n",
"4. [Corollaries](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#corollaries)\n",
"5. [Criteria](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#criteria)\n",
"6. [Definitions](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#definitions)\n",
"7. [Examples](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#examples)\n",
"8. [Lemmas](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#lemmas)\n",
"9. [Observations](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#observations)\n",
"10. [Properties](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#properties)\n",
"11. [Propositions](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#propositions)\n",
"12. [Proofs](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#proofs)\n",
"13. [Remarks](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#remarks)\n",
"14. [Theorems](https://sphinx-proof.readthedocs.io/en/latest/syntax.html#theorems)\n",
"\n",
"## Installation\n",
"\n",
"```{warning}\n",
"This is **not** currently a default package in `jupyter-book` as is a relatively new package.\n",
"\n",
"It needs to be enabled through the `_config.yml` after installation.\n",
"```\n",
"\n",
"To install you can use `pip`:\n",
"\n",
"```bash\n",
"pip install sphinx-proof\n",
"```\n",
"\n",
"## Adding extension through `_config.yml`\n",
"\n",
"Open `_config.yml` and add `sphinx_proof` to:\n",
"\n",
"```yaml\n",
"sphinx:\n",
" extra_extensions:\n",
" - sphinx_proof\n",
"```\n",
"\n",
"## Using [sphinx-proof](https://github.com/executablebooks/sphinx-proof)\n",
"\n",
"This package uses a `prf` sphinx domain.\n",
"\n",
"All markup objects follow the `{prf:}` (such as `{prf:proof}`) pattern and allows the directives to be referenced using the inline role `{prf:ref}`.\n",
"\n",
"```{warning}\n",
"When referencing directives in [sphinx-proof](https://github.com/executablebooks/sphinx-proof) you need to use the ```{prf:ref}`