I want to represent dBm in LaTeX. I have included the siunits package. But only dB is included. What is the best way to represent other units?
Asked
Active
Viewed 7,192 times
13
2 Answers
24
With SIunits:
\documentclass{article}
\usepackage{SIunits}
\addunit\decibelm{dBm}
\begin{document}
\decibelm
\end{document}
I would (not surprisingly) use siunitx. This looks like a separate unit for which I might use
\documentclass{article}
\usepackage{siunitx}
\DeclareSIUnit{\belmilliwatt}{Bm}
\DeclareSIUnit{\dBm}{\deci\belmilliwatt}
\begin{document}
\si{\deci\belmilliwatt}
\si{\dBm}
\end{document}
On the other hand, if it's a qualifier then
\documentclass{article}
\usepackage{siunitx}
\sisetup{qualifier-mode = text}
\begin{document}
\si{\deci\bel\of{m}}
\end{document}
Joseph Wright
- 259,911
- 34
- 706
- 1,036
-
thx Joseph! - one question: what do I need the \si for? I have tried, it works with $\dBm$ as well. – Feb 15 '17 at 17:58
-
@Luk In
siunitxwith the standard settings the unit macros are not globally defined, they are only available inside the arguments to\siand\SI. You can alter this if you wish. – Joseph Wright Feb 15 '17 at 18:08
1
For dBm with siunitx ---
\si{\dB\milli\nothing}
This has an unwanted space between B and m, but it does not require declaring new units, so good for a quick implementation. 
@daleif
Might be an idea to explain what dBm is
dBm (or dBmW) means deci-bel milliwatt, or the power in milliwatts but written in 10*log10 format, e.g., 10 dBm = 10 mW.
It seems that the author of siunitx refused to add this unit, since it is not a standard unit.
Well, it is an industrial (and academic) standard.
siunitxpackage https://www.ctan.org/pkg/siunitx?lang=en – samcarter_is_at_topanswers.xyz Feb 15 '17 at 16:08