Situational plus minus “[+|-]” symbol in LaTeX
In this tutorial, you will learn how to write the Situational plus minus symbol in a LaTeX document.
You can type this symbol from the keyboard to print this symbol in LaTeX.
\documentclass{article} \begin{document} If y = $[+|-]$x then x is either positive or negative depending on the situation. \end{document}
Output:
Resize the Situational plus minus symbol
You can also resize this symbol small or big with the given code. Just change the \scalebox{<value>}
command’s <value>
and resize it.
\documentclass{article} \usepackage{amsmath} \usepackage{graphicx} \DeclareMathOperator*{\spm}{\text{\raisebox{0.25ex}{\scalebox{0.75}{$[+|-]$}}}} \begin{document} Normal size: If y = $[+|-]$ x then x is either positive or negative depending on the situation. Small size: If y = $\spm$ x then x is either positive or negative depending on the situation. \end{document}
Output:
Leave a Reply