Upfolding shading device modelling problem

Hi,

I’m trying to model the movement of an upfolding textile shading device, which should work like this (the bottom and top points should move in a vertical line):

  1. Closed state

  1. Intermediate state

  2. Opened state

I created a Grasshopper definition that I would like to animate with an “opening fraction” slider in the end. However, I’m not nearly done yet… I fail to solve creating the frame sweeps in the proper direction, until an opening fraction of 0.292 it works as expected:

When the opening fraction is equal to 0.293 it flips direction:

In general I have issues using Sweep1 with Grasshopper, I don’t reall understand why this is happening. If you examine the wireframe only, it moves as expected, I suspect I have problems with my Orient geometry and Sweep1 components at the end of my definition.

Any ideas how to do a proper sweep that wont flicker all around the rails? Or should I use some other command?

My GH script:

shading device.gh (16.8 KB)

I wish a happy New Year for everyone! :slight_smile:

I’m a little pressed for time this morning so haven’t looked at your code yet, but you might find this old thread useful (though it drifts into thicken issues):

Version ‘a’ keeps the center points linear while version ‘b’ keeps edge points linear, per your request?

FoldingPlatec_2017Nov5a.gh (20.7 KB)
FoldingPlatec_2017Nov5b.gh (22.0 KB)

How about this way?


shading device_re.gh (22.2 KB)

Thanks, @Joseph_Oster, I took a look at the thread and the script,it’s not exactly my problem that is being discussed there. I can do a solid plate, but I need to model a textile device, so I have to be able to change the profile later on.

This is a work in progress section of my building to better understand the situation:

It would need to look like this (the translucent part in the second row from the top is the upfolding part, and some other parts…):



This is what I have in mind to use as the material:

In a similar way to this:

This is the profile that I wish to sweep at the end (this is what fastens the membrane):

These are all the frames (in another document, the .gh that I shared is a separated “proof of concept” test) that I need to apply the section to:

I thought Sweep1 is what I’m looking for.:frowning:

For this reason, @HS_Kim, your suggestion is not a solution now, unfortunately, as I won’t be able to alter the rectangular cross section, if I understand your file properly.

I think I found the problematic part in my definition: when I create the planes with a normal and an origin, it is free to rotate around that Z axis.

Is there a way to define the X direction for instance? That would be the bottom edge for each panel.


Notice the flip of the X and Y axis… This is how I define the “oriented plane”:
top normal is the left “vertical” edge of each panel, the Brep Edges is the frame of the panel - the start point should be the bottom left for each.

I flipped Z to have the positive XY portion plane inside the curve and on the outside surface (as @HS_Kim did too).

Is there a way to lock the X axis to a certain direction?

Ok, nevermind. I’ve constructed a plane with X and Y axis (X being world Y and Y being the surface normal, origin is the same as before…).

As long as you are using rectangular section profiles, my suggestion should work by adjusting offset and extrusion distance. But if you use section of custom shape, then you are right.

Yes, I meant custom profiles, sorry if I wasn’t clear.
This is my next obstacle actually: with a rectangular profile my script works now.

If I switch to a custom frame however (coming from the manufacturer as a DXF), Sweep1 dies even for the outline (in the Python component rs.AddSweep1 works), creating the full frame geometry is not working with either one.

Do you have anything in mind?

This is my updated script, the frame curves are internalised in the red group on the right.

shading device2.gh (24.2 KB)

The only thing I got from all your pictures is that your “Upfolding shading device” has only two sections and is fixed at the top. The old code worked only in the WorldXY plane so I fixed that and adapted it (hastily) to handle multiple sections.


FoldingPlates_2020Dec31a.gh (29.5 KB)

The ‘gap’ slider is intended to allow for a hinge but that value can be reduced to zero.
The horizontal gap between sections is hard-coded into the Series ‘N’ input in the cyan group (a fixed value added to ‘Length’).

I’m late, gotta go.

P.S. I see that it fails when there are more than two panels. No time now to fix it.

1 Like

Here is another solution.


shading device_reV2.gh (25.5 KB)

1 Like

For what it’s worth, I’ve had a chance to repair my model to work with more than two folding panels.


FoldingPlates_2020Dec31b.gh (29.5 KB)

And to examine all the other models posted in this thread. It seems to me that some abstractions are needed to take this further, such as:

  1. Using a panel/frame that is constructed separately, with any arbitrary frame cross-section and size, as long as it amounts to a rectangular box. That single panel would be oriented and used as often as needed to make “upfolding” pairs.

  2. Location and orientation of each pair (or vertical set if more than two were used) would be defined by a list of planes.

I tackled the second part first by isolating the code that uses planes from the code that creates the planes in specific locations (cyan group). So far, it works well when all the planes are either XZ or YZ but fails when mixing the two… :thinking:



FoldingPlates_2020Dec31c.gh (31.8 KB)

It responds quickly to all parameter changes.

