Trouble positioning bodies for Boolean in PartDesign

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
Obliterax
Posts: 2
Joined: Thu May 06, 2021 12:16 am

Trouble positioning bodies for Boolean in PartDesign

Post by Obliterax »

Hi everyone,

I'm trying to figure out how to position one PartDesign part with respect to another so that I can perform a boolean cut. I am trying to make a threaded hole in a part to be 3D printed, but the boolean tool keeps putting the hole somewhere other than where the cutout body is located.
If I'm reading the wiki right, the body that material is being removed from needs to be positioned at the world origin, but not the part that's being removed. That's the way I have it set up now. I also tried it with the cutout part at the origin and the main body elsewhere, but had similar problems.
Tricky Bore.png
Tricky Bore.png (22.8 KiB) Viewed 531 times
If there's an easier way of handling this, I'm open to that, but I'm not using the built-in hole tool because I need to print the screw, too. The file I attached is pre-boolean.

Thanks One Million!
Attachments
Mount m2.FCStd
(616.14 KiB) Downloaded 11 times
chrisb
Veteran
Posts: 54302
Joined: Tue Mar 17, 2015 9:14 am

Re: Trouble positioning bodies for Boolean in PartDesign

Post by chrisb »

Your model doesn't include the boolean cut, so I am guessing: You applied the boolean to the features. This is not allowed, you must apply Part booleans to the bodies. However, it still doesn't work, probably due to some coplanar feature. I have to investigate this further. Can take a while. In the meantime, try turning or lifting the thread ba a minimal amount.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
chrisb
Veteran
Posts: 54302
Joined: Tue Mar 17, 2015 9:14 am

Re: Trouble positioning bodies for Boolean in PartDesign

Post by chrisb »

A recompute shows errors in Sketch001, it has redundant constraints. Furthermore the external line seems to be unneeded, you can use the center for reference instead.

You shouldn't have detached the ShapeBinders from their source, you loose parametricity of the threads.

Bore 1 shows errors with CheckGeometry.

You should fully constrain your sketches. Especially for Core it is important to have some overlap with the thread. This fixes the geometry check. And then the boolean works.

I have not yet performed the cut itself in order to reduce the size of the model.
Attachments
Mount_cb.FCStd
(845.46 KiB) Downloaded 13 times
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
Obliterax
Posts: 2
Joined: Thu May 06, 2021 12:16 am

Re: Trouble positioning bodies for Boolean in PartDesign

Post by Obliterax »

I got it to work the way I wanted it to. It looks like the problem was that the rotations of the body and the bore weren't the same. Once I set the angle to zero and the axis to [0,0,1] for both of them, they ended up where they were supposed to be.

You were totally right about making the core bigger, though. I guess that must be a problem with trying to fit a B-spline to a circle?

Regarding your suggestions: Is there a way to get the original helix into the Bore body? Or can you make a helix in PartDesign mode? I'd have preferred to do that, but I couldn't figure out how. And does the geometry checker work on PartDesign parts, too?

Thanks for your insights!
chrisb
Veteran
Posts: 54302
Joined: Tue Mar 17, 2015 9:14 am

Re: Trouble positioning bodies for Boolean in PartDesign

Post by chrisb »

Obliterax wrote: Fri May 07, 2021 5:43 am I got it to work the way I wanted it to. It looks like the problem was that the rotations of the body and the bore weren't the same. Once I set the angle to zero and the axis to [0,0,1] for both of them, they ended up where they were supposed to be.
Even then not use a Part boolean on a feature, but only on whole bodies.
You were totally right about making the core bigger, though. I guess that must be a problem with trying to fit a B-spline to a circle?
Sort of, but it occurs with simpler shapes too. It is - my guess - the limited precision when calculating planes that just touch. It can happen, that they don't really touch, but that they cross more than once. Something that is not possible in pure geometry.
Is there a way to get the original helix into the Bore body? Or can you make a helix in PartDesign mode?
Yes and yes. You can edit the bodies Group property and add the helix, and you can use the helix feature in the current FreeCAD version. Which shows, how important it is to add the FreeCAD infos to topics.
And does the geometry checker work on PartDesign parts, too?
Yes, on any shape. And probably easyer - and more convincing - would have been to try it; it's only four clicks away.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
drmacro
Veteran
Posts: 9006
Joined: Sun Mar 02, 2014 4:35 pm

Re: Trouble positioning bodies for Boolean in PartDesign

Post by drmacro »

With Geomtry check, it is more thorough with the BOP option ticked.
Star Trek II: The Wrath of Khan: Spock: "...His pattern indicates two-dimensional thinking."
Post Reply