Reference

Math & engineering notation

Look up symbols, units, probability, vectors and engineering formulas.

Scope and conventions

Common mathematical and engineering notation, with domains, units and assumptions. Estimates and idealized models are labeled; check their assumptions against the system you are describing.

Units & representation

Keep bits and bytes distinct

Notation & units

A byte contains 8 bits. Lowercase b commonly denotes bits and uppercase B bytes; check the producer’s convention.

Fragment

Notation & units · Keep bits and bytes distinct
Follow appearance
GitHub Light
GitHub Dark
Rosé Pine
Catppuccin Mocha
VS Code Dark+
1 B = 8 bits
100 Mb/s ÷ 8 = 12.5 MB/s (before overhead)

Networking rates include protocol/transport effects; application throughput can be lower.

Decimal and binary prefixes

Notation & units

SI prefixes use powers of ten. The storage prefixes k, M and G shown here advance by powers of 1000; IEC binary prefixes Ki, Mi and Gi advance by powers of 1024.

Fragment

Notation & units · Decimal and binary prefixes
Follow appearance
GitHub Light
GitHub Dark
Rosé Pine
Catppuccin Mocha
VS Code Dark+
1 kB = 1000 B       1 KiB = 1024 B
1 MB = 10⁶ B        1 MiB = 2²⁰ B
1 GB = 10⁹ B        1 GiB = 2³⁰ B

Convert time and rates consistently

Notation & units

A rate divides a quantity by time. Convert the time unit before combining arrival rate, duration and concurrency.

Fragment

Notation & units · Convert time and rates consistently
Follow appearance
GitHub Light
GitHub Dark
Rosé Pine
Catppuccin Mocha
VS Code Dark+
1 s = 1000 ms = 10⁶ µs = 10⁹ ns
200 requests/s × 0.050 s = 10 requests

Absolute error, relative error and percentage points

Notation & units

Absolute error retains units. Relative error divides by a nonzero reference magnitude. Percentage-point change subtracts percentages directly.

Fragment

Notation & units · Absolute error, relative error and percentage points
Follow appearance
GitHub Light
GitHub Dark
Rosé Pine
Catppuccin Mocha
VS Code Dark+
absolute error = |estimate - reference|
relative error = absolute error / |reference|
80% -> 90%: +10 percentage points, +12.5% relative

Recognize finite numeric representation

Notation & units

Fixed-width integers have bounded ranges. Floating-point values approximate a discrete set of numbers; many decimal fractions are not represented exactly in binary.

Fragment

Notation & units · Recognize finite numeric representation
Follow appearance
GitHub Light
GitHub Dark
Rosé Pine
Catppuccin Mocha
VS Code Dark+
unsigned b-bit integer: 0 .. 2ᵇ-1
two’s-complement signed: -2ᵇ⁻¹ .. 2ᵇ⁻¹-1

Overflow behavior is language/type dependent. For floating comparisons, choose an error model rather than an arbitrary universal epsilon.