Three-dimensional representation methods, interference detection methods and Boolean operation methods of building components

Through polygonal prism model and local coordinate system transformation, the complexity and redundancy of three-dimensional representation and Boolean operations of building components are solved, and efficient and reliable interference detection and Boolean operations are achieved.

CN119378048BActive Publication Date: 2025-09-26CHINA NORTHEAST ARCHITECTURAL DESIGN & RES INST CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310921371.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-07-26
Publication Date
2025-09-26
Estimated Expiration
2043-07-26

AI Technical Summary

Technical Problem

In the three-dimensional representation and Boolean operations of building components, the existing grid representation methods are computationally complex, prone to errors, and have redundant information, making them difficult to adapt to the characteristics of building components.

Method used

A polygonal prism model is adopted to transform the building components into polygonal prisms by defining a local coordinate system. Interference detection and Boolean operations are performed by combining triangulation and Boolean operation rules.

Benefits of technology

It simplifies the modeling process of building components, improves modeling efficiency, and enables more efficient and reliable engineering processing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119378048B_ABST
    Figure CN119378048B_ABST
Patent Text Reader

Abstract

The present invention relates to a three-dimensional representation method, an interference detection method, and a Boolean operation method for building components. The three-dimensional representation method converts building components of common shapes into a three-dimensional representation form of a polygonal prism to form a polygonal prism model of the building component. The interference detection method and the Boolean operation method are performed based on the building components of the polygonal prism model. The present invention provides a universal three-dimensional representation method for building components of different shapes, simplifies the modeling process of building components, and improves modeling efficiency. At the same time, when the building components are used for interference detection and Boolean operations in engineering, calculations based on the polygonal prism model can achieve more efficient, more standardized, and more reliable engineering processing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of architecture, and in particular to a three-dimensional representation method, an interference detection method and a Boolean operation method of architectural components. Background Art

[0002] Typically, three-dimensional shapes are represented using triangular or quadrilateral meshes. This method can express arbitrarily complex shapes, offers high degrees of freedom, and is adaptable to a wide range of scenarios. However, mesh representation also has the drawback of complex and error-prone interference detection and Boolean operations.

[0003] The geometry of building components typically has horizontal tops and bottoms, rarely exhibiting slopes. Representing this information using a mesh results in a significant amount of redundant information, which also needs to be factored into calculations, hindering computational efficiency. Furthermore, it's common for building components to overlap or become tangent to each other, a situation where mesh interference detection and Boolean operations are prone to errors.

[0004] In summary, building components are not suitable for the currently commonly used triangular mesh or quadrilateral mesh representation, and it is necessary to find a simplified and reliable representation method for building components. Summary of the Invention

[0005] In view of this, the present invention aims to propose a three-dimensional representation method, an interference detection method and a Boolean operation method for building components, so as to solve the problem that building components of different shapes are difficult to form standard three-dimensional modeling, and the problem that interference detection and Boolean operations of building components of different shapes cannot be completed efficiently and reliably due to different model standards.

[0006] In a first aspect, a first embodiment of the present invention provides a three-dimensional representation method for a building component, the three-dimensional representation method for a building component comprising:

[0007] S100, determining the type of building component;

[0008] There are four types of building components, namely rectangular columns, rectangular beams, cylinders and arc-shaped bodies;

[0009] S200, constructing a local coordinate system for representing the building component in a three-dimensional form of a polygonal prism according to the type of the building component, thereby converting the building component into a polygonal prism model;

[0010] Among them, the rectangular column building component has a rotation angle parameter for establishing the local coordinate system, the rectangular beam building component has line segment, thickness and height parameters for establishing the local coordinate system, the cylindrical building component has cylinder parameters for establishing the local coordinate system, and the arc-shaped building component has arc, thickness and height parameters for establishing the local coordinate system.

[0011] Furthermore, in S200, for the rectangular column building component:

[0012] Define the original x-axis direction as east (1,0,0), the original y-axis direction as north (0,1,0), and the original z-axis direction as up (0,0,1);

[0013] Define the center point of the bottom as O, the length of the bottom in the x-axis direction as l, the length of the bottom in the y-axis direction as w, the height as h, the rotation angle around the z-axis as α, and define the vertices of the bottom in the counterclockwise direction as P0, P1, P2, and P3 respectively,

[0014] P0=O+(l*cosa+w*sina,-l*sina+w*cosa,0)

[0015] P1=O+(-l*cosa+w*sina,-l*sina+w*cosa,0)

[0016] P2=O+(-l*cosa+w*sina,l*sina+w*cosa,0)

[0017] P3=O+(l*cosa+w*sina,l*sina+w*cosa,0)

[0018] Then the local coordinate system of the rectangular column building component is the homogeneous matrix with the x-axis, y-axis and original z-axis rotated by an angle α around the z-axis as the coordinate axes and the bottom center point O as the translation, which is:

[0019]

[0020] Among them, Ox, Oy, and Oz are the components of point O on the xyz axis; the rotation angle α ≥ 0.

[0021] Furthermore, in S200, for the rectangular beam building component:

[0022] Define the endpoints of the bottom midline segment as A and B, the width of the bottom perpendicular to the midline as w, and the height as h. Based on the endpoints A and B of the bottom midline segment, the length of the bottom midline segment is obtained as l. The tangent direction T of the building component of the rectangular beam is determined. Based on the z-axis direction, the normal direction N of the building component of the rectangular beam is determined as follows:

[0023] l=|BA|

[0024]

[0025] The vertices of the bottom surface defined in the counterclockwise direction are P0, P1, P2, and P3, respectively, and we have:

[0026]

[0027] Then the local coordinate system of the rectangular beam building component is a homogeneous matrix with the tangent direction T, the normal direction N and the z-axis direction as coordinate axes and the endpoint A of the bottom midline segment as the translation:

[0028]

[0029] Among them, Tx, Ty are the xy-axis components of T; Nx, Ny are the xy-axis components of N; Ax, Ay, Az are the xyz-axis components of A.

[0030] Furthermore, in S200, for the cylindrical building component:

[0031] Define the original x-axis direction as east (1,0,0) and the original z-axis direction as up (0,0,1);

[0032] Define the bottom center as O, the bottom radius as r, and the height as h, and transform the cylindrical building component into a polygonal prism with a predetermined number of side segments i, and define the vertices of the bottom polygon in the counterclockwise direction as P0, P1, P2, ..., P i-1 , then for a given number of side segments i, we have:

[0033]

[0034]

[0035]

[0036] Then the local coordinate system of the cylindrical building component is a cylindrical coordinate system with the bottom center O as the center, the original x-axis as the polar axis, and the original z-axis as the height.

[0037] Furthermore, in S200, for the arc-shaped building component:

[0038] Define the arc center as O, the two endpoints of the arc as A and B, the radius of the arc as r, the radial width as w, and the height as h. Convert the arc-shaped building component into a polygonal prism with a predetermined number of side segments i, and calculate the arc positions of the two endpoints of the arc:

[0039] θA =arctan2(Ay-Oy,Ax-Ox)

[0040] θ B =arctan2(By-Oy,Bx-Ox)

[0041] Define α as the distance from θ in the counterclockwise direction A to θ B The angle between , and α is a positive number, we have:

[0042] α=(θ B +2π-θ A )%2π

[0043] For a given number of side segments i, calculate the step length θ according to the size of the angle α Δ :

[0044] θ Δ =α / i

[0045] According to the step size θ Δ In the counterclockwise direction from θ A to θ B Step by step, calculate the normal function f for any angle θ on the arc norm (θ) and position function f Pos (θ), we have:

[0046] f Norm (θ)=(cosθ,sinθ,0)

[0047] f Pos (θ)=O+f Norm (θ)*r

[0048] Then the position function f of the vertex of the bottom polygon of the arc-shaped building component located outside the arc AB is P (θ) is:

