File Size Calculation and Data Storage Units
Convert between bytes, kilobytes, megabytes, and understand the difference between binary and decimal units.
Percentage Calculator
Calculate percentages, increases, decreases, and ratios
Data Storage Units
The distinction between binary (KiB, MiB, GiB) and decimal (KB, MB, GB) units causes confusion in file sizes, storage capacity, and bandwidth calculations.
Binary vs Decimal Units
Binary: 1 KiB = 1,024 bytes (2^10). 1 MiB = 1,048,576 bytes (2^20). 1 GiB = 1,073,741,824 bytes (2^30). Decimal: 1 KB = 1,000 bytes (10^3). 1 MB = 1,000,000 bytes (10^6). 1 GB = 1,000,000,000 bytes (10^9). The difference grows with scale: 1 TB (decimal) is 931 GiB (binary). This is why your "1 TB" hard drive shows ~931 GB in your operating system.
Who Uses Which
Hard drive and SSD manufacturers use decimal units (makes their drives appear larger). Operating systems historically used binary units but labeled them with decimal prefixes. Network speeds use decimal: 100 Mbps = 100,000,000 bits per second. RAM uses binary: 8 GB of RAM = 8 GiB = 8,589,934,592 bytes.
Bandwidth Calculations
Network speeds are measured in bits, storage in bytes. 1 byte = 8 bits. A 100 Mbps connection transfers a maximum of 12.5 MB/s (100/8). In practice, overhead (protocol headers, retransmissions) reduces this by 5-10%. A 1 GB file takes approximately 85 seconds on a 100 Mbps connection: 1,000 MB / 11.75 MB/s effective.
Image and Video File Size Estimation
Uncompressed image size: width × height × bytes per pixel (3 for RGB, 4 for RGBA). A 4000×3000 RGB image = 36 MB uncompressed. JPEG compression typically achieves 10:1, so ~3.6 MB. Uncompressed video: width × height × 3 × fps × seconds. 1080p at 30fps for 60 seconds = 5.6 GB uncompressed. H.264 compression achieves roughly 50:1-200:1 depending on content.
Practical Conversions
Quick mental math: divide bytes by 1 million for MB (close enough for estimation). 15,728,640 bytes ≈ 15 MB. For precise conversion, divide by 1,048,576 for MiB: 15,728,640 / 1,048,576 = 15.0 MiB. For bandwidth: divide Mbps by 8 for MB/s. 50 Mbps ≈ 6 MB/s download speed.
Verwandte Tools
Verwandte Anleitungen
How to Use Scientific Notation and Number Formatting
Scientific notation makes very large and very small numbers manageable. This guide covers notation systems, significant figures, and formatting conventions used in science, engineering, and finance.
Unit Conversion Best Practices for Developers
Incorrect unit conversions have caused spacecraft crashes and medical errors. This guide covers best practices for implementing unit conversions in software, including precision handling and common pitfalls.
Percentage Calculations: Common Formulas and Pitfalls
Percentage calculations appear simple but hide common errors, especially around percentage change, percentage points, and compound percentages. This guide clarifies the math behind everyday percentage problems.
Matrix Operations: A Visual Guide for Developers
Matrices are fundamental to graphics, machine learning, and data processing. This guide explains matrix addition, multiplication, transposition, and inversion with visual examples and practical applications.
Troubleshooting Floating-Point Precision Errors
Floating-point arithmetic produces surprising results that can cause bugs in financial calculations, comparisons, and cumulative operations. This guide explains why these errors occur and how to handle them.