Using the cancel package, you can cross expressions in various ways.
However, what I can do to cross a symbol, with the strikethrough a different color, say red.
Using the cancel package, you can cross expressions in various ways.
However, what I can do to cross a symbol, with the strikethrough a different color, say red.
You can do this with the command \renewcommand{\CancelColor}{\color{red}}, described in the canceldocumentiontation, section 2 Options, page 1.
If you use the color package, then you can declare
\renewcommand{\CancelColor}{<color_command>}and the cancellation marks will be printed in that color (e. g., \blue). However, if you are using color, I recommend lightly shaded blocks rather than diagonal arrows for cancelling.
Note that you can always locate the documentation using the command-line/terminal by writing texdoc cancel, and that works for any package. The documentation is also available at http://ctan.org/pkg/cancel
It might sound tedious to look up the documentation for various small problems/features, but the package documentations tend to be well-written and easy to browse. Also, it will at the same time help you to understand how LaTeX works.
\documentclass{article}
\usepackage{cancel}
\usepackage{xcolor}
\renewcommand{\CancelColor}{\color{red}}
\begin{document}
\begin{equation}
2+2=\cancelto{4}{5}
\end{equation}
\end{document}