[0049]

[0050] and the position function f of the vertex of the bottom polygon of the arc-shaped building component located inside the arc AB P '(θ) is

[0051]

[0052] Among them, when θ is taken as θ A ,θ A +θ Δ ,θ A +θ Δ *2、θ A +θ Δ*3. When θB, f P (θ) is the polygonal vertex P0, P1, P2, ..., P from the arc endpoint A to the outside of B. i , f P '(θ) is the polygon vertex P0', P1', P2', ..., P from the arc endpoint A to the inner side of B i ';

[0053] Then the local coordinate system of the arc-shaped building component is (x, y, z), where x is the arc length from point A, y is the radial distance from the arc, and z is the height, and:

[0054]

[0055] f(x,y,z)=O+f Pos (θ)+f Norm (θ)*y+(0,0,z)

[0056] Where θ is the radian distance to point A.

[0057] In a second aspect, a second embodiment of the present invention provides a method for detecting interference of building components, for performing interference detection on a building component represented in the form of a polygonal prism in the three-dimensional representation method of building components as described in any one of the first aspects. The method for detecting interference of building components comprises:

[0058] S300, obtaining a coordinate range of a building component in the form of a polygonal prism in its local coordinate system;

[0059] S400, dividing the top surface of the building component in S300 into a plurality of triangles;

[0060] S500 , in the local coordinate system of the building component in S300 , calculating interference conditions between each triangle on the top surface of the building component obtained in S400 and the point to be detected, the straight line, the line segment and other building components.

[0061] Furthermore, the S400 includes:

[0062] S410, judging whether the top surface of the current building component is a convex polygon based on the angles of the internal angles of the top surface of the current building component;

[0063] When at least one interior angle greater than 180° exists, it is determined to be a concave polygon top surface and the process proceeds to S420 ;

[0064] When all interior angles are less than 180°, it is determined to be a convex polygon top surface and the process proceeds to S430 ;

[0065] S420: For any interior angle of the top surface of the current building component with an angle greater than 180°, connect the two sides on one side of the interior angle end-to-end to form a first triangle, and connect the two sides on the other side end-to-end to form a second triangle, and determine whether the first triangle and the second triangle are inside the top polygon of the current building component. If so, retain the line connecting the triangles; if not, cancel the line connecting the triangles, and then return to S410;

[0066] S430 , starting from any vertex of the top surface of the current building component, connecting lines to all other vertices respectively, and dividing the top surface of the current building component into a plurality of triangles.

[0067] Furthermore, in S500, regarding the interference between the points:

[0068] Obtain the coordinate range of each triangle on the top surface of the current building component, and determine whether the coordinate of the point to be measured is within the coordinate range of any of the triangles;

[0069] Among them, to determine whether the coordinates of the point to be measured are within the triangle, the steps are as follows:

[0070] In the clockwise direction, the three vertices of the triangle are A, B and C. Connect the point P to be measured with points A, B and C respectively to obtain vectors AP, BP and CP;

[0071] Determine whether vector AP is in the clockwise direction of vector AB or coincides with vector AB, and obtain result 1;

[0072] Determine whether vector BP is in the clockwise direction of vector BC or coincides with vector BC, and obtain result 2;

[0073] Determine whether vector CP is in the clockwise direction of vector CA or coincides with vector CA, and obtain result three;

[0074] If the first, second and third results are all yes, then the test point P is inside the triangle ABC, otherwise the test point P is not inside the triangle ABC;

[0075] If the point to be measured is not within any triangle on the top surface of the current building component, it is determined that there is no interference between the point to be measured and the current building component; otherwise, there is interference.

[0076] Furthermore, in S500, for the interference with the straight line:

[0077] Obtain the projection line segment of the straight line to be measured on the top surface of the current building component;

[0078] If the straight line to be measured is a horizontal line, the endpoints of the projected line segment are the intersections of the straight line to be measured and the maximum and minimum value ranges of the x-axis and / or y-axis and / or z-axis coordinates of the current building component;

[0079] If the straight line to be measured is a non-horizontal line, the endpoints of the projected line segment are the intersection points of the straight line to be measured and the top and bottom surfaces of the current building component respectively;

[0080] If any endpoint of the projected line segment is above or within the top polygon of the current building component, and / or the projected line segment is tangent to or intersects with any edge of the top polygon of the current building component, then it is determined that the straight line to be measured interferes with the current building component; otherwise, the straight line to be measured does not interfere with the current building component;

[0081] The steps to determine whether the projected line segment intersects with any edge of the top polygon of the current building component are as follows:

[0082] The endpoints of the projected line segment are A and B, and the endpoints of one side of the top polygon of the current building component are C and D. If vector AC and vector AD are in different clockwise directions with respect to vector AB, and vector CA and vector CB are in different clockwise directions with respect to vector CD, then it is determined that line segment AB and line segment CD intersect; otherwise, line segment AB and line segment CD do not intersect.

[0083] Furthermore, in S500, for the interference with the line segment:

[0084] Obtaining coordinates of the endpoints of the line segment to be measured in the local coordinate system of the current building component, and determining that the line segment to be measured interferes with the current building component if any endpoint of the line segment to be measured is above or within the top polygon of the current building component, and / or the line segment to be measured is tangent to or intersects with any edge of the top polygon of the current building component; otherwise, determining that the line segment to be measured does not interfere with the current building component;

[0085] The steps to determine whether the line segment to be tested intersects with any edge of the top polygon of the current building component are as follows:

[0086] The endpoints of the line segment to be tested are A and B, and the endpoints of one side of the top polygon of the current building component are C and D. If vector AC and vector AD are in different clockwise directions with respect to vector AB, and vector CA and vector CB are in different clockwise directions with respect to vector CD, then it is determined that line segment AB and line segment CD intersect; otherwise, line segment AB and line segment CD do not intersect.

[0087] Furthermore, in S500, regarding the interference with other building components:

[0088] Obtaining the coordinate range of the building component to be measured in the local coordinate system of the current building component, projecting the top surfaces of the two building components onto the same plane, and sequentially determining whether each edge of the top surface of one building component interferes with each edge of the top surface of the other building component. If at least one set of edges interferes with each other, then it is determined that there is interference between the two building components; otherwise, there is no interference between the two building components.

[0089] The steps for determining the interference between any edge of the top surface of one building component and any edge of the top surface of another building component are as follows:

[0090] The endpoints of one side are A and B, and the endpoints of the other side are C and D. If vector AC and vector AD are in different clockwise directions with respect to vector AB, and vector CA and vector CB are in different clockwise directions with respect to vector CD, then line segment AB and line segment CD intersect; otherwise, line segment AB and line segment CD do not intersect.

[0091] In a third aspect, a third embodiment of the present invention provides a Boolean operation method for building components, for performing a Boolean operation on a building component represented in the form of a polygonal prism in the three-dimensional representation method of the building component as described in any one of the first aspects. The Boolean operation method for building components includes:

[0092] S600, sequentially marking serial numbers on the vertices and intersections of the top surfaces of the building components in the form of two polygonal prisms in a clockwise or counterclockwise order;

[0093] S700 , calculating the Boolean difference, union, or intersection between two building components represented by polygonal prisms according to the sequence number in S600 .

[0094] Furthermore, in the step S600, any vertex or intersection point on any one of the two building components is marked with a serial number (A m , B n );

[0095] When the marked point is a vertex on the top surface of the first building component, A m The order of the points on the top surface of the first building element in a predetermined sequence, B n is -1;

[0096] When the marked point is a vertex on the top surface of the second building component, B n The order of the points on the top surface of the second building element in a predetermined sequence, A m is -1;

