Questions tagged [cancel]
The cancel package is used to draw diagonal lines through words and symbols.
82
questions
1
vote
1
answer
20
views
\amsmath \align \display Please identify log errors
The mwe code below compiles and produces the desired layout.
However, the log shows 3 errors which I can't find after going through the code several times.
Your assistance identifying the source of ...
0
votes
2
answers
60
views
How to type cancel to with a line not an arrow
I want to use cancel to but with just a line instead of an arrow
0
votes
2
answers
65
views
RStudio not exporting while TeXworks does
Problem Overview
I want to use the cancel-package for my R-Markdown-file project.rmd. For that, I created a preamble.tex-file with following content:
\usepackage{amsmath}
\usepackage[makeroom]{cancel}
...
1
vote
0
answers
37
views
Siunitx and Cancel packages : bad alignment
Cancel package disturbs Sunitx tabular alignment :
\documentclass{article}
\usepackage{siunitx,cancel}
\begin{document}
\begin{tabular}{S[table-format=3]|S[table-format=4]}
\cancel{14} & \cancel{...
2
votes
0
answers
61
views
Cross out a multiline expression inside an align* environment
I'd like to cross out a subsection of an aligned environment, as below (the actual content doesn't matter).
\documentclass{article}
\usepackage{amsmath,cancel}
\begin{document}
\begin{align*}
4h + b &...
1
vote
1
answer
79
views
Uniformly oriented cancelling lines across math or texts
How do I cross out maths to show they vanish with evenly oriented diagonal lines (i.e., all lines parallel?)
I don't like how the crossing lines appear due to size of the expressions. It doesn't ...
2
votes
2
answers
325
views
How show rational simplification?
I need to show the path to simplify fractions, i.e., through their common divisors, so that show the first simplifications. For example:
18/6
I'd want to show some like this:
\frac{\cancel{18}^9}{\...
2
votes
1
answer
47
views
Formatting is off with cancel to package
I am trying to use the cancel package when showing a term is zero and therefore can be discounted. Here is a MWE:
\documentclass{article}
\usepackage{cancel}
\begin{document}
$\Gamma_{yy}^x = \frac{1}...
2
votes
2
answers
161
views
How to cancel the prefixes only?
See my MWE:
\documentclass{scrartcl}
\usepackage{siunitx,
cancel}
\begin{document}
Test $\qty{1}{\cancel\mega\W}\cdot\SI{1}{\cancel\micro\ohm}$ test.
\end{document}
It is possible ...
-1
votes
2
answers
426
views
How I can use cancel package? [closed]
\dfrac{\cancel{4} \times \cancel{5} \times \cancel{3}}{\cancel{2} \times \cancel{10}}
4
votes
1
answer
127
views
How could I typeset this? (Horizontal and aligned cancelling)
Let's say I have a reducible fraction, like 77/33, and I want to show its reduction. I'd like to create something similar to cancel's \cancelto, in that it overlaps the superseded digit, but ...
3
votes
1
answer
84
views
Selective coloration of polynomial parts of rational expressions
I'm teaching high school students how to simplify rational expressions by cancelling factors.
The cancelled expressions should be colored red (incl. L /R parenthesis), but not the fraction bar. The ...
5
votes
1
answer
421
views
How can I write one number vertically above another?
I wonder if you can help me in how to place one number on top of another (vertically) just as I show in the following image. I appreciate too much any help.
3
votes
1
answer
190
views
Cancel command spans multiple lines of equations
I am trying to cancel out an equation term that is simply too long, and the cancelling arrow overlaps the equations above and below what I want to cancel:
Minimal code:
\documentclass[8pt]{extarticle}
...
1
vote
1
answer
129
views
\cancel or \bcancel draws non-parallel lines in math mode; looking for better solutions
I have very similar lines in math mode under a \align environment. When I use \cancel or \bcancel it doesn't draw parallel lines for what should be similar width terms.
I think a simple repro would be:...
1
vote
0
answers
164
views
Is it possible to use \cancel without imports? [closed]
I was writing a response to someone for a math class of mine in Piazza (a sort of chat forum for classes) when I tried to use $$\usepackage{cancel}\cancel{x}$$ when I realized that $$\usepackage$$ ...
9
votes
2
answers
746
views
How to cancel the root but not the expression inside it?
I wanted to cancel the root of an expression like this
\documentclass{article}
\usepackage{cancel}
\begin{document}
\[\cancel{\sqrt{\left(a+b+c+d+f+g+h+e\right)^{\cancel{2}}}}\]
\end{document}
I'm ...
2
votes
1
answer
256
views
`cancelto` : choppy arrow problem
I am using the package cancel to do the operation as shown in figure.
As you can see the arrow is choppy. I read another question mentioning the same error : here. As suggested in the accepted ...
4
votes
2
answers
2k
views
How do cross out text in math mode?
Since \sout does not work in math mode, what can I use instead? I don't want the diagonal strikeout like with cancelf
0
votes
1
answer
298
views
Using "cancel" package in pandoc
I'm trying to convert a .md file that contains the "\cancel" control sequence, but pandoc throws error due to the package "cancel" not being included.
example:
file.md
$\cancel{X+2}-\cancel{X+2}=c$
...
0
votes
1
answer
135
views
How to cancel powered number?
How to get the result circled in red? I tried 3^\cancel{4} but it doesn't work.
3
votes
1
answer
545
views
Cancel package enhancement
How difficult is it to enhance (=copy the code of the package in my project and adapt it) the Cancel package,
Cancel package, with a command \cancelno{〈label〉}{〈expression〉} such that
a slash is put ...
1
vote
1
answer
607
views
Aborting a compilation in Texmaker
Well, I've read this, but doesn't solve the problem for Texmaker, and I'm really clumsy, instantly seeing errors after a tedious long time wrong compilation.
As I really don't expect any self-...
5
votes
2
answers
339
views
Equivalent of cancelto in ConTeXt
Is there any equivalent of \cancelto in ConTeXt? I want to cancel math expression with an arrow as in "goes to zero".
2
votes
1
answer
408
views
Error on using "\rl{}" inside "inline math"
I use TeXstudio 2.12.16 and want to write Farsi words in \cancelto{value}{expression}. So I used xepersian package and \rl. What I tried is:
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{...
0
votes
0
answers
75
views
Repetition of terms due to \cancel error
I'm writing the following equations
\[k_f^\dagger k_f = M_f U_f^\dagger (y_f ^\dagger)^{-1}(y_f)^{-1}U_f M_f = M_f \cancel{U_f^\dagger} \cancel{(U_f^\dagger)^{-1}}(M_f^2)^{-1}\cancel{U_f^{-1}}\cancel{...
0
votes
1
answer
1k
views
How to use $$ in mathjax to be inline? [closed]
I have used the following code to display inline mathjax
<script type="text/x-mathjax-config">
MathJax.Hub.Config({tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}});
</script>
<...
2
votes
1
answer
162
views
Cancel a term using tikzmark package
Recently, @marmot in Need help to create a more flexible \cancel command that works inside an align environment suggested the use of the \tikzmarknode command of the last version (1.6) of the tikzmark ...
2
votes
1
answer
490
views
Need help to create a more flexible \cancel command that works inside an align environment
Please, consider the snippet below.
I would like to cancel out the two middle terms of equation (1) and to cancel to 1 the expression in between the braces in equation (2).
If I use \cancel and \...
5
votes
1
answer
3k
views
How to strike through or cancel using different colors in the same line
For example, suppose I had an equation
x = 2 + 1 - 2 - 1 (obviously toy example)
I want the +2 to cancel out with the -2, +1 to cancel out with the -1
So in Latex I would want something like
Is there ...
2
votes
2
answers
281
views
How to strikeout an flalign block?
I am trying to strikeout an entire flalign block. This post shows how to strikeout an aligned block using the cancel package, but I'm not able to get it to work for the flalign environment. Any ...
3
votes
1
answer
646
views
cancel package documentation, shaded blocks to cancel
I would like to use some kind of colored cancel lines to mark simplifications. The cancel package documentation reads:
If you use the color package, then you can declare
\renewcommand{\CancelColor}{&...
1
vote
1
answer
829
views
Conflict between cancel and align
It seems that the cancel package does not behave well as one needs to cross out 'large' amount of text as the bar crosses the next line, and the result clearly seems unacceptable.
\documentclass{...
2
votes
1
answer
116
views
Packages cancel and schulschriften_lin not working together?
When I use the "schulschriften_lin"-package, cancellation is no longer working (see MWE).
\documentclass{article}
\usepackage{amsmath}
\usepackage{cancel}
\usepackage{schulschriften_lin} % ...
4
votes
1
answer
4k
views
Coloring the cancellation line with \cancel
I would like the strike-out line colored grey when using the \cancel command from the cancel package.
The code...
\documentclass{article}
\usepackage{cancel}
\begin{document}
$$a+\cancel b+c$$
\...
1
vote
2
answers
441
views
cancel package and tables
I have a "friend" who needs to do some kind of strikethrough or cancel but for a whole row or column (or both) of a table at a time. It should ideally be something supported by MathJax, so various ...
3
votes
1
answer
450
views
Line jump using the \xcancel macro in beamer
My question is related to this one : Latex - Beamer: Applies the \cancel command only a specified slides. I tried to apply Loop Space's answer to this question, but I get a line jump when the xcancel ...
3
votes
1
answer
2k
views
Unable to get cancel.sty to work
I'm a newbie in using Latex. I use the TexMaths Equations editor within LibreOffice.
I installed cancel package in MiKTex Package Manager. I'm not sure where it was installed or whether it was ...
0
votes
1
answer
428
views
fun style cross-strike-out
I want to cross out (strike out) words or letters in fun ways for poster-sized text for children.
ulem and cancel produce rather formal/sterile-looking cancellations, as do tikz-based combinations of ...
4
votes
1
answer
637
views
How do I cancel an exponent in an equation using siunitx?
The minimum working example below demonstrates the problem. I have a number of equations formatted like the first one below, where say the numerator has square meters and the denominator has meters. ...
0
votes
0
answers
125
views
Lualatex compilation problem using cancel and breqn packages [duplicate]
foo.tex
\documentclass{article}
\usepackage{cancel}
\usepackage{breqn} % <= this include is causing troubles
\begin{document}
\[\cancelto{0}{foo}\]
\end{document}
compiling produces these ...
7
votes
1
answer
1k
views
multiple colors to cancelto
Is it possible to assign multiple colors to the command "cancelto" of the package cancel?
This answer change color cancelto is almost there, but it changed the color for all the environments, at ...
3
votes
1
answer
881
views
\cancel: double strike
Is it possible to generate multiple \cancel stripes? Say for instance I have
$f(x,y) = 3x^2 +2xy +4y^2 - 3x^3 - 3x^2 - 2xy + 4xy^3$
and I want to cancel the 3x^2-term once and the 2xy-term twice.
$...
4
votes
2
answers
826
views
How to cross-out a number several times?
Hello. I want to be able to cross out a number several times (just like in the picture!) at least 3 times. How do i do that? And how do i make a circle around a number?
10
votes
1
answer
187
views
Active ! Character Hangs within TikZ
The MWE below
makes the ! active in math mode using the solution from Make Characters Active via Macro in Math Mode and
uses the tikz \hcancel via Diagonal strikeout starting too low and ending too ...
2
votes
1
answer
835
views
Cancel out factorial fractions
I have the following fraction:
How can I use a line and cross off the 3, 2, and 1s in the numerator and denominator?
I need a line crossing off the 3s in the numerator and denominator - one line. ...
6
votes
1
answer
354
views
How do I strike through the first text on a line using the cancel module?
I'm new to latex so please be gentle.
I installed cancel using this command:
tlmgr install cancel
Then I created a test file called test.tex with the following content:
\documentclass[12pt]{...
4
votes
1
answer
2k
views
cancel package: combine bcancel and cancelto (bcancelto?)
Is there a way to create a negative slope with the cancel package, but using \cancelto? i.e. I would like to combine the two commands so that I have a negative slope but with an arrow and number.
...
3
votes
1
answer
269
views
cancel line through a tikz picture in the background
I have defined a command \kr to draw a small circle to use it as a letter. Later I want to cancel out a circle. But the cancel line is in the background, see picture. How can I make the cancel line be ...
4
votes
2
answers
1k
views
Equation overlapping with body text
In the MWE below, my equation is clashing with the text of the body of the document and also the header. How can I get the equation to not clash/overlap with the document text?
Here is my code:
\...