That says all three types of calculation are potentially valid!
And as we are talking about files, you might assume that we should be
talking about storage calcuations (base 10).
But I would suggest that in terms of people interacting with the repository,
knowing the download size - the actual number of bytes [to be] transferred -
is more relevant (base 2).
Although anything *else* is wrong, there isn't a clear single definition
that is 'correct'.
I wouldn't want to try to argue for a preference either way, but if there
isn't a strong consensus on one calculation, maybe it should be a
configurable option to choose the calculation?
G
On 11 May 2011 20:55, stuart yeates <[email protected]> wrote:
> The correct terminology and abbreviations are explained at:
>
> https://secure.wikimedia.org/wikipedia/en/wiki/Megabyte
>
> anything else is just wrong.
>
> cheers
> stuart
>
> On 12/05/11 00:32, Richard, Joel M wrote:
> > Good morning!
> >
> > We got a question from a user:
> >
> > On the following URL [redacted], there is a description of the
> files,
> > namely the size that is expressed in MB. I'd like to know if that
> > size is calculated using base 10 or base 2 mathematics.
> >
> > Digging into the code, I find this comment for
> org/dspace/app/util/Util.java
> >
> > /**
> > * Formats the file size. Examples:
> > *
> > * - 50 = 50B
> > * - 1024 = 1KB
> > * - 1,024,000 = 1MB etc
> > *
> > * The numbers are formatted using java Locales
> > *
> > * @param in The number to covnert
> > * @return the file size as a String
> > */
> > public static String formatFileSize(double in) {
> >
> > That's some some funky math! it divides bytes by 1,024,000 to get MB, and
> 1,024,000,000 to get GB. So it's neither base 2 math nor base 10, but a
> combination of both.
> >
> > Can anyone make a strong argument for requesting this be changed to
> either pure base 10 math (divide by 1,000,000 to Mebibytes / MiB) or pure
> base 2 (divide by 1,048,576 to get Megabytes / MB). I prefer the latter,
> myself.
> >
> > --Joel
> >
> > Joel Richard
> > IT Specialist, Web Services Department
> > Smithsonian Institution Libraries | http://www.sil.si.edu/
> > (202) 633-1706 | [email protected]
> >
> >
> >
> >
> >
> >
> ------------------------------------------------------------------------------
> > Achieve unprecedented app performance and reliability
> > What every C/C++ and Fortran developer should know.
> > Learn how Intel has extended the reach of its next-generation tools
> > to help boost performance applications - inlcuding clusters.
> > http://p.sf.net/sfu/intel-dev2devmay
> > _______________________________________________
> > Dspace-general mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/dspace-general
> >
>
>
> --
> Stuart Yeates
> Library Technology Services http://www.victoria.ac.nz/library/
>
>
> ------------------------------------------------------------------------------
> Achieve unprecedented app performance and reliability
> What every C/C++ and Fortran developer should know.
> Learn how Intel has extended the reach of its next-generation tools
> to help boost performance applications - inlcuding clusters.
> http://p.sf.net/sfu/intel-dev2devmay
> _______________________________________________
> Dspace-general mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/dspace-general
>
------------------------------------------------------------------------------
Achieve unprecedented app performance and reliability
What every C/C++ and Fortran developer should know.
Learn how Intel has extended the reach of its next-generation tools
to help boost performance applications - inlcuding clusters.
http://p.sf.net/sfu/intel-dev2devmay
_______________________________________________
Dspace-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-general