Riemann sum with variable lengths of rectangles on a non planar curve


I’m trying to make an stepped ramp, from a non planar curve. To make the steps I thought in a Reimann sum, where the steps are defined by the variable length of the rectangles that approximates to the area under the curve

That’s a sketch of what I would like to achieve. It has to be known that the ramp it’s made of straight lines, not curves like an spiral staircase.

I’m inspiring by that staircase from Melopee School by XDGA, where the ramp it’s steeped to have a half more like a normal ladder, and the another half more like a slide or hill

Any help by how to achieve it with grasshopper or another tool it’s welcome!