# siunitx: localisation not working

I have just discovered the siunitx package and want to use it in a German language document. Unfortunately, I can't get the German word 'bis' instead of 'to' with the \SIrange command:

\listfiles
\documentclass{beamer}
\usepackage[ngerman]{babel}
\usepackage{siunitx}

\begin{document}
\begin{frame}
$\dot{V}=\SIrange{0}{650}{\litre\per\hour}$
\end{frame}
\end{document}


What's wrong?

• I've marked your inline code with backticks . Mar 15, 2011 at 11:35
• In my (short) experience, it's dangerous to use spacing characters such as \,, \;, ~, etc. in the range-phrase, because they can cause range commands to not line break/word wrap and go beyond the right margin. It's better to use just blanks (e.g. range-phrase={ bis } instead of range-phrase={\,bis\,}). Feb 11, 2014 at 19:14

Use the range-phrase option, either for the package or the \SIrange command. Note that you have to add the spaces before and after bis, e.g. using \, for 1/2 space.

\listfiles
\documentclass{beamer}
\usepackage[ngerman]{babel}
\usepackage[range-phrase={\,bis\,}]{siunitx}

\begin{document}
\begin{frame}
$\dot{V}=\SIrange{0}{650}{\litre\per\hour}$
\end{frame}
\end{document}

• If you're going to have lots of similar commands, it might be best to use the \sisetup command, rather than passing them all as package options... Mar 15, 2011 at 11:00
• @Martin: Thanks, but according to the documentation this should be done automatically if the translator' package is present on the system. Mar 15, 2011 at 11:22
• @Alexander: I thought something like this exists. You should mention such things in the main question. I personally prefer to do thing by myself to be sure they work. Mar 15, 2011 at 11:34
• @Alexander: The automated system seems to have a slight flaw, but I'm not sure if that is siunitx or translator. I'll look at it later today. Mar 15, 2011 at 11:44
• @Joseph: The "flaw" is that translator doesn't know the language as ngerman is not a class option. You must either use ngermanas class option, or load translator before siunitx with the option ngerman, or activate after siunitx the language \uselanguage{German} \languagealias{ngerman}{German} May 17, 2011 at 9:31