Sketcher constraints have non-unique solution

About the development of the Part Design module/workbench. PLEASE DO NOT POST HELP REQUESTS HERE!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
ubit
Posts: 57
Joined: Mon Dec 15, 2014 8:58 am

Sketcher constraints have non-unique solution

Post by ubit »

Hi,

whenever i have some problems when e.g. using tangential constraints in combination with parameters from a spreadsheet. Mostly there a more than one solutions to a set of constraints. A tangent to a circle can fit 2 points on the circle.

Helpful would be a constraint "without value" e.g. define a horizontal or vertical constraint with "has to be >=0" or "has to be<=0" to make the soltion unique. Is something like this possible? Or "in development"? Is the solver able to use something like this? Or is there another solution?

See the attached example:
tangent.jpg
tangent.jpg (57.29 KiB) Viewed 1120 times
This should be a clamp that connects to tubes. The clamp "opening" is set to a specific width - smaller than the tube diameter - constraint by construction lines that are tangential to the tips of the clamp (i have marked it with arrows). But there are 2 solutions. One where the inner circle of the clamp goes over 180° and one where it has less than 180°. If i change parameters something like this can happen:
tangent2.jpg
tangent2.jpg (34.5 KiB) Viewed 1120 times
Obviously this is a correct solution for the constraints. But it does not work for the intended purpose. If i could define a constraint that sets the distance between the center of the circle and the tangent points to be ">0" everything would be fine.

But i did not find a function like this. Am i missing something? Or is there another way to ensure the "correct" solution? BTW: The message from the solver that the sketch is fully constraint is WRONG! It is NOT as there are (at least) 2 possible solutions.

Ciao, Udo
chrisb
Veteran
Posts: 54289
Joined: Tue Mar 17, 2015 9:14 am

Re: Sketcher constraints have non-unique solution

Post by chrisb »

Currently it is not possible to enter inequalities as constraints. The problem has been discussed in the forum, e.g. here: https://forum.freecadweb.org/viewtopic. ... t=infinite
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
Post Reply