Foundations

Architecture

ATOMiK is not Von Neumann. State is reconstructed, not stored.

The fundamental equation

current_state = initial_state accumulator

Commutativity

a ⊕ b = b ⊕ a

Deltas can arrive in any order. No coordination needed between producers.

Associativity

(a ⊕ b) ⊕ c = a ⊕ (b ⊕ c)

Deltas can be grouped and merged in any tree structure. Enables parallel reduction.

Self-inverse

a ⊕ a = 0

Any delta applied twice cancels itself. Duplicate packets are harmless. Undo is free.

Identity

a ⊕ 0 = a

Accumulating zero changes nothing. The accumulator starts empty and grows only with real deltas.

Operations

LOAD

Set initial reference state

reference = value; accumulator = 0

ACCUM

XOR delta into accumulator

accumulator ^= delta

READ

Reconstruct current state

return reference ^ accumulator

SWAP

Atomic snapshot + reset

old = read(); reference = old; accumulator = 0; return old