[0097] When the marked point is an intersection of the top surface of the first building component and the top surface of the second building component, Am A is the value of the two vertices adjacent to the point and the top surface of the first building component. m Decimals between values, B n B is the value of the two vertices adjacent to the point and the top surface of the second building component. n Decimals between values.

[0098] Furthermore, in the above S700, for the case of calculating the Boolean difference between two building components:

[0099] Project the top surfaces of the two building components onto the same plane, and obtain the marked serial numbers of all vertices and intersections of the top surfaces of the two building components;

[0100] placing the labeled serial numbers of the vertices of the top surface of the subtrahend building component that are inside the top surface of the subtrahend building component into the result list, placing the labeled serial numbers of the vertices of the top surface of the subtrahend building component that are not above or inside the top surface of the subtrahend building component into the result list, and placing the labeled serial numbers of the intersection of the top surfaces of two building components into the result list;

[0101] According to the number of each point in the result list, m The values ​​are sorted in positive order and by B n The values ​​are sorted in reverse order and connected in sequence according to the first rule to form a two-dimensional projection of the top surface of the difference building component after the Boolean difference operation of the two building components, and the height of the minuend building component is used as the height of the difference building component to obtain a three-dimensional model of the difference building component;

[0102] The first rule includes:

[0103] When the top surfaces of two building components have two intersection points on the same edge, for all connection paths between the two intersection points, determine the position of the midpoint of the line segment where the connection path is located, and eliminate the connection path whose midpoint is within the subtractive polygon;

[0104] When one edge of the top surfaces of two building components is tangent, all vertices of the top surfaces of the two building components are traversed in the same order. For the two end points of the line segment where the overlapping part of the two tangent edges is located, if the traversal order is the same during the two traversals, they will be eliminated; if the traversal order is opposite, they will be retained.

[0105] Furthermore, in the above S700, for the case of calculating the Boolean union between two building components:

[0106] Project the top surfaces of the two building components onto the same plane, and obtain the marked serial numbers of all vertices and intersections of the top surfaces of the two building components;

[0107] Putting the marked serial numbers of the vertices located on the top surface of one building component but not on the top surface of the other building component into the result list, and putting the marked serial numbers of the intersection points of the top surfaces of the two building components into the result list;

[0108] Sort the building components where each vertex in the result list is located in a forward order according to their labeled serial numbers, and connect them in sequence according to the second rule to form a two-dimensional projection of the top surface of the union building component after the Boolean union operation of the two building components, and use the union of the heights of the two building components as the height of the union building component to obtain a three-dimensional model of the union building component;

[0109] The second rule includes:

[0110] When the top surfaces of two building components have two intersection points on the same edge, determine the midpoint of the line segment of the connection path between any two points in the result list, eliminate the connection paths whose midpoints are inside or above the top surface of any building component, and retain the connection paths that are not inside or above the top surface of any building component;

[0111] When one edge of the top surfaces of two building components is tangent, all vertices of the top surfaces of the two building components are traversed in the same order. For the two end points of the line segment where the overlapping part of the two tangent edges is located, if the order of the two traversals is the same, they are retained; if the order of the two traversals is opposite, they are discarded.

[0112] Furthermore, in the above S700, for the case of calculating the Boolean intersection between two building components:

[0113] Project the top surfaces of the two building components onto the same plane, and obtain the marked serial numbers of all vertices and intersections of the top surfaces of the two building components;

[0114] Adding the marked serial numbers of the vertices simultaneously located within the top surfaces of the two building components into the result list, and adding the marked serial numbers of the intersection points of the top surfaces of the two building components into the result list;

[0115] Sort the building components where the vertices and intersections are located in the result list in a positive order, and connect them in sequence according to the third rule to form a two-dimensional projection of the top surface of the intersection building component after the Boolean intersection operation of the two building components, and use the intersection of the heights of the two building components as the height of the intersection building component to obtain a three-dimensional model of the intersection building component;

[0116] The third rule includes:

[0117] When the top surfaces of two building components have two intersection points on the same edge, determine the midpoint of the line segment of the connection path between any two points in the result list, eliminate the connection paths with midpoints above or outside the top surfaces of the two building components, and retain the connection paths with midpoints within the top surface of any building component;

[0118] When one edge of the top surfaces of two building components is tangent, all vertices of the top surfaces of the two building components are traversed in the same order. For the two end points of the line segment where the overlapping part of the two tangent edges is located, if the order of the two traversals is the same, they are retained; if the order of the two traversals is opposite, they are discarded.

[0119] The embodiments of the present invention provide a universal three-dimensional representation method for building components of different shapes, simplifying the modeling process of building components and improving modeling efficiency. At the same time, when building components are used for interference detection and Boolean operations in engineering, calculations based on polygonal prism models can achieve more efficient, standardized and reliable engineering processing. BRIEF DESCRIPTION OF THE DRAWINGS

[0120] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0121] Figure 1 Schematic diagram of the flow of a three-dimensional representation method for building components according to the first embodiment of the present invention;

[0122] Figure 2 2 is a flow chart of a method for detecting interference of building components according to a second embodiment of the present invention;

[0123] Figure 3 1 is a flow chart of a Boolean operation method for building components according to a third embodiment of the present invention;

[0124] Figure 4 A schematic diagram of converting a rectangular column building component into a polygonal prism model according to the three-dimensional representation method of the building component according to the first embodiment of the present invention;

[0125] Figure 5 A schematic diagram of converting a rectangular beam building component into a polygonal prism model according to the three-dimensional representation method of the building component according to the first embodiment of the present invention;

[0126] Figure 6 A schematic diagram of converting a cylindrical building component into a polygonal prism model according to the three-dimensional representation method of the building component according to the first embodiment of the present invention;

[0127] Figure 7 A schematic diagram of converting an arc-shaped building component into a polygonal prism model according to the three-dimensional representation method of the building component according to the first embodiment of the present invention;

[0128] Figure 8 is a schematic diagram of point interference in the interference detection method for building components according to the second embodiment of the present invention;

[0129] Figure 9 is a schematic diagram of interference with a straight line in an interference detection method for a building component according to a second embodiment of the present invention;

[0130] Figure 10-14 Schematic diagrams of several situations of calculating difference sets in the Boolean operation method for building components in the third embodiment of the present invention;

[0131] Figures 15-19 Schematic diagrams of several situations of calculating unions in the Boolean operation method for building components in the third embodiment of the present invention;

[0132] Figure 20-24 Schematic diagrams of several situations of calculating intersections in the Boolean operation method for building components in the third embodiment of the present invention;

[0133] Figure 25 and Figure 26 FIG. 1 is a schematic diagram of dividing the top surface of a building component into triangles in the interference detection method for a building component according to the second embodiment of the present invention. DETAILED DESCRIPTION

[0134] The description of the embodiments in this specification should be combined with the corresponding drawings, which should be considered a complete part of this specification. In the drawings, the shapes and thicknesses of the embodiments may be exaggerated and indicated for simplicity or convenience. Furthermore, the various structural components in the drawings will be described separately. It is worth noting that components not shown in the drawings or not described in words are known to those of ordinary skill in the art.

[0135] The description of the embodiments herein and any references to directions and orientations are for ease of description only and are not to be construed as limiting the scope of the present invention. The following description of the preferred embodiments may involve combinations of features, which may exist independently or in combination. The present invention is not specifically limited to the preferred embodiments. The scope of the present invention is defined by the claims.

[0136] In the present invention, a polygonal prism refers to a prism with a polygonal cross section, wherein the polygon may be a convex polygon or a concave polygon, rather than a multi-prism as defined in mathematics.

[0137] like Figure 1As shown, the three-dimensional representation method of a building component according to the first embodiment of the present invention includes:

[0138] S100, determining the type of building component.

