TL:DR: Is there a (free, hopefully open source) C++ or C# library to do both symbolic calculation and non-linear equation solving?


I am trying write a software library to solve a particular kind of mechanical linkage. As an exercise, I am trying to implement a mechanism to solve a system of N-bar closed linkage. The i-th joint connects the i-th link with i-1-th link (or N-1th link, if i = 0), and can therefore be associated to a transformation matrix T_i between the two links. T_i contains trigonometric functions of the respective link's angle. The matrices satisfy:

T_0 * T_1 * ... * T_(N-1) = I

where I is an identity matrix. In my case, all links' length are known, and one of the angles is the input.

Because the above operation involves 4x4 matrices, there will be 16 equations with N-1 unknown variables. However, the exact equations depend on the number of links. Therefore, I thought I would need a (free, hopefully open source) library which can do both symbolic calculation and non-linear equation solving. Is there such a software library? I am also happy to hear other suggestions to do the implementation.

(There may be an underdetermined system if N > 16, but it is outside the scope of the current question).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.