Skip to content

Commit

Permalink
escaped some backslashes in docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
akissinger committed Oct 27, 2024
1 parent a5981ee commit 163b386
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pyzx/drawing.py
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down
2 changes: 1 addition & 1 deletion pyzx/generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down
2 changes: 1 addition & 1 deletion pyzx/todd.py
Original file line number Diff line number Diff line change
Expand Up @@ -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 = []
Expand Down

0 comments on commit 163b386

Please sign in to comment.