[0139] There are four types of building components: rectangular columns, rectangular beams, cylinders, and arcs. All building components can be categorized as one of these four types. For example, basement exterior walls, shear wall columns, and shear wall bodies can be classified as rectangular beams. Compared to commonly used triangular or quadrilateral meshes, representing building component 3D models using polygonal prisms generally does not lose information required for construction engineering and can significantly improve the efficiency and reliability of engineering calculations.

[0140] S200 : Constructing a local coordinate system for representing the building component in a three-dimensional form of a polygonal prism according to the type of the building component, thereby converting the building component into a polygonal prism model.

[0141] Among them, the building components of rectangular columns, rectangular beams, cylinders, and arcs each have parameters for converting into polygonal prism models. Therefore, the classification of building components of different shapes into one of the four types is determined by the inherent parameter characteristics of the building component itself, which will be described in detail below.

[0142] Polygonal prism models require a convenient local coordinate system, whether rectangular or cylindrical, depending on the characteristics of the building component. This allows for convenient location of any point on the polygonal prism for applications such as rebar generation. The definition of the local coordinate system varies for each geometric description method. Converting to a local coordinate system (i.e., a polygonal prism model) can significantly improve the efficiency and reliability of engineering calculations for building components.

[0143] like Figure 4 As shown, for a rectangular column building component, it has a rotation angle parameter for establishing a local coordinate system. The method for establishing a local coordinate system for a rectangular column building component is as follows:

[0144] Define the original x-axis direction as east (1, 0, 0) and the original y-axis direction as north (0, 1, 0);

[0145] Define the center point of the bottom surface as O, which is a three-element vector of double-precision floating-point numbers;

[0146] Define the length of the bottom surface in the x-axis direction as l, the length of the bottom surface in the y-axis direction as w, the height as h, and the rotation angle around the z-axis as α, all of which are double-precision floating-point numbers;

[0147] The vertices of the bottom surface defined in the counterclockwise direction are P0, P1, P2, and P3, respectively, and we have:

[0148] P0=O+(l*cosa+w*sina,-l*sina+w*cosa,0)

[0149] P1=O+(-l*cosa+w*sina,-l*sina+w*cosa,0)

[0150] P2=O+(-l*cosa+w*sina,l*sina+w*cosa,0)

[0151] P3=O+(l*cosa+w*sina,l*sina+w*cosa,0)

[0152] The height h of the polygonal prism model remains unchanged as the height h of the original rectangular column;

[0153] Then the local coordinate system of the rectangular column building component is the homogeneous matrix with the x-axis, y-axis and original z-axis rotated by an angle α around the z-axis as the coordinate axes and the bottom center point O as the translation, which is:

[0154]

[0155] Among them, the rotation angle α ≥ 0;

[0156] When the rotation angle α = 0, the polygonal prism model after transformation is as follows Figure 4 As shown in the rectangular column RC1; when the rotation angle α>0, the polygonal prism model after transformation is as follows Figure 4 As shown in the middle rectangular column RC2.

[0157] like Figure 5 As shown in the figure, for a rectangular beam building component, it has line segment, thickness, and height parameters for establishing a local coordinate system. Among them, the method for establishing a local coordinate system for rectangular beam building components such as rectangular beams, basement exterior walls, shear wall columns, and shear wall bodies is as follows:

[0158] Define the bottom midline segment (some rectangular beam building components often use the top surface in actual use, but can still be converted to be processed as the bottom surface) with endpoints A and B, which are three-element vectors of double-precision floating-point numbers;

[0159] Define the width of the bottom surface perpendicular to the midline as w, and the height as h, both of which are double-precision floating-point numbers;

[0160] According to the endpoints A and B of the bottom midline segment, the length of the bottom midline segment is obtained as l, and the tangent direction T of the building component of the rectangular beam is obtained. According to the z-axis direction, the normal direction N of the building component of the rectangular beam is determined, and:

[0161] l=|BA|

[0162]

[0163] The vertices of the bottom surface defined in the counterclockwise direction are P0, P1, P2, and P3, respectively, and we have:

[0164]

[0165] The height h of the polygonal prism model remains unchanged as the height h of the original rectangular beam;

[0166] Then the local coordinate system of the rectangular beam building component is a homogeneous matrix with the tangent direction T, the normal direction N and the z-axis direction as coordinate axes and the endpoint A of the bottom midline segment as the translation:

[0167]

[0168] Among them, the polygonal prism model after the transformation from the rectangular beam is as follows Figure 5 The rectangular beam RB1 is shown in the figure. The polygonal prism model after the transformation of the basement exterior wall (essentially also a rectangular beam) is as follows: Figure 5 The exterior wall of the middle basement is shown in PW1.

[0169] like Figure 6 As shown, for a cylindrical building component, it has cylindrical parameters for establishing a local coordinate system. The method for establishing a local coordinate system is as follows:

[0170] Define the center of the bottom circle as O, which is a three-element vector of double-precision floating-point numbers;

[0171] Define the bottom radius as r and the height as h, both of which are double-precision floating-point numbers;

[0172] The cylindrical building component is transformed into a polygonal prism with a predetermined number of side segments i, and the vertices of the bottom polygon are defined as P0, P1, P2, ..., P in the counterclockwise direction. i-1 , then for a given number of side segments i, we have:

[0173]

[0174]

[0175]

[0176] Among them, i is an integer. In order to ensure the accuracy of the positions of the four extreme points, i is generally specified as a multiple of 4.

[0177] The local coordinate system of the cylindrical building component is a cylindrical coordinate system with the bottom center O as the center, the x-axis as the polar axis, and the z-axis as the height.

[0178] When i=60, the cylindrical building component is transformed into a polygonal prism model as shown in Figure 6 As shown, i=60 is a more preferred value that takes both computational efficiency and computational accuracy into consideration.

[0179] like Figure 7 As shown, for an arc-shaped building component, it has arc, thickness and height parameters for establishing a local coordinate system. For an arc-shaped building component such as an arc beam, the method for establishing a local coordinate system is as follows:

[0180] Define the arc's center as O, and its two endpoints in the counterclockwise direction as A and B, both of which are triple vectors of double-precision floating-point numbers;

[0181] Define the arc's radius as r, radial width as w, and height as h, all of which are double-precision floating-point numbers;

[0182] The arc-shaped building component is converted into a polygonal prism with a predetermined number of side segments i, and the arc positions of the two end points of the arc are calculated:

[0183] θ A =arctan2(Ay-Oy,Ax-Ox)

[0184] θ B =arctan2(By-Oy,Bx-Ox)

[0185] Where i is an integer. To ensure the accuracy of the extreme point position, assume that the arc angle is 360° (full circle) and the number of segments is i', then i' should be a multiple of 4. At the same time, the actual number of segments i should be calculated using i' through the ratio of the actual angle to 360°;

[0186] The following example illustrates that when specifying 360°, i'=60, and the arc of the building component is 120°, then i should be specified as 1 / 3 of i', that is, 20;

[0187] Define α as the distance from θ in the counterclockwise direction A to θ B The angle between , and α is a positive number, we have:

[0188] α=(θ B +2π-θ A )%2π

[0189] Traverse the arc by angle, starting from θA, and calculate the step length θ based on the angle α and the number of segments i Δ , let the angle increase until θ B ,have:

[0190] θ Δ =α / i

[0191] According to the step size θ Δ In the counterclockwise direction from θA to θ B Step by step, calculate the normal function f for any angle θ on the arc norm (θ) and position function f Pos (θ), we have:

[0192] f Norm (θ)=(cosθ,sinθ,0)

[0193] f Pos (θ)=O+f Norm (θ)*r

[0194] Then the position function f of the vertex of the bottom polygon of the building component located outside the arc AB is P (θ) is:

[0195]

[0196] and the position function f of the vertex of the bottom polygon of the building component located inside the arc AB P '(θ) is

[0197]

