Model error judgment method, tolerance function module, equipment and medium
By introducing tolerance functional modules into the 3D modeling software system, the position information and local tolerance of geometric elements in the three-dimensional model are determined, and the problems of low tolerance determination accuracy and low efficiency in the prior art are solved, and efficient and accurate model error judgment is achieved.
Patent Information
- Application Number
- CN202510530350.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-25
- Publication Date
- 2025-08-12
AI Technical Summary
Existing 3D modeling software has low accuracy and low efficiency in tolerance determination, which affects the accuracy and efficiency of the model.
By introducing a tolerance function module into the modeling software system, the position information of any two geometric elements in the three-dimensional model is determined, the actual error is calculated based on the position information, and the local tolerance is determined through a preset method to determine whether the actual error is within the tolerance range. The preset method includes searching in the tolerance table, user-defined or calculation rules based on predesign.
It improves the accuracy and efficiency of model error judgment, can quickly judge the errors between a large number of geometric elements, reduce manual intervention, shorten the modeling cycle, and adapt to the diverse needs of different users and modeling scenarios.
Smart Images

Figure CN120470700A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a model error judgment method, a tolerance function module, a device and a medium. Background Art
[0002] With the continuous development of computer technology, 3D modeling software is increasingly being used in industrial design, mechanical manufacturing, architecture, and other fields. However, during the 3D modeling process, due to the limitations of computer floating-point number approximation and computational precision, errors in the computer representation of geometric models are inevitable, affecting the accuracy of the model.
[0003] Traditional 3D modeling software typically relies on either a global single tolerance or adaptive tolerance techniques to handle these geometric errors. While global single tolerance techniques offer fast calculation speeds, they store little information and can easily lead to precision loss. While adaptive tolerance techniques can adapt tolerance values to different locations, their calculations are complex and inefficient.
[0004] Therefore, there is an urgent need for a method that can improve the accuracy of tolerance determination while improving the efficiency of tolerance determination, thereby improving the efficiency of model error judgment. Summary of the Invention
[0005] Therefore, the technical problem to be solved by the present invention is to overcome the problems of low tolerance determination accuracy and low efficiency in the related art.
[0006] In order to solve the above technical problems, in a first aspect, the present invention provides a model error judgment method, which is applied to a tolerance function module in a modeling software system. The model error judgment method includes:
[0007] Determine any two geometric elements in the three-dimensional model as target elements, and determine position information of the target elements;
[0008] determining actual errors between target elements according to position information of the target elements;
[0009] Determine the local tolerance corresponding to the target element according to a preset method;
[0010] Determining a target tolerance according to the local tolerance corresponding to the target element;
[0011] When the actual error is less than or equal to the target tolerance, determining that the actual error between the target elements is within the tolerance range;
[0012] The preset manner includes: searching in a preset tolerance table, user-defined, or determining the local tolerance corresponding to the target element according to a preset calculation rule.
[0013] In an optional implementation, determining the actual error between the target elements according to the position information of the target elements includes:
[0014] A corresponding distance calculation method is determined according to the geometric type of the target element, and based on the corresponding distance calculation method, the actual error between the target elements is determined according to the position information of the target elements; wherein the geometric type includes: point, line, surface or body.
[0015] In an optional implementation, when the preset manner is the preset calculation rule, determining the local tolerance corresponding to the target element according to the preset manner includes:
[0016] Determine a corresponding preset calculation rule according to the geometric type corresponding to the target element, and determine a local tolerance corresponding to the target element according to the corresponding preset calculation rule;
[0017] Wherein, when the geometric type of the target element is a point, the corresponding preset calculation rule is a calculation rule of a distance tolerance determined according to a reference distance, a first proportional coefficient, and a first fixed deviation;
[0018] When the geometric type of the target element is a line, the corresponding preset calculation rules include a calculation rule for an angle tolerance and a calculation rule for a distance tolerance determined according to the reference angle difference, the second proportional coefficient, and the second fixed deviation;
[0019] When the geometric type of the target element is a surface or a body, the corresponding preset calculation rules include a calculation rule based on a distance tolerance and a calculation rule based on an angle tolerance.
[0020] In an optional embodiment, when the preset manner is to search in a preset tolerance table, where the tolerance table includes: geometric types, application conditions, and tolerance values stored in a corresponding relationship, determining the local tolerance corresponding to the target element according to the preset manner includes:
[0021] The tolerance table is searched according to the geometric type and application conditions corresponding to the target element, and the matching tolerance value found is determined as the local tolerance corresponding to the target element.
[0022] In an optional implementation, determining the target tolerance according to the local tolerance corresponding to the target element includes:
[0023] The target tolerance is determined according to the sum of the local tolerances corresponding to the target elements.
[0024] In an optional embodiment, the method further includes:
[0025] When the actual error is greater than the target tolerance, it is determined that the actual error between the target elements is not within the tolerance range.
[0026] In an optional embodiment, the method further includes:
[0027] When it is determined that the actual error between the target elements is within the tolerance range, a closeness value is returned; the closeness value represents the closeness between the actual value and the ideal value of the target elements;
[0028] When it is determined that the actual error between the target elements is not within the tolerance range, the actual error is returned.
[0029] In a second aspect, the present invention provides a tolerance function module, the tolerance function module comprising:
[0030] A first processing unit is configured to determine any two geometric elements in the three-dimensional model as target elements and determine position information of the target elements;
[0031] a second processing unit, configured to determine actual errors between target elements based on position information of the target elements;
[0032] A third processing unit, configured to determine a local tolerance corresponding to the target element according to a preset method;
[0033] a fourth processing unit, configured to determine a target tolerance according to the local tolerance corresponding to the target element;
[0034] a fifth processing unit, configured to determine that the actual error between the target elements is within a tolerance range when the actual error is less than or equal to the target tolerance;
[0035] The preset manner includes: searching in a preset tolerance table, user-defined, or determining the local tolerance corresponding to the target element according to a preset calculation rule.
[0036] In a third aspect, the present invention provides a computer device comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the model error judgment method of the first aspect or any corresponding embodiment thereof by executing the computer instructions.
[0037] In a fourth aspect, the present invention provides a computer-readable storage medium, wherein a single computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the model error judgment method of the above-mentioned first aspect or any corresponding embodiment thereof.
[0038] In a fifth aspect, the present invention provides a computer program product, comprising computer instructions, which are used to enable a computer to execute the model error judgment method of the above-mentioned first aspect or any corresponding embodiment thereof.
[0039] The technical solution provided by the present invention has the following technical effects:
[0040] The technical solution of the embodiment of the present invention calculates the actual error by determining the position information of the target element, and judges whether the actual error is within the tolerance range in combination with the local tolerance corresponding to the target element. It can accurately judge whether the actual error between any two geometric elements in the three-dimensional model is within the tolerance range. The preset method includes searching in the tolerance table, user customization, and determining the local tolerance corresponding to the target element according to preset calculation rules, which can meet the diverse needs of different users and different modeling scenarios. The technical solution of the present invention is realized by the tolerance function module in the modeling software system, which can automate the error judgment process. The tolerance function module in the modeling software system can automatically determine the target element, calculate the actual error, obtain the local tolerance and perform error judgment, reducing the workload of manual intervention and manual calculation, and greatly improving the modeling efficiency. In the process of modeling large and complex three-dimensional models, the errors between a large number of geometric elements can be quickly judged, problems can be discovered and corrected in time, and the modeling cycle can be shortened.
[0041] Provides multiple ways to determine local tolerances. Users can freely choose the appropriate local tolerance determination method based on the characteristics of the model and actual needs, thereby improving the efficiency and accuracy of tolerance determination. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the specific embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0043] Figure 1 is a flow chart of a model error determination method according to an embodiment of the present invention;
[0044] Figure 2 is a schematic structural diagram of a tolerance function module according to an embodiment of the present invention;
[0045] Figure 3 Schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0046] To make the purpose, technical solutions, and advantages of the embodiments of the present invention more clear, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying 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. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making creative efforts shall fall within the scope of protection of the present invention.
[0047] The embodiments of the present invention provide a model error judgment method, a tolerance function module, a device and a medium to solve the problems of low tolerance determination accuracy and low efficiency in related technologies.
[0048] According to an embodiment of the present invention, an embodiment of a model error judgment method is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer device such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0049] Figure 1 4 is a flow chart of a model error judgment method according to an embodiment of the present invention.
[0050] like Figure 1 As shown, an embodiment of the present invention provides a model error judgment method, which is applied to a tolerance function module in a modeling software system. The tolerance function module supports the import and export of multiple three-dimensional model data formats.
[0051] The model error judgment method includes:
[0052] S101: Determine any two geometric elements in a three-dimensional model as target elements, and determine position information of the target elements.
[0053] In this embodiment, the geometric types of geometric elements in a three-dimensional model generally include four types: point, line, surface, and body. The target elements are two geometric elements of the same geometric type. Two geometric elements of the same geometric type in the target elements can be defined as a first geometric element and a second geometric element. For example, point A (x1, y1, z1) and point B (x2, y2, z2), or lines L1 and L2, or surfaces F1 and F2. The position information of the target elements is represented in the form of three-dimensional coordinates.
[0054] For example, when the first geometric element and the second geometric element are both points, the position information of the first geometric element A can be expressed as (x1, y1, z1), and the position information of the second geometric element B can be expressed as (x2, y2, z2).
[0055] S102: Determine actual errors between target elements according to position information of the target elements.
[0056] In this embodiment, the actual error between target elements can be determined from the distance dimension or the angle dimension. The actual error includes the actual distance error and / or the actual angle error. When the geometric type of the target element is a point, the actual error between the target elements only includes the actual distance error. When the geometric type of the target element is a line, surface, or volume, the actual error between the target elements can include the actual distance error or the actual angle error, or can include both the actual distance error and the actual angle error. In the present invention, both the actual distance error and the actual angle error are included.
[0057] As an example, considering that different geometric types have different distance calculation methods between geometric elements, when determining the actual distance error between target elements based on the position information of the target elements, it is necessary to determine the corresponding distance calculation method according to the geometric type of the target elements, and based on the corresponding distance calculation method, determine the actual distance error between the target elements according to the position information of the target elements.
[0058] In this embodiment, conventional distance calculation methods in the art can be used as distance calculation methods for different geometric types. For example, the distance calculation methods corresponding to the geometric types of point, line, surface, and volume are Euclidean distance calculation, minimum distance calculation, surface-to-surface distance calculation, and boundary sampling-based methods to determine the actual distance error between two geometric elements of the volume type. In the present invention, conventional angle calculation methods in the art are used to calculate the actual angle and the actual angle error, which will not be further described here.
[0059] As an example, calculate the actual distance d between point A and point B using the Euclidean distance calculation method: The absolute value of the difference between the actual distance and the preset ideal distance is taken as the actual distance error.
[0060] Determine the actual distance between two volume-type geometric elements based on boundary sampling:
[0061] The boundary of two bodies is sampled to obtain a series of boundary points, and then the distance between these boundary points is calculated to approximate the actual distance between the two bodies. This method is suitable for irregularly shaped bodies.
[0062] Boundary sampling: Select a sufficient number of points on the surfaces of two bodies according to a specific sampling rule. For example, uniform sampling can be used to select sampling points on the surfaces of the bodies at a certain grid density. For example, for an irregular sculpture and an irregular container, a number of sampling points can be uniformly selected on their surfaces.
[0063] Calculate the distance between sampling points: Also use the Euclidean distance calculation method to calculate the distance between each pair of sampling points.
[0064] Determine the actual distance: Select the smallest distance between sampling points as the actual distance between the two bodies. If there are multiple calculated distances between sampling points, take the smallest value as the final actual distance between the two bodies.
[0065] S103: Determine the local tolerance corresponding to the target element according to a preset method.
[0066] In this embodiment, the preset manner includes: searching in a preset tolerance table, user-defined, or determining the local tolerance corresponding to the target element according to a preset calculation rule.
[0067] In this embodiment, the user can directly select two geometric elements in the user interface of the 3D modeling software and set a tolerance value. The tolerance value can be a specific numerical value (0.01 mm) or a specific ratio (±0.1%).
[0068] In this embodiment, a corresponding algorithm can be designed according to preset calculation rules, and the local tolerance values of the positions of two geometric elements can be automatically calculated according to the geometric characteristics and accuracy requirements of the model. When executing the algorithm, the software will traverse all geometric elements in the model and assign corresponding local tolerances to each geometric element according to the calculation rules of the algorithm.
[0069] In this embodiment, the local tolerance corresponding to the target element includes: a first tolerance corresponding to the first geometric element and a second tolerance corresponding to the second geometric element.
[0070] In this embodiment, when the preset method is a preset calculation rule, the corresponding preset calculation rule is determined based on the target element's geometry type, and the local tolerance corresponding to the target element is determined based on the corresponding preset calculation rule. Different preset calculation rules correspond to different geometry types. For example, when the geometry type is a point, the corresponding preset calculation rule is the distance tolerance calculation rule. When the geometry type is a line, the corresponding preset calculation rule includes the angle tolerance calculation rule and the distance tolerance calculation rule. When the geometry type is a surface or volume, the corresponding preset calculation rule includes the distance tolerance calculation rule and the angle tolerance calculation rule.
[0071] S104: Determine a target tolerance according to the local tolerance corresponding to the target element.
[0072] In this embodiment, the target tolerance can be determined based on the sum of the local tolerances corresponding to the target elements, that is, the sum of the first tolerance corresponding to the first geometric element and the second tolerance corresponding to the second geometric element. Target tolerance = first tolerance corresponding to the first geometric element + second tolerance corresponding to the second geometric element.
[0073] Determining the target tolerance based on the sum of the local tolerances corresponding to the target element can improve error tolerance and flexibility. This is particularly useful in many scenarios involving distance measurement or comparison, such as determining the positional relationships of geographic features in a Geographic Information System (GIS). For example, if we want to determine whether two cities are sufficiently close on a map, we can consider them "close" within a certain tolerance range if the actual distance is less than or equal to the sum of the two local tolerances. This determination method accounts for various errors that may occur during the measurement process. For example, when GPS locates a city, the positioning result may contain certain errors due to factors such as signal interference and device accuracy. By setting a tolerance value, even if the actual distance fluctuates due to these errors, as long as it is within the range of the sum of the tolerance values, the relative position relationship between the cities can still be accurately determined, avoiding misjudgments caused by minor measurement errors.
[0074] Adapting to diverse data quality scenarios: In the field of data acquisition and processing, data quality varies widely. For example, when measuring part dimensions in industrial production, different measuring tools and operators can introduce varying degrees of error. If the actual distance error (e.g., the distance between two parts' mounting locations) is less than or equal to the sum of two distance tolerances, and the actual angle error (e.g., the angle between two parts' mounting locations) is less than or equal to the sum of two angle tolerances, this approach can adapt to these data quality fluctuations. Even if the measured data exhibits some deviation, as long as it remains within the tolerance range, the production process can still proceed normally. For example, in automotive manufacturing, the mounting distance between engine and body components has certain design requirements. However, in actual production, component dimensions can vary slightly due to factors such as mold wear and machining accuracy. By setting appropriate tolerances, as long as the mounting distance is less than or equal to the sum of the tolerances, the engine and body can be mounted within an acceptable range, improving the production process's adaptability to data quality variations.
[0075] Simplify complex judgment logic: When considering distance judgment under the influence of multiple factors, this judgment method can simplify the logic. For example, in computer graphics, when judging whether two graphic elements (such as two polygons) overlap or are close enough, it is necessary to consider the position changes that may be caused by various transformation operations such as scaling, rotation, and translation of the graphics. If the judgment rule that the actual error is less than or equal to the sum of the two local tolerances is adopted, these complex situations can be handled in a relatively unified manner. There is no need to perform detailed and precise distance calculations for each transformation situation. As long as the final actual error is within the range of the sum of the tolerance values, it can be considered that the positional relationship between the graphics meets the requirements, thereby reducing the complexity of the judgment and improving the running efficiency of the program.
[0076] S105: When the actual error is less than or equal to the target tolerance, determine that the actual error between the target elements is within the tolerance range. The target tolerance is the sum of the local tolerances corresponding to two geometric elements in the target element. For example, it can be the sum of the distance tolerances corresponding to the two geometric elements, or it can be the sum of the angle tolerances corresponding to the two geometric elements. When the actual distance error is less than or equal to the sum of the distance tolerances, determine that the actual distance error between the target elements is within the distance tolerance range. When the actual angle error is less than or equal to the sum of the angle tolerances, determine that the actual angle error between the target elements is within the angle tolerance range. The tolerance range includes a distance tolerance range and an angle tolerance range.
[0077] In this embodiment, when the actual error is greater than the target tolerance, it is determined that the actual error between the target elements is not within the tolerance range. When the actual distance error is greater than the sum of the distance tolerances or the actual angle error is greater than the sum of the angle tolerances (neither condition is satisfied), it is determined that the actual error between the target elements is not within the tolerance range.
[0078] In this embodiment, the calculated actual error is compared with the sum of the local tolerances for the locations of the two geometric elements. If the actual error is less than or equal to the target tolerance, the two geometric elements (points, edges, and faces) are considered "close" within the tolerance range. If the actual error is greater than the sum of the two local tolerances, the 3D modeling software system proceeds to the next step.
[0079] This paper proposes a functional module for environmental tolerance in 3D modeling software systems. Its primary goal is to improve the accuracy and stability of 3D modeling while ensuring that the software can smoothly create and edit 3D models even in the presence of geometric tolerances. This module utilizes local tolerance algorithm technology. By analyzing the actual geometric model, a preset method is used to calculate and obtain local tolerances, and the corresponding tolerance range is set accordingly. This technology enables more accurate determination and calculation of tolerances, improving model accuracy and stability.
[0080] In an optional implementation, when the preset method is a preset calculation rule, S104 determines the local tolerance corresponding to the target element according to the preset method, specifically including:
[0081] A corresponding preset calculation rule is determined according to the geometric type corresponding to the target element, and a local tolerance corresponding to the target element is determined according to the corresponding preset calculation rule.
[0082] In this embodiment, when the target element's geometry type is a point, the local tolerance corresponding to the target element includes a distance tolerance. When the target element's geometry type is a line, plane, or volume, the local tolerance corresponding to the target element includes a distance tolerance and an angle tolerance, specifically, a distance tolerance and an angle tolerance corresponding to the first geometric element and a distance tolerance and an angle tolerance corresponding to the second geometric element.
[0083] In this embodiment, when the geometric type of the target element is a point, the corresponding preset calculation rule is a distance tolerance calculation rule determined according to the reference distance, the first proportional coefficient, and the first fixed deviation.
[0084] The reference distance can be determined based on the actual size of the target element's corresponding part and assembly requirements.
[0085] As an example, the determination of the reference distance: In a 3D model of mechanical design, the reference distance is usually determined by the actual size of the part and the assembly requirements. For example, for an assembly model of a shaft and a hole, the diameter of the shaft is 20mm and the diameter of the hole is designed to be 20.2mm. Then the reference distance can be the difference between the radius of the shaft and the hole, that is, 0.1mm, which is determined based on the actual fitting clearance requirements. In a 3D model of architectural design, the height of the room, the size of the doors and windows, etc. will affect the determination of the reference distance. If the design height of the room is 3m and the height of the window is 1.5m, then the reference distance of the upper and lower edges of the window from the upper and lower boundaries of the room can be calculated based on these dimensions. For example, the reference distance of the upper edge of the window from the top of the room is (3-1.5) / 2=0.75m.
[0086] The first proportional coefficient may be determined according to an industry standard proportionality of a part corresponding to the target element. The first proportional coefficient represents a proportional coefficient between a part corresponding to the first geometric element and a part corresponding to the second geometric element.
[0087] As an example, consider the determination of the first scaling factor: In a 3D model for automobile manufacturing, there are industry-standard ratios between tire size and vehicle body size. For example, the scaling factor between the outer diameter of a car tire and the vehicle body length might be between 0.2 and 0.25. This scaling factor is determined based on industry standards for various aspects of automotive design, such as safety and comfort. Similarly, in a 3D model for shipbuilding, the scaling factor between the length and width of a ship also has corresponding standards, determined based on the type of ship (e.g., cargo ship, passenger ship, etc.) and navigation requirements.
[0088] The first fixed deviation indicates the fixed deviation of the target element corresponding to the part when the geometry type of the target element is a point, including the fixed deviation of the first geometric element and the fixed deviation of the second geometric element.
[0089] As an example, the determination of the first fixed deviation: When 3D models produced in industrial production are used for quality control, fixed deviations may be caused by the precision limitations of the manufacturing equipment. For example, the machining accuracy of a CNC lathe is ±0.05mm. In the 3D model, the fixed deviation between the machined part size and the designed size can take this machining accuracy into account. If a cylindrical part is designed to have a diameter of 10mm, due to the influence of the lathe machining accuracy, the actual machined part diameter may be between 10±0.05mm. The ±0.05mm here is the fixed deviation of the cylindrical part. During the measurement process, the measuring tool will also introduce fixed deviations. For example, if a caliper is used to measure the size of a part, and the caliper has an accuracy of ±0.1mm, then this fixed deviation may exist between the measured size and the actual size.
[0090] When the target element's geometry type is a point, the distance tolerance determined based on the reference distance, the first scale factor, and the fixed deviation of the first geometric element can be determined as the local tolerance of the first geometric element. The distance tolerance determined based on the reference distance, the first scale factor, and the fixed deviation of the second geometric element can be determined as the local tolerance of the second geometric element. Specifically, the distance tolerance determined based on the product of the reference distance and the first scale factor and the sum of the first fixed deviation can be determined as the local tolerance corresponding to the target element.
[0091] Distance tolerance: For two points P1 and P2, their distance tolerance can be calculated as follows:
[0092] The distance tolerance of the first geometric element = base distance × first scale factor + fixed deviation of the first geometric element. The distance tolerance of the second geometric element = base distance × first scale factor + fixed deviation of the second geometric element. The distance tolerance is not a fixed value and is not the same for all points.
[0093] In this embodiment, when the geometric type of the target element is a line, the corresponding preset calculation rules include an angle tolerance calculation rule and a distance tolerance calculation rule determined according to the reference angle difference, the second proportional coefficient, and the second fixed deviation.
[0094] In this embodiment, the reference angle difference may be determined according to the maximum angle difference between the parts corresponding to the target element.
[0095] As an example, consider determining the reference angle difference: In mechanical design, for example, in a 3D model of a vehicle's steering system, the reference angle difference is determined based on the vehicle's steering performance requirements. The angular range between the vehicle's steering knuckle and wheels is a key factor in steering system design. If the vehicle's maximum steering angle is designed to be 30°, then the 30° angular difference between the steering knuckle and the wheels is the reference angle difference. This angular difference determines the steering system's range of motion and extreme positions within the 3D model, ensuring safe and flexible steering.
[0096] In this embodiment, the second proportionality factor can be determined based on the ratio of the angles at the same position between the architectural concept model and the comparative 3D model of the actual building. The architectural concept model and the comparative 3D model of the actual building are two models used in different stages of the architectural design and construction process.
[0097] Determining the Second Scale Factor: When comparing a conceptual building model with the actual building in a 3D model, the building's facade angles may be scaled to highlight specific angles. For example, if the actual building's facade has a 10° tilt, it may be scaled to 30° in the conceptual model to more clearly demonstrate the tilt. The second scale factor here is 30° / 10° = 3, which adjusts the display ratio of the angle in the model.
[0098] The second fixed deviation indicates the fixed deviation of the target element corresponding to the part when the geometry type of the target element is line, including the fixed deviation of the first geometry element and the fixed deviation of the second geometry element.
[0099] Determining the Second Fixed Deviation: In a 3D building construction model, the installation angles of prefabricated components may vary. For example, during installation, the perpendicular angle of a prefabricated wall panel to the ground may deviate due to site conditions and installation techniques. If the design calls for a wall panel to be perpendicular to the ground (90°), but the actual installation may be between 90° ± 2°, this ± 2° is the second fixed deviation.
[0100] When the geometry type of the target element is a line, the angular tolerance determined based on the base angular difference, the second scale factor, and the fixed deviation of the first geometric element can be determined as the local tolerance of the first geometric element. The angular tolerance determined based on the base angular difference, the second scale factor, and the fixed deviation of the second geometric element can be determined as the local tolerance of the second geometric element. Specifically, the angular tolerance determined based on the product of the base angular difference, the second scale factor, and the sum of the second fixed deviation can be determined as the local tolerance corresponding to the target element.
[0101] Angular tolerance: For two lines L1 and L2, the angular tolerance between them can be calculated as follows:
[0102] The angular tolerance of the first geometric element = the reference angular difference × the second proportional coefficient + the fixed deviation of the first geometric element. The angular tolerance of the second geometric element = the reference angular difference × the second proportional coefficient + the fixed deviation of the second geometric element.
[0103] In this embodiment, the distance tolerance of lines, surfaces, and volumes can refer to the above-mentioned method for determining the distance tolerance of points. Points in geometric elements, such as points on a line, are selected, and the distance tolerance determined based on the points on the line is determined as the distance tolerance of the line.
[0104] Additionally, you can determine the distance tolerance for a line in the following ways:
[0105] Based on the geometric characteristics of lines: For straight segments, the distance tolerance can be determined proportionally to their length. For example, in a 3D model of a building structure, there is a straight segment representing a steel beam with a length of 5 meters. If, based on construction accuracy requirements, the distance tolerance is set to 0.2% of the length, then the distance tolerance for this beam is 5000 mm x 0.2% = 10 mm. This means that within the 3D model, a variation in the length of this beam within a range of 5000 ± 10 mm is acceptable. For curves, such as the body contour curve in a 3D car model, distance tolerance calculation is more complex. This can be determined by analyzing the curvature of the curve. Portions with greater curvature (more curvature) may have a smaller distance tolerance to ensure curve accuracy. Portions with less curvature can have a larger distance tolerance. For example, for a curved curve with a radius of 1 meter, the distance tolerance for a specific accuracy requirement is calculated using a relevant formula to be 5 mm.
[0106] Consider the relationship between lines and other elements: In a 3D mechanical assembly model, if one line represents a drive shaft and another represents the edge of a mating belt, the distance tolerance between them must ensure transmission stability and accuracy. This distance tolerance can be determined based on the design requirements of the transmission system. For example, if the design requires a gap between the drive belt and the drive shaft to be between 1 and 3 mm, this range would be the distance tolerance. In a 3D electronic circuit board model, the distance tolerance between different lines is related to electrical performance. To prevent signal interference, the distance tolerance between adjacent lines may be determined by electrical engineers based on electromagnetic compatibility standards. For example, a minimum distance of 0.5 mm between two adjacent lines represents the distance tolerance.
[0107] The distance tolerance of the line determines whether it meets the tolerance range:
[0108] Calculating the difference between the actual and ideal values: Suppose there are two lines in a 3D model: one is a reference line representing the installation position of a mechanical part, and the other is the actual part edge line. Ideally, the distance between them is d0, and the actual distance, measured or calculated, is d. Calculate the absolute value of the difference between the two values, |d - d0|. For example, ideally, the two lines should be parallel and 20 mm apart (d0 = 20 mm), but the actual measured distance is 22 mm (d = 22 mm). Therefore, the actual distance error, |d - d0|, = |22 - 20| = 2 mm.
[0109] Comparison with the target tolerance: If the sum of the previously determined distance tolerances is Δd (for example, the distance tolerance between the two lines mentioned above is 3mm), when |d-d0| ≤ Δd, that is, 2mm ≤ 3mm, the actual distance error between the two lines is considered to meet the distance tolerance range. If |d-d0| > Δd, the distance tolerance range is not met, and adjustments to the model may be required, such as repositioning the part or modifying the design.
[0110] Judgment method when considering both angle tolerance and distance tolerance:
[0111] Calculate angle and distance errors separately: Taking a 3D robotic arm model as an example, the arm consists of multiple links connected by joints, making it a structure composed of multiple lines. During motion, not only must the joint angles (angle tolerance) be accurate, but also the distance tolerance (distance tolerance) required for the end arm to reach the target position. Assuming the ideal joint angle is θ0 and the actual angle is θ, calculate the actual angle error |θ-θ0|. Assuming the ideal distance between the end arm and the target position is d0 and the actual distance is d, calculate the actual distance error |d-d0|. For example, if the ideal joint angle is 90° and the actual angle is 92°, then |θ-θ0| = |92-90| = 2°. If the ideal distance between the end arm and the target position is 50cm and the actual distance is 52cm, then |d-d0| = |52-50| = 2cm.
[0112] Combined tolerance judgment: Given that the sum of the joint's angle tolerances is Δθ (e.g., 5°), and the distance tolerances are Δd (e.g., 3 cm), the robot arm's posture at that position is considered within the tolerance range only when |θ - θ0| ≤ Δθ and |d - d0| ≤ Δd, that is, 2° ≤ 5° and 2cm ≤ 3cm. If any of these conditions are not met, such as an actual angle error of 6°, even if the actual distance error is within the tolerance range, the overall posture still does not meet the tolerance range, and the robot's motion control parameters need to be adjusted.
[0113] In this embodiment, when the geometric type of the target element is a surface or a body, the corresponding preset calculation rules include a calculation rule based on a distance tolerance and a calculation rule based on an angle tolerance.
[0114] Tolerances for Other Geometric Properties: For other geometric element types (such as faces and volumes), tolerance calculations require a comprehensive consideration of multiple factors, employing a combination of distance and angle tolerances. For example, to determine the parallelism tolerance between two planes, multiple measurement points are selected on both planes. The distance tolerance is then used to calculate the distance from each point on each plane to the other plane. The maximum of these distances is then used as the flatness tolerance, or local tolerance when the target element's geometry type is face.
[0115] In the present invention, the technical effects brought about by selecting different local tolerance calculation rules for different geometric types are:
[0116] High adaptability: Specific preset calculation rules are set for different geometric types (points, lines, surfaces, and solids). Targeted calculation rules can meet diverse needs, whether it is the modeling of precision parts in mechanical manufacturing or the construction of large structures in architectural design, accurate tolerance calculation can be achieved.
[0117] Systematic and Complete: Calculation rules for various geometric types, including points, lines, surfaces, and solids, form a complete local tolerance calculation system. This facilitates comprehensive and systematic error management of each geometric element throughout the modeling process, preventing the quality and reliability of the entire model from being affected by inaccurate tolerance calculations for some geometric elements.
[0118] Unique technical effects of preset calculation rules for different geometry types:
[0119] Point geometry type:
[0120] Precise Positioning and Assembly Simulation: This system determines reference distances based on actual part dimensions and assembly requirements, determines the initial scale factor according to industry standard proportions, and accounts for fixed deviations introduced by manufacturing equipment and measuring tool accuracy. This allows the local tolerance calculation of points to accurately reflect the positional accuracy of parts in actual assembly. In mechanical assembly, this system accurately simulates the fit between parts like shafts and holes, proactively identifying potential assembly interference issues and reducing commissioning time and costs in actual production.
[0121] Refined quality control: Closely linking local tolerances of points with manufacturing and measurement accuracy facilitates refined quality control during the production process. By accurately controlling reference distances, scale factors, and fixed deviations, part quality can be monitored in real time, allowing for timely adjustments to production processes to ensure product compliance with design requirements.
[0122] Line geometry type:
[0123] Motion simulation and performance evaluation: The baseline angle difference is determined based on the maximum angle difference between the parts. The second proportional coefficient is determined by the angle ratio between the building concept model and the actual building 3D model. Fixed deviations such as the installation angle deviation of prefabricated components are taken into account to accurately simulate the movement and angle changes of line elements during the modeling process.
[0124] Improved architectural design accuracy: In the field of architecture, this calculation rule can accurately reflect the angular relationships of building components, ensuring that actual construction matches the design concept. For example, in the design of large curtain wall structures, precise control of the angle tolerance of lines can ensure the overall aesthetics and sealing of the curtain wall.
[0125] Surface or volume geometry type:
[0126] Precise Modeling of Complex Forms: Utilizing a comprehensive calculation method that combines distance and angle tolerances, this approach fully accounts for the position, posture, and shape errors of surfaces and volumes in space. This approach enables high-precision modeling of complex curved surfaces and irregular structures, such as aerospace vehicle hulls and the unique shapes of architectural art, accurately reflecting the geometric characteristics of the actual object.
[0127] Reasonable evaluation of spatial relationships: When calculating the local tolerance of a surface or volume, multiple factors are taken into consideration to reasonably evaluate the spatial relationships between them, such as parallelism and perpendicularity.
[0128] In the error judgment process of the entire three-dimensional model, the local tolerance calculation rules of different geometric types cooperate with each other. By jointly applying the preset calculation rules corresponding to different geometric types to calculate the local tolerance, the tolerance determination accuracy is improved.
[0129] In an optional embodiment, when the preset method is to search in a preset tolerance table, where the tolerance table includes: geometric types, application conditions, and tolerance values stored in a corresponding relationship, determining the local tolerance corresponding to the target element according to the preset method includes:
[0130] The tolerance table is searched according to the geometric type and application conditions corresponding to the target element, and the matching tolerance value found is determined as the local tolerance corresponding to the target element.
[0131] In this embodiment, a search may be performed in the tolerance table based on the geometry type and application conditions corresponding to the first geometric element, and the matching tolerance value found may be determined as the first tolerance corresponding to the first geometric element. A search may be performed in the tolerance table based on the geometry type and application conditions corresponding to the second geometric element, and the matching tolerance value found may be determined as the second tolerance corresponding to the second geometric element.
[0132] In this embodiment, the pre-set tolerance table includes multiple sets of tolerance values that are manually defined in advance, which include geometric elements (such as points, lines, and surfaces) and their tolerance values under different application conditions. The tolerance value can be a specific numerical value (0.01 mm) or a specific ratio (±0.1%).
[0133] In this embodiment, the application conditions include:
[0134] Geometric characteristics related conditions:
[0135] Size: Geometric elements of different sizes have different tolerance requirements. For example, when modeling mechanical parts, the accuracy requirements for holes in small parts and large parts are different. Small holes (e.g., diameters less than 5mm) may have a tolerance of ±0.01mm. Large holes (e.g., diameters greater than 50mm) may have a tolerance of ±0.1mm.
[0136] Shape complexity: Error control for simple geometric elements (such as standard circles and straight lines) is relatively easy, so tolerances can be set small. Complex elements (such as irregular curves and free-form surfaces) require larger tolerances due to the difficulty in manufacturing or modeling. For example, the tolerance for a simple circular outline is ±0.05mm, while the tolerance for a complex wavy curve outline might be ±0.2mm.
[0137] Curvature: For curved and surface geometric elements, different curvatures require different tolerances. Areas with large curvatures experience dramatic changes, resulting in greater error impact, and therefore require smaller tolerances. Areas with small curvatures are relatively flat, and therefore require larger tolerances. For example, when modeling the surface of a car body, the tolerance for sharp bends is set to ±0.03mm, while the tolerance for flatter areas is set to ±0.1mm.
[0138] Material properties related conditions:
[0139] Hardness and Rigidity: Materials with high hardness and rigidity offer good dimensional stability during processing or deformation, allowing for smaller tolerances. Soft materials are prone to deformation and require larger tolerances. For example, when modeling metal parts, set the tolerance to ±0.05mm. Plastic parts, susceptible to thermal expansion and contraction and deformation by external forces, require a tolerance of ±0.15mm.
[0140] Thermal Expansion Coefficient: Materials with large thermal expansion coefficients experience significant dimensional changes with temperature, so tolerances must account for thermal effects. When modeling parts used in high-temperature environments, tolerances must be calculated and set based on the temperature range and thermal expansion coefficient.
[0141] Processing related conditions:
[0142] Processing accuracy: Different processing techniques have different accuracy levels, and tolerances must be set to match these. For parts produced using high-precision processes (such as grinding), the tolerance can be set to a small value, such as ±0.005mm. For parts produced using low-precision processes (such as casting), the tolerance can be set to a large value, such as ±0.5mm.
[0143] Machining methods: Different machining methods have different effects on the accuracy of geometric elements. Parts machined with CNC machining centers have more precise tolerance control than those machined manually, and predefined tolerance tables must be set up separately.
[0144] Application scenario related conditions:
[0145] Functional requirements: Different tolerances are set for different parts. Parts used in precision instruments require high precision and tight tolerances. Parts used for general structural support can have wider tolerances. For example, the internal gears of a watch have a tolerance of ±0.002mm. The support frames of general machinery have a tolerance of ±0.5mm.
[0146] Assembly Relationships: The tolerances of geometric elements involved in assembly must take into account assembly requirements. Parts with tight fits should have narrow tolerances to ensure assembly accuracy. Parts without strict assembly requirements can have looser tolerances.
[0147] In an optional implementation, the model error determination method further includes:
[0148] When the actual error between target elements is determined to be within the tolerance range, a closeness value is returned. The closeness value indicates how close the actual value of the target elements is to the ideal value.
[0149] When the actual error between target elements is determined to be outside the tolerance range, the actual error is returned.
[0150] In this embodiment, the proximity value can be 0 or a decimal close to 0. If two geometric elements are not close enough to each other within the tolerance range, the algorithm returns the actual error between them. If they are close enough to each other within the tolerance range, a value indicating the proximity is returned. Returning both values provides comprehensive information about the relationship between the two geometric elements: when they are far apart, the actual distance and angle are provided. When they are close, a quantitative representation of the degree of proximity is provided. This helps to make more accurate logical decisions based on specific application scenarios and requirements.
[0151] In this embodiment, a value indicating the degree of proximity (when within a tolerance range) is calculated and returned.
[0152] As an example, when |d-d0|≤Δd, it indicates that the two geometric elements are close to each other within the tolerance range. In this case, you can choose an appropriate method to calculate the closeness value according to your needs.
[0153] If the normalized distance difference method is selected, according to the formula Calculation. For example, the ideal distance d0 = 50, the actual distance d = 52, and the target tolerance Δd = 5, then The returned closeness value is 0.6, which reflects how close the actual value is to the ideal value within the allowed tolerance range.
[0154] If the proportional method based on the tolerance range is used, the formula Calculation. Assuming the ideal distance d0 = 30, the actual distance d = 33, and the distance tolerance Δd = 5, then The returned proximity value of 0.8 reflects the relative position of the actual distance within the entire tolerance interval.
[0155] If we consider both angle tolerance and distance tolerance, we can take the weighted comprehensive method as an example. Assume that the angle tolerance weight w θ =0.3, distance tolerance weight w d =0.7, first calculate the angle proximity value P θ and the distance closeness value P d If the ideal joint angle is 60°, the actual angle is 62°, and the angle tolerance is 5°, then Ideal distance d0 = 40, actual distance d = 43, distance tolerance Δd = 5, The comprehensive proximity value P=0.3×0.6+0.7×0.4=0.46, and this comprehensive proximity value is returned to comprehensively reflect the degree of proximity of the angle and distance to the ideal state.
[0156] The specific application of local tolerance in the present invention is:
[0157] Compare the actual error d with the target tolerance (the sum of the two local tolerances tolA+tolB).
[0158] If d<=tolA+tolB, then point A and point B are considered close within the tolerance range.
[0159] If d>tolA+tolB, then point A and point B are considered not close within the tolerance range.
[0160] Return result:
[0161] If point A and point B are close within the tolerance range, a value indicating the degree of closeness (such as 0 or a decimal close to 0) can be returned.
[0162] If point A and point B are not close enough to within the tolerance, the actual error value d between point A and point B is returned.
[0163] Calculate and judge tolerances more accurately:
[0164] Implementation: Accurately set local tolerances by comprehensively considering factors such as geometry, material properties, processing accuracy, and application scenarios.
[0165] To set tolerance values based on geometry:
[0166] Complexity considerations: For complex geometric shapes, such as 3D models with irregular surfaces, the local tolerance value should be relatively small. For example, when designing a bionic mechanical part that simulates the skeletal structure of a living organism, there are many irregular undulations and holes on its surface. Since these details are crucial to the function and performance of the part, precise control is required when judging its proximity to other components. For areas with large changes in surface curvature, the distance tolerance may be set to 0.1mm and the angle tolerance to 0.5°. For simple geometric shapes, such as cuboids or cylinders, the tolerance value can be appropriately relaxed. For an ordinary cuboid metal block, when it is fitted with other components, the distance tolerance can be set to 0.5mm and the angle tolerance to 1°.
[0167] Differentiating critical parts: Different parts of a geometric shape have varying degrees of importance to the overall function, and therefore require varying tolerances. For example, the crankshaft of an automobile engine has a journal portion that mates with the bearings, and the dimensional accuracy of this portion directly impacts the engine's operational stability and lifespan. Therefore, the distance tolerance at the journal may be set to ±0.02mm, and the angular tolerance to ±0.1°. Meanwhile, for non-critical joints on the crankshaft, the tolerances can be larger, with distance tolerances set to ±0.1mm and angular tolerances set to ±0.5°.
[0168] To set tolerance values based on material properties:
[0169] Thermal expansion coefficient of materials: Different materials have different thermal expansion coefficients. In application scenarios with large temperature changes, this factor has a significant impact on the tolerance setting. For example, in aircraft engines, turbine blades are usually made of high-temperature alloys, which have a relatively large thermal expansion coefficient. When the engine is working, the temperature of the blades will rise sharply. In order to ensure that the blades and surrounding components can still work normally and do not collide at high temperatures, the impact of thermal expansion needs to be considered when setting tolerances at room temperature. Assuming that the ideal distance between the blade and the casing at room temperature is 2mm, considering the expansion of the material at high temperature, the distance tolerance may be set to +0.3mm (only positive expansion is allowed), and the angle tolerance is also adjusted accordingly to ensure a safe gap when the blades rotate at high temperatures. For some materials with a smaller thermal expansion coefficient, such as ceramic-based composites, the tolerance adjustment range is relatively small within the same temperature change range.
[0170] Elastic modulus of the material: The elastic modulus of the material determines the degree of deformation when subjected to force. Materials with a small elastic modulus, such as rubber, are prone to large deformation when subjected to external forces. In 3D modeling, if the fit of rubber seals and metal parts is simulated, since the rubber will be squeezed and deformed during the installation process, its elastic deformation needs to be considered when setting the tolerance. For example, when a rubber seal fits a metal groove, ideally the seal should fit tightly in the groove. Taking into account the elasticity of the rubber, the distance tolerance can be set to ±0.5mm to ensure that a good sealing effect can still be achieved after the rubber is deformed. For metal materials with a large elastic modulus, such as high-strength alloy steel, in similar fitting scenarios, the tolerance can be set more strictly, and the distance tolerance may be ±0.1mm.
[0171] Set the tolerance value based on the machining accuracy:
[0172] Precision limitations of machining processes: Different machining processes have different levels of precision. For example, traditional machining processes such as turning and milling generally have a machining accuracy of around ±0.05mm. In 3D modeling, if the final manufacturing of the model is achieved through these processes, the precision limitations of the machining process need to be considered when setting tolerances. For shaft parts that are machined by turning, the dimensional tolerance in the diameter direction can be set to ±0.05mm, and the angular tolerance can be set to ±0.2°, depending on the machining accuracy. For some high-precision machining processes, such as electrical discharge machining (EDM), the machining accuracy can reach ±0.005mm or even higher. For mold parts machined by EDM, when setting tolerances in 3D modeling, the distance tolerance can be set to ±0.01mm, and the angular tolerance to ±0.05°, to give full play to the advantages of high-precision machining technology and ensure the dimensional accuracy and fit accuracy of the parts.
[0173] Cumulative errors during machining: In the case of multiple machining operations, cumulative errors can affect the dimensional accuracy of the final product. For example, the manufacture of a complex mechanical component may require multiple processes such as turning, grinding, and drilling. Each process introduces a certain amount of machining error, and as the number of processes increases, these errors accumulate. These cumulative errors need to be considered when setting tolerances in 3D modeling. Suppose, after analysis, the cumulative errors of multiple processes may reach ±0.1mm in the distance direction and ±0.5° in the angle direction. When setting the final tolerance, it is necessary to appropriately relax the ideal tolerance to ensure that the final product meets the design requirements. For example, the original ideal distance tolerance is ±0.05mm, but after considering the cumulative error, it is set to ±0.15mm. The original angle tolerance is ±0.2°, but it is adjusted to ±0.7°.
[0174] Set the tolerance value according to the application scenario:
[0175] Requirements for motion accuracy: In some applications with high motion accuracy requirements, such as the matching of guide rails and slides in precision machine tools and the joint connections of robots, tolerance values need to be set very strictly. For the guide rails and slides of precision machine tools, to ensure high-precision positioning and smooth motion during the machine tool processing, the distance tolerance may be set to ±0.002mm, and the angle tolerance to ±0.01°. In some scenarios with relatively low motion accuracy requirements, such as the matching of chains and sprockets in ordinary industrial conveying equipment, the tolerance can be appropriately relaxed. The distance tolerance can be set to ±0.5mm, and the angle tolerance to ±1°.
[0176] Influence of environmental factors: Environmental factors of the application scenario, such as humidity and vibration, will also affect the tolerance setting. In a humid environment, metal parts are prone to rust and corrosion, resulting in dimensional changes. When simulating such scenarios in 3D modeling, if it is the cooperation of metal structural parts, considering the dimensional changes that may be caused by corrosion during long-term use, the distance tolerance can be appropriately increased, such as setting it to ±0.2mm (compared to ±0.1mm in a dry environment). For components in a vibrating environment, such as the connection between the bracket of a car engine and the engine, in order to prevent the components from loosening or colliding due to vibration, the tolerance setting needs to take the influence of vibration into account. The distance tolerance may be set to ±0.3mm and the angle tolerance to ±0.8° to provide sufficient buffer space to ensure the reliability of the components in a vibrating environment.
[0177] Effect: Improve the accuracy and reliability of the model and ensure accurate calculation and judgment of tolerances.
[0178] Returns the actual error:
[0179] Implementation: When point A and point B are not close within the tolerance range, the Euclidean distance formula is used to calculate and return the actual distance value d between them.
[0180] Effect: Provides users with information about the actual distance between point A and point B for subsequent analysis and processing.
[0181] The technical effects of the technical solution of the present invention are as follows:
[0182] Improved model accuracy: This solution goes beyond fixed global tolerances and instead customizes local tolerances for each geometric element based on its characteristics and application needs. This dynamic tolerance mechanism more accurately reflects the error distribution in actual manufacturing or measurement processes, thereby improving precision control and error assessment.
[0183] Improved modeling efficiency: The present invention utilizes a highly efficient algorithm to calculate actual error and determine proximity, while optimizing the process for determining local tolerances and reducing unnecessary computational effort. This optimization not only improves algorithm efficiency but also reduces computational costs, making the present invention more competitive in practical applications and enhancing modeling efficiency.
[0184] Optimized user interface: Provides 3D model display and editing interfaces, as well as an interface for user input of local tolerances. Design target tolerances can be displayed within the 3D model, with different colors used to indicate target tolerances that do or do not meet the tolerance range. The user interface is concise and intuitive, with simple operation processes, reducing learning costs and time, and improving the user experience. The interface design can be based on conventional system interface design methods in the field.
[0185] Enhanced compatibility: Supports import and export of multiple data formats, facilitating integration and data sharing with other software, and improving the flexibility and compatibility of the design process.
[0186] In combination with the above technical solutions, the main innovative features of the technical solutions of the present invention are as follows:
[0187] Application of local tolerance technology: Calculate and obtain tolerance data through predefined tolerance tables, user input, or automatic algorithm calculation, and set the corresponding tolerance range accordingly, thereby improving the accuracy and stability of the model.
[0188] User interface optimization: The user interface has been optimized to improve user experience and modeling efficiency.
[0189] Improved compatibility: Supports the import and export of 3D models in multiple data formats, improving the flexibility and compatibility of the design process.
[0190] The functional module of the environmental tolerance of the 3D modeling software system proposed in this invention is significantly innovative and practical. It can solve the problems existing in the existing 3D modeling software when dealing with geometric errors, improve the accuracy and stability of the model, reduce modeling costs, and improve design efficiency and quality.
[0191] It should be noted that the contents not described in detail in the specification of the present invention belong to the common knowledge of those skilled in the art.
[0192] In this embodiment, a tolerance function module is also provided. A single module is used to implement the above-mentioned embodiment and optional implementation methods. Details that have already been described will not be repeated here. As used below, the term "module" may refer to a combination of software and / or hardware that implements a predetermined function. Although the modules described in the following embodiments are preferably implemented in software, implementation using hardware, or a combination of software and hardware, is also possible and contemplated.
[0193] Figure 2 2 is a schematic structural diagram of a tolerance function module according to an embodiment of the present invention.
[0194] The present invention provides a tolerance function module, such as Figure 2 As shown, the tolerance function module includes:
[0195] The first processing unit 11 is configured to determine any two geometric elements in the three-dimensional model as target elements and determine position information of the target elements.
[0196] The second processing unit 12 is configured to determine actual errors between target elements according to position information of the target elements.
[0197] The third processing unit 13 is configured to determine a local tolerance corresponding to the target element according to a preset method.
[0198] The fourth processing unit 14 is configured to determine a target tolerance according to the local tolerance corresponding to the target element.
[0199] The fifth processing unit 15 is configured to determine whether the actual error between the target elements is within a tolerance range when the actual error is less than or equal to the target tolerance.
[0200] The preset methods include: searching in a preset tolerance table, user-defined, or determining the local tolerance corresponding to the target element according to preset calculation rules.
[0201] In an optional embodiment, the second processing unit 12 is specifically configured to determine a corresponding distance calculation method based on a geometric type of the target element, and determine the actual error between the target elements based on the corresponding distance calculation method and the position information of the target elements. The geometric type includes: point, line, surface, or volume.
[0202] In an optional embodiment, the third processing unit 13 includes a first processing sub-unit, which is used to determine the corresponding preset calculation rule according to the geometric type corresponding to the target element when the preset method is the preset calculation rule, and determine the local tolerance corresponding to the target element according to the corresponding preset calculation rule.
[0203] When the geometric type of the target element is a point, the corresponding preset calculation rule is a distance tolerance calculation rule determined according to the reference distance, the first proportional coefficient, and the first fixed deviation.
[0204] When the geometry type of the target element is a line, the corresponding preset calculation rules include an angle tolerance calculation rule and a distance tolerance calculation rule determined according to the reference angle difference, the second proportional coefficient, and the second fixed deviation.
[0205] When the geometry type of the target element is a surface or a body, the corresponding preset calculation rules include a calculation rule based on a distance tolerance and a calculation rule based on an angle tolerance.
[0206] In an optional embodiment, the third processing unit 13 also includes a second processing sub-unit, which is used to search in a pre-set tolerance table in a preset manner, where the tolerance table includes: geometric types, application conditions and tolerance values stored in a corresponding relationship, and search in the tolerance table according to the geometric types and application conditions corresponding to the target element, and determine the matching tolerance value found as the local tolerance corresponding to the target element.
[0207] In an optional implementation, the fourth processing unit 14 is specifically configured to determine the target tolerance according to the sum of the local tolerances corresponding to the target elements.
[0208] In an optional implementation, the tolerance function module further includes: a sixth processing unit, configured to determine that the actual error between the target elements is not within the tolerance range when the actual error is greater than the target tolerance.
[0209] In an optional embodiment, the tolerance function module further includes: a seventh processing unit configured to return a proximity value when determining that the actual error between the target elements is within the tolerance range. The proximity value represents the degree of proximity between the actual value and the ideal value of the target elements.
[0210] When the actual error between target elements is determined to be outside the tolerance range, the actual error is returned.
[0211] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.
[0212] The tolerance functional module in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.
[0213] The embodiment of the present invention also provides a computer device having the above Figure 2 Tolerance function block shown.
[0214] See also Figure 3 , Figure 3 Schematic diagram of the hardware structure of the computer device according to the embodiment of the present invention. Figure 3As shown, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components utilize different buses to communicate with each other and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In an optional embodiment, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Equally, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor device). Figure 3 A processor 10 is taken as an example.
[0215] The processor 10 may be a central processing unit, a network processor, or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be an application-specific integrated circuit, a programmable logic device, or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic, or any combination thereof.
[0216] The memory 20 stores instructions that can be executed by at least one processor 10, so as to enable at least one processor 10 to execute the method shown in the above embodiment.
[0217] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating device, an application required for at least one function. The data storage area may store data created according to the use of the computer device, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In an optional embodiment, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0218] The memory 20 may include volatile memory, such as random access memory. The memory may also include non-volatile memory, such as flash memory, a hard disk, or a solid-state drive. The memory 20 may also include a combination of the above types of memory.
[0219] The computer device further includes a communication interface 30 for the computer device to communicate with other devices or a communication network.
[0220] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or implemented as a computer code that can be recorded in a storage medium, or downloaded through a network and originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state drive, etc. Further, the storage medium can also include a combination of the above-mentioned types of memory. It can be understood that a computer, a processor, a microprocessor controller or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor or hardware, the method shown in the above embodiment is implemented.
[0221] A portion of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the form in which the computer program instruction exists in a computer-readable medium includes, but is not limited to, a source file, an executable file, an installation package file, etc. Accordingly, the way in which the computer program instruction is executed by the computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium may be any available computer-readable storage medium or communication medium that can be accessed by the computer.
[0222] Although the embodiments of the present invention have been described with reference to the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention. Such modifications and variations are all within the scope defined by the appended claims.
Claims
1. A model error judgment method, applied to the tolerance function module in the modeling software system, characterized in that: include: Determine any two geometric elements in the three-dimensional model as target elements, and determine position information of the target elements; determining actual errors between target elements according to position information of the target elements; Determine the local tolerance corresponding to the target element according to a preset method; Determining a target tolerance according to the local tolerance corresponding to the target element; When the actual error is less than or equal to the target tolerance, determining that the actual error between the target elements is within the tolerance range; The preset manner includes: searching in a preset tolerance table, user-defined, or determining the local tolerance corresponding to the target element according to a preset calculation rule.
2. The method according to claim 1, characterized in that The determining the actual error between the target elements according to the position information of the target elements includes: A corresponding distance calculation method is determined according to the geometric type of the target element, and based on the corresponding distance calculation method, the actual error between the target elements is determined according to the position information of the target elements; wherein the geometric type includes: point, line, surface or body.
3. The method according to claim 2, characterized in that When the preset manner is the preset calculation rule, determining the local tolerance corresponding to the target element according to the preset manner includes: Determine a corresponding preset calculation rule according to the geometric type corresponding to the target element, and determine a local tolerance corresponding to the target element according to the corresponding preset calculation rule; Wherein, when the geometric type of the target element is a point, the corresponding preset calculation rule is a calculation rule of a distance tolerance determined according to a reference distance, a first proportional coefficient, and a first fixed deviation; When the geometric type of the target element is a line, the corresponding preset calculation rules include a calculation rule for an angle tolerance and a calculation rule for a distance tolerance determined according to the reference angle difference, the second proportional coefficient, and the second fixed deviation; When the geometric type of the target element is a surface or a body, the corresponding preset calculation rules include a calculation rule based on a distance tolerance and a calculation rule based on an angle tolerance.
4. The method according to claim 2, characterized in that When the preset method is to search in a preset tolerance table, and the tolerance table includes: geometric types, application conditions, and tolerance values stored in a corresponding relationship, determining the local tolerance corresponding to the target element according to the preset method includes: The tolerance table is searched according to the geometric type and application conditions corresponding to the target element, and the matching tolerance value found is determined as the local tolerance corresponding to the target element.
5. The method according to claim 1, wherein The determining the target tolerance according to the local tolerance corresponding to the target element includes: The target tolerance is determined according to the sum of the local tolerances corresponding to the target elements.
6. The method according to claim 1, characterized in that The method further comprises: When the actual error is greater than the target tolerance, it is determined that the actual error between the target elements is not within the tolerance range.
7. The method according to claim 6, characterized in that The method further comprises: When it is determined that the actual error between the target elements is within the tolerance range, a closeness value is returned; the closeness value represents the closeness between the actual value and the ideal value of the target elements; When it is determined that the actual error between the target elements is not within the tolerance range, the actual error is returned.
8. A tolerance function module, characterized in that: include: A first processing unit is configured to determine any two geometric elements in the three-dimensional model as target elements and determine position information of the target elements; a second processing unit, configured to determine actual errors between target elements based on position information of the target elements; A third processing unit, configured to determine a local tolerance corresponding to the target element according to a preset method; a fourth processing unit, configured to determine a target tolerance according to the local tolerance corresponding to the target element; a fifth processing unit, configured to determine that the actual error between the target elements is within a tolerance range when the actual error is less than or equal to the target tolerance; The preset manner includes: searching in a preset tolerance table, user-defined, or determining the local tolerance corresponding to the target element according to a preset calculation rule.
9. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the model error judgment method according to any one of claims 1 to 7 by executing the computer instructions.
10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the model error judgment method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Variable-tolerance entity model representation method
CN114943104A
Error elimination method and device of model component, electronic equipment and storage medium
CN115239520A