# Expressing computer time units with siunitx

I need to express things like (longhand) 'this fullword contains the elapsed time in units of 1048576 microseconds'.

I would imagine something like '... units of µs × 2²° ...' (horrid superscript, I know) might be an adequate shorthand, and thought of siunitx:

\documentclass{article}
\usepackage[%
binary-units=true,
prefixes-as-symbols=false,
]{siunitx}
\begin{document}
%In units of \si{\mebi\micro\second}. % <= Fails

In units of \si{\mebi\bit}.

In units of \si{\mebi\second}.

In units of \SI{1}{\mebi\second}
\end{document}


It appears that siunitx, reasonably, won't let me mix prefixes:

! siunitx error: "prefix-base-mismatch"
!
! Prefix bases do not match.


Can anyone suggest an adequate notation, and how I might achieve it in siunitx?

-
What's wrong with 'in units of \SI[parse-numbers = false]{2^{20}}{\micro\second}'? –  Joseph Wright Jun 11 '12 at 16:18
How about \DeclareSIUnit{\microsecond}{\ensuremath{\mu}s} \si{\mebi\microsecond}? –  Jake Jun 11 '12 at 16:29
@JosephWright: Nothing. An excellent suggestion! –  Brent.Longborough Jun 11 '12 at 16:43
@Jake: I like that slightly better than Joseph's, as it gives me the flexibility of producing 'Miµs' (as in mimsy). If you'd like to make that an answer, it's got a good chance. After Joseph has had another opportunity to comment. –  Brent.Longborough Jun 11 '12 at 16:46
@Jake That will use the wrong symbol for micro (italic rather than upright by default). If you want to go this way, use \SIUnitSymbolMicro rather than \ensuremath{\mu}. –  Joseph Wright Jun 11 '12 at 17:09

You can use

\DeclareSIUnit{\microsecond}{\SIUnitSymbolMicro s} \si{\mebi\microsecond}


which allows you to type

In units of \si{\mebi\microsecond}.


to get

-
"Prefixes may not be used in combination." - en.wikipedia.org/wiki/Metric_prefix . "mebi (megabinary)" (a number) - en.wikipedia.org/wiki/Mebi-#IEC_standard_prefixes . I would write : In_units_of_mebi_us (u=$\mu$) –  Hans-Peter E. Kristiansen Jul 13 '12 at 1:42
Just to clarify: I think that Mi is a prefix, while mebi is a number. \mu is a prefix. You are not allowed to use two prefixes in combination. Of cause mebi \mu s still needs to be declared in siunitx somehow. –  Hans-Peter E. Kristiansen Jul 13 '12 at 1:52