Back-calculation verification system and back-calculation verification method for parameterized components of ship CAD system
By introducing a parameterized component counter-calculation verification system in the ship CAD system, the problems of complex definition of counter-calculation and difficulty in verification are solved, effective verification and error positioning of counter-calculation formulas are achieved, and design efficiency and accuracy are improved.
Patent Information
- Application Number
- CN202411595478.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-11
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2044-11-11
AI Technical Summary
In the marine CAD system, the inverse definition of parameterized component design is complex and difficult to verify, which makes it difficult for designers to locate the causes and locations of the incorrect counter calculation formula, affecting design efficiency and accuracy.
Provide a parameterized component counter-calculation verification system, including parameterized component connection point identification module, installation connection point definition module, installation connection point inspection module and counter-calculation verification module. Through the coordinated work of these modules, parameterization can be parsed and verified. The component's inverse calculation formula, the cause and location of the positioning error.
Effectively help users check the reverse calculation formula of parameterized components, improve design efficiency and design effect, improve the structural entity modeling capabilities of the ship's CAD design system, and ensure the accuracy of the design.
Smart Images

Figure CN119129112B_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the field of digital ship design, and in particular relates to a parameterized component back-calculation verification system and a back-calculation verification method based on a ship CAD system. Background Art
[0002] The Ship Product Design (CAD) system is a design software system with independent intellectual property rights that improves my country's innovative capabilities in ship design and construction. The system is based on OpenGL and develops a 3D CAD graphics platform with independent intellectual property rights. It has functions such as overall design, structural design, piping design, duct design, electrical design, iron and steel outfitting design, and painting production design. The ship CAD system can realize integrated ship design, form a 3D digital model of the ship, and provide complete data information for ship design, manufacturing, and management.
[0003] Parametric component design is an important part of the basic data in the ship CAD system and a new way to describe component products. The biggest difference from the general design method is that parametric component design retains the entire design process of the product, and by changing the design parameters, the parameter-driven parametric model instantiation is generated to generate a model of the size required by the user. Therefore, a parametric component can generate a series of component products of the same type but different specifications, and designers do not need to perform the entire design process again. They can complete the new design by simply modifying the component size parameters or constraint relationships. In addition, the inverse calculation in parametric component design is also an important auxiliary tool in parametric component design. After defining the inverse calculation formula in the parametric component, by selecting the installed connection point in the atlas of the ship CAD system, a product that meets the specifications can be directly generated. Therefore, defining the inverse calculation formula in the parametric component can best help designers shorten the product design cycle and improve the work efficiency of designers.
[0004] In practical operation, the back calculation definition of parametric component design uses complex formulas, and the back calculation definition of complex parametric models will become more complicated. In addition, after the back calculation definition is completed in the prior art, designers are often unable to verify the correctness of the back calculation definition, nor can they know the cause of the error, which makes it more difficult to define the back calculation. If the back calculation problem cannot be discovered in time in the ship CAD system, it will affect the efficiency and accuracy of the entire parametric component, thereby affecting the design of the parametric component, and affecting the user's experience of the overall ship CAD system. Summary of the invention
[0005] In view of the problems existing in the prior art, the present invention provides a method for back-calculation verification of parameterized components of a ship CAD system. Some embodiments of the present invention are capable of back-calculation verification of parameterized components in the development of a ship CAD system, providing a back-calculation verification system and a verification method to help users check the back-calculation formula of parameterized components, locate the cause and position of the back-calculation formula error, and aim to improve the design efficiency and design effect of parameterized components.
[0006] To achieve the above object, the present invention adopts the following technical solutions:
[0007] A back-calculation verification system for a parametric component of a ship CAD system, wherein the parametric component is a component composed of elements including parameters, variables, references, connection points, and back-calculation formulas in a ship CAD system, and the back-calculation verification system comprises:
[0008] A parameterized component connection point identification module, the parameterized connection point identification module is connected to the ship CAD system, and the parameterized component connection point identification module is used to parse the connection point information in the parameterized component script, obtain the parameterized component inverse calculation formula, and copy and generate a copy of the parameterized component script;
[0009] An installation connection point definition module, the installation connection point definition module is connected to the parameterized component connection point identification module, obtains the identified parameterized component connection point data and the parameterized component inverse calculation formula from the parameterized component connection point identification module, defines the installation connection point data connected to the parameterized component connection point according to the connection point matching rule, organizes the defined installation connection point data into a script format, and adds it to the parameterized component script copy data to form the parameterized component inverse calculation verification data;
[0010] An installation connection point check module is connected with an installation connection point definition module to obtain parameterized component back-calculation inspection data, check whether the installation connection point script data format in the parameterized component back-calculation inspection data is correctly defined, check whether the base point, coordinate system and connection point attribute data of the installation connection point are correctly defined, check whether the type of the installation connection point matches the parameterized component connection point, and output the error information if an error message is found, and indicate the error location;
[0011] A back-calculation verification module is connected to the installation connection point inspection module, and obtains parameterized component back-calculation verification data from the installation connection point inspection module. The parameterized component back-calculation verification data is used to verify whether the back-calculation formula is correctly defined. If the definition is correct, the verification passes. If the definition is incorrect, a matching error is output, an error message is returned, and the location of the error is indicated.
[0012] In the parametric component back-calculation verification system of the ship CAD system of the present invention, the parametric connection point identification module parses and obtains the connection point data from the parsed parametric component script, parses the attribute information of the connection point and the referenced connection surface information from the connection point data, and parses the local coordinate system of the connection surface from the connection surface information data. The local coordinate system is the local coordinate system of the connection point. The local coordinate system of the connection point is combined with the attribute information of the connection point to obtain the complete data of the parametric connection point. The parametric connection point identification module obtains the parametric component back-calculation formula while parsing the parametric component script.
[0013] In the parametric component back-calculation verification system of the ship CAD system of the present invention, the back-calculation verification module obtains a script copy of the parametric component, parses the parametric component script copy data, matches the parametric component connection points and installation connection points, integrates the installation connection point coordinate system data and attribute data into variables and adds them to the parametric component variable data, uses the variable data to calculate the back-calculation formula, verifies whether the back-calculation formula is correctly defined, traverses the installation connection points and calculates the parametric local coordinate system according to the base point and coordinate system of the connection point data, verifies whether the parametric component local coordinate system can be calculated, and further verifies whether the back-calculation formula is correctly defined.
[0014] A method for back-calculation verification of parameterized components of a ship CAD system, based on the above-mentioned back-calculation verification system of parameterized components, specifically comprises the following implementation steps:
[0015] The first step is to obtain and parse the parametric component data from the ship CAD system, and parse and generate the parametric component connection point structured data set from the obtained parametric component connection point script information, that is, to obtain the parametric component connection point information and the inverse calculation formula;
[0016] Step 2: According to the connection point information of the parameterized component, find the connection point type that matches the connection point of the parameterized component in the connection point matching table, and define the installation connection point according to the requirements of the connection point type;
[0017] Step 3: Check the coordinate system and attribute data of all defined installation connection points. If the check passes, generate the inverse calculation variable according to the installation connection point data; if the check fails, return an error message to indicate the definition error.
[0018] Step 4. Add the back calculation variables of the installation connection points to the parameterized component variable list, substitute the back calculation variables into the back calculation formula, and determine the value of the parameter according to the type of the back calculation formula. The types of back calculation formulas include the preferred back calculation formula, the verification back calculation formula, and the substitute back calculation formula.
[0019] Step 5. Calculate the local coordinate system of the parameterized component based on the relationship between the connection points in the inverse calculation formula. If the local coordinate system can be calculated, the inverse calculation formula is correct. If the local coordinate system cannot be calculated, the inverse calculation formula is incorrect and an error message is returned.
[0020] Preferably, in the first step, the implementation process includes: back-calculation verification requires that the parameterized component is a complete and correct subtree, and the complete and correct subtree means that the topological relationship between the elements of the parameterized component is perfect, and the parameters, variables and formulas used are correct.
[0021] Preferably, in the first step, the parameterized component connection point identification implementation steps are:
[0022] S11. Input the data of the parameterized component to be verified;
[0023] S12. Parsing the parametric component script to determine whether there is an inverse calculation formula and connection point information; if there is no such inverse calculation formula and connection point information, then return to the main program and end the verification;
[0024] S13. Analyzing the connection surface data used by the connection point;
[0025] S14. parsing coordinate system data from the connection surface data;
[0026] S15. Parsing the type data of the connection point;
[0027] S16. Parsing connection point attribute data;
[0028] S17. Analytical parameterized component back calculation formula;
[0029] S18. Return the connection point data and the inverse calculation formula data of the parameterized component, thereby obtaining the connection point information of the parameterized component and obtaining the inverse calculation formula of the parameterized component.
[0030] Preferably, in the second step, the implementation process includes: analyzing the information of the parameterized component connection points used in the inverse calculation formula, defining the corresponding installation connection points as needed, the connection point data including the connection point type, coordinate system P, W, U coordinates, attributes FN, ND, FD, FP, FH, DN, NS and NL, and defining the base point position, coordinate system and included attribute data of the connection point according to the profession and type in the ship software where the connection point is located.
[0031] Preferably, in the third step, the implementation process includes: traversing and checking whether the structure defined by the installation connection point is correct, checking whether the type of the installation connection point is correct, checking whether the position data of the installation connection point is correct, checking whether the W vector in the coordinate system of the installation connection point is a 0 vector, and checking whether the attributes of the installation connection point are correct. If the check passes, the internal format of the connection point in the back calculation is generated; checking for errors, returning error information, and indicating the location of the error. The back calculation refers to using the data variables of the installation connection point as parameters to define the back calculation formula in the parametric component definition stage, and replacing the data variables with the actual data of the installation connection point in the layout stage of the parametric component to calculate the parameters, thereby determining the geometric shape of the parametric component and the coordinate system position of the parametric component. The installation connection point refers to the location where the parametric component is installed when the parametric component is installed in the ship CAD.
[0032] Preferably, in the fourth step, the implementation process includes: matching the parameterized component connection points and the installation connection points, traversing the installation connection points, organizing the coordinate system data and attribute data in the installation connection points into the format required by the parameterized component variables in the order between the installation connection points, and adding them to the parameterized component variable list. There is often more than one inverse calculation formula for a parameter. When there are multiple inverse calculation formulas, the preferred formula, the verification formula, and the substitute formula must be determined first. When the verification formula and the preferred formula both have results, the result of the verification formula must be the same as the result of the preferred formula, otherwise it is considered to have no result, and the substitute formula uses its calculated result as the result only when the preferred formula has no result. After the calculation is completed, check whether the inverse calculation of all parameters can calculate the results. If the check passes, the parameter data is returned; if an error is checked, an error message is returned to indicate the location of the error.
[0033] Preferably, in the fifth step, the implementation process includes: traversing according to the number of installation connection points, analyzing the use status of the connection points in the inverse calculation formula, the use status includes: on a plane, on a straight line and fixed, according to the state of the installation connection point, based on the data of the parameterized component connection point and the installation connection point, checking whether the local coordinate system of the parameterized component can be matched, the specific type and calculation method are:
[0034] S51. If one connection point is fixed and the other connection point is also fixed, then it is only necessary to match the layout coordinate system of the parameterized component according to the position of the connection point and their W direction, that is, to calculate the local coordinate system;
[0035] S52. If one connection point is fixed and the other is on a straight line, the distance and the perpendicular point from the base point to the straight line are calculated using the base point of the fixed connection point, and then the fixed point, the perpendicular point and the distance are used to match the layout coordinate system of the parameterized component, that is, the local coordinate system is calculated;
[0036] S53. If one connection point is fixed and the other is on the plane, the distance and the vertical point from the base point to the plane are calculated using the base point of the fixed connection point, and then the fixed point, the calculated vertical point and the distance are used to match the layout coordinate system of the parameterized component, that is, the local coordinate system is calculated;
[0037] S54. If one connection point is on a straight line and the other point is also on a straight line, it is necessary to find the common perpendicular line of the two straight lines, and then match the parameterized component layout coordinate system according to the common perpendicular point, that is, calculate and obtain the local coordinate system;
[0038] S55. If one connection point is on a straight line and the other connection point is on a plane, the intersection of the plane and the straight line is calculated. If the line and the plane have an intersection, the parameterized component coordinate system is matched with the intersection as a fixed point, that is, the local coordinate system is calculated.
[0039] In the above situation, if the match is successful, the reverse calculation verification is successful; if the match is wrong, an error message is returned to indicate the location of the error.
[0040] After the error message is returned, if adjustments and updates have been made, the parameterized component back-calculation verification will be performed again, starting the verification process from the first step to the fifth step.
[0041] Compared with the prior art, the present invention has the following beneficial effects:
[0042] 1. The parametric component back-calculation verification system and verification method of the present invention solve the problem of difficulty in locating errors in the back-calculation formula of the parametric component design in the ship CAD system. It can effectively help users check the back-calculation formula of the parametric component and locate the cause and position of the error in the back-calculation formula, which is of great significance for improving the design efficiency and design effect of the parametric component.
[0043] 2. The present invention can verify the back calculation verification of parametric components based on the ship CAD design system, thereby improving the structural entity modeling capability of the ship CAD design system. Designers can use parametric components faster and better when arranging models, thereby improving the accuracy of the design. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. 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 creative work.
[0045] Figure 1 It is a schematic diagram of the composition architecture of a parameterized component back-calculation verification system of a ship CAD system of the present invention.
[0046] Figure 2 The present invention is a schematic flow chart of a method for back-calculating and verifying a parameterized component of a ship CAD system.
[0047] Figure 3 The present invention discloses a schematic diagram of information analysis of a parameterized component in a parameterized component back-calculation verification method of a ship CAD system.
[0048] Figure 4 The invention discloses a schematic diagram of a technique for defining installation connection points in a method for back-calculating and verifying a parameterized component of a ship CAD system.
[0049] Figure 5 The present invention is a schematic diagram of the installation connection point inspection technology in the back calculation verification method of the parameterized component of the ship CAD system.
[0050] Figure 6 The present invention is a schematic diagram of a back-calculation verification technology in a back-calculation verification method for a parameterized component of a ship CAD system.
[0051] Figure 7 It is a schematic diagram of a coordinate system matching technology in a back-calculation verification method for a parameterized component of a ship CAD system of the present invention. DETAILED DESCRIPTION
[0052] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. 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.
[0053] In the ship CAD system, parametric components are components composed of elements including parameters, variables, references and connection points. Parameters are the basic data that constitute the components, variables are the basic attributes that constitute the components, references build the geometric shape of the components, and connection points define the connection position and attributes of the components. In the ship CAD system, back calculation refers to using the data variables of the installation connection points as the parameters to define the back calculation formula in the parametric component definition stage, and replacing the data variables with the actual data of the installation connection points to calculate the parameters in the layout stage of the parametric components, thereby determining the geometric shape of the parametric component and the coordinate system position of the parametric component. The installation connection point refers to the location where the parametric component is installed when the parametric component is installed in the ship CAD. Example 1
[0054] This embodiment provides a parametric component back-calculation verification system for a ship CAD system. Figure 1 and Figure 2As shown, the system consists of: a parameterized component connection point identification module, an installation connection point definition module, an installation connection point inspection module and a back calculation verification module, wherein:
[0055] The parametric connection point identification module is connected to the ship CAD system, in which the parametric components are stored. The script of the parametric components contains connection point information and inverse calculation formula, which is the existing data that has been completed in the ship CAD system. The parametric component connection point identification module is used to parse the connection point information in the parametric component script and obtain the inverse calculation formula of the parametric component. During operation, the parametric component connection point identification module parses the parametric component script to obtain the connection point data, and then parses the attribute information of the connection point and the connection surface information referenced by it from the connection point data, and then parses the local coordinate system of the connection surface from the connection surface data. The local coordinate system of the connection surface is the local coordinate system of the connection point, and then the local coordinate system of the connection point is combined with the attribute information of the connection point to obtain the complete data of the connection point. While parsing the parametric component script, the inverse calculation formula of the parametric component is also obtained. The inverse calculation formula is the key point that needs to be checked for correctness.
[0056] The installation connection point definition module is connected to the parameterized component connection point identification module. The installation connection point definition module is used to define the installation connection point data connected to the parameterized component connection points according to the identified parameterized component connection points and the connection points used in the analysis of the inverse calculation formula, according to the connection point matching rules, organize the defined installation connection point data into a script format, and add it to the parameterized component script copy data to form inverse calculation verification data. The connection point matching rules are the inherent connection point matching table in the ship CAD system, including the types and corresponding relationships of the connection points.
[0057] The installation connection point checking module is connected to the installation connection point definition module, and the installation connection point checking module obtains the installation connection point data as the back calculation verification data from the installation connection point definition module. The installation connection point checking module is used to check whether the data format of the installation connection point script is correctly defined, check whether the base point, coordinate system and connection point attribute data of the installation connection point are correctly defined, and check whether the type of the installation connection point matches the parameterized component connection point;
[0058] The reverse calculation verification module is connected to the installation connection point inspection module, and obtains the parameterized component script copy data from the installation connection point inspection module. The reverse calculation verification module obtains the script copy of the parameterized component, parses the script copy data of the parameterized component, matches the parameterized component connection point and the installation connection point, specifically integrates the installation connection point coordinate system data and attribute data into variables and adds them to the parameterized component variable data, uses the variable data to calculate the reverse calculation formula, and verifies whether the reverse calculation formula is correctly defined. Specifically, the parameterized local coordinate system is calculated according to the base point and coordinate system of the connection point data by traversing the installation connection point, and verifies whether the parameterized component local coordinate system can be calculated, thereby further verifying whether the reverse calculation formula is correctly defined. Thus, the correctness of the reverse calculation formula is judged.
[0059] The parameterized component back-calculation verification system of the present invention obtains parameterized component data information from the ship CAD system, determines whether the back-calculation formula of each parameter component is correct, and if correct, checks and ends the verification; if incorrect, outputs back-calculation formula error information to remind the cause of the data error and the location of the error.
[0060] like Figure 3 As shown, in this implementation case, the first step is to use a parametric component connection point recognition module, which is used to parse the connection point information in the parametric component script and obtain the inverse calculation formula of the parametric component. The implementation steps of the parametric component connection point recognition are:
[0061] (1) Input the data of the parameterized component to be verified;
[0062] (2) Parse the parameterized component script to determine whether there is an inverse calculation formula and connection point information; if any of the above does not exist, then return to the main program and end the verification.
[0063] (3) Analyze the connection surface data used by the connection point;
[0064] (4) Analyze coordinate system data from connection surface data;
[0065] (5) Parse the type data of the connection point;
[0066] (6) Analyze the connection point attribute data;
[0067] (7) Analytical inverse calculation formula of parameterized components
[0068] (8) Return the connection point data and inverse calculation formula data of the parametric component, thereby obtaining the connection point information of the parametric component and obtaining the inverse calculation formula of the parametric component.
[0069] Secondly, the installation connection point definition module in this implementation case is used to define the installation connection point data connected to the parameterized component connection points according to the identified parameterized component connection points and the connection points used in the analysis of the inverse calculation formula, and organize the defined installation connection point data into a script format, and add it to the parameterized component script copy data to form inverse calculation verification data.
[0070] like Figure 4 As shown, the implementation steps for installing the connection point definition are:
[0071] (1) Analyze the connection point data of the parametric component and the connection point data used in the inverse calculation formula to determine the number and type of installation connection points to be defined.
[0072] (2) Define the coordinate system of the installation connection points to simulate the actual installation position of the parametric components in the atlas.
[0073] (3) Define the attribute data of the connection point according to the installation connection point profession and type.
[0074] (4) Organize the installation connection point data and organize the parameterized component scripts and installation connection point data into back-calculation verification data.
[0075] Again, the installation connection point checking module in this implementation case is used to check whether the installation connection point script data format is defined correctly, check the base point, coordinate system and connection point attribute data of the installation connection point, and check whether the type of the installation connection point matches the parametric component connection point.
[0076] like Figure 5 As shown, the installation connection point inspection can be divided into:
[0077] (1) Compile and check the script to check whether the installation connection point script format of the parameterized component is defined correctly;
[0078] (2) Check whether the type of the installation connection point is defined correctly;
[0079] (3) Check whether the base point position of the installation connection point is defined correctly;
[0080] (4) Check whether the coordinate system data of the installation connection point is defined correctly;
[0081] (5) Check whether the attribute data of the installation connection point is defined correctly;
[0082] (6) If the check passes, the correct data will be returned.
[0083] (7) If the check fails, an error message is returned, indicating the cause of the data error.
[0084] Finally, the back-calculation verification module in this implementation case is used to obtain a script copy of the parametric component, parse the parametric component script copy data, match the parametric component connection points and installation connection points, integrate the installation connection point coordinate system data and attribute data into variables and add them to the parametric component variable data, use the variable data to calculate the back-calculation formula, verify whether the back-calculation formula is defined correctly, traverse the installation connection points to calculate the parametric local coordinate system according to the base point and coordinate system of the connection point data, and verify whether the parametric component local coordinate system can be calculated, thereby further verifying whether the back-calculation formula is defined correctly.
[0085] like Figure 6 As shown in the figure, the back calculation test implementation steps are:
[0086] (1) Traverse the installation connection points and match the parameterized component connection points and installation connection point data;
[0087] (2) After the match is correct, add the coordinate system data and attribute data of the installation connection point to the parameterized component variable data;
[0088] (3) Determine the preferred formula, verification formula, and backup formula. When both the verification formula and the preferred formula have results, the result of the verification formula must be the same as that of the preferred formula, otherwise it is considered to be no result. The result of the backup formula is used as the result only when the preferred formula has no result. After the calculation is completed, check whether the inverse calculation of all parameters can calculate the results;
[0089] (4) Match the local coordinate system of the parameterized component according to the connection points;
[0090] (5) The calculation succeeds and the correct data is returned.
[0091] (6) If a calculation error occurs, an error message will be returned, indicating the cause of the data error.
[0092] like Figure 7 As shown, the parametric component coordinate system is matched according to the following five situations:
[0093] If one connection point is fixed and the other connection point is also fixed, then the layout coordinate system of the parametric component only needs to be matched according to the positions of the connection points and their W directions.
[0094] If one connection point is fixed and the other connection point is on a straight line, the base point of the fixed connection point is used to calculate the distance from the base point to the straight line and the perpendicular point. Then, the fixed point, the perpendicular point and the distance are used to match the layout coordinate system of the parametric component.
[0095] If one connection point is fixed and the other connection point is on the plane, the base point of the fixed connection point is used to calculate the distance and the perpendicular point from the base point to the plane. Then, the fixed point, the perpendicular point and the distance are used to match the layout coordinate system of the parametric component.
[0096] If one connection point is on a straight line and the other connection point is also on a straight line, it is necessary to find the common perpendicular point of the two straight lines and then match the parametric component layout coordinate system based on the common perpendicular point.
[0097] If one connection point is on a straight line and the other connection point is on a plane, the intersection of the plane and the straight line is calculated. If the line and the plane have an intersection, the intersection is used as a fixed point to match the parametric component coordinate system.
[0098] The present invention solves the problem of difficulty in locating errors in the reverse calculation formula of parametric component design in the autonomous ship CAD system, and can effectively help users check the reverse calculation formula of the parametric component and locate the cause and location of the reverse calculation formula error. The system and method of the present invention can verify the reverse calculation verification of the parametric component based on the ship CAD design system, improve the structural entity modeling capability of the ship CAD design system, and designers can use the parametric components faster and better when arranging the model, thereby improving the accuracy of the design.
[0099] Although the above embodiments have been described in detail for the present invention, it should be understood by those skilled in the art that modifications or improvements may be made based on the contents disclosed in the present invention without departing from the spirit and scope of the present invention, and such modifications and improvements are within the spirit and scope of the present invention.
Claims
1. A back-calculation verification system for parameterized components of a ship CAD system, wherein the parameterized components are components in the ship CAD system composed of elements including parameters, variables, references, connection points, and back-calculation formulas, characterized in that: The back calculation verification system comprises: A parameterized component connection point identification module, the parameterized component connection point identification module is connected to the ship CAD system, and the parameterized component connection point identification module is used to parse the connection point information in the parameterized component script, obtain the parameterized component inverse calculation formula, and copy and generate a copy of the parameterized component script; An installation connection point definition module, the installation connection point definition module is connected to the parameterized component connection point identification module, obtains the identified parameterized component connection point data and the parameterized component inverse calculation formula from the parameterized component connection point identification module, defines the installation connection point data connected to the parameterized component connection point according to the connection point matching rule, organizes the defined installation connection point data into a script format, and adds it to the parameterized component script copy data to form the parameterized component inverse calculation verification data; An installation connection point check module is connected with an installation connection point definition module to obtain parameterized component back-calculation inspection data, check whether the installation connection point script data format in the parameterized component back-calculation inspection data is correctly defined, check whether the base point, coordinate system and connection point attribute data of the installation connection point are correctly defined, check whether the type of the installation connection point matches the parameterized component connection point, and output the error information if an error message is found, and indicate the error location; A back-calculation verification module is connected to the installation connection point inspection module, and the back-calculation verification module obtains the parameterized component back-calculation verification data from the installation connection point inspection module. The parameterized component back-calculation verification data is used to verify whether the back-calculation formula is correctly defined. According to the relationship between the connection points in the back-calculation formula, the local coordinate system of the parameterized component is calculated. If the local coordinate system can continue to be calculated, it is verified that the back-calculation formula is correctly defined. If the local coordinate system cannot be calculated, the back-calculation formula is incorrectly defined. If the definition is correct, the verification passes. If the definition is incorrect, a matching error is output, an error message is returned, and the location of the error is prompted.
2. The parameterized component back-calculation verification system of the ship CAD system according to claim 1 is characterized in that: The parametric connection point identification module parses and obtains the connection point data from the parsed parametric component script, parses the attribute information of the connection point and the referenced connection surface information from the connection point data, and parses the local coordinate system of the connection surface from the connection surface information data. The local coordinate system is the local coordinate system of the connection point. The local coordinate system of the connection point is combined with the attribute information of the connection point to obtain the complete data of the parametric connection point. The parametric connection point identification module obtains the parametric component inverse calculation formula while parsing the parametric component script.
3. The parameterized component back-calculation verification system of the ship CAD system according to claim 1 is characterized in that: The inverse calculation verification module obtains a script copy of the parameterized component, parses the parameterized component script copy data, matches the parameterized component connection points and the installation connection points, integrates the installation connection point coordinate system data and attribute data into variables and adds them to the parameterized component variable data, uses the variable data to calculate the inverse calculation formula, verifies whether the inverse calculation formula is correctly defined, traverses the installation connection points to calculate the parameterized local coordinate system according to the base point and coordinate system of the connection point data, verifies whether the parameterized component local coordinate system can be calculated, and further verifies whether the inverse calculation formula is correctly defined.
4. A method for back-calculation verification of parameterized components of a ship CAD system, using the back-calculation verification system of parameterized components according to any one of claims 1 to 3, characterized in that: The method comprises the following implementation steps: The first step is to obtain and parse the parametric component data from the ship CAD system, parse the connection point information in the parametric component data, obtain the parametric component inverse calculation formula and copy the parametric component script to generate a copy of the parametric component script, and parse and generate a parametric component connection point structured data set based on the obtained parametric component connection point script information, that is, to obtain the parametric component connection point information and the inverse calculation formula; Step 2: According to the connection point information of the parameterized component, find the connection point type that matches the connection point of the parameterized component in the connection point matching table, and define the installation connection point according to the requirements of the connection point type; Step 3: Check the coordinate system and attribute data of all defined installation connection points. If the check passes, generate the inverse calculation variable according to the installation connection point data; if the check fails, return an error message to indicate the definition error. Step 4. Add the back calculation variables of the installation connection points to the parameterized component variable list, substitute the back calculation variables into the back calculation formula, and determine the value of the parameter according to the type of the back calculation formula. The types of back calculation formulas include the preferred back calculation formula, the verification back calculation formula, and the substitute back calculation formula. Step 5. Calculate the local coordinate system of the parameterized component based on the relationship between the connection points in the inverse calculation formula. If the local coordinate system can be calculated, the inverse calculation formula is correct. If the local coordinate system cannot be calculated, the inverse calculation formula is incorrect and an error message is returned.
5. The method for back-calculation verification of parameterized components of a ship CAD system according to claim 4, characterized in that: In the first step, if the parameterized component meets the back-calculation verification requirements, the parameterized component is required to be a complete and correct subtree, where the complete and correct subtree means that the topological relationship between the elements of the parameterized component is perfect, and the parameters, variables and back-calculation formulas used are correct.
6. The method for back-calculation verification of parameterized components of a ship CAD system according to claim 4, characterized in that: In the first step, the identification of connection points of parametric components is implemented as follows: S11. Input the data of the parameterized component to be verified; S12. Parsing the parameterized component script to determine whether there is an inverse calculation formula and connection point information; if there is no inverse calculation formula and connection point information, return to the main program and end the verification; S13. Analyzing the connection surface data used for the connection point; S14. parsing coordinate system data from the connection surface data; S15. Parsing the type data of the connection point; S16. Parsing connection point attribute data; S17. Analytical parameterized component back calculation formula; S18. Return the connection point data and the inverse calculation formula data of the parameterized component, thereby obtaining the connection point information of the parameterized component and obtaining the inverse calculation formula of the parameterized component.
7. The method for back-calculation verification of parameterized components of a ship CAD system according to claim 4, characterized in that: In the second step, the parametric component connection point information used in the inverse calculation formula is analyzed, and the corresponding installation connection points are defined as needed. The base point position, coordinate system and attribute data of the installation connection points are defined according to the profession and type of the parametric component connection points in the ship CAD system software. The defined installation connection point data includes the connection point type, coordinate system P, W, U coordinates, and attributes FN, ND, FD, FP, FH, DN, NS and NL.
8. The method for back-calculation verification of parameterized components of a ship CAD system according to claim 4, characterized in that: In the third step, its implementation includes: traversing and checking whether the structure of the installation connection point definition is correct, checking whether the type of the installation connection point definition is correct, checking whether the position data of the installation connection point definition is correct, checking whether the W vector in the installation connection point coordinate system is a 0 vector, and checking whether the installation connection point attributes are correct.
9. The method for back-calculation verification of parameterized components of a ship CAD system according to claim 4, characterized in that: The fourth step includes: matching the parameterized component connection points and the installation connection points, traversing the installation connection points, organizing the coordinate system data and attribute data in the installation connection points into the format required by the parameterized component variables according to the order between the installation connection points, and adding them to the parameterized component variable list; If there are multiple inverse calculation formulas, first determine the preferred formula, verification formula and substitute formula. When both the verification formula and the preferred formula have results, the result of the verification formula must be the same as that of the preferred formula, otherwise it is considered to have no result. The substitute formula will only use its calculated result as the result when the preferred formula has no result. After the calculation is completed, check whether the inverse calculation of all parameters can calculate the results. If the check passes, the parameter data is returned; If an error is detected, an error message is returned, indicating the location of the error.
10. The method for back-calculation verification of parameterized components of a ship CAD system according to claim 4, characterized in that: In the fifth step, the implementation includes: Traverse according to the number of installation connection points, analyze the use status of the connection points in the inverse calculation formula, the use status includes: on the plane, on the line and fixed, according to the state of the installation connection point and the data of the parameterized component connection point and the installation connection point, check whether the parameterized component coordinate system can be matched. The specific type and calculation method are as follows: S51. If one connection point is fixed and the other connection point is also fixed, then the layout coordinate system of the parameterized component is matched based on the position of the connection points and their W direction; S52. If one connection point is fixed and the other connection point is on a straight line, the distance and the perpendicular point from the base point to the straight line are calculated using the base point of the fixed connection point, and then the fixed connection point, the perpendicular point and the distance are used to match the layout coordinate system of the parameterized component; S53. If one connection point is fixed and the other connection point is on the plane, the base point of the fixed connection point is used to find the distance and the vertical point from the base point to the plane, and then the fixed point, the found vertical point and the distance are used to match the layout coordinate system of the parameterized component; S54. If one connection point is on a straight line and the other connection point is also on a straight line, it is necessary to find the common perpendicular line of the two straight lines, and then match the parameterized component layout coordinate system according to the common perpendicular point; S55. If one connection point is on a straight line and the other connection point is on a plane, the intersection of the plane and the straight line is calculated. If the straight line and the plane have an intersection, the intersection is used as a fixed point to match the parametric component layout coordinate system; In any of the above S51-S55, if the matching is successful, the local coordinate system of the parameterized component is obtained, and the inverse calculation verification is successful; if the matching is wrong, the local coordinate system of the parameterized component cannot be obtained, and an error message is returned to indicate the location of the error.
Citation Information
Patent Citations
Automatic verification method orienting to parameterization system
CN103729523A
Real-time error detection system and method for household parameterized model
CN111857092A