Tunnel line center line modeling method based on CATIA
By adopting local centerline creation, template instantiation and line assembly methods on the CATIA platform, the problem of model offset and inefficiency caused by the simplified solution of BIM software when dealing with long-distance three-dimensional special-shaped curves is solved, and efficient and accurate modeling of tunnel line centerlines is achieved.
Patent Information
- Application Number
- CN202510027704.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-08
- Publication Date
- 2025-04-18
AI Technical Summary
When existing BIM software deals with long-distance three-dimensional special-shaped curves, they usually adopt simplified solutions, such as polylines or straight lines, which leads to model position offset, reduced modeling quality, and increases the difficulty of computer processing.
The CATIA-based tunnel line centerline modeling method is adopted to achieve accurate three-dimensional tunnel line centerline modeling by creating local centerlines, template instantiation and line assembly. The specific steps include using parallel command offsets to create a local centerline, customizing the template and instantiating the generation of multiple local centerlines, and finally assemble in the overall coordinate system to form a complete model.
It realizes the rapid and accurate drawing of the center line of the tunnel engineering line, improves modeling efficiency, reduces the difficulty of model changes and modification, and improves modeling quality.
Smart Images

Figure CN119849004A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of tunnel engineering BIM modeling, and in particular to a tunnel line centerline modeling method based on CATIA. Background Art
[0002] With the continuous development of BIM technology, the structure of 3D models is becoming more and more complex, and the requirements for precision and quality are becoming higher and higher. CATIA software is well-known for its excellent surface modeling capabilities, and has therefore gradually participated in the BIM field. After more than 20 years of use, CATIA software has become an extremely important platform in the BIM software field.
[0003] Tunnel engineering is different from general construction engineering, which is mainly based on vertical intersecting straight lines. For tunnels in common railway or highway projects, the center line of the line is usually used as the positioning reference of the entire model. Therefore, accurate and continuous center lines are of great significance to ensure the accuracy of the overall model of tunnel engineering.
[0004] However, the creation of the centerline of the line is the superposition of horizontal curves and vertical curves in three-dimensional space. It is determined by horizontal curves and vertical curves and is a mixture of curves. Its modeling belongs to the modeling of complex irregular space structures and accurate modeling is difficult.
[0005] The existing mainstream BIM software is mostly used in construction projects, and rarely encounters three-dimensional special-shaped curves with a length of tens of kilometers. When dealing with such complex curves, a simplified solution is usually adopted. Abandon the complex curves and replace them all with broken lines or straight lines to turn the special-shaped components into simple components. Although the curves generated in this way are continuous, the mileage of the line will be slightly shortened by replacing the curves with broken lines. As the mileage of the line increases, this error will continue to accumulate, eventually leading to the position offset of the model based on the centerline of the line as the positioning reference, and the quality of modeling will decrease; at the same time, if the error is reduced by simply reducing the length of the broken line segment to approximate the arc, the number of segments will increase, increasing the difficulty of computer processing, and resulting in reduced modeling efficiency.
[0006] CATIA software was once a widely used CAD\CAM\CAE software in the fields of machinery, aviation, and automobiles. It has flexible and rich curve modeling tools and can directly solve this problem without using approximate methods.
[0007] At present, based on the limited knowledge of the inventor, there are two main methods for using CATIA to accurately model the center line of a tunnel line. The main difference lies in the scheme used when mixing horizontal curves and vertical curves. One is to use a sweep command, add a law curve to the angle parameter to control the sweep angle, form a sweep surface of the vertical curve, and then intersect the sweep surface with the horizontal curve stretch surface to obtain a mixed spatial curve, that is, the center line of the line; the other is to use a surface unfolding command to unfold the horizontal curve stretch surface, turning it from a curved surface into a plane, and then use this plane as a reference surface to draw the vertical curve, and finally fold the unfolded surface and the vertical curve on the surface back to the horizontal curve stretch surface to obtain the center line of the line.
[0008] The first solution uses a swept surface generated by changing the sweep angle to accurately intersect with the flat curve stretch surface, and the intersection line deviates from the true value. This is because the surface swept by changing the angle is not parallel to the horizontal plane in the direction of the guide line. The second method makes it difficult to fold the vertical curve back to the flat curve stretch surface after unfolding a longer flat curve stretch surface. This is because the flat curve is several kilometers long, and its stretch surface equation is complex and has a large value. It is easy to have errors due to memory reasons, resulting in calculation failure.
[0009] Therefore, it is necessary to develop a tunnel line centerline modeling method based on CATIA to solve the above problems. Summary of the invention
[0010] The purpose of the present invention is to design a tunnel line centerline modeling method based on CATIA in order to solve the above problems.
[0011] The present invention achieves the above-mentioned purpose through the following technical solutions: A tunnel line centerline modeling method based on CATIA, comprising: Step a, create a local centerline, use the parallel command to offset the horizontal curve driven by the parametric equation to achieve the drawing of the local centerline; Step b: creating and instantiating a local centerline template, creating a custom feature in the knowledge engineering module, packaging the method for creating the local centerline in step a to generate a template, modifying parameters according to design requirements and instantiating the template to generate multiple local centerlines; Step c: line assembly, assembling multiple local center lines in the global coordinate system to form a complete three-dimensional tunnel line center line model.
[0012] In step a, using the parallel command to offset the horizontal curve driven by the parametric equation includes: determining the relationship between the mileage and the elevation by programming or reference curve generation rule curve, and then adjusting the elevation of the horizontal curve according to the above relationship by the parallel command, and finally determining the local centerline position Specifically, the local centerline creation method includes the following steps: Step a1, create parameters and relationships; use the formula command to create a new type of parameters, the new type of parameters include: L0, R0, A, tangent length, α, p, q; and assign values to L0 and R0 according to the design; determine the mathematical relationship between the parameters according to the formulas of the transition curve; use the rule command to create a new rule transition curve x_l and transition curve y_l in the rule editor; in the above transition curve x_l, after setting the parameter t according to the requirements of the rule editor, enter the relationship equation between x and l: , Similarly, enter the relationship equation between y and l in the relaxation curve y_l: , Step a2, create horizontal curve reference elements; create intersection points, tangent lines, transition curve reference lines and reference planes, the creation method includes: firstly draw three intersection points according to the coordinates, when drawing, the geodetic projection coordinates should be replaced with the mathematical coordinate system, and obtain point .1, point .2, and point .3; then connect the three intersection points in sequence with the line command to obtain two line segments, namely line .1 and line .2; make points on the two line segments respectively to obtain two points T1 and T2, and modify the distances of points T1 and T2 from the intersection point .2 to the parameter tangent length; use the line command to pass through the above two points T1 and T2, respectively create reference lines perpendicular to the XY plane, namely line .3 and line .4, and modify the lengths of line .3 and line .4 to 150m; use the plane command to pass through the above reference lines line .3 and line .4, and establish reference planes parallel to and perpendicular to the tangent lines line .1 and line .2, respectively, for a total of four, namely plane .1, plane .2, plane .3, and plane .4; Step a3, create a horizontal curve transition curve segment; set parameter l, create a relationship curve of x, y, and parameter l in three-dimensional space according to the parametric equation of the transition curve, project the three-dimensional curve to the horizontal plane, and obtain the transition curve segment on the horizontal curve. The creation method includes: firstly, use the parallel command to create the x and l relationship curve, select straight line.3 for reference curve, select plane.1 for support surface, select law curve function for offset, select transition curve x_l for law curve element, and obtain offset curve parallel.1; create y and l relationship curve parallel.2, use the parallel command to create, select straight line.3 for reference curve, select plane.2 for support surface, select law curve function for offset, select transition curve y_l for law curve element, and obtain offset curve parallel.2; then use the mix command to mix the above relationship curves parallel.1 and parallel.2 to obtain the three-dimensional relationship curve mix.1 of x, y, and parameter l; finally, mix the three-dimensional relationship curve. 1 is projected onto the horizontal XY plane to obtain projection.1, which is a transition curve on the flat curve; the creation method of the transition curve on the other side is the same, including: firstly, the parallel command is used to create the x and l relationship curve, the reference curve selects straight line.4, the support surface selects plane.3, the offset selects the law curve function, and the law curve element selects the transition curve x_l, so as to obtain the offset curve parallel.3, and then the y and l relationship curve is created by the parallel command, the reference curve selects straight line.4, the support surface selects plane.4, the offset selects the law curve function, and the law curve element selects the transition curve y_l, so as to obtain the offset curve parallel.4; then the mixed command is used to mix the above relationship curves parallel.3 and parallel.4 to obtain the three-dimensional relationship curve mixed.2 of x, y, and parameter l; finally, the three-dimensional relationship curve mixed.2 is projected onto the horizontal XY plane to obtain projection.2, which is the transition curve on the other side of the flat curve; Step a4, creating a support surface for the offset of a flat curve; when using the parallel command to offset the flat curve upward, it is necessary to determine the offset direction, and create a support surface to determine the offset direction. The creation method includes: first, using the circle command to connect and create curve projection.1 and projection.2 in the transition curve segment of the flat curve, the radius selects parameter R0, the support surface selects the horizontal plane, and obtains the flat curve arc circle.1; then, using the stretch command, respectively create stretch surfaces of projection.1, projection.2 and circle.1, the surface contours select projection.1, projection.2 and circle.1 respectively, the stretch direction selects the Z axis direction, and the size selects any length greater than the elevation, and respectively obtains stretch surfaces stretch.1, stretch.2, stretch.3, and the flat curve offset will use these three surfaces as support surfaces; Step a5, offset the horizontal curve; use the parallel command to offset the horizontal curve upward so that its z coordinate changes according to the value of the designed vertical curve to obtain the corresponding line center line, and the creation method includes: firstly create a law curve, specify the mathematical relationship between the elevation offset and the horizontal curve mileage, and obtain the law curve.1, then use the parallel command to offset the horizontal curve, select projection.1, projection.2 and circle.1 as reference curves, select stretch.1, stretch.2 and stretch.3 as support surfaces, select law curve.1 as offset, and obtain parallel.3, parallel.4, and parallel.5 respectively; finally, use the join command to merge parallel.3, parallel.4, and parallel.5 into a whole to obtain curve join.1, that is, a section of the tunnel center line.
[0013] Furthermore, in step a5, the creation method is to use a rule command to create it in a rule curve editor, and by writing code, the mathematical relationship between the elevation offset and the horizontal curve mileage is specified to obtain the rule curve 1.
[0014] Further, in step a5, the creation method is to use the law curve command, define the law curve by drawing a vertical curve, reference select projection.1, projection.2 and circle.1, reference select the newly drawn vertical curve, and obtain the law curve.1.
[0015] Furthermore, in step b, the custom template generates a new local centerline by modifying the parameters in the creation and relationship; the script is written in VBScript, the default language of CATIA macros, and three operations are implemented through the script, which automatically reads the parameter table containing the centerline design parameter information, automatically assigns the parameters to the centerline template, and saves it as a new independent part. In this way, the template is read, modified and copied in a cycle to complete the modeling of all local centerlines; The local centerline template creation method includes the following steps: Step b1, create user features; use the Create User Features command, select Curve Joining.1 for the internal component, adjust the component input points.1, .2, .3, XY plane, design parameters and law curve, select L0, R0 for the design parameters, and the intersection coordinates to obtain user feature 1; Step b2, create a macro copy script; use the macro to perform secondary development on CATIA, and use Excel as a data storage and transmission tool, combined with parametric templates, to complete centerline modeling; Step b3, create other local center lines; use the macro script to modify user feature 1, adjust the corresponding parameters according to the design table, and obtain user feature 1.1, that is, create other local center lines.
[0016] Specifically, step c includes the following steps: Step c1, create a new product and import each local centerline; in the assembly design module, select Import existing parts and import the local centerline file; Step c2, creating constraints; the coordinates of each local centerline are created based on the local coordinates of each file; in the global coordinate system, the local coordinate offset is adjusted back to the original design position; and each local centerline component is fixed at the corresponding design position using the matching constraint; Step c3, create a clip line; use the straight line command to connect the local center lines to form a complete three-dimensional tunnel line center line.
[0017] The beneficial effects of the present invention are: (1) The present invention uses a parallel command to offset a horizontal curve. During the offset, the offset amount is adjusted according to a law curve so that each point on the horizontal curve satisfies the mathematical relationship between mileage and elevation. The center line of the tunnel engineering line can be drawn quickly and accurately, providing a simple and feasible new idea for tunnel engineering modeling.
[0018] (2) The present invention adopts user-defined features to establish a route centerline creation method template, and achieves the purpose of rapid replication by modifying template parameters, which can improve modeling efficiency and reduce the difficulty of model change and modification.
[0019] (3) The present invention uses VBScript scripting language to carry out secondary development of CATIA to realize functions such as automatic reading of parameters, automatic modification of parameters, and automatic saving of newly created center lines. At the same time, templates, macro programs, and design tables are distributed to multiple computers, which can perform parallel processing, thereby further increasing modeling efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 It is a schematic diagram of the process of the present invention; Figure 2 This is a schematic diagram of using the parallel command to offset a horizontal curve; Figure 3 This is a schematic diagram of the center line after assembly. DETAILED DESCRIPTION
[0021] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Generally, the components of the embodiments of the present invention described and shown in the drawings here can be arranged and designed in various different configurations.
[0022] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the invention claimed for protection, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0023] It should be noted that similar reference numerals and letters denote similar items in the following drawings, and therefore, once an item is defined in one drawing, further definition and explanation thereof is not required in subsequent drawings.
[0024] In the description of the present invention, it should be understood that the terms "upper", "lower", "inside", "outside", "left", "right", etc. indicate directions or positional relationships based on the directions or positional relationships shown in the accompanying drawings, or are directions or positional relationships in which the product of the invention is usually placed when in use, or are directions or positional relationships commonly understood by those skilled in the art. These directions or positional relationships are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific direction, be constructed and operated in a specific direction, and therefore should not be understood as a limitation on the present invention.
[0025] Furthermore, the terms “first”, “second”, etc. are merely used for distinguishing descriptions and should not be understood as indicating or implying relative importance.
[0026] In the description of the present invention, it is also necessary to explain that, unless otherwise clearly specified and limited, the terms such as "setting" and "connection" should be understood in a broad sense. For example, "connection" can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or an indirect connection through an intermediate medium, or it can be the internal communication of two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0027] The specific implementation modes of the present invention are described in detail below in conjunction with the accompanying drawings.
[0028] like Figure 1-3 As shown, a tunnel line centerline modeling method based on CATIA includes: Step a, create a local centerline, use the parallel command to offset the horizontal curve driven by the parametric equation to achieve the drawing of the local centerline; Step b: creating and instantiating a local centerline template, creating a custom feature in the knowledge engineering module, packaging the method for creating the local centerline in step a to generate a template, modifying parameters according to design requirements and instantiating the template to generate multiple local centerlines; Step c: line assembly, assembling multiple local center lines in the global coordinate system to form a complete three-dimensional tunnel line center line model.
[0029] like Figure 2 As shown, in step a, using the parallel command to offset the horizontal curve driven by the parametric equation includes: determining the relationship between the mileage and the elevation by programming or reference curve generation rule curve, and then adjusting the elevation for the horizontal curve according to the above relationship by the parallel command, and finally determining the local centerline position Specifically, the local centerline creation method includes the following steps: Step a1, create parameters and relationships; use the formula command to create a new type of parameters, the new type of parameters include: L0, R0, A, tangent length, α, p, q; and assign values to L0 and R0 according to the design; determine the mathematical relationship between the parameters according to the formulas of the transition curve; use the rule command to create a new rule transition curve x_l and transition curve y_l in the rule editor; in the above transition curve x_l, after setting the parameter t according to the requirements of the rule editor, enter the relationship equation between x and l: , Similarly, enter the relationship equation between y and l in the relaxation curve y_l: , Step a2, create horizontal curve reference elements; create intersection points, tangent lines, transition curve reference lines and reference planes, the creation method includes: firstly draw three intersection points according to the coordinates, when drawing, the geodetic projection coordinates should be replaced with the mathematical coordinate system, and obtain point .1, point .2, and point .3; then connect the three intersection points in sequence with the line command to obtain two line segments, namely line .1 and line .2; make points on the two line segments respectively to obtain two points T1 and T2, and modify the distances of points T1 and T2 from the intersection point .2 to the parameter tangent length; use the line command to pass through the above two points T1 and T2, respectively create reference lines perpendicular to the XY plane, namely line .3 and line .4, and modify the lengths of line .3 and line .4 to 150m; use the plane command to pass through the above reference lines line .3 and line .4, and establish reference planes parallel to and perpendicular to the tangent lines line .1 and line .2, respectively, for a total of four, namely plane .1, plane .2, plane .3, and plane .4; Step a3, create a horizontal curve transition curve segment; set parameter l, create a relationship curve of x, y, and parameter l in three-dimensional space according to the parametric equation of the transition curve, project the three-dimensional curve to the horizontal plane, and obtain the transition curve segment on the horizontal curve. The creation method includes: firstly, use the parallel command to create the x and l relationship curve, select straight line.3 for reference curve, select plane.1 for support surface, select law curve function for offset, select transition curve x_l for law curve element, and obtain offset curve parallel.1; create y and l relationship curve parallel.2, use the parallel command to create, select straight line.3 for reference curve, select plane.2 for support surface, select law curve function for offset, select transition curve y_l for law curve element, and obtain offset curve parallel.2; then use the mix command to mix the above relationship curves parallel.1 and parallel.2 to obtain the three-dimensional relationship curve mix.1 of x, y, and parameter l; finally, mix the three-dimensional relationship curve. 1 is projected onto the horizontal XY plane to obtain projection.1, which is a transition curve on the flat curve; the creation method of the transition curve on the other side is the same, including: firstly, the parallel command is used to create the x and l relationship curve, the reference curve selects straight line.4, the support surface selects plane.3, the offset selects the law curve function, and the law curve element selects the transition curve x_l, so as to obtain the offset curve parallel.3, and then the y and l relationship curve is created by the parallel command, the reference curve selects straight line.4, the support surface selects plane.4, the offset selects the law curve function, and the law curve element selects the transition curve y_l, so as to obtain the offset curve parallel.4; then the mixed command is used to mix the above relationship curves parallel.3 and parallel.4 to obtain the three-dimensional relationship curve mixed.2 of x, y, and parameter l; finally, the three-dimensional relationship curve mixed.2 is projected onto the horizontal XY plane to obtain projection.2, which is the transition curve on the other side of the flat curve; Step a4, creating a support surface for the offset of a flat curve; when using the parallel command to offset the flat curve upward, it is necessary to determine the offset direction, and create a support surface to determine the offset direction. The creation method includes: first, using the circle command to connect and create curve projection.1 and projection.2 in the transition curve segment of the flat curve, the radius selects parameter R0, the support surface selects the horizontal plane, and obtains the flat curve arc circle.1; then, using the stretch command, respectively create stretch surfaces of projection.1, projection.2 and circle.1, the surface contours select projection.1, projection.2 and circle.1 respectively, the stretch direction selects the Z axis direction, and the size selects any length greater than the elevation, and respectively obtains stretch surfaces stretch.1, stretch.2, stretch.3, and the flat curve offset will use these three surfaces as support surfaces; Step a5, offset the horizontal curve; use the parallel command to offset the horizontal curve upward so that its z coordinate changes according to the value of the designed vertical curve to obtain the corresponding line center line, and the creation method includes: firstly create a law curve, specify the mathematical relationship between the elevation offset and the horizontal curve mileage, and obtain the law curve.1, then use the parallel command to offset the horizontal curve, select projection.1, projection.2 and circle.1 as reference curves, select stretch.1, stretch.2 and stretch.3 as support surfaces, select law curve.1 as offset, and obtain parallel.3, parallel.4, and parallel.5 respectively; finally, use the join command to merge parallel.3, parallel.4, and parallel.5 into a whole to obtain curve join.1, that is, a section of the tunnel center line.
[0030] Furthermore, in step a5, the creation method is to use a rule command to create it in a rule curve editor, and by writing code, the mathematical relationship between the elevation offset and the horizontal curve mileage is specified to obtain the rule curve 1.
[0031] Further, in step a5, the creation method is to use the law curve command, define the law curve by drawing a vertical curve, reference select projection.1, projection.2 and circle.1, reference select the newly drawn vertical curve, and obtain the law curve.1.
[0032] Furthermore, in step b, the custom template generates a new local centerline by modifying the parameters in the creation and relationship; the script is written in VBScript, the default language of CATIA macros, and three operations are implemented through the script, which automatically reads the parameter table containing the centerline design parameter information, automatically assigns the parameters to the centerline template, and saves it as a new independent part. In this way, the template is read, modified and copied in a cycle to complete the modeling of all local centerlines; The local centerline template creation method includes the following steps: Step b1, create user features; use the Create User Features command, select Curve Joining.1 for the internal component, adjust the component input points.1, .2, .3, XY plane, design parameters and law curve, select L0, R0 for the design parameters, and the intersection coordinates to obtain user feature 1; Step b2, create a macro copy script; use the macro to perform secondary development on CATIA, and use Excel as a data storage and transmission tool, combined with parametric templates, to complete centerline modeling; Step b3, create other local center lines; use the macro script to modify user feature 1, adjust the corresponding parameters according to the design table, and obtain user feature 1.1, that is, create other local center lines.
[0033] Specifically, step c includes the following steps: Step c1, create a new product and import each local centerline; in the assembly design module, select Import existing parts and import the local centerline file; Step c2, create constraints; the coordinates of each local centerline are created according to the local coordinates of each file; in the global coordinate system, there may be a problem of local coordinate offset for ease of processing, and these offsets need to be adjusted back to the original design position in the global coordinate system; use coincidence constraints to fix each local centerline component at the corresponding design position; Step c3, create a clip line; if there is no clip line segment between the above local center lines, use the straight line command to connect the local center lines to form a complete three-dimensional tunnel line center line, such as Figure 3 shown.
[0034] When using this application method: (1) According to the project design and drawing content, export the line parameter information to an Excel table. This information includes intersection coordinates, transition curve length, curve radius and other parameters.
[0035] (2) Open the CATIA macro, modify the address of the Excel table to be read, and the plug-in will run automatically. During the operation, the plug-in will perform the following operations in sequence: read the line parameters, modify the line geometry parameters, update the local centerline, and save it to the specified folder.
[0036] (3) Create a new product, load each local centerline, check the centerline coordinates, and complete the centerline assembly after modification to form a complete tunnel centerline model.
[0037] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the technical principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A tunnel line centerline modeling method based on CATIA, characterized in that: include: Step a, create a local centerline, use the parallel command to offset the horizontal curve driven by the parametric equation to achieve the drawing of the local centerline; Step b: creating and instantiating a local centerline template, creating a custom feature in the knowledge engineering module, packaging the method for creating the local centerline in step a to generate a template, modifying parameters according to design requirements and instantiating the template to generate multiple local centerlines; Step c: line assembly, assembling multiple local center lines in the global coordinate system to form a complete three-dimensional tunnel line center line model.
2. The method for modeling the centerline of a tunnel route based on CATIA according to claim 1, characterized in that: In step a, using the parallel command to offset the horizontal curve driven by the parametric equation includes: determining the relationship between the mileage and the elevation by programming or reference curve generation rule curve, and then adjusting the elevation of the horizontal curve according to the above relationship by the parallel command, and finally determining the local centerline position The local centerline creation method includes the following steps: Step a1, create parameters and relationships; use the formula command to create a new type of parameters, the new type of parameters include: L0, R0, A, tangent length, α, p, q; and assign values to L0 and R0 according to the design; determine the mathematical relationship between the parameters according to the formulas of the transition curve; use the rule command to create a new rule transition curve x_l and transition curve y_l in the rule editor; in the above transition curve x_l, after setting the parameter t according to the requirements of the rule editor, enter the relationship equation between x and l: , Similarly, enter the relationship equation between y and l in the relaxation curve y_l: , Step a2, create horizontal curve reference elements; create intersection points, tangent lines, transition curve reference lines and reference planes, the creation method includes: firstly draw three intersection points according to the coordinates, when drawing, the geodetic projection coordinates should be replaced with the mathematical coordinate system, and obtain point .1, point .2, and point .3; then connect the three intersection points in sequence with the line command to obtain two line segments, namely line .1 and line .2; make points on the two line segments respectively to obtain two points T1 and T2, and modify the distances of points T1 and T2 from the intersection point .2 to the parameter tangent length; use the line command to pass through the above two points T1 and T2, respectively create reference lines perpendicular to the XY plane, namely line .3 and line .4, and modify the lengths of line .3 and line .4 to 150m; use the plane command to pass through the above reference lines line .3 and line .4, and establish reference planes parallel to and perpendicular to the tangent lines line .1 and line .2, respectively, for a total of four, namely plane .1, plane .2, plane .3, and plane .4; Step a3, create a horizontal curve transition curve segment; set parameter l, create a relationship curve of x, y, and parameter l in three-dimensional space according to the parametric equation of the transition curve, project the three-dimensional curve to the horizontal plane, and obtain the transition curve segment on the horizontal curve. The creation method includes: firstly, use the parallel command to create the x and l relationship curve, select straight line.3 for reference curve, select plane.1 for support surface, select law curve function for offset, select transition curve x_l for law curve element, and obtain offset curve parallel.1; create y and l relationship curve parallel.2, use the parallel command to create, select straight line.3 for reference curve, select plane.2 for support surface, select law curve function for offset, select transition curve y_l for law curve element, and obtain offset curve parallel.2; then use the mix command to mix the above relationship curves parallel.1 and parallel.2 to obtain the three-dimensional relationship curve mix.1 of x, y, and parameter l; finally, mix the three-dimensional relationship curve. 1 is projected onto the horizontal XY plane to obtain projection.1, which is a transition curve on the flat curve; the creation method of the transition curve on the other side is the same, including: firstly, the parallel command is used to create the x and l relationship curve, the reference curve selects straight line.4, the support surface selects plane.3, the offset selects the law curve function, and the law curve element selects the transition curve x_l, so as to obtain the offset curve parallel.3, and then the y and l relationship curve is created by the parallel command, the reference curve selects straight line.4, the support surface selects plane.4, the offset selects the law curve function, and the law curve element selects the transition curve y_l, so as to obtain the offset curve parallel.4; then the mixed command is used to mix the above relationship curves parallel.3 and parallel.4 to obtain the three-dimensional relationship curve mixed.2 of x, y, and parameter l; finally, the three-dimensional relationship curve mixed.2 is projected onto the horizontal XY plane to obtain projection.2, which is the transition curve on the other side of the flat curve; Step a4, creating a support surface for the offset of a flat curve; when using the parallel command to offset the flat curve upward, it is necessary to determine the offset direction, and create a support surface to determine the offset direction. The creation method includes: first, using the circle command to connect and create curve projection.1 and projection.2 in the transition curve segment of the flat curve, the radius selects parameter R0, the support surface selects the horizontal plane, and obtains the flat curve arc circle.1; then, using the stretch command, respectively create stretch surfaces of projection.1, projection.2 and circle.1, the surface contours select projection.1, projection.2 and circle.1 respectively, the stretch direction selects the Z axis direction, and the size selects any length greater than the elevation, and respectively obtains stretch surfaces stretch.1, stretch.2, stretch.3, and the flat curve offset will use these three surfaces as support surfaces; Step a5, offset the horizontal curve; use the parallel command to offset the horizontal curve upward so that its z coordinate changes according to the value of the designed vertical curve to obtain the corresponding line center line, and the creation method includes: firstly create a law curve, specify the mathematical relationship between the elevation offset and the horizontal curve mileage, and obtain the law curve.1, then use the parallel command to offset the horizontal curve, select projection.1, projection.2 and circle.1 as reference curves, select stretch.1, stretch.2 and stretch.3 as support surfaces, select law curve.1 as offset, and obtain parallel.3, parallel.4, and parallel.5 respectively; finally, use the join command to merge parallel.3, parallel.4, and parallel.5 into a whole to obtain curve join.1, that is, a section of the tunnel center line.
3. The method for modeling the centerline of a tunnel route based on CATIA according to claim 2, characterized in that: In step a5, the creation method is to use the rule command to create it in the rule curve editor, and by writing code, the mathematical relationship between the elevation offset and the horizontal curve mileage is specified to obtain the rule curve.
1.
4. The method for modeling the centerline of a tunnel route based on CATIA according to claim 2, characterized in that: In step a5, the creation method is to use the law curve command, define the law curve by drawing a vertical curve, select projection.1, projection.2 and circle.1 as references, and select the newly drawn vertical curve as reference to obtain law curve.
1.
5. The method for modeling the centerline of a tunnel route based on CATIA according to claim 2, characterized in that: In step b, the custom template generates a new local centerline by modifying the parameters in the creation and relationship; the script is written in VBScript, the default language of CATIA macros, and three operations are implemented through the script, which automatically reads the parameter table containing the centerline design parameter information, automatically assigns the parameters to the centerline template, and saves it as a new independent part. In this way, the template is read, modified and copied in a cycle to complete the modeling of all local centerlines; The local centerline template creation method includes the following steps: Step b1, create user features; use the Create User Features command, select Curve Joining.1 for the internal component, adjust the component input points.1, .2, .3, XY plane, design parameters and law curve, select L0, R0 for the design parameters, and the intersection coordinates to obtain user feature 1; Step b2, create a macro copy script; Use macros to conduct secondary development of CATIA, and use Excel as a data storage and transmission tool, combined with parametric templates, to complete centerline modeling; Step b3, create other local center lines; use the macro script to modify user feature 1, adjust the corresponding parameters according to the design table, and obtain user feature 1.1, that is, create other local center lines.
6. The method for modeling the centerline of a tunnel route based on CATIA according to claim 5, characterized in that: Step c comprises the following steps: Step c1, create a new product and import each local centerline; in the assembly design module, select import existing parts and import the local centerline file; Step c2, creating constraints; the coordinates of each local centerline are created based on the local coordinates of each file; in the global coordinate system, the local coordinate offset is adjusted back to the original design position; and each local centerline component is fixed at the corresponding design position using the matching constraint; Step c3, create a clip line; use the straight line command to connect the local center lines to form a complete three-dimensional tunnel line center line.