I am having trouble getting the strikeout to work in this equation. I'd appreciate your help.
1 Answer
Welcome to TeX:SE!
For such purposes is package cancel
:
\documentclass{article}
\usepackage{cancel}
\begin{document}
\[
\frac{(x-2)\cancel{(x+1)}}{\cancel{x+1}} = x-2
\]
\end{document}
-
-
The full code provided did not work however, shortened to this works. [\frac{(x-2)\cancel{(x+1)}}{\cancel{x+1}} = x-2]. Thanks– tinaJan 18, 2022 at 19:54
-
@tina, I do not understand your comment. What does not work? What error you receive? My solution (as it is) definitely works, so I wonder what you change in your test.– ZarkoJan 18, 2022 at 21:57
-
I cut and pasted your code (changed nothing) and put it into my document. When I save, if it doesn't work, I see the code; if it does work I see the formatted equation. When I removed the first three lines and the last line of your code - it did work I saw the equation you have screen clipped above. For some reason the system I use doesn't need? like? the begin/end code. I have experienced this issue in the past. Thank you for helping you solved it anyway. :-)– tinaJan 19, 2022 at 19:24