A method and device for drawing a tunnel structure plane display diagram based on CAD
Through automated processing and geometric calculations in CAD software, efficient and accurate drawing of tunnel structural surface planar displays is achieved, solving the time-consuming, labor-intensive and error-prone problems of traditional methods and providing a fast and accurate tunnel design and geological analysis tool.
Patent Information
- Application Number
- CN202411410518.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-10
- Publication Date
- 2025-09-23
- Estimated Expiration
- 2044-10-10
AI Technical Summary
Drawing traditional tunnel structure surface plan views is time-consuming, labor-intensive and error-prone. Existing CAD software is insufficiently functional and cannot meet the needs of fast and accurate drawing.
The CAD software interface guides users to select the tunnel axis and cross-sectional lines, automatically checks data validity, generates a tunnel tensile surface model, inputs structural surface parameters, automatically constructs the tunnel structural surface, calculates intersection points, draws a plane display diagram, and outputs it to the CAD model space.
It achieves efficient and accurate generation of tunnel structural surface plan displays, providing more accurate tunnel design and geological condition analysis tools.
Smart Images

Figure CN119416304B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of computer-aided design, and in particular to a method and device for drawing a planar display diagram of a tunnel structure surface based on CAD. Background Art
[0002] During the design and construction phases of tunnel projects, accurate depiction of tunnel structural surfaces is crucial for ensuring project safety and quality. Traditional tunnel structural surface planar representations rely heavily on manual labor, which is not only time-consuming and labor-intensive, but also prone to errors.
[0003] With the development of CAD technology, although the drawing efficiency has been improved to a certain extent, the functions of existing CAD software are still insufficient due to the complexity and diversity of tunnel structural surfaces, and it is difficult to meet the needs of quickly and accurately drawing plane display drawings of tunnel structural surfaces. Summary of the Invention
[0004] The main purpose of this application is to provide a CAD-based method and device for drawing a tunnel structure surface plan display diagram, which realizes the efficient and accurate generation of the tunnel structure surface plan display diagram by integrating automated data processing, geometric calculation and graphics drawing functions.
[0005] To achieve the above objectives, this application provides the following technical solutions:
[0006] According to a first aspect of the present invention, the present invention claims protection for a method and apparatus for drawing a planar display diagram of a tunnel structure based on CAD, comprising:
[0007] The CAD software interface guides the user to select the tunnel axis line and the tunnel cross-section line in sequence, and automatically reads and verifies the data validity of the tunnel axis line and the tunnel cross-section line;
[0008] Based on the selected tunnel axis line and tunnel cross-section line, automatically generating a tunnel extrusion surface model using a surface extrusion operation;
[0009] The user inputs the structural surface attitude parameters through the interactive interface, and the tunnel structural surface is automatically constructed according to the structural surface attitude parameters;
[0010] Evenly dividing the tunnel axis line and the tunnel cross-section line into a specified number of segments to generate a plurality of dividing lines, and calculating the intersection points between the dividing lines and the tunnel structural surface;
[0011] According to the calculated intersection points, lines are automatically connected to form a plane display diagram of the tunnel structure surface in the direction of the tunnel axis, and auxiliary information is drawn to present the distribution of the tunnel structure surface;
[0012] The generated plan display diagram is output to the CAD model space, and the user can edit, annotate or export the graphic file as needed to apply it to the required scene.
[0013] Furthermore, when guiding the user to sequentially select the tunnel axis line and the tunnel cross-section line through the CAD software interface, and automatically reading and verifying the data validity of the tunnel axis line and the tunnel cross-section line, the method further includes:
[0014] In the CAD software, the tunnel axis line and the tunnel cross-section line selected by the user are respectively received, and the direction vector of the tunnel axis is calculated;
[0015] According to the tunnel axis line and the tunnel cross-section line, performing two rotation operations on the tunnel cross-section line so that the direction of the tunnel cross-section line is consistent with the direction of the tunnel axis line;
[0016] Furthermore, when automatically generating a tunnel extrusion surface model using a surface extrusion operation based on the selected tunnel axis line and tunnel cross-section line, the method further includes:
[0017] The direction vector of the tunnel axis and the tunnel cross section obtained after rotation are obtained, and a three-dimensional tunnel extruded surface is created using the CreateExtrudedSurface function.
[0018] Furthermore, when the user inputs the structural surface attitude parameters through the interactive interface and automatically constructs the tunnel structural surface according to the structural surface attitude parameters, it also includes:
[0019] Select the specific location of the exposed structural surface on the tunnel axis line and the tunnel cross section, and input the strike, strike angle, dip and inclination information of the structural surface;
[0020] The tunnel structural surface is generated based on the specific location of the structural surface exposure point and its occurrence information.
[0021] Furthermore, when the tunnel axis line and the tunnel cross-section line are evenly divided into a specified number of segments to generate a plurality of dividing lines, and the intersection points between the dividing lines and the tunnel structural surface are calculated, the method further includes:
[0022] Convert the generated tunnel structure surface into a surface region and calculate the normal vector of the surface region;
[0023] Evenly dividing the tunnel cross-section line and the tunnel axis line into a specified number of segments to generate a series of segmentation lines;
[0024] For each segmentation line of the tunnel cross section, the intersection point between the segmentation line and the tunnel structural surface is calculated to determine the specific position and shape of the tunnel structural surface inside the tunnel.
[0025] Furthermore, according to the calculated intersection points, automatically connecting lines to form a plane display diagram of the tunnel structure surface in the tunnel axis direction, which is used to display the distribution of the tunnel structure surface on the plane diagram, further includes:
[0026] Check whether the intersection point is located on the dividing line of the tunnel section. If so, calculate the corresponding point on the tunnel section expansion line based on the specific position of the intersection point on the tunnel section, the direction of the tunnel axis and the geometric shape of the tunnel, and save it in the point set;
[0027] Use the point information in the point set to draw a 3D polyline to represent the unfolding line of the tunnel structure surface.
[0028] Furthermore, the method further comprises:
[0029] Add the point information of the 3D polyline and point set to the model space of the CAD software to achieve visual display and complete the drawing of the plane display diagram of the tunnel structure surface;
[0030] Users can edit, annotate or export graphic files as needed for use in engineering report preparation and construction guidance scenarios.
[0031] According to a second aspect of the present invention, the present invention claims protection for a method and apparatus for drawing a planar display diagram of a tunnel structure based on CAD, comprising:
[0032] one or more processors;
[0033] A memory having one or more programs stored thereon, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the method and device for drawing a CAD-based tunnel structure plane display diagram.
[0034] The present application relates to the field of computer-aided design technology, and in particular to a method and device for drawing a planar display diagram of a tunnel structure surface based on CAD, and relates to the drawing of a planar display diagram of a tunnel structure surface in the geological survey industry. In the CAD software, the positions of the tunnel axis, tunnel section, and the exposed points of the tunnel structure surface on the tunnel axis and tunnel section are selected in sequence, and the corresponding occurrence information is given. Then, a planar display diagram of the tunnel structure surface can be quickly drawn through a series of operations such as creating a tunnel stretching surface, generating a structural surface, interactive analysis of the tunnel and the structural surface, and displaying the results in model space. Compared with the traditional method for drawing a planar display diagram of a tunnel structure surface, the present invention provides a more efficient and accurate drawing method, which provides an effective tool for tunnel design and geological condition analysis. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] Figure 1A flowchart of a method and apparatus for drawing a plan view of a tunnel structure surface based on CAD as claimed in an embodiment of the present application;
[0036] Figure 2 A schematic diagram of tunnel axes and cross-sectional lines of a method and device for drawing a planar display of a tunnel structure surface based on CAD as claimed in an embodiment of the present application;
[0037] Figure 3 A tunnel structure surface plan display diagram of a method and device for drawing a tunnel structure surface plan display diagram based on CAD as claimed in an embodiment of the present application. DETAILED DESCRIPTION
[0038] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0039] The terms "first", "second" and "third" in this application are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, a feature defined as "first", "second" and "third" may explicitly or implicitly include at least one of such features. In the description of this application, "multiple" means at least two, for example, two, three, etc., unless otherwise clearly and specifically defined. All directional indications in the embodiments of this application (such as up, down, left, right, front, back...) are only used to explain the relative positional relationship, movement, etc. between the components under a certain specific posture (as shown in the accompanying drawings). If the specific posture changes, the directional indication will also change accordingly. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally also include steps or units that are not listed, or may optionally also include other steps or units inherent to these processes, methods, products or devices.
[0040] References to "embodiments" herein mean that a particular feature, structure, or characteristic described in connection with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various places in the specification does not necessarily refer to the same embodiment, nor does it constitute an independent or alternative embodiment that is mutually exclusive of other embodiments. It is understood, both explicitly and implicitly, by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0041] According to the first embodiment of the present invention, the present invention claims a method and device for drawing a tunnel structure plane display diagram based on CAD, referring to Figure 1 ,include:
[0042] S101, guiding the user to sequentially select tunnel axis lines and tunnel cross-section lines through the CAD software interface, and automatically reading and verifying the data validity of the tunnel axis lines and tunnel cross-section lines;
[0043] S102, based on the selected tunnel axis line and tunnel cross-section line, automatically generating a tunnel stretching surface model using a surface stretching operation;
[0044] S103, the user inputs structural surface occurrence parameters through the interactive interface, and the tunnel structural surface is automatically constructed according to the structural surface occurrence parameters;
[0045] S104, uniformly dividing the tunnel axis line and the tunnel cross-section line into a specified number of segments to generate a plurality of dividing lines, and calculating the intersection points between the dividing lines and the tunnel structural surface;
[0046] S105, automatically connecting lines based on the calculated intersection points to form a planar display diagram of the tunnel structure surface in the tunnel axis direction, for displaying the distribution of the tunnel structure surface on the plan diagram;
[0047] S106: Output the generated plan display diagram to the CAD model space, and the user can edit, annotate or export the graphic file as needed to apply it to the required scene.
[0048] Furthermore, S101 also includes:
[0049] In the CAD software, the tunnel axis line and the tunnel cross-section line selected by the user are respectively received, and the direction vector of the tunnel axis is calculated;
[0050] According to the tunnel axis line and the tunnel cross-section line, performing two rotation operations on the tunnel cross-section line so that the direction of the tunnel cross-section line is consistent with the direction of the tunnel axis line;
[0051] In this embodiment, the PromptEntityOptions and PromptEntityResult classes are used to interact with the user, prompting the user to select a polyline as the tunnel axis and a tunnel section line without a bottom plate, and the above two objects are stored in the variables zhouxiangx and pl0 respectively.
[0052] Encapsulate the tunnel axis and tunnel cross-section lines in a PromptEntityResult object. Retrieve these objects from the database by calling the GetObject method and perform a type check to ensure they are of type Polyline. Then, use the GetVectorTo method to calculate the vector xld1 between the tunnel axis's starting point (zhouxiangx.StartPoint) and its end point (zhouxiangx.EndPoint) to serve as the tunnel axis's direction vector.
[0053] Calculate the average value of the starting and ending point coordinates of the tunnel section line pl0 to obtain the center point sdjmdbzd of the tunnel section, and use the GetVectorTo method to calculate the vector sdjmysxl from the center point sdjmdbzd of the tunnel section to the starting point of the tunnel axis zhouxiangx.StartPoint; use the GetAngleTo method to calculate the angle xlang0 between the vector sdjmysxl from the center point sdjmdbzd of the tunnel section to the starting point of the axis zhouxiangx.StartPoint and the tunnel axis direction vector xld1.
[0054] The tunnel section line is rotated using a custom "Rotate" method. This method uses Matrix3d.Rotation to create a rotation matrix mt based on the rotation angle, rotation axis, and rotation base point parameters. Then, using TransformBy, the rotation matrix mt is applied to the tunnel section line object, resulting in the rotated tunnel section line pl. For the first rotation, the rotation angle xlang is set to 90° (Math.PI * 90.0 / 180.0), the rotation axis is set to the X axis (newVector3d(1,0,0)), and the rotation base point is set to the center point of the tunnel section line (sdjmdbzd), placing the tunnel section line in a position that facilitates subsequent rotation around the Z axis. For the second rotation, the rotation angle xlang is calculated from the angle between the center point of the tunnel section line and the tunnel axis vector. This angle is adjusted based on the direction of the tunnel axis: xlang = 0 when the tunnel axis is oriented from left to right, and -xlang = 0 when the tunnel axis is oriented from right to left. Set the rotation axis to the Z axis (newVector3d(0,0,1)) and the rotation base point to the starting point of the tunnel axis, zhouxiangx.StartPoint. Ensure that the tunnel cross-section lines after two rotations are consistent with the direction of the tunnel axis.
[0055] Furthermore, S102 further includes:
[0056] The direction vector of the tunnel axis and the tunnel cross section obtained after rotation are obtained, and a three-dimensional tunnel extruded surface is created using the CreateExtrudedSurface function.
[0057] In this example, the 3D tunnel extruded surface is created by calling the custom "NewExtrudedSurface" method. This method accepts two main parameters: the extrusion profile entity object (the tunnel cross-section line) and the extrusion direction vector (xld1). It then uses the CreateExtrudedSurface function to extrude the rotated tunnel cross-section line along the tunnel axis, generating the 3D tunnel extruded surface sdm.
[0058] Furthermore, S103 also includes:
[0059] Select the specific location of the exposed structural surface on the tunnel axis line and the tunnel cross section, and input the strike, strike angle, dip and inclination information of the structural surface;
[0060] The tunnel structural surface is generated based on the specific location of the structural surface exposure point and its occurrence information.
[0061] In this example, the PromptPointOptions class is used to create an options object that prompts the user to enter a point. The GetPoint method of the Editor object prompts and waits for the user to enter point information. The PromptPointResult object returns the user-entered point and saves it to the corresponding variable. This method saves the location of the exposed point on the tunnel axis to the variable chuludianwz, and the location of the exposed point on the tunnel cross section to the variable jmcldzb.
[0062] The GetKeywords function retrieves the strike and dip information of the tunnel structure surface entered by the user and saves them to the variables dianzoux and dianqingx, respectively. The PromptKeywordOptions object lists all keywords ("NE," "NW," "SE," and "SW") and displays them to the user through the GetKeywords method of the Editor class, allowing the user to select from a predefined list of keywords. The GetAngle function retrieves the strike and dip angles entered by the user and saves them to the variables zxjiao and dianqingj, respectively.
[0063] The user-defined "jgmdianjimian" method is used to calculate and generate the structural surface based on the specific point position (chuludianwz), strike keyword (dianzoux), strike angle (zxjiao), dip keyword (dianqingx), and dip angle (dianqingj) input on the tunnel axis. The specific steps include:
[0064] (1) Define the point set: First, a point set jiegoupos of type Point3dCollection is created inside the method to store the four vertices of the structural surface.
[0065] (2) Calculate the vertices of the structural surface: According to the specific point position chuludianwz of the structural surface exposed on the tunnel axis input by the user and the given structural surface length jgmchangdu and width jgmkuandu (both set to 100) parameters, calculate the half-length banchang and half-width bankuan of the structural surface (banchang=jgmchangdu / 2,bankuan=jgmkuandu / 2), and then obtain the coordinates of the four vertices of the structural surface as shown below, and add these vertex information to the jiegoupos set.
[0066] (chuludianwz.X-banchang,chuludianwz.Y+bankuan,chuludianwz.Z);
[0067] (chuludianwz.X-banchang,chuludianwz.X-bankuan,chuludianwz.Z);
[0068] (chuludianwz.X+banchang,chuludianwz.X+bankuan,chuludianwz.Z);
[0069] (chuludianwz.X+banchang,chuludianwz.X-bankuan,chuludianwz.Z).
[0070] (3) Create a three-dimensional polyline: Using the point information in the jiegoupos collection, a three-dimensional polyline jxjgbjx is created through the Polyline3d class to represent the boundary of the structural surface.
[0071] (4) Generate a structural surface: Generate a structural surface jgmian based on the 3D polyline jxjgbjx by calling the Surface.CreateFrom(jxjgbjx) method. The Surface.CreateFrom method is a static method used to create a surface object based on one or more curve objects.
[0072] (5) Rotating the structural surface: Based on the occurrence information input by the user, the custom "Rotate" method is called to rotate the generated structural surface. This method accepts the entity object, rotation base point, rotation angle, and rotation axis as parameters. The rotation of the structural surface is achieved by constructing a rotation matrix and applying it to the entity. The entity object in the rotation matrix is the structural surface jgmian, the rotation base point is the outcrop chuludianwz, and the rotation angle and rotation axis parameters are related to the occurrence information of the structural surface, as shown in Table 1:
[0073] Table 1 Relationship between rotation angle and rotation axis parameters and structural surface occurrence information
[0074]
[0075] (6) Returning the structural surface: Finally, the function returns the structural surface object jgmian obtained after two rotations, which is the generated structural surface;
[0076] Figure 2 It is the plane position of the tunnel axis and the cross-sectional line of the tunnel in the CAD software. The specific position of the structural surface exposed on the tunnel axis and the cross-sectional line of the tunnel is also marked in the figure.
[0077] Furthermore, S104 also includes:
[0078] Convert the generated tunnel structure surface into a surface region and calculate the normal vector of the surface region;
[0079] Evenly dividing the tunnel cross-section line and the tunnel axis line into a specified number of segments to generate a series of segmentation lines;
[0080] For each segmentation line of the tunnel cross section, the intersection point between the segmentation line and the tunnel structural surface is calculated to determine the specific position and shape of the tunnel structural surface inside the tunnel.
[0081] In this embodiment, the generated structural surface object jgmian is converted into an array of region objects by calling the Surface.ConvertToRegion method. This method returns a DBObjectCollection array named mianyu containing all the region objects. The normal vector mianxl of the region is then obtained by traversing the mianyu array and accessing the Normal property of each region object.
[0082] The tunnel section line and tunnel axis are divided by calculating the starting and ending parameters of the line and dividing it into equal parts according to the specified number of segments fenduans (set to 100). The tunnel section line pl0 is divided by calculating the starting parameter pl0.StartParam of the section line and the increment of the length parameter of each segment zdcanshuf = (pl0.EndParam-pl0.StartParam) / fenduans, and using pl0.GetPointAtParameter(pl0.StartParam+zdcanshuf*j) to obtain each division point. The tunnel axis is divided similarly by calculating the starting parameter zhouxiangx.StartParam of the axis and the increment of the length parameter sdqdxf = (zhouxiangx.EndParam-zhouxiangx.StartParam) / fenduans, and using zhouxiangx.GetPointAtParameter(zhouxiangx.StartParam+sdqdxf*j) to obtain each division point.
[0083] The intersection between the tunnel section line and the tunnel structural plane is calculated by calling the custom IntersectWithLineAndPlane method. Within the loop, for each tunnel section line segment pl, a line jiaoxianxt is constructed from the starting point of that segment to the point translated by vector xld1. The IntersectWithLineAndPlane method is then called to calculate the intersection between this line and the tunnel structural plane, which is defined by a point chuludianwz on the plane and its normal vector mianxl. The specific process for finding the intersection point is as follows:
[0084] (1) First, calculate the dot product of the line's direction vector dianxl and the plane's normal vector mianxl. If the result is 0, that is, denominator = dianxl.X*mianxl.X+dianxl.Y*mianxl.Y+dianxl.Z*mianxl.Z = 0, it means that the line is parallel to the plane. The return value is false, indicating that the intersection does not exist. The process of obtaining the line's direction vector dianxl is as follows: 1) Calculate the starting point of the segmented line Point3d diyidian = pl.GetPointAtParameter(pl.StartParam+zdcanshuf*j); 2) Calculate the point obtained by translating the starting point of the segmented line by vector xld1 Point3d dierdian = diyidian.Add(xld1); 3) Calculate the direction vector of the segmented line Vector3ddianxl = diyidian.GetVectorTo(dierdian).
[0085] (2) If the line and the plane are not parallel, the intersection of the line and the plane is calculated through the following process: 1) First calculate the distance d = ((chuludianwz.X-diyidian.X)*mianxl.X+(chuludianwz.Y-diyidian.Y)*mianxl.Y+(chuludianwz.Z-diyidian.Z)*mianxl.Z) / denominator from the starting point diyidian of the line pl along the direction vector dianxl of the line; 2) Calculate the X, Y, and Z values of the intersection coordinates: intjdx = diyidian.X+dianxl.X*d, intjdy = diyidian.Y+dianxl.Y*d, intjdz = diyidian.Z+dianxl.Z*d; 3) Return the intersection information: intersection = newPoint3d(intjdx, intjdy, intjdz), and complete the calculation of the intersection of the line and the plane.
[0086] The specific position and shape of the structural surface inside the tunnel are indirectly represented by its intersection with the tunnel section decomposition line inside the tunnel. After the intersection points are calculated, the intersection point information is saved to the collection p3ddc through the p3ddc.Add(xiantjd) method. The distribution of the structural surface in the tunnel is visualized by drawing polylines connecting the intersection points.
[0087] Furthermore, S105 also includes:
[0088] Check whether the intersection point is located on the dividing line of the tunnel section. If so, calculate the corresponding point on the tunnel section expansion line based on the specific position of the intersection point on the tunnel section, the direction of the tunnel axis and the geometric shape of the tunnel, and save it in the point set;
[0089] Use the point information in the point set to draw a 3D polyline to represent the unfolding line of the tunnel structure surface.
[0090] In this embodiment, the loop body calculates the distance between the midpoint of the current tunnel section dividing line and the intersection point by double jdzhizdjg=GetDistance(xiantjd,jiaoxianxt.GetPointAtDist(jiaoxianxt.Length / 2)), and compares the distance with half the length of the current tunnel dividing line. If the distance is less than half the length of the dividing line, it is considered that the intersection point is above the dividing line; otherwise, the intersection point is located on the extension line of the dividing line. This is because the distance from the midpoint of the line segment to any point on the line segment will not exceed half the length of the line segment.
[0091] If the loop determines that the intersection is on the tunnel section decomposition line, the pl.GetClosestPointTo(xiantjd,false) method is used to find the closest point sdjmtyd of the intersection on the tunnel section line pl. The distance ldjg from the intersection to the closest point sdjmtyd is then calculated, and the corresponding point on the tunnel section expansion line sdzhansxt is found using the sdzhansxt.GetPointAtDist(ldjg) method. This point is the projection point of the intersection on the tunnel section expansion line. The tunnel section expansion line sdzhansxt is obtained based on the rotated tunnel section line pl and the tunnel axis vector xld1, as follows:
[0092] (1) First, calculate the scaling factor sfbl, which is the ratio of the tunnel section line length to the base plate line length, that is, pl.Length / pl.StartPoint.DistanceTo(pl.EndPoint). Then, scale the start and end points of the tunnel section line according to this ratio and connect them to form a new line to construct a line in the direction of the tunnel axis, that is, szzxqsxt = newLine(pl.StartPoint.ScaleBy(sfbl,zhouxiangx.StartPoint),pl.EndPoint.ScaleBy(sfbl,zhouxiangx.StartPoint)).
[0093] (2) Calculate the segmentation parameters of the tunnel axis direction line sddiyidiancs = szzxqsxt.StartParam + sdqdxf*j, and use the sddiyidian = szzxqsxt.GetPointAtParameter(sddiyidiancs) method to calculate the starting coordinates of the tunnel expansion line (when the current segment is at the two ends of the tunnel direction line, the starting coordinates of the tunnel expansion line sddiyidian = szzxqsxt.GetPointAtParameter(sddiyidiancs-0.00000001)), and apply the tunnel axis direction vector xld1 on the basis of the starting point of the tunnel display line to obtain the end point of the tunnel display line Point3dsddierdian = sddiyidian.Add(xld1).
[0094] (3) According to the coordinates of the starting point and end point of the tunnel expansion line, create the expansion line Linesdzhansxt = newLine (sddiyidian, sddierdian) of the tunnel section in the direction of the tunnel axis.
[0095] When ldjg is greater than the length of the tunnel section expansion line (sdzhansxt.Length), it means that the intersection point is on the extension line of the expansion line. At this time, an extension factor yanshencs is calculated (doubleyanshencs=sdzhansxt.Length / ldjg), and the sddierdian.ScaleBy(yanshencs,diyidian) method is used to scale diyidian with the yanshencs ratio to obtain the extended point zhanshid. Finally, the p3dc.Add(zhanshid) method is used to add the corresponding point found to the collection p3dc, and a Polyline3d object is created using the points in the collection to represent the expansion line of the tunnel section.
[0096] Furthermore, S106 also includes:
[0097] Add the point information of the 3D polyline and point set to the model space of the CAD software to achieve visual display and complete the drawing of the plane display diagram of the tunnel structure surface;
[0098] Reference Figure 3 , is the drawing result of the tunnel structure plane display diagram, where the red lines are the drawn tunnel structure plane display lines. Users can edit, annotate or export the graphic file as needed for project report preparation and construction guidance scenarios.
[0099] In this embodiment, a custom ToModelSpace method is called to add the 3D polyline entity and the point information in the point set to the model space of the currently active CAD document, achieving a visual display and thus completing the drawing of the tunnel structure surface plan. The ToModelSpace method accepts an entity object as a parameter and adds it to the model space of the current document. This is accomplished by starting a transaction, obtaining a reference to the model space (BlockTableRecord) within the transaction, calling the AppendEntity method to add the entity to the model space, and then committing the transaction.
[0100] The specific methods used in this embodiment are summarized as follows:
[0101] 1. Data input and preprocessing:
[0102] 1) Use the PromptEntityOptions and PromptEntityResult classes to create a user interface to guide the user to select the tunnel section line (pl0) and the axis line (zhouxiangx) respectively.
[0103] 2) Check whether the selected line is of Polyline type and calculate the axis vector (xld1).
[0104] 2. Tunnel extrusion surface generation:
[0105] 1) In the Addsdqm() function, rotate the tunnel section lines so that they are consistent with the axis direction.
[0106] 2) Use the NewExtrudedSurface() function to stretch the rotated cross-section lines along the axial direction to generate the tunnel extrusion surface (sjdx).
[0107] 3. Structural surface parameter input and model construction:
[0108] 1) Get the structural surface direction, dip keywords, strike angle and dip angle information input by the user through the GetKeywords() and GetAngle() functions.
[0109] 2) In the jiegoumian() function, the jgmdianjimian() function is called according to the user input parameters to generate the structural surface model (chulm).
[0110] 4. Tunnel sectioning and intersection calculation:
[0111] 1) According to the preset section spacing fenduans, the tunnel section line is sectioned along the axis direction to obtain each section point.
[0112] 2) For each section line, use the IntersectWithLineAndPlane() function to calculate the intersection point between the section line and the structural surface.
[0113] 5. Drawing of plane display diagram:
[0114] 1) Connect the calculated intersection points in sequence to form a plane display line of the structural surface in the direction of the tunnel axis.
[0115] 2) Use the ToModelSpace() function to output the plane display lines and related auxiliary information to the CAD model space for display.
[0116] 6. Result output and post-processing:
[0117] Users can directly view the generated tunnel structure plane display in the CAD software and further edit, annotate or export the graphic file as needed.
[0118] According to a second embodiment of the present invention, the present invention claims a method and apparatus for drawing a plan view of a tunnel structure surface based on CAD, comprising:
[0119] one or more processors;
[0120] A memory having one or more programs stored thereon, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the method and device for drawing a CAD-based tunnel structure plane display diagram.
[0121] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0122] In addition, the functional units in the various embodiments of the present application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units. The above is only an implementation method of the present application and does not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the description and drawings of this application, or directly or indirectly used in other related technical fields, are also included in the patent protection scope of the present application.
[0123] The above detailed description of the specific embodiments of the invention is intended only as an example, and the present application is not limited to the specific embodiments described above. For those skilled in the art, any equivalent modifications or substitutions of the invention are also within the scope of the present application. Therefore, equivalent changes, modifications, and improvements made without departing from the spirit and scope of the present application should be included within the scope of the present application.
Claims
1. A method for drawing a tunnel structure plane display diagram based on CAD, characterized in that: include: In the CAD software, the tunnel axis line and the tunnel cross-section line selected by the user are respectively received, and the direction vector of the tunnel axis is calculated; According to the tunnel axis line and the tunnel cross-section line, performing two rotation operations on the tunnel cross-section line so that the direction of the tunnel cross-section line is consistent with the direction of the tunnel axis line; Based on the selected tunnel axis line and tunnel cross-section line, automatically generating a tunnel extrusion surface model using a surface extrusion operation; The user inputs the structural surface attitude parameters through the interactive interface, and automatically constructs the tunnel structural surface based on the structural surface attitude parameters. The specific location of the structural surface exposure is selected on the tunnel axis line and tunnel cross section, and the strike, strike angle, dip and inclination information of the structural surface are input; Generate tunnel structural surface according to the specific location of structural surface exposure and its occurrence information; Evenly dividing the tunnel axis line and the tunnel cross-section line into a specified number of segments to generate a plurality of dividing lines, calculating the intersection points between the dividing lines and the tunnel structure surface, converting the generated tunnel structure surface into a surface domain, and calculating the normal vector of the surface domain; Evenly dividing the tunnel cross-section line and the tunnel axis line into a specified number of segments to generate a series of segmentation lines; For each segmentation line of the tunnel cross section, calculating the intersection point between the segmentation line and the tunnel structural surface, and determining the specific position and shape of the tunnel structural surface inside the tunnel; Automatically connect the calculated intersection points to form a planar display diagram of the tunnel structure surface in the direction of the tunnel axis, so as to display the distribution of the tunnel structure surface on the planar diagram; The generated plan display drawing is output to the CAD model space, and the user edits, annotates or exports the graphic file to be applied to the required scene.
2. The method for drawing a tunnel structure plane display diagram based on CAD according to claim 1, characterized in that: When automatically generating a tunnel extrusion surface model using a surface extrusion operation based on the selected tunnel axis line and tunnel cross-section line, the method further includes: The direction vector of the tunnel axis and the tunnel cross section obtained after rotation are obtained, and a three-dimensional tunnel extruded surface is created using the CreateExtrudedSurface function.
3. The method for drawing a tunnel structure plane display diagram based on CAD according to claim 1, characterized in that: Automatically connecting lines based on the calculated intersection points to form a planar display diagram of the tunnel structure surface in the direction of the tunnel axis, which is used to display the distribution of the tunnel structure surface on the plan diagram, also includes: Check whether the intersection point is located on the dividing line of the tunnel section. If so, calculate the corresponding point on the tunnel section expansion line based on the specific position of the intersection point on the tunnel section, the direction of the tunnel axis and the geometric shape of the tunnel, and save it in the point set; Use the point information in the point set to draw a 3D polyline to represent the unfolding line of the tunnel structure surface.
4. The method for drawing a tunnel structure plane display diagram based on CAD according to claim 1, characterized in that: Also includes: Add the point information of the 3D polyline and point set to the model space of the CAD software to achieve visual display and complete the drawing of the plane display diagram of the tunnel structure surface; Users edit, annotate, or export graphic files for use in engineering report preparation and construction guidance scenarios.
5. A device for drawing a planar display diagram of a tunnel structure based on CAD, characterized in that: include: one or more processors; A memory having one or more programs stored thereon, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement a method for drawing a plan view of a tunnel structure surface based on CAD according to any one of claims 1 to 4.
Citation Information
Patent Citations
A coupling modeling method for numerical model of complex geological body
CN109102564A
Online sectioning and mapping method for three-dimensional geological model
CN117409157A