[0198] Among them, when θ is taken as θ A ,θ A +θ Δ ,θ A +θ Δ *2、θ A +θ Δ *3. When θB, f P (θ) is the polygonal vertex P0, P1, P2, ..., P from the arc endpoint A to the outside of B. i , f P '(θ) is the polygon vertex P0', P1', P2', ..., P from the arc endpoint A to the inner side of B i ';

[0199] The height h of the polygonal prism is the same as the height h of the building component;

[0200] Then the local coordinate system of the arc-shaped building component is (x, y, z), where x is the arc length from point A, y is the radial distance from the arc, and z is the height, and:

[0201]

[0202] f(x,y,z)=O+f Pos (θ)+f Norm (θ)*y+(0,0,z)

[0203] Where θ is the radian distance to point A.

[0204] In summary, the three-dimensional representation method of this embodiment converts building components of different shapes into polygonal prism models for expression, which can be conveniently used in subsequent engineering calculations, thereby improving calculation efficiency and reliability.

[0205] like Figure 2 As shown, the interference detection method for building components according to the second embodiment of the present invention is used to perform interference detection on a polygonal prism building component or a building component converted into a polygonal prism model according to the method of the first embodiment, comprising:

[0206] S300: Obtain the coordinate range of a building component in the form of a polygonal prism in its local coordinate system.

[0207] The local coordinate system information of the corresponding building component can be obtained according to the three-dimensional representation method of the first embodiment.

[0208] S400: Divide the top surface of the building component in S300 into a plurality of triangles.

[0209] In this embodiment, it specifically includes:

[0210] S410, judging whether the top surface of the current building component is a convex polygon based on the angles of the internal angles of the top surface of the current building component;

[0211] When at least one interior angle greater than 180° exists, it is determined to be a concave polygon top surface and the process proceeds to S420 ;

[0212] When the angles of all internal angles are less than 180°, it is determined to be a convex polygon top surface and the process proceeds to S430 .

[0213] S420, such as Figure 25 and Figure 26 As shown, for any internal angle of the top surface of the current building component with an angle greater than 180°, two sides on one side of the internal angle are connected end to end to form a first triangle, and two sides on the other side are connected end to end to form a second triangle, and it is determined whether the first triangle and the second triangle are inside the top surface polygon of the current building component. If so, the connection line of the triangles is retained; if not, the connection line of the triangles is cancelled, and then the process returns to S410;

[0214] After this step, an inner angle with an angle greater than 180° may be segmented. If the angle after segmentation is still greater than 180°, the process returns to S410 and then enters S420 for segmentation again until all segmented angles of the inner angle are less than 180°.

[0215] S430 , starting from any vertex of the top surface of the current building component, connecting lines to all other vertices respectively, and dividing the top surface of the current building component into a plurality of triangles.

[0216] S500 , in the local coordinate system of the building component in S300 , calculating interference conditions between each triangle on the top surface of the building component obtained in S400 and the point to be detected, the straight line, the line segment and other building components.

[0217] like Figure 8 As shown, for the interference between points, the detection method is as follows:

[0218] Obtain the coordinate range of each triangle on the top surface of the current building component, and determine whether the coordinate of the point to be measured is within the coordinate range of any of the triangles;

[0219] Among them, the cross multiplication method is used to determine whether the coordinates of the measured point are within the triangle. The steps are as follows:

[0220] like Figure 8 As shown, along the clockwise direction, the three vertices of any triangle on the top surface of the building component are A, B and C respectively. Connect the point P to be measured with points A, B and C respectively to obtain vectors AP, BP and CP. Point P is inside or on the triangle, and the triangle is defined clockwise. Then vector AP should be in the clockwise direction of vector AB or coincide with vector AB; vector BP should be in the clockwise direction of vector BC or coincide with vector BC; vector CP should be in the clockwise direction of vector CA or coincide with vector CA, that is:

[0221] AB×AP≥0∧BC×BP≥0∧CA×CP≥0

[0222] If the above conditions are met, point P is on triangle ABC or inside triangle ABC, that is, the coordinates of point P are within the coordinate range of triangle ABC.

[0223] According to the above process, by detecting each triangle between the test point and the top surface of the building component, it can be determined whether the test point interferes with the building component. If the test point is not within any triangle on the top surface of the current building component, it is determined that there is no interference between the test point and the current building component; otherwise, there is interference.

[0224] like Figure 9 As shown, the detection method for interference with a straight line is as follows:

[0225] First, determine whether the line to be measured interferes with the maximum and minimum values ​​of the xyz axis of the polygonal prism. This requires determining the intersection of the line to be measured with the xy plane, yz plane, and zx plane, and whether the intersection is within the maximum and minimum values ​​of the xy axis, yz axis, and zx axis. If at least one of the above three conditions is met, it means that the line to be measured and the polygonal prism may interfere. Otherwise, the result is directly returned as no interference. If there is possible interference, the following method is used to determine whether there is interference:

[0226] Obtain a projection line segment of the straight line to be measured on the top surface of the current building component; if the straight line to be measured is a horizontal line, the endpoints of the projection line segment are the intersection points of the straight line to be measured with the maximum and minimum value ranges of the x-axis and / or y-axis and / or z-axis coordinates of the current building component; if the straight line to be measured is a non-horizontal line, the endpoints of the projection line segment are the intersection points of the straight line to be measured with the top surface and the bottom surface of the current building component, respectively; in addition, if the straight line to be measured is a vertical line, the two endpoints of the projection line segment coincide on the projection surface.

[0227] If any endpoint of the projected line segment is above or within the top polygon of the current building component, and / or the projected line segment is tangent to or intersects with any edge of the top polygon of the current building component, then it is determined that the straight line to be measured interferes with the current building component; otherwise, the straight line to be measured does not interfere with the current building component;

[0228] The method for determining whether the projected line segment intersects with any edge of the top polygon of the current building component is as follows:

[0229] like Figure 9 As shown, the endpoints of the projection line segment are A and B, and the endpoints of one side of the top polygon of the current building component are C and D. If vector AC and vector AD are in different clockwise directions of vector AB, and vector CA and vector CB are in different clockwise directions of vector CD, that is:

[0230] (AB×AC)*(AB×AD)<0∧(CD×CA)*(CD×CB)<0

[0231] Then it is determined that line segment AB and line segment CD intersect, otherwise line segment AB and line segment CD do not intersect.

[0232] According to the above process, by detecting the straight line to be measured and each triangle on the top surface of the building component, it can be determined whether the straight line to be measured interferes with the building component. If the straight line to be measured is not tangent to or intersects with any triangle on the top surface of the current building component, it is determined that the straight line to be measured does not interfere with the current building component; otherwise, there is interference.

[0233] For interference with line segments, the detection method is as follows:

[0234] Obtaining coordinates of the endpoints of the line segment to be measured in the local coordinate system of the current building component, and determining that the line segment to be measured interferes with the current building component if any endpoint of the line segment to be measured is above or within the top polygon of the current building component, and / or the line segment to be measured is tangent to or intersects with any edge of the top polygon of the current building component; otherwise, determining that the line segment to be measured does not interfere with the current building component;

[0235] The method for determining whether the line segment to be tested intersects any edge of the top polygon of the current building component is the same as the determination principle of the projected line segment when determining the linear interference, which will not be repeated here.

[0236] For interference with other building components, the detection method is as follows:

[0237] Obtaining the coordinate range of the building component to be measured in the local coordinate system of the current building component, projecting the top surfaces of the two building components onto the same plane, and sequentially determining whether each edge of the top surface of one building component interferes with each edge of the top surface of the other building component. If at least one set of edges interferes with each other, then it is determined that there is interference between the two building components; otherwise, there is no interference between the two building components.

[0238] The method for determining the interference between any edge of the top surface of one building component and any edge of the top surface of another building component is the same as the principle for determining the interference of projection line segments mentioned above, and will not be repeated here.

