0

I am writing a basic CAD application where a user can create 2D constraints between points.

There will be a number of different constraint types and so I am looking for a free general constraints solver library which can handle a few (~20) simple non-linear constraints.

My initial searches came across the Cassowary Algorithm which works great for linear constraints (i.e. x2 = x1 + distance) but fails to handle non-linear ones (x2 + y2 = distance).

Ideally I would like the library to be as lightweight as possible (header only would be even better), fast (as I would like to update the point's positions as the user moves a point around) and in either C or C++.

1 Answer 1

0

Google OR-Tools is a software suite for optimization, containing many different solvers.

The CP-SAT Solver is a non-linear solver, ideal for my use.

1
  • Welcome to Software Recommendations! While it obviously must match your requirements as you self-answer, you didn't even include where to find it. Could you please edit your answer and add a few details? For a guide, see e.g. our discussion on what makes an answer high quality. Thanks!
    – Izzy
    Mar 15, 2022 at 21:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.