Intersecting Lines or Faces
-
In the model below you can see that the I-joist is supported or touches three separate faces (surfaces).
I am trying to figure out a way to code an algorithm that lets me know all of the bearing points along a beam or joist. Starting from one end of the joist, it would give me the location of each of the (left and right boundary line) bearing surfaces.
If I can figure out a way to do this I can then put together the engineering for joists and beams and add this functionality into the truss plugin.
An example of a typical simple beam calculation would look something like this:
-
I think the first step would be to determine the entities or faces that touch or coincide with the face of the bottom of the joist. Once I gather a list of those entities it should be fairly straightforward to intersect each entity with the joist face and then determine the distance from one end of the joist to the perpendicular line(s) that form the boundary of the intersecting entity's face.
I think the hard part for me is how to find the entities that touch the face of the bottom of the joist.
-
I think it is possible to use "face.classify_point(pt)" method to find/select entities, that "touch" some face.
For intersection I would recommend a method "intersect_line_plane" from Geom class. Face plane can be simply obtained like "face.plane", edge line like "edge.line", then it is possible to get intersection point like "Geom.intersect_line_plane". Finally it might be useful to make sure that intersection point lies inside of a face boundary using "face.classify_point".
Advertisement