Mathias Lange 1 Posted December 6 (edited) Hey Community, is it possible or is there a script, that show me automaticly the smallest dimension of a space in a table. So in the example, that is in the table - 1,35m - because of the escape route wide. The answer can be in german. Best regards Mathias Lange Edited December 6 by Mathias Lange Share this post Link to post

DomC 153 Posted December 6 (edited) For sure, this is possible. But not an easy chase. It looks really interesting to solve that kind of task. Regardless the question if this would be a time-saving script. I see a lot of spaces in my life and most of them are much more simpler than that and a space contour like this maybe exists for less than 5% of the spaces. OK, in a big project with 3500 spaces, there could be still 150 spaces like this (corridors etc.) with critical minimum space. But what I know, just the initial question for every time consuming Project. OK, the possible procedere for this: 1. Find an algorithm, to check the distances. If the spaces could have every form and angles, the solution would result in a much higher complexity. 2. If the spaces are at 90° angles, it could be a simple strategy like draw a (two in both directions but just use the one, which do not hit a space bound line) perpendicular line on every edge and check where it collide with another boundary line. It would fail with freeform (or inaccurate) spaces but is relatively simple: If the strategy matches, you will have further hurdles. 3. How to extract polygon from space 4. How to check intersection of perpendicular lines 5. How to check which direction line has to be checked 6. how to mark at least the smallest passage (I think in the middle of the line from which the edge line was generated the smallest distance) Interesting. A Script which detects smallest passage in a space. But if you will transport bigger objects and check if they stuck somewhere this is maybe not exact enough because you have to turn things around the edges (We know that from apartment relocation :-) Edited December 6 by DomC 1 Share this post Link to post

Mathias Lange 1 Posted December 7 Thanks DomC for your answer. I need it only for orthogonal spaces. We plan in 98% orthogonal spaces. The 2% nonorthogonal rooms, i would check manually. 😆 So do you have a script like this or an Idea for the script? Best regards and thanx alot. Mathias Lange VWX | BIM | CADmin Share this post Link to post

DomC 153 Posted Monday at 10:01 PM (edited) Quote So do you have a script like this or an Idea for the script? The Idea was yours. Some good Scripts resulted of Ideas of real-existing exercises. I did not had that idea, because it is costly and the benefit may be low. I could give you an plan for the methode: 1. Make Polygon Clockwise (because you minimize number of solutions) 2. Define Vectors on every Polygon Edge which are perpendicular (let's call them measure lines) 3. Intersect measure lines with every line of the bounding polygon. Filter shortest intersection lines for every line 4. Draw perpendicular line from vertexes on every edge of the polygon and filter shortest lines 5. Filter measure lines of concave parts of the space polygon for getting out polygon out of space and refer to correct coordinates, just get object path node (which do not exists yet) use entity matrix on it (to refer to correct coordinates and angle) Maybe there was a pan-ready solution with shapely, numpy or other python packages. You will feel free, if you accomplish that by yourself ... 🙂 I did some work for that question. But I have to pause that until next year. Main issue (I would have to start new with perpendicular on edge method but I consumed my time for this with the perpendicular on vertex method). Which would do the job but is not the best solution. As you can see, this Script Version produces some measure lines, which we don't want do have (the concave parts). Also Diagolan Distances are not measured. Also perpendicular distances on edges are not measured (which is not necessary, if spaces are orthogonal) This Method will fail for non-orthogonal spaces. Which bother me now. The perpendicular on edge methode would be much bether. Also the concave parts for non-orthogonal shapes could be very tricky. For orthogonal parts i think it can be done for just delete parts, which have a continuation line with same direction (At least it looks like this). Maybe this all can be solved with the perpendicular measure on edge method (which looks now like a propper solution but maybe could be the wrong direction) Screenshot, where you can see, why this do not work on non-orthogonal spaces I hope, you unterstand what I did in the script and are able to continue your work on this. Some of the biggest puzzle already solved. The rest is routine peace of work 🙂 I used some custom nodes for that: 1. Rotate point (an existing custom node which is the same like rotate line, but I do not like to draw lines bevor all Points are calculated). I prefer the math way 2. Line Intersection Dir nearest. It calculates of a line1 the nearest collision with the lines input in input line2. The Standard intersection do not check direction so i desided to modify standard node. also the minimum line distance was hard to sort out. 3. Sort nested list (an existing one. Hard so sort several objects and values all by one type without that) smallest distance beta 0.8.0.vwx Edited Monday at 10:07 PM by DomC Share this post Link to post

STERNontwerp 9 Posted Wednesday at 03:38 PM This might help, although it has not been done with the original poly. It gives the inner corners, the only corners that need to be checked. (If a node would exist that enabled a change of the start vertex of a poly, marionette-live would be a lot easier.) Ernst van der Vecht smallest distance beta 0.8.0 _EV.vwx 1 2 Share this post Link to post

DomC 153 Posted Wednesday at 10:32 PM Incredible clever to use an offset poly to detect inner corners! This can kill seven with one strike. Smallest distances would result on a combination of perpendicular lines from corners on edges on the right side of a cw polygon. And distances between inner corners which do not cross outer poly offset (still excited about that creative offset poly method). @STERNontwerp Great contribution Share this post Link to post