Trim surface

Good afternoon,
Can anyone tell me what is the best way to trim a surface and a curve? I’m trying to keep the area inside the rectangle and remove the rest.


Trim.gh (14.5 KB)

Your geometry was messed up in several ways. I removed a duplicate line in the polyline that defines the corrugated surface by replacing these disabled components with the yellow group:
trim_2023Jan18a

Two corners of the cutting rectangle extend beyond the edge of that corrugated surface:


trim_2023Jan18a.gh (22.6 KB)

P.S. White group is a different way of finding the correct split fragment closest to center of the rectangle:


trim_2023Jan18bb.gh (18.4 KB) (UPDATED!)

That was really helpful! Thank you!!

I’d like to suggest another way of creating the corrugated surface (light blue group below).


trim_2023Jan19a.gh (22.8 KB)

Using it is slightly different in several ways.

  • Separate sliders for ‘Width’ and ‘Length’.

  • Replaced ‘Stepover’ slider (I didn’t understand it?) with ‘Wavelength’ slider that sets the distance between peaks.

  • Labeled Value List as ‘Amplitude’ and removed multiplication by ‘Stepover’ slider. I still don’t understand the labels that appear to be angles? (30, 45, 60, 90, 120)

  • Used Dispatch to separate alternate points. (the main idea behind the change)

Thank You!