News for hackers. Stuff that matters.
Re:CADmium: A Local-First CAD Program Built for the Browser by alright2565 on Tuesday May 21, 2024 @01:21PM (#40431230)
I think this is amazing. I'd love to get to the point where we are with open source EDA with open source physical CAD.

> Another downside is that solving this kind of matrix equation gets prohibitively slow when you have a lot of unknowns, which gives rise to the conventional wisdom that individual sketches should be small and simple.

I've gotten quite deep into this, and this is really not a problem in practice[1]

1. FreeCAD's main issues with constraint performance come from a redundant & unnecessary GUI layout algorithm, which falls over with just a few hundred constraints.

2. Eigen's sparse QR decomposition benchmarks at 18s for 2200 constraints, which is really not too bad

3. There are sparse QR decomposition libraries that can handle 500k-1M constraints in about 18s. I can't imagine a CAD sketch with more than a few thousand constraints.

[1]: https://github.com/FreeCAD/FreeCAD/issues/11498#issuecomment...

Re:CADmium: A Local-First CAD Program Built for the Browser by JBits on Tuesday May 21, 2024 @05:26PM (#40434185)
Without knowing anything about CAD, it's surprising to me that the author didn't try any of these matrix solvers. Particularly since the case of non square matrices with iterative methods is common to many fields.
Re:CADmium: A Local-First CAD Program Built for the Browser by aiksiongkoh on Tuesday May 21, 2024 @07:36PM (#40435575)
OndselSolver at https://github.com/Ondsel-Development/OndselSolver can do redundant constraint removal and handle under constrained systems readily using direct Gauss Elimination on sparse matrices. It is used in FreeCAD and Ondsel ES for Assembly constraints.