[0239] like Figure 3 As shown, the interference detection method for building components according to the third embodiment of the present invention is used to perform Boolean operations on polygonal prism building components or building components converted into polygonal prism models according to the method of the first embodiment, including:

[0240] S600: Mark the vertices and intersections of the top surfaces of the building components in the form of two polygonal prisms with serial numbers in a clockwise or counterclockwise order.

[0241] Each vertex or intersection point can be represented by two indexes: the first is index A, which is located in the minuend polygon, and the second is index B, which is located in the subtrahend polygon. If a resulting vertex is not on the minuend or subtrahend polygon, a null value is used. If a resulting vertex is not a vertex of the minuend or subtrahend polygon, but is located on the edge of the top polygon, the index can be represented as a decimal.

[0242] S700 , calculating the Boolean difference, union, or intersection between two building components represented by polygonal prisms according to the sequence number in S600 .

[0243] like Figure 10As shown, for the case of computing the Boolean difference between two building components:

[0244] There are two possible scenarios: One is to keep the xy position of the top polygon of the first polygonal prism unchanged, and to use the difference in the z-axis extents of the two polygons as the resulting z-axis position and height of the top polygon. This method is relatively simple and will not be described in detail here. The other method is to use the difference in the top polygons of the two polygonal prisms as the resulting top polygon, and use the height of the first polygonal prism as the resulting height. The method is as follows:

[0245] The top surfaces of the two building components are projected onto the same plane (such as the top surface of the minuend polygonal prism), so that the two three-dimensional polygonal prisms can be converted into polygons on the plane for processing.

[0246] The labeled serial numbers of the vertices of the top surface of the minuend building component that are inside the top surface of the minuend building component are placed in the result list, and the labeled serial numbers of the vertices of the top surface of the minuend building component that are not above or inside the top surface of the minuend building component are placed in the result list, and the labeled serial numbers of the intersection of the top surfaces of two building components are placed in the result list.

[0247] After the above process, the result list contains serial numbers such as Figure 11 As shown in the figure, it can be seen that by sorting the subtracted polygon numbers in the forward direction and the subtrahend polygon numbers in the reverse direction, the vertex order of the difference polygon can be obtained. However, there are some common problems that need to be handled:

[0248] like Figure 12 As shown in the figure, when there are multiple intersection points on the same side of the minuend polygon or the subtrahend polygon, it is more complicated to determine the connection path. According to the serial number arrangement principle, ABCD and AD are both reasonable. The former is sorted in reverse order according to the subtrahend polygon serial number, while the latter is sorted in forward order according to the minuend polygon serial number. In fact, ABCD should be selected. Figure 13 As shown, a binary search method is used to solve this problem: for each path, determine whether its midpoint lies within the subtrahend polygon. If so, discard the path. Since the midpoint of AD lies within the subtrahend polygon, it is discarded; however, the midpoints of AB, BC, and CD all lie within the subtrahend polygon, so they are retained.

[0249] like Figure 14As shown in the figure, when the minuend and subtrahend polygons are tangent, the direction method is used to determine: for internal tangency, if the AB edge in the minuend and subtrahend polygons is the same direction (clockwise), then it is eliminated; for external tangency, if the CD edge in the minuend and subtrahend polygons is different, clockwise in the minuend and counterclockwise in the subtrahend, then it is retained. In other words, the AB edge in the left figure is internal and needs to be eliminated from the result; the CD edge in the right figure is external and needs to be retained.

[0250] After the above processing, the vertices in the result list are sorted in forward order according to serial number A and in reverse order according to serial number B to obtain the correct arrangement order. The result polygons are generated by connecting them in sequence, thereby obtaining the polygonal prism resulting from the Boolean subtraction operation.

[0251] like Figure 15 As shown, for the case of computing the Boolean union between two building blocks:

[0252] Project the top surfaces of the two building components onto the same plane, add the annotation serial numbers of the vertices located on the top surface of one of the building components but not on the top surface of the other building component into the result list, and add the annotation serial numbers of the intersection points of the top surfaces of the two building components into the result list.

[0253] After the above process, the result list contains serial numbers such as Figure 16 As shown in the figure, it can be seen that by sorting the vertices in the order of the polygons they belong to, the vertex order of the union polygon can be obtained. However, there are some common problems that need to be handled:

[0254] like Figure 17 As shown in , when there are multiple intersection points on the same side of the minuend polygon or the subtrahend polygon, according to the serial number arrangement principle, ABCD and AD are both reasonable. The former is sorted in a positive order according to the serial number of the first polygon, while the latter is sorted in a positive order according to the serial number of the second polygon. In fact, ABCD should be selected. Figure 18 As shown, a bisection method is used to solve this problem: for each path, determine whether its midpoint lies within a polygon. If so, discard the path. Since the midpoint of AD lies within the second polygon, it is discarded. However, the midpoints of AB, BC, and CD do not lie within any polygon, so they are retained.

[0255] like Figure 19 As shown in the figure, when two polygons are tangent, the direction method is used to determine: if the AB edge is in the same direction in both polygons, it is retained; on the right, if the CD edge is in different directions in the two polygons, it is removed. In other words, the AB edge in the left figure is internal and needs to be retained; the CD edge in the right figure is external and needs to be removed.

[0256] After the above processing, the vertices in the result list are sorted according to the sequence number A and the sequence number B to obtain the correct arrangement order, generate the result polygon, and thus obtain the polygonal prism resulting from the Boolean operation union.

[0257] like Figure 20 As shown, for the case of computing the Boolean intersection between two building components:

[0258] Project the top surfaces of the two building components onto the same plane, add the marked serial numbers of the vertices simultaneously located within the top surfaces of the two building components into the result list, and add the marked serial numbers of the intersection points of the top surfaces of the two building components into the result list;

[0259] After the above process, the result list contains serial numbers such as Figure 21 As shown in the figure, it can be seen that by sorting the vertices in the order of the polygons they are in, the vertex order of the intersection polygon can be obtained. However, there are some common problems that need to be handled:

[0260] like Figure 22 As shown in , when there are multiple intersection points on the same side of the minuend polygon or the subtrahend polygon, where the first polygon is a rectangle and the second polygon is a large C-shape, the intersection should be a small C-shape. According to the principle of sequence number arrangement, ABCD and AD are both reasonable. The former is sorted in a positive order according to the sequence number of the first polygon, while the latter is sorted in a positive order according to the sequence number of the second polygon. In fact, ABCD should be selected. Figure 23 As shown, we use a binary search to solve this problem: for each connecting path, determine whether the midpoint is inside any polygon. If so, remove the path. Since the midpoint of AD is outside two polygons, it is removed; while the midpoints of AB, BC, and CD are inside at least one polygon, so they are retained.

[0261] like Figure 24 As shown in the figure, when two polygons are tangent, the direction method is used to determine: if the AB edge is in the same direction in both polygons, it is retained; if the CD edge is in different directions in the two polygons, it is removed. In other words, the AB edge in the left figure is internal and needs to be retained; the CD edge in the right figure is external and needs to be removed.

[0262] After the above processing, the vertices in the result list are sorted according to the sequence number A and the sequence number B to obtain the correct arrangement order, generate the result polygon, and thus obtain the polygonal prism resulting from the Boolean intersection operation.

