How can create a \newcommand that be able generate:

|\phi\rangle\langle \psi|

However \ket{\phi}\bra{\psi} does that but we think that the distance between ket and bra in |\phi\rangle\langle \psi| is shorter than that of \ket{\phi}\bra{\psi}.

  • 2
    \op{\phi}{\psi} from the physics package does this. – Troy Jan 25 '18 at 7:54

Use the braket package:








enter image description here


try the command \ketbra{\phi}{\psi}, this should minimize the distance between the ket and the bra.

command \ketbra{\phi}{\psi}

  • 3
    Welcome to TeX.SE! Can you please add a screenshot of your result? (And no, I did not downvote!) – Mensch Jun 13 '19 at 16:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.