diff --git a/qualtran/bloqs/arithmetic/controlled_add_or_subtract.ipynb b/qualtran/bloqs/arithmetic/controlled_add_or_subtract.ipynb index 97da1cd23..562990ed5 100644 --- a/qualtran/bloqs/arithmetic/controlled_add_or_subtract.ipynb +++ b/qualtran/bloqs/arithmetic/controlled_add_or_subtract.ipynb @@ -41,8 +41,10 @@ "Applies the transformation\n", "\n", "$$\n", + "\\begin{aligned}\n", " |1\\rangle |a\\rangle |b\\rangle \\mapsto |1\\rangle |a\\rangle |b + a\\rangle \\\\\n", " |0\\rangle |a\\rangle |b\\rangle \\mapsto |0\\rangle |a\\rangle |b - a\\rangle\n", + "\\end{aligned}\n", "$$\n", "\n", "Given two numbers `a`, `b` and a control bit `ctrl`, this bloq computes:\n", diff --git a/qualtran/bloqs/arithmetic/controlled_add_or_subtract.py b/qualtran/bloqs/arithmetic/controlled_add_or_subtract.py index ad4ab2554..2074e3446 100644 --- a/qualtran/bloqs/arithmetic/controlled_add_or_subtract.py +++ b/qualtran/bloqs/arithmetic/controlled_add_or_subtract.py @@ -32,8 +32,10 @@ class ControlledAddOrSubtract(Bloq): Applies the transformation $$ + \begin{aligned} |1\rangle |a\rangle |b\rangle \mapsto |1\rangle |a\rangle |b + a\rangle \\ |0\rangle |a\rangle |b\rangle \mapsto |0\rangle |a\rangle |b - a\rangle + \end{aligned} $$ Given two numbers `a`, `b` and a control bit `ctrl`, this bloq computes: