I get 1.0 Nm. But how to get 1.0 N.m
\documentclass{article}
\usepackage{siunitx}
\begin{document}
\SI{1.0}{\newton\meter}\\
1.0~N$\cdot$m
\end{document}
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It only takes a minute to sign up.
Sign up to join this communityinter-unit-product
is an available option and described in the documentation. To get correct spacing you should use ${}\cdot{}$
. However I prefer a tighter spacing by $\cdot$
.
\documentclass{article}
\usepackage{siunitx}
\parindent0pt
\begin{document}
\SI[inter-unit-product =$\cdot$]{1.0}{\newton\meter}\\
\SI[inter-unit-product =${}\cdot{}$]{1.0}{\newton\meter}\\
$1.0\,\mathrm{N}\cdot\mathrm{m}$
\end{document}
To set his behavior for the whole document you can specify the option via \sisetup
\sisetup{inter-unit-product =$\cdot$}
\si[inter-unit-product = \ensuremath{{}\cdot{}}]
to get the corrected spacing.
Apr 10, 2013 at 12:57
$
-symbols: \usepackage[inter-unit-product =\cdot]{siunitx}
Sorry for the zombie reply, but aren't the units typeset in math mode? In that case:
\SI[inter-unit-product =$\cdot$]{1.0}{\newton\meter}
won't compile. You should use:
\SI[inter-unit-product =\ensuremath{\cdot}]{1.0}{\newton\meter}
instead.
\SI
command has changed to \qty
command. And you can still use the old commands, the author says "Where possible, older names are mapped to newer ones internally: you will be warned in the log if this is the case."
Jul 5, 2021 at 15:00