This site is version 0.0.1. Most of the code on this site is drafted by an agent and needs review. I apologize for the AI-speak, we are working on rewriting it!
viv-lang.org

Notebooks · posts/wigner-semicircle

The eigenvalues of a random matrix fill Wigner's semicircle

Fill a symmetric matrix with independent random numbers, divide by , and look at its eigenvalues. They do not scatter. They fill the semicircle , whatever distribution the entries came from.

Only the entries' variance matters; these are uniform on , which has variance 1 and looks nothing like a Gaussian. The even moments of the semicircle are the Catalan numbers because counts closed walks that never cross themselves. The tests check the second, fourth and sixth moments (1, 2 and 5), and that no eigenvalue lies beyond .

At the program runs in your browser in about a tenth of a second. The post also shows a recorded run of the same program at (the large setting), compiled to C and run natively; the Jacobi eigensolver costs per sweep, so that run takes minutes. Its histogram is smoother, and its largest eigenvalue in absolute value is .

Look inside this program

  • Atlas

    The program’s map: every function and which calls which.

  • There’s no recorded run of this program yet.

Shift+Enter in a cell runs it and moves to the next. Running a cell runs every cell above it too, as one program.

[1]lines 24–80