I want numbered the third (blue) equation in out of box. what do I do?

Attractive Boxed Equations

  • Welcome to TeX.SX! Which third blue box equation?
    – user31729
    Jun 20, 2016 at 6:17

1 Answer 1


You can choose:

enter image description here



\tcbset{colframe=blue!30!black, colback=blue!30, boxrule=1pt}

    nobeforeafter, math upper, tcbox raise base,


    c_i = \langle\psi|\phi\rangle

    c_i = \langle\psi|\phi\rangle

    c_i = \langle\psi|\phi\rangle

    c_i = \langle\psi|\phi\rangle

  • 1
    thank you, it work in a single file just like above. But in my file again i have an equation without numbering
    – Baruch
    Jun 20, 2016 at 6:49
  • 4
    @user108438 I don't want to be rude, but how can we deduce this problem from your question? would you mind to edit your question and better explain what's the problem and the desired result? You could even write the equation you want to box, or even better, include it inside a complete minimal working example (MWE). Thanks.
    – Ignasi
    Jun 20, 2016 at 7:03
  • Sorry for bad explain! Your commands are worked in a single file correctly. However, when I put them in my file, again I have an equation without numbering. Maybe I used many package that are conflict together. \begin{empheq}[box=\mymath]{equation} ‎L‎\y‎=‎\b‎‎‎ ‎‎\quad‎‎‎ ‎\quad ‎‎‎‎‎‎U\x=‎\y‎‎ \end{empheq}
    – Baruch
    Jun 20, 2016 at 7:15
  • @user108438 Let me insist: This description doesn't help. I don't know what packages are you using, I don't know how is written your equation, ... Please, write a Minimal working (or not) example. This means some code starting from \documentclass to \end{document} including the relevant and only relevant parts of your file. In this case it seems that between \begin{document} and \end{document} it just need to include the failing equation. Once you have this file, include in your question and we will better help you.
    – Ignasi
    Jun 20, 2016 at 7:34
  • I found my problem! I use xepersian package. It is a package for Persian writing. Unfortunately, I can't remove this package, because I am writing a Persian book. In the other hand I need a numbered formula in a colored box. It is a bad situation for me.
    – Baruch
    Jun 20, 2016 at 8:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .