Problem with repetitive object coming from different sketches

Post here for help on using FreeCAD's graphical user interface (GUI).
pablin
Posts: 8
Joined: Tue Jan 10, 2017 4:38 pm

Problem with repetitive object coming from different sketches

Postby pablin » Tue Jan 10, 2017 5:08 pm

Hello
I am new to FreeCAD but very impressed by the software, Thank!!!

OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.16.6706 (Git)
Build type: Release
Branch: releases/FreeCAD-0-16
Hash: f86a4e411ff7848dea98d7242f43b7774bee8fa0
Python version: 2.7.8
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 6.8.0.oce-0.17

My problem: I can't manage to achieve drawing a part that is very repetitive:
Here is a view of the final shape of the object
Dsn001_SbsBseGeoA1Wal004bTopSdeCrnPadCtrTopSdeCrn_017011017.png
Dsn001_SbsBseGeoA1Wal004bTopSdeCrnPadCtrTopSdeCrn_017011017.png (42.66 KiB) Viewed 367 times


The problem is that the pad function didn't work for all sub parts of the object as seen here
Dsn001_SbsBseGeoA1Wal004bTopSdeCrnPadCtrTopSdeCrn_3DV_017011017.png
Dsn001_SbsBseGeoA1Wal004bTopSdeCrnPadCtrTopSdeCrn_3DV_017011017.png (207.79 KiB) Viewed 367 times


The way I had built it here is by drawing 5 sketches for the 5 different sub-parts of the object and then used the transformation, as you can see form the file
The attachment Dsn001_SbsBseGeoA1Wal004bTopSdeCrnPadCtrTopSdeCrn_017011017.FCStd is no longer available


I tried other options, such as making different sketches and using symetry or array, but FreeCAD would freeze when reaching the 77 repeats of the most commun sub-part...

Could someone help me?
Thanks a lot
Attachments
Dsn001_SbsBseGeoA1Wal004bTopSdeCrnPadCtrTopSdeCrn_017011017.FCStd
(287.71 KiB) Downloaded 15 times
User avatar
ppemawm
Posts: 224
Joined: Fri May 17, 2013 3:54 pm
Location: Manhattan New York

Re: Problem with repetitive object coming from different sketches

Postby ppemawm » Tue Jan 10, 2017 7:28 pm

pablin wrote: and then used the transformation

If you check each of your transformations with Part=>Check Geometry (Run BOP check true in Edit Parameters/Mod/Part) you will find that none are valid solids. The problem is that the transformations either overlap or are touching (within tolerance allowances). A workaround is to increase the transformation length a slight amount:
Capture.JPG
Capture.JPG (135.4 KiB) Viewed 360 times


[EDIT] Note also that you have "forked" your model. Each pad should be generated from the last multi-transformation before the next multi-transformation. The dependency graph should be linear unless you actually want separate solids for each transformation.

Capture2.JPG
Capture2.JPG (53.28 KiB) Viewed 353 times

OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.16.6706 (Git)
Build type: Release
Branch: releases/FreeCAD-0-16
Hash: f86a4e411ff7848dea98d7242f43b7774bee8fa0
Python version: 2.7.8
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 6.8.0.oce-0.17
pablin
Posts: 8
Joined: Tue Jan 10, 2017 4:38 pm

Re: Problem with repetitive object coming from different sketches

Postby pablin » Wed Jan 11, 2017 4:32 pm

Hi
thanks a lot for your answer. That indeed solves the problem. The only thing I was wondering is if that would have any impact on the 3D printing of the object, ie will there be some space between lines (I guess no, but would the printer accept such an object)?

The other question is what you would advise to be able to correctly draw this object. I tried different options and can't find a correct one...

Thanks in advance for your help.

Pablo
OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.16.6706 (Git)
Build type: Release
Branch: releases/FreeCAD-0-16
Hash: f86a4e411ff7848dea98d7242f43b7774bee8fa0
Python version: 2.7.8
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 6.8.0.oce-0.17
User avatar
NormandC
Posts: 12077
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Problem with repetitive object coming from different sketches

Postby NormandC » Wed Jan 11, 2017 6:04 pm

Hello Pablo,

When working with multitransform features, I found that it's much more reliable to cut away material than to add material.

So create a thick filled block on top of your base plate, then create pockets inside it that you'll then use for multitransforms. The important thing is to work in sequence: sketch --> pocket1 --> multitransform --> sketch --> pocket2 --> multitransform --> repeat.

To work around the bug with occurrences sharing coplanar faces, make sure that the width of your sketch profile is less than the distance between occurrences. This means you may have to add pockets to remove leftover material.

