From 163b38655b046df3f33639f17df6f2117d812e19 Mon Sep 17 00:00:00 2001 From: Aleks Kissinger Date: Sun, 27 Oct 2024 15:10:39 +0000 Subject: [PATCH] escaped some backslashes in docstrings --- pyzx/drawing.py | 2 +- pyzx/generate.py | 2 +- pyzx/todd.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pyzx/drawing.py b/pyzx/drawing.py index d3f49836..7c3e81b8 100644 --- a/pyzx/drawing.py +++ b/pyzx/drawing.py @@ -543,7 +543,7 @@ def pretty_complex(z: complex) -> str: else: out += f"{r:.2f}".rstrip("0").rstrip(".") if abs(f) > 1: - out += f"\cdot 10^{{{-f}}}" + out += f"\\cdot 10^{{{-f}}}" minus = "" if arg < 0: diff --git a/pyzx/generate.py b/pyzx/generate.py index a0b49a34..32dbd652 100644 --- a/pyzx/generate.py +++ b/pyzx/generate.py @@ -130,7 +130,7 @@ def CNOT_HAD_PHASE_circuit( clifford:bool=False ) -> Circuit: """Construct a Circuit consisting of CNOT, HAD and phase gates. - The default phase gate is the T gate, but if ``clifford=True``\ , then + The default phase gate is the T gate, but if ``clifford=True``\\ , then this is replaced by the S gate. Args: diff --git a/pyzx/todd.py b/pyzx/todd.py index f8742f68..798cf3e3 100644 --- a/pyzx/todd.py +++ b/pyzx/todd.py @@ -207,7 +207,7 @@ def phase_gates_to_poly(gates: List[Gate], qubits: int) -> Tuple[ParityPolynomia def xi(m: Mat2, z: List[Z2]) -> Mat2: - """Constructs the \chi matrix from the TOpt paper.""" + """Constructs the \\chi matrix from the TOpt paper.""" arr = np.asarray(m.data) rows = m.rows() data = []