Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

In most language, long numbers are split into groups of three digits, to increase readability.

In Dutch (my native language), 1000000 is usually written as 1 000 000. In English, this would be 1,000,000.

Now, I would like to know how to use this kind of formatting in LaTeX. I searched google, but I only found some articles that explain how to split very long numbers over multiple lines, which is not what I need.

Is there a package that does this automatically? Or a certain tag I can use for this?

share|improve this question

migrated from stackoverflow.com Apr 23 '13 at 15:19

This question came from our site for professional and enthusiast programmers.

    
sorry I didn't realize it was latex, anyway searching "number formatting" will help you find something instead of split. for example this post: latex-community.org/forum/viewtopic.php?f=44&t=9548 hope it helps –  aleation Apr 23 '13 at 9:45
3  
siunitx provides this functionality. –  Werner Apr 23 '13 at 14:20
2  
Or numprint –  Joseph Wright Apr 23 '13 at 15:21
add comment

1 Answer 1

up vote 11 down vote accepted

Normally you would use \, for a thin space $1\,000\,000$ If you are entering that by hand. As noted in the comments siunitx or other packages have the ability to parse the bare number 1000000 and then format it according to formatting parameters with commas or thin spaces, so it depends what you want to do (and where the numbers are generated). Whether it is a few numbers in a hand authored text or if you are typesetting thousands of numbers in table data where hand editing to add grouping separator is not really an option.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.