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]
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]
The prompt that got it in the end is here:
https://claude.ai/share/eb3b2054-a1ee-45b6-b040-943bc5fbbd74