Binary units converter

1
1073741824

When dealing with binary data sizes, units like kibibytes (KiB), mebibytes (MiB), and gibibytes (GiB) are used instead of their decimal counterparts (KB, MB, GB) to provide a more accurate representation of memory sizes in computing. Binary units are based on powers of 2, whereas decimal units are based on powers of 10.

Understanding the difference between binary and decimal units is critical when working with storage and memory in computing. For example: A 1 TB hard drive advertised by a manufacturer is actually around 931 GiB when reported by your operating system, because manufacturers use decimal units (TB), while operating systems typically use binary units (GiB). This knowledge helps avoid confusion, especially when dealing with large data sets, network storage, or purchasing new hardware.

So does my current machine main memory (RAM) size. 32GB becomes 31GiB. 32*(1000^3) / (1024^3). Running free -h / lsmem does show me 31Gi

Formula Reference for Binary Units Conversion

Here's a quick reference for converting between the most commonly used binary units:

From KiB to Bytes

Bytes=KiB×1024

From MiB to KiB

KiB=MiB×1024

From GiB to MiB

MiB=GiB×1024

From TiB to GiB

GiB=TiB×1024

From MiB to MB (Decimal Conversion)

MB=MiB×10241000

From GiB to GB (Decimal Conversion)

GB=GiB×1024210002