I have an inline equation, well really its just a number with some units, but its sticking awkwardly outside the margins of the text. How can I get it to sit nicely within the margins?
Here's what the code looks like...
In 2008, low temperature electron transport in graphene was shown to be ballistic, with mobilities as high as $200,000\mbox{cm}^2\mbox{V}^{-1}\mbox{s}^{-1}$ \cite{Du2008}. Additionally, graphene is a two-dimension..........
On Sunday, September 30, 2012 12:41:42 PM UTC+1, Tom Sturges wrote:
> I have an inline equation, well really its just a number with some units, but its sticking awkwardly outside the margins of the text. How can I get it to sit nicely within the margins?
> Here's what the code looks like...
> In 2008, low temperature electron transport in graphene was shown to be ballistic, with mobilities as high as $200,000\mbox{cm}^2\mbox{V}^{-1}\mbox{s}^{-1}$ \cite{Du2008}. Additionally, graphene is a two-dimension..........
> Thanks for any help =)
Howsabout:
\documentclass{article}
\usepackage{siunitx}
\begin{document}
In 2008, low temperature electron transport in graphene was shown to be ballistic, with mobilities as high as \SI{20}{\metre^2\per\volt\second}~\cite{Du2008}.
Additionally, graphene is a two-dimension..........
\end{document}
Better to use \metre\squared\per\volt\second (or an abbreviated form) as
it leaves siunitx free to work 'magic' with the display of the unit.
-- Joseph Wright
> > > Better to use \metre\squared\per\volt\second (or an abbreviated form) as
> > > it leaves siunitx free to work 'magic' with the display of the unit.
> > Thanks. I don't use the siunitx package and I obviously haven't studied the documentation!
> > Regards,
> > Marc van Dongen
> Joseph and Mark, thanks for the solution! That makes a lot more sense than what I'm doing. Appreciated!
oh one other related thing. that works fine but if i wanted to display 200,000 how would i do that? when i write SI{200,000}{\.......\} it shows up as 200.000 (a decimal point, not a comma)
> > > > Better to use \metre\squared\per\volt\second (or an abbreviated form) as
> > > > it leaves siunitx free to work 'magic' with the display of the unit.
> > > Thanks. I don't use the siunitx package and I obviously haven't studied the documentation!
> > > Regards,
> > > Marc van Dongen
> > Joseph and Mark, thanks for the solution! That makes a lot more sense than what I'm doing. Appreciated!
> oh one other related thing. that works fine but if i wanted to display 200,000 how would i do that? when i write SI{200,000}{\.......\} it shows up as 200.000 (a decimal point, not a comma)
sorry actually that fix didn't work, it still overspills =S and if i include the tilda bit at the end it just drags up even more stuff out of line!
Tom Sturges <sturges....@gmail.com> wrote:
> oh one other related thing. that works fine but if > i wanted to display 200,000 how would i do that? > when i write SI{200,000}{\.......\} it shows up as > 200.000 (a decimal point, not a comma)
Write numbers without the comma for separating thousands:
\SI{200000}{...}
There are options for automatically inserting a separator
for thousands and the default choice is a thin space, which
is the correct separator to use according to ISO and SI
standards, AFAIK.
On 2012-09-30, Tom Sturges <sturges....@gmail.com> wrote:
> On Sunday, 30 September 2012 16:24:04 UTC+1, Tom Sturges wrote:
>> On Sunday, 30 September 2012 14:00:39 UTC+1, Marc van Dongen wrote:
>> > On Sunday, September 30, 2012 1:41:49 PM UTC+1, Joseph Wright wrote:
>> > > On 30/09/2012 13:34, Marc van Dongen wrote:
>> > > > \SI{20}{\metre^2\per\volt\second}~\cite{Du2008}.
>> > > Better to use \metre\squared\per\volt\second (or an abbreviated form) as
> oh one other related thing. that works fine but if i wanted to display 200,000 how would i do that? when i write SI{200,000}{\.......\} it shows up as 200.000 (a decimal point, not a comma)
Sounds like it is using European rather than US conventions. Try
SI{200.000}{\.......\}
unruh <un...@invalid.ca> wrote:
> On 2012-09-30, Tom Sturges <sturges....@gmail.com> wrote:
> > On Sunday, 30 September 2012 16:24:04 UTC+1, Tom Sturges wrote:
> >> On Sunday, 30 September 2012 14:00:39 UTC+1, Marc van Dongen wrote:
> >> > On Sunday, September 30, 2012 1:41:49 PM UTC+1, Joseph Wright wrote:
> >> > > On 30/09/2012 13:34, Marc van Dongen wrote:
> >> > > > \SI{20}{\metre^2\per\volt\second}~\cite{Du2008}.
> >> > > Better to use \metre\squared\per\volt\second (or an abbreviated form)
> >> > > as
> > oh one other related thing. that works fine but if i wanted to display
> > 200,000 how would i do that? when i write SI{200,000}{\.......\} it shows
> > up as 200.000 (a decimal point, not a comma)
> Sounds like it is using European rather than US conventions. Try
> SI{200.000}{\.......\}
The convention siunitx for inputting numbers is that /no/
group separator (for thousands) is used, but a space is
allowed.
The comma or period is used to separate the integer from the
fractional part and is translated to the preferred separator
(default is period).
(with thin spaces, not interword spaces). If one prefers to always
have the comma as group sepqrator (which wouldn't follow ISO or SI standard, AFAIK), then
\sisetup{group-separator={,}}
can be issued in the document preamble.
The decimal separator is chosen in a similar way:
\sisetup{output-decimal-marker={,}}
would be used in continental Europe. The advantage is that
simply changing these options and leaving untouched the body
of the document, the output can change depending on the
required standard.