question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Improve the parenthesis in the circuit gates documentation

See original GitHub issue

What is the expected enhancement?

In many place our documentation shows LaTeX fractions that are larger than the surrounding parenthesis. For example in the sine and cosines in the UGate documentation we have image

That’s because we don’t use the \left \right or \big commands if a parenthesis surrounds a \frac-fraction. It would be nice if we could go through the docs and ensure everything is nicely rendered by e.g. replacing occurances as

        \newcommand{\th}{\frac{\theta}{2}}
        U(\theta, \phi, \lambda) =
            \begin{pmatrix}
                \cos(\th)          & -e^{i\lambda}\sin(\th) \\
                e^{i\phi}\sin(\th) & e^{i(\phi+\lambda)}\cos(\th)
            \end{pmatrix}

with

        \newcommand{\th}{\frac{\theta}{2}}
        U(\theta, \phi, \lambda) =
            \begin{pmatrix}
                \cos\left(\th\right)          & -e^{i\lambda}\sin\left(\th\right) \\
                e^{i\phi}\sin\left(\th\right) & e^{i(\phi+\lambda)}\cos\left(\th\right)
            \end{pmatrix}

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:7 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
jakelishmancommented, Apr 4, 2022

Thanks for your interest, @stoicodin, but this issue has already been solved by @saktar-unr in #7872. You can see the context and linked pull requests above. If you’d like to find something else to work on, please have a look at the issues tagged “good first issue”.

1reaction
Cryoriscommented, Apr 1, 2022

Just one pull request for all of them would be good! You can build the documentation locally and check there how it looks like. If you have tox installed you should be able to do that by calling tox -edocs in the qiskit-terra root folder 🙂

Read more comments on GitHub >

github_iconTop Results From Across the Web

COMBINATIONAL LOGIC CIRCUITS
In Chapter 3, we studied the operation of all the basic logic gates, and we used Boolean algebra to describe and analyze circuits...
Read more >
Circuit Simplification Examples | Boolean Algebra
To convert a Boolean expression to a gate circuit, evaluate the expression using standard order of operations: multiplication before addition, and operations ...
Read more >
Logic Gates and truth tables
- The operators inside and outside the brackets must be different. - The term outside the brackets must also be included inside the...
Read more >
Logic Circuit Structure with an Introduction to Computer Aided ...
This module presents the basic structure of combinational logic circuits, and introduces the use of computer aided design (CAD) tools in modern circuit...
Read more >
Using parentheses around a Qcircuit - LaTeX Stack Exchange
A hack I found was to compile the circuit alone, and then use this answer to encapsulate the resulting pdf in parenthesis.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found