Get the lines Inside of beam pockets @ bottom of slab

Hey everyone, Im trying to get the lines at the inside of the beams and the bottom of the slab. Ive tried a couple different things and im not sure how to go about doing it.


What i want to get:

thanks ahead of time for any help

soffit.dyn (8.5 KB)

//Select Floors and Beams
elm1 = ElementQueries.OfCategory(Category.ByName(["Floors","Structural Framing"]));

//Solids - Floors and Beams
sld1 = Solid.ByUnion(List.Flatten(elm1.Solids,-1));

//Solid - Floors
sld2 = Solid.ByUnion(List.Flatten(elm1[0].Solids,-1));

//Solid Faces
srf1 = sld1.Explode();

//Faces parallel to XY plane
bln1 = srf1.NormalAtParameter(0.5,0.5).IsParallel(Vector.ZAxis());
srf2 = List.FilterByBoolMask(srf1,bln1)["in"];

bln2 = sld2.DoesIntersect(srf2.Translate(0,0,0.1));
srf3 = List.FilterByBoolMask(srf2,bln2)["in"];

Once again, thank you Vikram! you rock!

1 Like

@Vikram_Subbaiah how would i create lines from the top corner in a 8x4 ft grid pattern? but only on the surface extents? I got the starting point and i created the geometry that i want. but now i need to make the lines.

Im also wanting to get the inside faces of the beams under the slab though.

Thanks for any help you can give me

Add these lines …

//Beam Inner Side
bln3 = List.AllFalse(srf1<1>.DoesIntersect(srf3<2>)<1>);
srf4 = List.FilterByBoolMask(srf1,bln3)["out"];

soffit.dyn (7.7 KB)

1 Like

sweet thank you! any ideas about making the lines 8’x4’ grid?

1 Like

soffit.dyn (13.1 KB)

wdt1 = 4;
lgt1 = 8;
edg1 = List.SortByKey(srf3.PerimeterCurves()<1>,srf3.PerimeterCurves().Length<1>)["sorted list"];
edg2 = List.LastItem(edg1<1>);
pnt1 = edg2.PointAtSegmentLength(wdt1..edg2.Length..wdt1);
edg3 = List.Flatten(edg2.PlaneAtParameter(edg2.ParameterAtPoint(pnt1)).Intersect(srf3)<1>,-1);
pnt2 = List.FirstItem(edg3<1>).PointAtSegmentLength(lgt1..List.FirstItem(edg3<1>).Length..lgt1);
edg4 = List.Flatten(edg3.PlaneAtParameter(edg3.ParameterAtPoint(pnt2)).Intersect(srf3)<1>,-1);

cut1 = PolySurface.ByJoinedSurfaces(List.Flatten(edg3<1>,-1).Extrude(Vector.ZAxis(),1));
cut2 = PolySurface.ByJoinedSurfaces(List.Flatten(edg4<1>,-1).Extrude(Vector.ZAxis(),1));
srf4 = srf3.Split(cut1.Translate(0,0,-0.5));
srf5 = List.Flatten(srf4.Split(cut2.Translate(0,0,-0.5))<1>,-1);


1 Like

@Vikram_Subbaiah any idea why im getting acouple null values? the end game is to cut the surface into the rectangles. i think it may be because the smallest formwork area is too small

formwork.dyn (159.3 KB)

I Think i found the solution to the cutting: but not the null

Could be, but unable to clarify as your file works fine on a sample project.
See if you can identify the source of the error by checking the results of each output port in the code block.

@Vikram_Subbaiah im trying to recreate your code with nodes so i can understand whats going on and i can find the error but i cant figure it out. can you tell me what im doing wrong with this?

Difficult to say without seeing the outputs of the different nodes.
My guess is Levels on the last FilterByBoolMask

@Vikram_Subbaiah sorry about that. heres the drop downs and dyn

formwork.dyn (102.2 KB)

nvm i got it! i needed to flatten my geometry for sld1 before i did solid by union!
formwork.dyn (111.6 KB)

1 Like