ALGEBRA

Median Algebra Explorer

Structure Presets:
Selected Triple: x: A y: B z: C → Median m(x,y,z): D Click nodes to set x, y, or z
Node x
Node y
Node z
Unique Median m
Computed Median
D
Pairwise Distance Sum
6
d(x,m) + d(y,m) + d(z,m)
3
Ternary Status
Unique Compromise

Axiomatic Foundations

Ternary Algebra (Birkhoff-Kiss)
1. Majority / Idempotence
m(x, x, y) = x & m(x, y, x) = x
✓ Verified
2. Full Permutation Symmetry
m(x,y,z) = m(y,x,z) = m(x,z,y)
✓ Invariant
3. Distributive Property
m(m(x,w,y), u, z) = m(m(x,u,z), w, m(y,u,z))
✓ Satisfied
4. Geodesic Intersection
I(x,y) ∩ I(y,z) ∩ I(x,z) = {m}
✓ Unique {D}
Shortest-Path Distance Matrix d(u,v)
Ternary Computation Log
Theoretical Context: A median algebra is an algebraic system satisfying ternary consensus rules. In every median graph (such as trees and hypercubes), the ternary operation $m(x,y,z)$ corresponds exactly to the unique node lying simultaneously on geodesics between all pairs.

Graph intervals, ternary medians and source proof limits

Read the explanation

This educational algebra tool starts with a star tree: leaves A, B and C each connect by one unweighted edge to center D. Every leaf pair is two graph hops apart. Their geodesic intervals share only D, so D is the ternary median. The three pairwise distances sum to six; distances from the leaves to D sum to three. The diagram uses a common one hundred sixty pixels per edge and each drawn edge means one graph hop. The source graph’s arbitrary on-screen node coordinates do not themselves define its metric: dragging changes the drawing, not the hop distances. The two by two grid preset selects vertices zero zero, one zero and zero one. Distances from zero zero to the other two are one hop each; the diagonal pair is two hops apart. That diagonal has two shortest paths, one through zero zero and one through one one. Its interval therefore contains all four vertices. Intersecting it with the other two intervals leaves only zero zero. The pairwise sum is four and the median-distance sum is two. Here every square edge represents one hop on a common one hundred eighty pixel drawing scale. Multiple shortest paths do not imply multiple medians for this triple. In the cube preset, vertices one zero zero, zero one zero and zero zero one each differ from zero zero zero in one bit. Their pairwise Hamming distances are all two; their coordinate-wise majority is zero zero zero, the median. Common eighty pixels per graph hop gives a four hundred eighty pixel pairwise-sum bar for six hops and a two hundred forty pixel median-radius-sum bar for three. The source voting graph is not automatically a median graph. When its interval intersection is empty, the program instead chooses the first minimum-distance-sum vertex and still labels it unique. That fallback is not proof of a unique geodesic median. Its distributive badge checks only one selected sample, not every axiom instance. The tool is a finite illustrative explorer, not a general theorem prover.

Super generates helpful tools and automates fact-checking across the internet proactively. If you enjoyed this tool, build your own with Super and share it with a friend.