[0263] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A three-dimensional representation method for building components, characterized in that: The three-dimensional representation method of the building component includes: S100, determining the type of building component; There are four types of building components, namely rectangular columns, rectangular beams, cylinders and arc-shaped bodies; S200, constructing a local coordinate system for representing the building component in a three-dimensional form of a polygonal prism according to the type of the building component, thereby converting the building component into a polygonal prism model; The rectangular column building component has a rotation angle parameter for establishing the local coordinate system, the rectangular beam building component has line segment, thickness and height parameters for establishing the local coordinate system, the cylindrical building component has cylindrical parameters for establishing the local coordinate system, and the arc-shaped building component has arc, thickness and height parameters for establishing the local coordinate system. In the S200, for the arc-shaped building component: Define the arc center as O, the two endpoints of the arc as A and B, the radius of the arc as r, the radial width as w, and the height as h. Convert the arc-shaped building component into a polygonal prism with a predetermined number of side segments i, and calculate the arc positions of the two endpoints of the arc: θ A =arctan2(A.y-O.y,A.x-O.x) θ B =arctan2(By-Oy,Bx-Ox) Define α as the distance from θ in the counterclockwise direction A to θ B The angle between , and α is a positive number, we have: α=(θ B +2π-θ A )%2π Among them, % represents the remainder operation; For a given number of side segments i, calculate the step length θ according to the size of the angle α Δ : i Δ =a / i According to the step size θ Δ In the counterclockwise direction from θ A to θ B Step by step, calculate the normal function f for any angle θ on the arc norm (θ) and position function f Pos (θ), we have: f Norm (θ)=(cosθ,sinθ,0) f Pos (θ)=O+f Norm (i)*r Then the position function f of the vertex of the bottom polygon of the arc-shaped building component located outside the arc AB is P (θ) is: and the position function f of the vertex of the bottom polygon of the arc-shaped building component located inside the arc AB P '(θ) is Among them, when θ is taken as θ A ,θ A +θ Δ ,θ A +θ Δ *2、θ A +θ Δ *3. When θB, f P (θ) is the polygonal vertex P0, P1, P2, ..., P from the arc endpoint A to the outside of B. i , f P '(θ) is the polygon vertex P0', P1', P2', ..., P from the arc endpoint A to the inner side of B i '; Then the local coordinate system of the arc-shaped building component is (x, y, z), where x is the arc length from point A, y is the radial distance from the arc, and z is the height, and: f(x,y,z)=O+f Pos (θ)+f Norm (θ)*y+(0,0,z) Where θ is the radian distance to point A.

2. The three-dimensional representation method of building components according to claim 1, characterized in that: In the S200, for the rectangular column building component: Define the original x-axis direction as east (1,0,0), the original y-axis direction as north (0,1,0), and the original z-axis direction as up (0,0,1); Define the center point of the bottom surface as O, the length of the bottom surface in the x-axis direction as l, the length of the bottom surface in the y-axis direction as w, the height as h, the rotation angle around the z-axis as α, and the vertices of the bottom surface defined in the counterclockwise direction as P0, P1, P2, and P3 respectively. Then the local coordinate system of the rectangular column building component is the homogeneous matrix with the x-axis, y-axis and original z-axis rotated by an angle α around the z-axis as the coordinate axes and the bottom center point O as the translation, which is: Among them, Ox, Oy, and Oz are the components of point O on the xyz axis; the rotation angle α ≥ 0.

3. The three-dimensional representation method of building components according to claim 1, characterized in that: In S200, for the rectangular beam building component: Define the endpoints of the bottom midline segment as A and B, the width of the bottom perpendicular to the midline as w, and the height as h. Based on the endpoints A and B of the bottom midline segment, the length of the bottom midline segment is obtained as l. The tangent direction T of the building component of the rectangular beam is determined. Based on the z-axis direction, the normal direction N of the building component of the rectangular beam is determined as follows: l=|BA| The vertices of the bottom surface defined in the counterclockwise direction are P0, P1, P2, and P3, respectively, and we have: Then the local coordinate system of the rectangular beam building component is a homogeneous matrix with the component tangent direction T, normal direction N and z-axis direction as coordinate axes and the endpoint A of the bottom midline segment as translation: Among them, Tx, Ty are the xy-axis components of T; Nx, Ny are the xy-axis components of N; Ax, Ay, Az are the xyz-axis components of A.

4. The three-dimensional representation method of building components according to claim 1, characterized in that: In S200, for the cylindrical building component: Define the original x-axis direction as east (1,0,0) and the original z-axis direction as up (0,0,1); Define the bottom center as O, the bottom radius as r, and the height as h, and transform the cylindrical building component into a polygonal prism with a predetermined number of side segments i, and define the vertices of the bottom polygon in the counterclockwise direction as P0, P1, P2, ..., P i-1 , then for a given number of side segments i, we have: The local coordinate system of the cylindrical building component is a cylindrical coordinate system with the bottom center O as the circle center, the original x-axis direction as the polar axis direction, and the original z-axis direction as the height direction.

5. A method for interference detection of building components, for performing interference detection on building components represented in the form of polygonal prisms in the three-dimensional representation method of building components according to any one of claims 1 to 4, characterized in that: The interference detection method of the building component comprises: S300, obtaining a coordinate range of a building component in the form of a polygonal prism in its local coordinate system; S400, dividing the top surface of the building component in S300 into a plurality of triangles; S500 , in the local coordinate system of the building component in S300 , calculating interference conditions between each triangle on the top surface of the building component obtained in S400 and the point to be detected, the straight line, the line segment and other building components.

6. The interference detection method for building components according to claim 5, characterized in that: The S400 includes: S410, judging whether the top surface of the current building component is a convex polygon based on the angles of the internal angles of the top surface of the current building component; When at least one interior angle greater than 180° exists, it is determined to be a concave polygon top surface and the process proceeds to S420 ; When all interior angles are less than 180°, it is determined to be a convex polygon top surface and the process proceeds to S430 ; S420: For any interior angle of the top surface of the current building component with an angle greater than 180°, connect the two sides on one side of the interior angle end-to-end to form a first triangle, and connect the two sides on the other side end-to-end to form a second triangle, and determine whether the first triangle and the second triangle are inside the top polygon of the current building component. If so, retain the line connecting the triangles; if not, cancel the line connecting the triangles, and then return to S410; S430 , starting from any vertex of the top surface of the current building component, connecting lines to all other vertices respectively, and dividing the top surface of the current building component into a plurality of triangles.

7. The interference detection method for building components according to claim 6, characterized in that: In the above S500, regarding the interference between the points: Obtain the coordinate range of each triangle on the top surface of the current building component, and determine whether the coordinate of the point to be measured is within the coordinate range of any of the triangles; Among them, to determine whether the coordinates of the point to be measured are within the triangle, the steps are as follows: In the clockwise direction, the three vertices of the triangle are A, B and C. Connect the point P to be measured with points A, B and C respectively to obtain vectors AP, BP and CP; Determine whether vector AP is in the clockwise direction of vector AB or coincides with vector AB, and obtain result 1; Determine whether vector BP is in the clockwise direction of vector BC or coincides with vector BC, and obtain result 2; Determine whether vector CP is in the clockwise direction of vector CA or coincides with vector CA, and obtain result three; If the first, second and third results are all yes, then the test point P is inside the triangle ABC, otherwise the test point P is not inside the triangle ABC; If the point to be measured is not within any triangle on the top surface of the current building component, it is determined that there is no interference between the point to be measured and the current building component; otherwise, there is interference.

8. The interference detection method for building components according to claim 6, characterized in that: In the above S500, regarding the interference with the straight line: Obtain the projection line segment of the straight line to be measured on the top surface of the current building component; If the straight line to be measured is a horizontal line, the endpoints of the projected line segment are the intersections of the straight line to be measured and the maximum and minimum value ranges of the x-axis and / or y-axis and / or z-axis coordinates of the current building component; If the straight line to be measured is a non-horizontal line, the endpoints of the projected line segment are the intersection points of the straight line to be measured and the top and bottom surfaces of the current building component respectively; If any endpoint of the projected line segment is above or within the top polygon of the current building component, and / or the projected line segment is tangent to or intersects with any edge of the top polygon of the current building component, then it is determined that the straight line to be measured interferes with the current building component; otherwise, the straight line to be measured does not interfere with the current building component; The steps to determine whether the projected line segment intersects with any edge of the top polygon of the current building component are as follows: The endpoints of the projected line segment are A and B, and the endpoints of one side of the top polygon of the current building component are C and D. If vector AC and vector AD are in different clockwise directions with respect to vector AB, and vector CA and vector CB are in different clockwise directions with respect to vector CD, then it is determined that line segment AB and line segment CD intersect; otherwise, line segment AB and line segment CD do not intersect.

