1

is there a way to set automaticly comma-decimal separator in latex in the "environment" $$ ? I mean having a 1,23 instead 1.23 by typing $1.23$. I tried to set by my own without any success, by inserting

 \sisetup{output-decimal-marker={,}}. 

But it didn't work. Any ideas? Thank you

percusse
  • 157,807
Jordan_b
  • 283
  • 1
    If you always write $\num{1.23}$ instead of $1.23$ that would happen with the setting you have, but I assume that is not really an option for you? – moewe Jun 19 '18 at 18:25
  • I use \num{123456} for large numbers, but doing it for all of the $1.23$ it's an heavy work. I should consider to keep it as it is, if it's not possible. Thanks for the help. – Jordan_b Jun 19 '18 at 18:31
  • 1
    I guess with a bit of RegEx-search-and-replace it should be doable. Not that I would recommend it, but you could try \mathcode`\.="8000 {\catcode`\.=13 \expandafter }\expandafter \newcommand\noexpand.{{,}} or \mathcode`\.="8000 \begingroup \catcode`\.=13 \gdef.{{,}} \endgroup – moewe Jun 19 '18 at 18:35
  • Even better: https://tex.stackexchange.com/q/97571/35864 – moewe Jun 19 '18 at 18:38
  • have you consulted the siunitx manual about Localisation? – naphaneal Jun 19 '18 at 18:47
  • I tried with moewe answer and it worked. thanks – Jordan_b Jun 19 '18 at 19:40
  • It' s not a duplicate becouse I have ,,, instead of ... in equation environment, how to fix it? with \dots doesn't seem working well. – Jordan_b Jun 20 '18 at 14:58

0 Answers0