The problem was only in the cyan group, creating the planes. This model has an internalized list of 30 planes (one per folding pair) facing two directions at four different locations, How they are created can be determined separately, perhaps from properties of the building such as planar surfaces that serve as placeholders for each pair.


FoldingPlates_2020Dec31d.gh (30.1 KB)

Getting there. The orange group is a building with Random Reduce applied to SubSrf (Isotrim) sections to represent locations (planes) for the folding devices (shown in white).

The ‘Custom Frame’ from @HS_Kim’s code is internalized and oriented to each of these planes (shown in yellow) but not yet used by the folding mechanism.



FoldingPlates_2020Dec31f.gh (263.1 KB)

Happy New Year!


ShadingDevice
shading device_reV3.gh (24.0 KB)

Interesting approaches, thank you! I will try to incorporate them into my model later today.

@Joseph_Oster your definition is really cool to think about tolerances (hinges, operating distances between neighbouring frames to fasten screws, etc.), which I haven’t yet accounted in my solution (it folds to zero at the starting position):

@HS_Kim I’m on my laptop now, and your latest file requires Lunchbox (I’m on a Mac when mobile and it is Windows-only if I recall), so I’m not able to test right now. When I get to my desktop I will, but it looks really promising on your GIF.

Thinking loud here about further issues...

What I have issues now is the sorting of my subdivided surfaces, when I built the concept model I haven’t thought about actual structural detailing later on, so I have these annoying misalignments around the edges:

Again, wrong plane construction method. Argh. Lesson (should be) learned…

facade_structure.gh (30.6 KB)

Maybe I’m better off now baking each side as simple surfaces, rebuilding the boundaries in a proper way, and applying the framing logic (either fixed or folding), .gh starts to lag too much now.

I cannot complain, this what you get when your model is becoming a dumpster fire hacked together weeks before a deadline.:slight_smile:

I really appreciate the help, this proves to be a life saver for me. I think I can merge the pieces into a final solution.

Happy New Year!

1 Like

I don’t have Lunchbox installed but I can tell from the animated GIF that only one pair of panels is being folded and then it is copied (using Orient) to all the target planes.

Out of curiosity, I changed the ‘U Count’ slider in my model (orange group) from 3 to 10 and noticed a significant delay (~35 seconds?) that turns out to be caused by Orient in the gray group, which is copying the unused ‘Custom Frame’ to all the target planes. Disabling Custom Frame removes that delay. Re-enabling it freezes the GH canvas for ~35 seconds.

Wow, that’s costly compared to the way I’m creating the folding panels in place.

By the way, I’ve never seen that dropdown arrow you used and almost missed what it reveals when you click it. I see it now in the post editor, the ‘Hide details’ feature?

This is an example of the 'Hide details' feature (CLICK ME)

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

Seeing how slow Orient can be, I made the ‘Custom Frame’ optional. It is now used to get dimensions (‘Length’, ‘Width’ and ‘Thickness’ sliders removed) but as noted in the gray group:

Enable Orient to use ‘Custom Frame’ (SLOW!)

How slow? Enough to make interactive folding impractical, even when the number of “folding devices” is low. When ‘U Count’ (orange group) is changed from 3 to 10, the number of planes goes from 24 to 304 and takes more than 1.5 minutes with Orient enabled, so default is disabled.


FoldingPlates_2021Jan1a.gh (269.2 KB)

Yeah, it takes minutes.

I’m not sure how else to do custom profiling other than Orient, but I need(ed) the geometric complexity, I don’t want to draw the profiles in 2D on all my sections (I bake the results into Rhino then export it to ARCHICAD as a Rhino 5 model).

I didn’t think the “detailed” model would be this heavy, I’m thinking about only using the rectangular cross section for lightness… At a scale of 1:50 the profile itself is not really visible anyway, but it bugs me.

Sweeping manufacturer provided frames is a generic issue which surfaces whenever creating windows, curtain walls, or other metal framings.

Maybe creating blocks could help?

The interior details of the ‘Custom Frame’ are complex and completely lost at building scale. A much simpler version could be created that more closely approximates the dimensions and cross-section.

P.S. Here is a simple ''Rectangle Frame" that is much faster than the ‘Custom Frame’, though still slow interactively with a large number of planes.

RectangleFrame_2021Jan1a.gh (12.9 KB)

Maybe what you should do is show an animation using only one plane with the ‘Custom Frame’ and use a simpler version when showing the whole building?

That may be, I’ve never used them.

I intended to create close up renderings from a section of the facade.
It must have been the food coma after Christmas that I am recovering from now.:slight_smile:

I recall seeing quite detailed structural models on this forum, but I couldn’t find them now, I’m wondering how they are managed.

I managed to open it. The operation is really fast, I like how you reused half of the folding panel to scatter it across the surface.

I wonder if this method is the trade-off for speed. I was thinking in panels from the beginning, maybe it would be better to create a set from all the different sized closed polylines and use blocks to populate the facade

Me neither. If I’m correct, there isn’t much native components to define and manage blocks in Grasshopper, right? So I need to use the likes of Human, Elefront, etc.?