Is there a way to do strikethrough math formula in the math mode?

I had known this:

\sout{ ...}



are useful but they can not be used in the math mode. So one needs to turn it to the \text mode then do it. Is there any better way out?

I also know this:


but they do not look like the strikethrough lines.

Thanks! See also this.

1 Answer 1


This will get you started. Note, this does not strike out each component individually; you have to do that yourself.

The \bgroup ... \egroup serves two purposes. First is preserves the contents of \box0. It also means you can use \mathsout as an exponent etc. without having to enclose it in braces.


\newcommand{\mathsout}[1]% will draw line through middle of #1


x= \cos(\omega t) + \mathsout{sin(\omega t)} + \mathsout{e}^\mathsout{-t}



You must log in to answer this question.

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