General ⇒ Thousands separator
-
- Posts: 10
- Joined: Wed Mar 19, 2008 11:04 pm
Thousands separator
I want to use thousands separator in the numbers. For example, write 10123456.789012, and show 10,123,456.789012
I tried to use numprint package, but it show thousand separator after decimal point. eg. 10,123,456.789,012
Do you know any package???
Thanks!
Learn LaTeX easily with newest books:
The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis
The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more
LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis
Thousands separator
Code: Select all
\npthousandsep{,}\npthousandthpartsep{}\npdecimalsign{.}
I've seen in other thread that you load the spanish language with babel. In this case, the above way of writing decimal numbers is not in accordance with Spanish typography. See the document ortomatem.pdf, by Javier Bezos, about ortotypography in mathematics. I quote two paragraphs from page 17 of this document:
So, when writing in spanish, I would suggest the following settings for numprint:h) El separador decimal es la coma: 3,142.
i) Antes y después de la coma, se pueden separar los dígitos en grupos de tres
con espacios finos: 2,718 281 8. Si se emplean estos espacios finos, se admite su
supresión si la parte entera o la decimal sólo tienen cuatro cifras: 1200, 3,1415.
Code: Select all
\npthousandsep{\,}\npdecimalsign{,}
-
- Posts: 10
- Joined: Wed Mar 19, 2008 11:04 pm