Apex › Data & encoding
How genomes are assembled (de Bruijn graphs)
A sequencer reads millions of short overlapping fragments; reassembling the original is genome assembly. Shred into k-mers, make each (k−1)-overlap a node and each k-mer a directed edge, and reassembly becomes an Eulerian path — walk every edge once (Hierholzer) and the sequence spells back out. Verified: distinct k-mers reconstruct the original exactly, each k-mer used once; but repeated (k−1)-mers branch the graph so several paths are valid (ambiguous) — the real difficulty, fixed by longer reads / larger k. Slide k and watch it snap between exact and ambiguous.
More in Data & encoding
- Encoding
- How a computer stores a fraction (IEEE-754)
- Why encoders use Gray code (one bit at a time)
- Varint & zigzag
- Base58 & Base58Check
- Line coding
- LZ77 compression
- LZW compression
- Burrows-Wheeler
- Move-to-front
- Content-defined chunking
- rsync (delta sync)
- Finite automata (DFA)
- Huffman coding
- How JPEG compresses an image
- How content-aware resize works (seam carving)
- How video inter-frame compression works
- How MP3 shrinks audio (psychoacoustic masking)
- How dithering fakes gray with black & white
- Why 128 isn’t half-bright (gamma)
- Why RGB blends look muddy (OKLab)
- How HDR fits the sun on your screen (tone-mapping)
- Golomb-Rice coding
- Elias γ/δ coding
- Gorilla (time-series)
- COBS (byte stuffing)
- Arithmetic coding
- CRC-32 walk
- Hamming(7,4) code
- Reed-Solomon
- Viterbi / convolutional
- Error control
- How a barcode works (UPC check digit)
- How a QR code is built (Reed-Solomon + masking)