Nice visualizations! Brings back fond memories of playing with Maplesoft in the 1990s to build up intuition about physical systems. In a nonlinear optimization class I was taking, I wanted to find the optimal truss configuration of a stack of hexapods [1] just as you're doing, but I got stuck on the Lagrange multipliers and gave up. You've shown it's much easier today using autodiff.
[1] https://www.aerotech.com/products/hexapods