7

My question is about possible advantages of writing

$\mbox{\textit{Re}}=\SI{0.137}{}$

instead of

$\mbox{\textit{Re}}=0.137$

Is there any?

7
  • 2
    you don't need \mbox in either case you could just use \textit or better, \mathit Commented Sep 28, 2014 at 10:06
  • 3
    For this purpose, siunitx has \num{<number>} macro so you don't need to skip the unit.
    – percusse
    Commented Sep 28, 2014 at 10:06
  • 1
    You should not be using \SI if you just want a number: they are semantically different.
    – Joseph Wright
    Commented Sep 28, 2014 at 10:20
  • 1
    @Andrestand, you can load the package with the decimalsymbol option, if you are writting in spanish and you don't want to use the international format. Just load \usepackage[decimalsymbol=comma]{siunitx}
    – umarcor
    Commented Sep 28, 2014 at 16:28
  • 1
    @U.Martinez-Corral, thanks, although I use in fact point, despite Spanish babel for some reason switches it to comma.
    – Andrestand
    Commented Sep 29, 2014 at 7:19

1 Answer 1

11

The \num command is provided primarily to allow consistent number formatting with the first argument to \SI. Thus whether you want to use \num is primarily about whether you need that consistent formatting. For example, \num will do things like turn , into . (as standard) to produce normal scientific output even if the input is localised. It will also turn 1.2e3 into 1.2 \times 10^{3} and so forth.

Of course, if you choose to turn off the number parser in siunitx then the format of numbers is the same between $1.23$ and \num{1.23}. (Indeed, while people mainly ask about number formatting the real core point of siunitx is not that but the idea of consistent application of units.)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .