sketcher: changing angle results in unresolvable sketch

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!
Post Reply
User avatar
uwestoehr
Veteran
Posts: 4960
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

sketcher: changing angle results in unresolvable sketch

Post by uwestoehr »

I stumble frequently over cases when I suddenly are in an unresolvable sketch state. I found now a reproducible case:

- open the attached test file:
Sketch-Array-bug-FC-018-result.FCStd
test case
(10.98 KiB) Downloaded 18 times
- there is only one angle constraint. Change it to -45°

result: your sketch became unresolvable.

The point is that if the solver fails, the input should be ignored and the former (last resolvable state should be kept).
(I don't understand why the solver fails because it should be geometrically possible. However, this is not the point.)

OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.16117 (Git)
Build type: Release
Branch: releases/FreeCAD-0-18
Hash: dbb4cc6415bac848a294f03b80f65e888d531742
Python version: 3.6.6
Qt version: 5.6.2
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: German/Germany (de_DE)
chrisb
Veteran
Posts: 51227
Joined: Tue Mar 17, 2015 9:14 am

Re: sketcher: changing angle results in unresolvable sketch

Post by chrisb »

This seems to be indeed a problem. If I change the unconstraint arcs as shown in the image, I can change the angle to a value of -45. I will try to simplify the sketch. It seems too complicated to me to help Abdullah to comfortably find the problem.
Attachments
Bildschirmfoto 2019-06-28 um 22.24.12.png
Bildschirmfoto 2019-06-28 um 22.24.12.png (27.34 KiB) Viewed 766 times
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
chrisb
Veteran
Posts: 51227
Joined: Tue Mar 17, 2015 9:14 am

Re: sketcher: changing angle results in unresolvable sketch

Post by chrisb »

Bildschirmfoto 2019-06-28 um 22.57.33.png
Bildschirmfoto 2019-06-28 um 22.57.33.png (11.48 KiB) Viewed 763 times
The problem seems to come from the circles getting negative radius values. In the attached example the same issue occurs if you change the length constraint to 50mm.

The error does not occur if I change one of the slots to a circle.
Abdullah wrote:ping
Attachments
solver_issue_cb.FCStd
(5.57 KiB) Downloaded 15 times
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
chrisb
Veteran
Posts: 51227
Joined: Tue Mar 17, 2015 9:14 am

Re: sketcher: changing angle results in unresolvable sketch

Post by chrisb »

A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
chrisb
Veteran
Posts: 51227
Joined: Tue Mar 17, 2015 9:14 am

Re: sketcher: changing angle results in unresolvable sketch

Post by chrisb »

I could simplify it even further. This sketch contains only 4 elements.

- Load file
- edit sketch
- change dimension to 50
Bildschirmfoto 2019-06-28 um 23.26.36.png
Bildschirmfoto 2019-06-28 um 23.26.36.png (11.01 KiB) Viewed 751 times
Attachments
solver_issue_cb_2.FCStd
(5.34 KiB) Downloaded 18 times
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
User avatar
uwestoehr
Veteran
Posts: 4960
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: sketcher: changing angle results in unresolvable sketch

Post by uwestoehr »

chrisb wrote: Fri Jun 28, 2019 9:27 pm I could simplify it even further.
Many thanks Chris for having a look and providing a simple test case.
Post Reply