9. The interference detection method for building components according to claim 6, characterized in that: In S500, regarding the interference with the line segment: Obtaining coordinates of the endpoints of the line segment to be measured in the local coordinate system of the current building component, and determining that the line segment to be measured interferes with the current building component if any endpoint of the line segment to be measured is above or within the top polygon of the current building component, and / or the line segment to be measured is tangent to or intersects with any edge of the top polygon of the current building component; otherwise, determining that the line segment to be measured does not interfere with the current building component; The steps to determine whether the line segment to be tested intersects with any edge of the top polygon of the current building component are as follows: The endpoints of the line segment to be tested are A and B, and the endpoints of one side of the top polygon of the current building component are C and D. If vector AC and vector AD are in different clockwise directions with respect to vector AB, and vector CA and vector CB are in different clockwise directions with respect to vector CD, then it is determined that line segment AB and line segment CD intersect; otherwise, line segment AB and line segment CD do not intersect.

10. The interference detection method for building components according to claim 6, characterized in that: In S500, regarding interference with other building components: Obtaining the coordinate range of the building component to be measured in the local coordinate system of the current building component, projecting the top surfaces of the two building components onto the same plane, and sequentially determining whether each edge of the top surface of one building component interferes with each edge of the top surface of the other building component. If at least one set of edges interferes with each other, then it is determined that there is interference between the two building components; otherwise, there is no interference between the two building components. The steps for determining the interference between any edge of the top surface of one building component and any edge of the top surface of another building component are as follows: The endpoints of one side are A and B, and the endpoints of the other side are C and D. If vector AC and vector AD are in different clockwise directions with respect to vector AB, and vector CA and vector CB are in different clockwise directions with respect to vector CD, then line segment AB and line segment CD intersect; otherwise, line segment AB and line segment CD do not intersect.

11. A Boolean operation method for building components, used for performing Boolean operations on building components represented in the form of polygonal prisms in the three-dimensional representation method of building components according to any one of claims 1 to 4, characterized in that: The Boolean operation method of the building component includes: S600, sequentially marking serial numbers on the vertices and intersections of the top surfaces of the building components in the form of two polygonal prisms in a clockwise or counterclockwise order; S700 , calculating the Boolean difference, union, or intersection between two building components represented by polygonal prisms according to the sequence number in S600 .

12. The Boolean operation method for building components according to claim 11, characterized in that: In the above S600, any vertex or intersection point on any of the two building components is marked with a serial number (A m , B n ); When the marked point is a vertex on the top surface of the first building component, A m The order of the points on the top surface of the first building element in a predetermined sequence, B n is -1; When the marked point is a vertex on the top surface of the second building component, B n The order of the points on the top surface of the second building element in a predetermined sequence, A m is -1; When the marked point is an intersection of the top surface of the first building component and the top surface of the second building component, A m A is the value of the two vertices adjacent to the point and the top surface of the first building component. m Decimals between values, B n B is the value of the two vertices adjacent to the point and the top surface of the second building component. n Decimals between values.

13. The Boolean operation method for building components according to claim 12, characterized in that: In the above S700, for the case of calculating the Boolean difference between two building components: Project the top surfaces of the two building components onto the same plane, and obtain the marked serial numbers of all vertices and intersections of the top surfaces of the two building components; placing the labeled serial numbers of the vertices of the top surface of the subtrahend building component that are inside the top surface of the subtrahend building component into the result list, placing the labeled serial numbers of the vertices of the top surface of the subtrahend building component that are not above or inside the top surface of the subtrahend building component into the result list, and placing the labeled serial numbers of the intersection of the top surfaces of two building components into the result list; According to the number of each point in the result list, m The values ​​are sorted in positive order and by B n The values ​​are sorted in reverse order and connected in sequence according to the first rule to form a two-dimensional projection of the top surface of the difference building component after the Boolean difference operation of the two building components, and the height of the minuend building component is used as the height of the difference building component to obtain a three-dimensional model of the difference building component; The first rule includes: When the top surfaces of two building components have two intersection points on the same edge, for all connection paths between the two intersection points, determine the position of the midpoint of the line segment where the connection path is located, and eliminate the connection path whose midpoint is within the subtractive polygon; When one edge of the top surfaces of two building components is tangent, all vertices of the top surfaces of the two building components are traversed in the same order. For the two end points of the line segment where the overlapping part of the two tangent edges is located, if the traversal order is the same during the two traversals, they will be eliminated; if the traversal order is opposite, they will be retained.

14. The Boolean operation method for building components according to claim 12, characterized in that: In the above S700, for the case of calculating the Boolean union between two building components: Project the top surfaces of the two building components onto the same plane, and obtain the marked serial numbers of all vertices and intersections of the top surfaces of the two building components; Putting the marked serial numbers of the vertices located on the top surface of one building component but not on the top surface of the other building component into the result list, and putting the marked serial numbers of the intersection points of the top surfaces of the two building components into the result list; Sort the building components where each vertex in the result list is located in a forward order according to their labeled serial numbers, and connect them in sequence according to the second rule to form a two-dimensional projection of the top surface of the union building component after the Boolean union operation of the two building components, and use the union of the heights of the two building components as the height of the union building component to obtain a three-dimensional model of the union building component; The second rule includes: When the top surfaces of two building components have two intersection points on the same edge, determine the midpoint of the line segment of the connection path between any two points in the result list, eliminate the connection paths whose midpoints are inside or above the top surface of any building component, and retain the connection paths that are not inside or above the top surface of any building component; When one edge of the top surfaces of two building components is tangent, all vertices of the top surfaces of the two building components are traversed in the same order. For the two end points of the line segment where the overlapping part of the two tangent edges is located, if the order of the two traversals is the same, they are retained; if the order of the two traversals is opposite, they are discarded.

15. The Boolean operation method for building components according to claim 12, characterized in that: In the above S700, for calculating the Boolean intersection between two building components: Project the top surfaces of the two building components onto the same plane, and obtain the marked serial numbers of all vertices and intersections of the top surfaces of the two building components; Adding the marked serial numbers of the vertices simultaneously located within the top surfaces of the two building components into the result list, and adding the marked serial numbers of the intersection points of the top surfaces of the two building components into the result list; Sort the building components where the vertices and intersections are located in the result list in a positive order, and connect them in sequence according to the third rule to form a two-dimensional projection of the top surface of the intersection building component after the Boolean intersection operation of the two building components, and use the intersection of the heights of the two building components as the height of the intersection building component to obtain a three-dimensional model of the intersection building component; The third rule includes: When the top surfaces of two building components have two intersection points on the same edge, determine the midpoint of the line segment of the connection path between any two points in the result list, eliminate the connection paths with midpoints above or outside the top surfaces of the two building components, and retain the connection paths with midpoints within the top surface of any building component; When one edge of the top surfaces of two building components is tangent, all vertices of the top surfaces of the two building components are traversed in the same order. For the two end points of the line segment where the overlapping part of the two tangent edges is located, if the order of the two traversals is the same, they are retained; if the order of the two traversals is opposite, they are discarded.

Citation Information

Patent Citations

  • Automatic modeling approach for high precision model of complex building

    CN106683167A

  • Open type BIM cross-platform online visualization method based on WebGL

    CN110414148A