Understanding data: sweep1

Dear everybody,

I have a slight problem with a sweep1-command that does something strange. I’ve made my section curves and the “rails” that they should sweep - so far so good. However, when I try it out, the direction of the sweeps are not the same, and I’m unsure why this happens.

Curiously, if I choose to rotate the section curves and use the same arcs, it works flawlessly in the same direction - however, from a wrong section curve! Then I rotate them back, and it looks as it should.

My question is more one of understanding the data, as the “detour” above seems to get the correct result. However, at some point in my use of Grasshopper, I would also like to understand WHY things happen :slight_smile:

I’ve uploaded the file, which I think will explain it better. The RED GROUPS in the end are where I’m at, but maybe the problem happens before, I guess :fearful:

Thanks in advance!

1.gh (25.8 KB)


Well, I was a bit quick: actually, the “rotate cure”, that I propose, doesn’t really work. For example, if I change the seed in the “rotation” area to i.e. 28, one of the sweeps goes the wrong way again. So I’m lost, I guess!

I don’t think Sweep 1 is the right command for this.

I’d use revolve instead.

1.gh (27.2 KB)

In general, I find your approach quite complicated.

Here’s another way to achieve your goal:

1.gh (23.3 KB)

Hello Martin,

Thank you so much for your response. I agree with what you’re saying - it was very complicated! However, there are elements from your script, that I don’t even understand after looking at them (In the beginning, reg. “Relative Item” - I must admit, I don’t know what that does! :thinking: )

In the end, it worked out with your script :slight_smile: I was trying to “avoid” revolve, as I wanted to have an inner surface that would be slightly different than the outer one, which is why I would like it to follow an arc, but that also works with your script, so I guess your sharp script solved the a problem beyond what I had explained :smiley:

I’ve uploaded the script to show you what I wanted to try (as you can see, I also messed it up, and you could probably have done it in just a few strings… oh well…)

Thanks again! 1_2.gh (40.3 KB)

Relative item looks at a data tree and in this case you have three branches with 4 items each.

{0} (1) is the Offset for each item combination. Curly brackets is for branches and here it means no offset on the branches and (1) means one offset in the items.

You could also create a polyline out of the 4 points in each branch and then explode the polyline into segments. It does the same thing.

Regarding the use of Revolve, your “rail” is circular, so Revolve is more efficient.

1 Like