Sketcher bug, says is fully constrained when it is not

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
User avatar
bejant
Posts: 5953
Joined: Thu Jul 11, 2013 3:06 pm

Re: Sketcher bug, says is fully constrained when it is not

Postby bejant » Tue Sep 10, 2019 9:44 pm

freecc wrote:
Tue Sep 10, 2019 4:52 pm
move the vertical lines back and forth a little bit as you wish, then apply a 8mm horizontal constraint to the horizontal line. Now drag the horizontal line up and down with one of the vertical lines. The horizontal constraint disappears.
Thanks - I can reproduce this too (only occasionally) and for me the 8 mm Horizontal Distance Constraint doesn't only disappear - it gets deleted.

After dragging the vertical line segments and then applying the 8 mm Horizontal Distance Constraint the Solver correctly reports that I have 1 DOF remaining. If drag one of the vertical line segments (I used the right one), the Solver incorrectly Fully Constrains the Sketch. Now, while sometimes after dragging a bit more, the Solver correctly reverted to Under-constrained with 1 DOF.

It sure is a weird bug...
freecc
Posts: 158
Joined: Wed Feb 21, 2018 4:17 pm

Re: Sketcher bug, says is fully constrained when it is not

Postby freecc » Tue Sep 10, 2019 11:09 pm

bejant wrote:
Tue Sep 10, 2019 9:44 pm
freecc wrote:
Tue Sep 10, 2019 4:52 pm
move the vertical lines back and forth a little bit as you wish, then apply a 8mm horizontal constraint to the horizontal line. Now drag the horizontal line up and down with one of the vertical lines. The horizontal constraint disappears.
Thanks - I can reproduce this too (only occasionally) and for me the 8 mm Horizontal Distance Constraint doesn't only disappear - it gets deleted.

After dragging the vertical line segments and then applying the 8 mm Horizontal Distance Constraint the Solver correctly reports that I have 1 DOF remaining. If drag one of the vertical line segments (I used the right one), the Solver incorrectly Fully Constrains the Sketch. Now, while sometimes after dragging a bit more, the Solver correctly reverted to Under-constrained with 1 DOF.

It sure is a weird bug...
another scenario that I get when moving the vertical lines is that the horizontal constraint gets deleted but the DOF remains at 1 when it should be 2. After some more moving up and down with the vertical lines it becomes 2 DOF which is correct.
User avatar
bejant
Posts: 5953
Joined: Thu Jul 11, 2013 3:06 pm

Re: Sketcher bug, says is fully constrained when it is not

Postby bejant » Wed Sep 11, 2019 3:02 pm

Notes added to existing tickets:
issue #3791 and issue #4032
openBrain
Posts: 2382
Joined: Fri Nov 09, 2018 5:38 pm

Re: Sketcher bug, says is fully constrained when it is not

Postby openBrain » Wed Sep 11, 2019 4:05 pm

bejant wrote:
Wed Sep 11, 2019 3:02 pm
Notes added to existing tickets:
issue #3791 and issue #4032
As said, I think that issue #4032 has the same root cause as issue #3976, i.e. edges that are tangent by design and not by constraint. ;)
User avatar
bejant
Posts: 5953
Joined: Thu Jul 11, 2013 3:06 pm

Re: Sketcher bug, says is fully constrained when it is not

Postby bejant » Wed Sep 11, 2019 9:57 pm

openBrain wrote:
Wed Sep 11, 2019 4:05 pm
i.e. edges that are tangent by design and not by constraint.
I was thinking here there initially is no tangency. The vertical edges aren't tangent to the arc until Tangency Constraints are applied or until the 8 mm Horizontal Distance Constraint is added to the horizontal line segment. Am I missing something?
openBrain
Posts: 2382
Joined: Fri Nov 09, 2018 5:38 pm

Re: Sketcher bug, says is fully constrained when it is not

Postby openBrain » Thu Sep 12, 2019 9:43 am

bejant wrote:
Wed Sep 11, 2019 9:57 pm
I was thinking here there initially is no tangency. The vertical edges aren't tangent to the arc until Tangency Constraints are applied or until the 8 mm Horizontal Distance Constraint is added to the horizontal line segment. Am I missing something?
No that's it. 8mm is a special value that makes arc and lines tangent indirectly without having tangent constraints applied. This case seems to be wrongly handled by the solver. ;)