Let me know if it's not clear for you and I'll try to provide an example file tonight.
User avatar
NormandC
Posts: 12077
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Problem with repetitive object coming from different sketches

Postby NormandC » Thu Jan 12, 2017 3:04 am

I got it. Actually I had the idea 2 minutes after I posted, but I didn't have time to try it until now.

The trick is to use a combination of pads and pockets.

  1. We start by building a thick hollowed out block over the base plate:
    FC_Pablin_multitransform_02.png
    FC_Pablin_multitransform_02.png (17.8 KiB) Viewed 298 times

     
  2. Next we create a sketch at the top corner.
    FC_Pablin_multitransform_03.png
    FC_Pablin_multitransform_03.png (19.74 KiB) Viewed 298 times

     
  3. We pocket the sketch (for the length of the pocket, I used Expressions and set the formula Pad001.Length). Then we create a MultiTransform feature with 4 steps: two LinearPatterns and two Mirrored features. The two linear patterns are to create a grid that only fills the upper left quadrant of the space inside the hollowed out block, and the mirrored features mirror to the other three quadrants. Of course it would have been better to create the patterns only on the perimeter and not cut empty space in the middle, but I didn't find a way to do that from only a single pocket.
    FC_Pablin_multitransform_04.png
    FC_Pablin_multitransform_04.png (47.52 KiB) Viewed 298 times

    You'll notice this leaves a lot of residual edges on the bottom of the hollowed out block. The MultiTransform feature succeeds because none of the occurences touch each other, as can be seen by the residual edge imprints.

    I didn't like to have so many scraps for the next operations, so I cleaned it up by applying an Image OpenSCAD RefineShapeFeature on the MultiTransform.
     
  4. Then I created a new sketch of a rounded square on the bottom face and padded it. What was left was to create a second MultiTransform feature, this time with only two LinearPatterns, one on the horizontal sketch axis and the other on the vertical sketch axis. And we end up with this:
    FC_Pablin_multitransform_01.png
    FC_Pablin_multitransform_01.png (56.23 KiB) Viewed 298 times

Please note that the MultiTransform features take a lot of time to generate, it's not the most efficient tool. A Draft Array of separate solids would be much faster, but it would require using Part Booleans, and you couldn't use Linked external geometry in sketches.

Also have a look at Sketch and Sketch001 to see how I centred the rectangles to the sketch origin with a symmetric constraint between diagonally opposed corners of the rectangle and the sketch origin point. This avoid using two dimensional constraints. It's always best to use geometric constraints whenever possible because dimensional constraints are more taxing on the Sketcher solver.

Hope this helps, and that you won't be offended by my teasing you for your insanely long filename. ;)

Cheers,

Norm
Attachments
RidiculouslyLongFileName_normandc1.fcstd
(265.98 KiB) Downloaded 6 times
Last edited by NormandC on Thu Jan 12, 2017 3:17 am, edited 1 time in total.
User avatar
NormandC
Posts: 12077
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Problem with repetitive object coming from different sketches

Postby NormandC » Thu Jan 12, 2017 3:08 am

NormandC wrote:Of course it would have been better to create the patterns only on the perimeter and not cut empty space in the middle, but I didn't find a way to do that from only a single pocket.

And of course, now that I'm done I thought just now how to simplify this further. :D

Since I initially worked on a single quadrant, then simply make the base solid a quarter of the final shape, and make two Image Part Mirror at the end then fuse everything.

Updated file to follow shortly. ;)

Revised file is attached. Funny enough, its file size is double the first one. Nonetheless I think it's easier to edit the MultiTransform features since they don't have as many occurrences.
Attachments
RidiculouslyLongFileName_normandc2.fcstd
(483.92 KiB) Downloaded 8 times
pablin
Posts: 8
Joined: Tue Jan 10, 2017 4:38 pm

Re: Problem with repetitive object coming from different sketches

Postby pablin » Thu Jan 12, 2017 10:33 am

