algorithmic modeling for Rhino
Hi Guys,
This is my first post and my first attempt using grasshopper. I'd like to think this is OK so far, but please tell me if/where you think I have gone wrong.
The gist of this is its a vented housing for an LED PCB. The object is a parametric series of discs with an opening inside made up of a mirrored curve [drawn in Rhino, mirrored in GH]
It is madde up of N number of discs which can be varied through the distance between the circular outline using a divided curve [straight line in GH]. The length of the object can be varied using a length parameter, and the shape using a graph mapper.
I've chosen to cap the end two discs by creating two sets of outlines. One set has the central aperture cutout for the PCB, whereas the other set is a trimmed circle [achieved using the "trim box" layer profile in Rhino]
I then cull the outer two curves from one array, and the inner N-2 curves from the inner array.
The final outcome I am after is to create the housing as both an STL and a 2d template for laser cutting. This is a learning exercise for me as well as a cool project.
I had it working OK, but then I adjusted the profile for the PCB and joined it and now it is giving me some grief. I am sure the answer is obvious. The problem is the PCB profile is made up of 3 polycurves, whereas the disc profile is one planar curve. I have no problem using the flatten option so there are only N sets of curves coming out of the "Join Curves" component. However when I cull the curves, the planar curves making up the exterior edge cull fine, but the interior curves [the joined, PCB profile] culls in a different [irrational?] order to what I would expect. If I connect the single planar curve to the culls section, it works fine, but the joined line section just won't play.
In the instance uploaded N = 10, based on spacings. And index white it appears that 0 and 9 are diagonal to what I'd expect, although if you fiddle with the values they go all over the place.
Can someone please help me and explain what I did wrong? Files are attached... I have screen grabbed the relevant section, but it is grouped in red and labelled as "problem child" :)
Many thanks for your help, sorry if this looks like a clusterf**k, first time for everything... any advice very much appreciated, not just relating to my problem.
All the best
Nick
Tags:
sorry guys, little bump, any ideas as to what I am doing wrong?
that is right, but has missed out the culling... I had tried joining the curves again, but it just seems like they don't get joined in the right order for the culling element. As soon as I join the outer curve with the inner profiles, the culling sequence is all wrong.
The problem occurs after the join curves command, I join the inner profiles which gives 30 curves, then flatten to give 10 planar curves. But when culling they are not in order. I guess it's because prior to being joined they cull in this order:
10x curves, 10x profile, 10x profile mirrored
when it should cull 10x(curve, profile, profile mirrored)
Thanks in advance,
Nick
ahaa, I see I will check that out now...
Hi Nick, here's my edit of your file, hope I understood your goal correctly.
that is correct :) thank you so much
Any tips as to how my approach was wrong [that you can describe] - I will pick the network apart so as to understand but there are some elements in there I have not yet come across.
Thank you again, a million times :) super happy, and much late night frustration gone in a flash...
Nick
ok so as I understand it, you used a domain from 1 to n-1 for the inner sections,
and then a "list item" element with two outputs - "0" and "0-1" [which wraps to the last item on the list]
There is no need for any culling or indexes or any nonsense like that, the list is the curves, the index dictates which curves are output on the pins?
So I was basically adding a load of steps which were unnecessary [culling] as the list commands were picking out the curves I wanted.
Finally, the close arc command did exactly that...
Thank you so much for your help, sometimes the best way to learn...
Nick
Your file wasn't all that wrong (except the outer arcs weren't closed off). I just used a more consize way to separate the outer arcs, but that really was just meant to help me see/comprehend what you were after. Oh, if you remove the (superfluous, sorry) flatten operator from the SubList component, you'll see more clearly what happened.
I've attached another edit of your file, that joines the curves in a more controlled way (so their order doesn't get shuffled).
many thanks for all your help... the STL stage of this experiment is complete!
now I am just trying to create a template for laser cutting the same shape, which will be held together with spacers and dowels.
I have managed to get the dowel holes in place and do all the relevant sums for creating the spacers, but I can't work out now how to project the groups of curves onto a flat plane. There is plenty of examples of projecting section cuts [single closed curves] onto a plane, but not a lot showing multiple curves, with circular holes inside.
I know I have probably run before I can walk, and I suspect this should have been approached differently, but its some organic learning. Is there any way of doing this, as per the attached.
Many thanks for all your help in advance, I hope you guys don't mind new questions etc, I am working my way through tutorials and the primer, so hopefully it will all become clearer as I get through more examples.
Nick
Any suggestions as to how to group those outlines and flatten them? Sorry guys I've tried loads of approaches and it sends them all in a funny order. Any advice appreciated, e.g. how I should have approached it differently...
Thank you :)
Nick
Hi Nick, the attached edit of your file should get you started
wow. that is going to take me some time to parse :)
I shall return, thank you for your help...
thank you... a lot of this gas gone way over my head, I am just trying to transplant it to another set of parameters. I can't think you enough, but I reckon I'm a long way off comprehending all this :)
Thank you again...
Welcome to
Grasshopper
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
© 2024 Created by Scott Davidson. Powered by