This is a special post for quick takes by Hastings. Only they can create top-level comments. Comments here also appear on the Quick Takes page and All Posts page.
Language models have come a huge way since 2022. However, remarkably, in 2022 they could reliably write a cholesky decomposition in javascript, but could not reliably write an eigenvalue decomposition. Now, in 2025, they can still reliably write a cholesky decomposition and can't reliably write an eigenvalue decomposition. Hard to say if progress is slower than I thought or linear algebra is deeper than I thought.
Update: with aggressive prompting claude appears to have written an eigenvalue decomposition. This should come with the caveat that the previous best attempt passed all tests by cheating, and so it's possible that I just didn't find the cheat this time.
Claude Code not being able to write an eigenvalue decomposition is very surprising to me! Can you share any more detail? I would take the strong bet I would get it right on the first or maybe second try.
In claude's defense, it kept saying I should use a battle tested numerical library for tasks like this, and suggested nuneric.js. numeric.js also has a broken eigendecomposition routine, it can't handle edge cases like [1 0 0; 0 -1 0; 0 0 1]