Hi NormandC
Thanks a lot for all the work you achieved, it's impressive!!
Thanks to your advise I also tried to build the object yesterday, and I think it is not too bad (I didn't get the outer part pocketed as you did though):

017011200_SbsSkhPad_CtrSkhPktMtp_VrtPktMtp_HrzPktMtp.png
017011200_SbsSkhPad_CtrSkhPktMtp_VrtPktMtp_HrzPktMtp.png (89.14 KiB) Viewed 285 times


I tooke another route than the one you suggested, and only used pokets.



I had the same problem of scraps so I've solved it with the tool you used (so powerfull!!).

I now want to chamfer all the top edges, and I was wondering if there would be a way to get that done for the inner pad in a simple way (outer ones are done readily)?

017011211_SbsPad_CtrPktMtp_VrtPktMtp_HrzPktMtp_ClnChm.png
017011211_SbsPad_CtrPktMtp_VrtPktMtp_HrzPktMtp_ClnChm.png (151.42 KiB) Viewed 285 times


Thanks again. I hope this might be usefull to others...
Do you think it would be usefull to make a tutorial out of it and to remove the help from here?

Thanks again
Pablo

PS: the "ridiculouslylongname" is just a way I found to try to be able to go back when taking a wrong route and to be able to always get a step back, since sometimes, the calculations make the undo longer that reopening another file :shock:
But you're right, it is ridiculousely long!!! :lol:
User avatar
NormandC
Posts: 12077
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Problem with repetitive object coming from different sketches

Postby NormandC » Sat Jan 14, 2017 6:10 pm

Hi Pablo,

Glad I could help!

pablin wrote:I now want to chamfer all the top edges, and I was wondering if there would be a way to get that done for the inner pad in a simple way (outer ones are done readily)?

Unfortunately, there is no quick way to apply a chamfer to the top edges of the inner pads, the only way is to select either one edge for each "tower" (assuming the rounded corners are tangent, the chamfer will propagate all around) or the top face if using the PartDesign Chamfer feature.

One method that would be quicker would require leaving the PartDesign workbench, and work in a similar method as one of my file, using different tools:

  1. Using my last file, right after the creation of Sketch003, create a Image Part Extrude instead of a Pad. The reason is that an Extrude won't automatically be fused to the solid its sketch is mapped to; it creates a separate solid, but keeps the advantage brought by mapping the sketch (mainly the linking of external geometry).
  2. Apply a Chamfer (either from Part or PartDesign workbench) on the Extrude.
  3. Switch to the Draft workbench, and create a Image Draft Array based on the Chamfer.
  4. Switch again to the Part workbench, and create a Image Part Union between the Array and the main solid.

pablin wrote:Do you think it would be usefull to make a tutorial out of it and to remove the help from here?

I think so, multitransforms are tricky, and the more tutorials we have for FreeCAD, the better. But I admit to not having much time to dedicate to the wiki. Now if you are volunteering yourself, that's another matter. ;)
Attachments
RidiculouslyLongFileName_normandc3.fcstd
(259.09 KiB) Downloaded 7 times
pablin
Posts: 8
Joined: Tue Jan 10, 2017 4:38 pm

Re: Problem with repetitive object coming from different sketches

Postby pablin » Mon Jan 16, 2017 1:47 pm

Hi Normand and thank you again for all the help.

For Tutorial, I was indeed thinking about trying to at least make a draft that you or someone else could review in order to ger something really useful. I also deal with a bit of a time problem, but I can start writting something and post it here for corrections, so that it reaches to something nice sometime soon. Now I don't know if that would be the best procedure, but if it is ok, I can start this week.

For chamfer/array, I'm looking and trying to reproduce what you did. Thanks again!

Last, with all the help, I got a bit more ambitious and I would like to get a spherical bottom for the part as seen here

Dsn002_96wSphBtm_017011611.png
Dsn002_96wSphBtm_017011611.png (176.47 KiB) Viewed 215 times


Here is the file, but I'm almost shure it is not the most straight forward... at least not very elegant :? ... Oops, actually
the file is too big, here is just the starting part of it (I then used mirror and fusion to get the full object)

Dsn002_96wSphBtm_SphBseBrdFil_Prt_017011611.FCStd
(651.66 KiB) Downloaded 5 times


Do you have any suggestion to get this spherical bottom using another tool?

I'm building the rest of the object as the previous versions you suggested and post it when it's done, except if there is another way to get the spherical part achieved.

Thanks again
Pablo
chrisb
Posts: 1666
Joined: Tue Mar 17, 2015 9:14 am

Re: Problem with repetitive object coming from different sketches

Postby chrisb » Mon Jan 16, 2017 4:16 pm

How about making one of the sphere headed cylinders and making an array of it and subtract that array? If you really want to model them all as singles you should first model them all, then fusion them to one subtractive part and cut that from the cube. It makes the tree so much simpler and the file becomes 1/3 smaller.
Attachments
Dsn002_96wSphBtm_SphBseBrdFil_Prt_017011611_modified_by_chrisb_and_thus_filename_becomes_even_longer.FCStd
(446.53 KiB) Downloaded 8 times