Randomize "pipe variable" across multiple lines

Hi everyone
I’m trying to randomize “pipe variable” across multiple lines
I would like it if each line had its own randomized pipe
I’m trying different ways but i cant achive any resutl
hope someone can help me, even just a suggestion or an idea is appreciated


Ppioppeta.gh (13.9 KB)
LinesForPioppeta.3dm (113.6 KB)

Like this?

Ppioppeta_fb_v1.gh (11.1 KB) (Updated File)

You can play with the start or step to change the seed in this case.

1 Like

Looks like the main problem is that the ‘Curve’ input of Pipe Variable needs to be grafted.

P.S. I see that done in your image but it’s not in your GH file.

Do you want to randomize other aspects like the ‘Count’ and position of Divide Curve?
And the ‘Radii’?

This version implements random (per pipe) Count, Radii and Seeds. It culls similar ‘t’ values to avoid abrupt changes in radius (purple group with ‘Tolerance’ slider). Geometry is internalized so may be used in R7.


Ppioppeta_2025May5a.gh (22.8 KB)

Added white group to create a “forest” of pipes, illustrating an issue I struggled (and failed) to solve, culling similar ‘t’ values… Sometimes it removes the (inserted) top and/or bottom of these pipes. It’s probably simple (:wink:) and will occur to me later. :thinking:


Ppioppeta_2025May5b.gh (24.9 KB)

1 Like

This wasn’t simple but I think it works. Replaced the previous purple group to generate a series of intervals defined by the ‘Min_Incr’ and ‘Max_Incr’ sliders, then cull them and add 0 and 1 (bottom and top) so all pipes are the same height.


Ppioppeta_2025May5c.gh (28.0 KB)

Might be a simpler way… :thinking:

DOH :bangbang: Just realized that ‘Min_Count’ and ‘Max_Count’ are no longer used. :roll_eyes:


Ppioppeta_2025May5cc.gh (26.3 KB)

2 Likes

WOW
I don’t know how to thank you @Joseph_Oster @felix.brunold :folded_hands:
I have a lot to learn
I have to get to work right away

It bothered me to see some pipes with abrupt transitions near their tops so I looked further.

Finally located and fixed the problem but made other changes too. Instead of generating random seed values so each branch (pipe) is different, now I generate random ‘radii’ and ‘intervals’ for all branches and then partition both lists.

The code is simpler in some respects, and hopefully better.


Ppioppeta_2025May6a.gh (25.6 KB)

NOTE: The random intervals are between zero and one, applied to reparameterized lines, so they are independent of line lengths.

The essence of this problem was to generate random ‘t’ values between zero and one, inclusive, and not have them too close together.

1 Like