Latex typesetting conditional
How can I type set :
If x est positive write in Latex "H>0" else "H<=0"
add a comment
How can I type set :
If x est positive write in Latex "H>0" else "H<=0"
The following works on my computer:
x = -1
if x > 0:
show(LatexExpr('H>0'))
else:
show(LatexExpr('H\leq 0'))
Alternate solution:
LatexExpr("H>0" if H>0 else "H<=0")
Please start posting anonymously - your entry will be published after you log in or create a new account.
Asked: 2019-09-20 19:26:32 +0100
Seen: 205 times
Last updated: Nov 25 '19