TeX - LaTeX Asked on December 17, 2020
I am using the hphantom
command to center the middle 0, but the middle 0 is still too far left.
Here is a picture of my problem:
Here is my MWE:
documentclass{article}
usepackage[utf8]{inputenc}
usepackage{amsmath}
begin{document}
begin{align}
Delta G =
begin{cases}
< 0 & quad A
hphantom{<} 0 & quad B
> 0 & quad C
end{cases}
end{align}
end{document}
You can do (quick and dirty)
documentclass{article}
usepackage[utf8]{inputenc}
usepackage{amsmath}
begin{document}
begin{align}
Delta G =
begin{cases}
< 0 & quad A
hphantom{< mbox{}} 0 & quad B
> 0 & quad C
end{cases}
end{align}
end{document}
Correct answer by Denis on December 17, 2020
You need an empty relation symbol with the same width as >
(or <
):
documentclass{article}
usepackage{amsmath}
begin{document}
begin{equation}
Delta G =
begin{cases}
< 0 & A
mathrel{phantom{<}} 0 & B
> 0 & C
end{cases}
end{equation}
end{document}
I wouldn't add quad
. Avoid the trailing ; while it has no effect in this particular case, it would have in
align
or similar constructions, producing an empty line. Also avoid align
for a single equation.
But why not using =0
?
Answered by egreg on December 17, 2020
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP