A method for reconstructing and generating G1 continuity curved surface based on boundary constraint

CN122634952BActive Publication Date: 2026-10-13HUAZHONG UNIV OF SCI & TECH +1
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202611132768.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-07-29
Publication Date
2026-10-13
Estimated Expiration
2046-07-29

AI Technical Summary

Technical Problem

[0007](2)引入跨界导数场正交投影约束实现切平面共面:针对三维空间中跨界切矢因缺乏法向约束而易发生的法向偏移问题,建立几何约束机制

Benefits of technology

[0037]本发明从跨界导数的数值大小、空间方向及扭矢相容性三个维度重构了Coons曲面的生成逻辑,带来了以下显著的有益效果:

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122634952B_ABST
    Figure CN122634952B_ABST
Patent Text Reader

Abstract

The application discloses a G1 continuity curved surface reconstruction and generation method based on boundary constraint, and belongs to the technical field of computer aided design and computer graphics technology. Step 1: taking a three-dimensional industrial model to be repaired as input, a unified normalized parameter mapping is established to obtain a standard boundary data set; step 2: taking the standard boundary data set as input, a basic cross-border tangent vector field is obtained; step 3: taking the basic cross-border tangent vector field as input, an original modified cross-border tangent vector field is obtained; step 4: taking the original modified cross-border tangent vector field as input, a tangent plane geometric constraint mechanism is established, and a final cross-border tangent vector field is obtained; step 5: taking the final cross-border tangent vector field as input, a rational harmonic formula is introduced, and four corner point torsion vectors after rational harmonic are obtained; step 6: a high-order B-spline geometric entity satisfying an industrial tolerance is generated through a reverse approximation algorithm, and a B-spline curved surface is obtained. The application can automatically generate a high-quality transition curved surface without high-light tearing under complex and disordered boundary constraints.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the fields of computer-aided design (CAD) and computer graphics technology, and relates to a method for reconstructing and generating G1 continuous surfaces based on boundary constraints. Specifically, it relates to a method for reconstructing and generating G1 continuous Coons surfaces based on tangent plane projection constraints and rational harmonic reconciliation of incompatible torsional vectors. This invention can be widely applied to scenarios with strict requirements for surface splicing continuity and topological integrity, such as the repair of Class A surfaces on automotive bodies and the seamless splicing and surface repair of high-end mold surfaces. Background Technology

[0002] In the fields of digital design and high-end manufacturing of modern industrial products, the surface quality of a 3D model directly determines the product's aerodynamic performance, aesthetic appearance, and the feasibility of subsequent CNC machining. In the modeling of complex products (such as automotive body panels and aircraft skins), it is often necessary to stitch together multiple surface patches with different curvatures and parametric features. To achieve a smooth transition both visually and physically, engineering requirements stipulate that the stitched surfaces must meet at least a G1 (tangential continuity) or even higher continuity standard.

[0003] In surface generation algorithms based on polygonal boundary constraints, Coons surfaces (especially second-type Coons surfaces) have become a core mathematical tool for surface patching and reconstruction due to their ability to accurately interpolate boundary positions and cross-boundary derivatives. However, in practical four-boundary topological surface construction scenarios (such as repairing complex spatial holes), the four boundaries of the hole are often extracted from independent adjacent parent surfaces with different parameterizations, mathematical definitions, and geometric qualities. This severe mismatch in parameterization space means that forcibly substituting the original parameters will not only cause severe stretching and distortion of the internal isoparametric lines of the newly generated surface, but also make it difficult to stitch together higher-order continuity at the intersection of multiple surfaces due to scale distortion of cross-boundary derivatives in different parameter domains.

[0004] To address the aforementioned issues, Chinese invention patent CN121302533A proposes an automatic hole repair method based on Coons surfaces. This method analyzes the initial 3D vehicle body model, calculates the normal partial derivative vector of each boundary edge based on the hole boundary information, and generates a corresponding Coons surface based on the boundary position and normal partial derivative information to fill and repair the holes, thereby achieving batch automatic detection and surface repair of topological defects in vehicle body holes. However, this patent primarily focuses on the automated hole detection and batch filling process in CFD preprocessing scenarios. Its calculation of cross-boundary derivatives still relies on the scalar scaling of the traditional chain rule in parameter space, failing to consider the continuous transition of the physical arc length of the hole's two sides in real 3D space. Chinese invention patent CN117788771A proposes a method for filling NURBS surfaces with line constraints for N-sided holes. This method generates a center point and its normal based on a given boundary curve and cross-boundary guide vector. It then optimizes the center point using a given constraint curve and finally optimizes the control vertices using a least-squares asymptotic iterative approximation method, ensuring that the generated filled surface satisfies the given geometric continuity conditions both internally and at the boundary. However, this patent still uses the traditional Coons surface filling framework for surface continuity processing. The generation of its cross-boundary guide vector relies solely on local information from the endpoints of the boundary curve, lacking a normal constraint mechanism based on the geometry of the original supporting surface's tangent plane, making it difficult to strictly satisfy the G1 continuity condition.

[0005] In summary, current technologies have not yet solved the three core challenges in the process of patching complex surfaces: cross-boundary tangent physical scale distortion, normal deviation, and corner torsion vector incompatibility caused by parameter space mismatch. Therefore, there is an urgent need for a novel surface reconstruction and generation technology that, starting from geometric tangent plane mapping, high-precision numerical calculation, and rational harmonic reconciliation of torsion vectors, systematically solves the problems of torsion vector conflict and normal deviation in the process of repairing complex surfaces, and achieves truly meaningful G1 continuous high-quality surface reconstruction and generation. Summary of the Invention

[0006] To address the problems existing in the prior art, this invention provides a method for reconstructing and generating G1 continuous surfaces based on boundary constraints. This method reconstructs the cross-boundary tangent vector magnitude through physical arc length interpolation and Hermite basis function compensation, achieves coplanar boundary normals by introducing orthogonal projection constraints on the tangent plane of the cross-boundary tangent vector field, and harmonizes incompatible torsional vectors at corners using numerical difference and Gregory's rational formula. Specifically, it reconstructs the derivative magnitude through physical arc length interpolation, corrects the tangent vector direction through tangent plane projection constraints on the cross-boundary derivative field, and harmonizes incompatible torsional vectors using numerical difference and Gregory's rational formula. This enables the automatic generation of high-quality, specular-free transition surfaces (Coons surfaces of the second kind) even under complex and disordered boundary constraints. The specific objectives are as follows: (1) Constructing a cross-boundary derivative field based on physical arc length interpolation and Hermite compensation: Introducing a linear transition and mapping of the numerical magnitude of the cross-boundary tangent vector to the actual physical arc length. For the physical position error caused by boundary matching, cubic Hermite basis functions are used for global assignment; taking advantage of the mathematical property that the first derivative at the endpoints is zero, the endpoint error is eliminated while avoiding the introduction of new errors in the higher-order derivative information at the endpoints, thus avoiding the pollution of the original derivative field by error compensation.

[0007] (2) Introducing orthogonal projection constraints of cross-boundary derivative field to achieve coplanarity of tangent planes: To address the problem of normal offset that easily occurs in cross-boundary tangent vectors in three-dimensional space due to the lack of normal constraints, a geometric constraint mechanism is established. By extracting the true surface normal of the original support surface, the reconstructed cross-boundary derivative field is forced to be orthogonalized by projection, ensuring that the generated cross-boundary tangent vectors are absolutely attached to the tangent plane of the original support surface.

[0008] (3) Solving torsional vector conflict by combining numerical difference and Gregory rational fraction: Perform high-precision small-step numerical difference on the constructed boundary tangent plane projection function to obtain the torsional vector under the new parameterization. By introducing Gregory rational formula, the parameter distance from the calculation point to the adjacent boundary is used as a dynamic weight to smoothly transition the incompatible torsional vector, solve the second derivative singularity at the corner point, and eliminate the light and shadow tearing in the diagonal region.

[0009] To achieve the above-mentioned objectives, the technical solution adopted by this invention is as follows: A method for reconstructing and generating G1 continuous surfaces based on boundary constraints, the method comprising the following steps: Step 1: Using the 3D industrial model to be repaired as input, the goal is to extract the four boundary curves of the holes and establish a unified normalized parameter mapping through topological loop reconstruction and equal arc length discrete sampling to obtain a standard boundary dataset. Specifically: The 3D industrial model to be repaired is composed of four original support surfaces with distinct parametric definitions. These original support surfaces are existing surface patches around the hole to be repaired, each with its own independent parametric definition and geometry; they are the geometric source for extracting the boundary curves. Ideally, the four adjacent original support surfaces can be spatially distributed as a bottom, right, top, and left surface, collectively enclosing a quadrilateral void region not yet covered by the surface; this quadrilateral void region is called the hole. Each original support surface... Each has its own independent parametric domain and geometry, and each contributes an isoparametric line adjacent to the hole. The isoparametric line refers to a line on the original support surface with a fixed parameter (such as...). The curve obtained It is a direct geometric method for extracting boundary curves from the original support surface. The boundary curve refers to the spatial curve that forms one side of the quadrilateral contour of the hole, which is directly extracted from the isoparametric line at the intersection of the original support surface and the hole.

[0010] Step 1.1: Analyze the model to be repaired and extract the boundary curves; The 3D industrial model to be repaired is read, and four original support surfaces surrounding the hole are obtained for the area to be repaired. Boundary constraints are set, and corresponding isoparametric lines are extracted from each original support surface as the initial boundary curves of the hole. This results in a set of four discrete spatial curves with independent local parameter domains, as shown in the following formula: (1) Among them, the definition Let be the position vector of the i-th boundary curve in three-dimensional space, where , For the first i The original physical parameters of the boundary curve on its original supporting surface, i.e., the original supporting surface. In the parameter field u coordinates or v The coordinates depend on whether the boundary curve on the surface is a constant u-curve or a constant v-curve.

[0011] Simultaneously, extract the starting coordinates of each boundary curve in three-dimensional space. coordinates of the endpoint Where P represents a physical coordinate point in three-dimensional space, and the superscripts 0 and 1 correspond to the start and end points of the boundary curve, respectively. The original physical parameters... Starting from point 1, the original physical parameters The endpoint is at this point.

[0012] Step 1.2: Greedy evaluation of topological distance and forced loop reassembly; Due to micro-tolerances present during model format conversion, the endpoints of the four extracted boundary curves may not perfectly coincide in 3D space. To prevent these minute gaps from causing subsequent Boolean sum operations to fail, a forced topological loop closure operation is performed. First, a greedy algorithm is used to calculate the spatial Euclidean distance between the endpoints of each boundary curve sequentially. The curve segments with the closest spatial Euclidean distance are then concatenated in order, thus defining four logical roles: bottom, right, top, and left. Taking the bottom as an example, the starting coordinates in 3D space... coordinates of the endpoint middle Let B represent belonging to the bottom edge, and then use the coordinates of the starting point of the bottom edge. and endpoint coordinates As an absolute benchmark, evaluate the directions of the remaining boundary curves separately: if a point on the left boundary is perpendicular to the starting point of the bottom edge... The distance is greater than its distance from the end point of the bottom edge. If the distance is such that the boundary direction is reversed, a reversal mark is recorded; similarly, the right and top boundaries are evaluated and corrected sequentially, thus transforming the disordered boundary curves into a closed directed quadrilateral loop in the topological structure. Finally, the recombined boundary curves are obtained.

[0013] Step 1.3: Establish the mapping between equal arc length sampling and normalized parameters; To eliminate the inconsistency between parameter step size and physical arc length caused by different parameterization definitions in the original boundary curves, an equal arc length mapping model from normalized parameters to original physical parameters is established for each reconstructed boundary curve in step 1.2. Taking any reconstructed boundary curve... An explanation is provided, in which s is the normalized parameter after normalization. .

[0014] Set the number of discrete sampling points to N To ensure that the actual physical arc lengths between two adjacent nodes are equal, a series of original physical parameters for each node are calculated. It satisfies the following integral equation of arc length: (2) in, For the first i The tangent derivative vector of the recombined boundary curve; Represents the Euclidean norm in three-dimensional space; For integration variables; is the index of the discrete node. For the first One original physical parameter node, For the first One original physical parameter node.

[0015] For normalized parameters Perform uniform discretization to obtain normalized parameter sampling points. Thus, a discrete mapping lookup table is established. Each normalized parameter sampling point The original physical parameters obtained by sampling with equal arc length One-to-one correspondence. For any given normalization parameter... First, based on the reversal marker recorded in step 1.2, set the valid parameters. The definition is as follows: when the boundary is marked as inverted, the normalization parameter is mirrored, i.e. ;otherwise Then locate in the discrete mapping lookup table. The discrete interval The corresponding original physical parameters are solved by linear interpolation, as shown in formula (3): (3) Step 1.3 outputs a set of standard boundary datasets that are closed loops in the topology and have equal physical arc lengths in the parameter domain. Each normalized boundary curve All use the normalized parameter s as the independent variable.

[0016] Step 2: Using the standard boundary dataset output from Step 1 as input, address the physical scale distortion problem caused by parameter mismatch in different parameter domains of the cross-boundary tangent vector. This is achieved by extracting the basic cross-boundary derivative direction, calculating the true physical arc length of adjacent boundaries, linearly interpolating the derivative magnitude, and constructing the basic cross-boundary tangent vector field. The cross-boundary tangent vector refers to the first-order partial derivative vector pointing from the boundary curve towards the interior of the hole. It describes the geometric rate of change of the surface along the direction inside the hole at the boundary and is a key physical quantity controlling the continuity of adjacent surfaces at the splicing boundary. Step 2 assigns a geometrically compatible magnitude to the cross-boundary tangent vector on the current boundary curve by extracting the true three-dimensional physical span of the adjacent boundary curves. Specifically: Step 2.1, extract the fundamental cross-boundary derivative directions; For any normalized boundary curve output in step 1 For the normalized parameters on the boundary curve s First, the corresponding original physical parameters are calculated using the discrete mapping lookup table in step 1.3. Then, the corresponding original support surface... Seeking s The original first-order partial derivative vector along the cross-boundary direction, that is, the direction from the current boundary to the inside of the hole. or To remove the interference of the original support surface parameterization on the vector magnitude, the partial derivative vector is... or Perform a normalization operation, retaining only the cross-boundary unit direction vector, as shown in the following formula: (4) Among them, for The cross-boundary unit direction vector at the location, For the current boundary curve on the original support surface The upper edge is fixed To the isoparametric parameter values, For the fixed boundary along the current boundary To the isoparametric parameter values, For the original supporting surface at point along First-order partial derivative vector of direction, Let Euclidean modulus operator be a vector.

[0017] Based on the reversal markers recorded in step 1.2, an orientation correction factor is introduced. To ensure that the cross-boundary unit direction vectors all point to the inside of the hole, a reference direction vector is obtained. .

[0018] Step 2.2, calculate the actual physical arc length of adjacent boundaries; Extract the two endpoints of the current boundary. and Two adjacent normalized boundary curves and ,in, Calculate the lengths of their adjacent physical boundaries in three-dimensional space, including and ,in Corresponding to the adjacent boundary length on the starting side, This corresponds to the length of the adjacent boundary on the endpoint side. The physical length of the adjacent boundary is obtained by the spatial Euclidean distance between its endpoints: (5) in, These are the three-dimensional physical coordinates of the endpoints of the two boundary curves adjacent to the current boundary start and end points, respectively. The superscripts 0 and 1 also correspond to the start and end points of each adjacent boundary curve, respectively.

[0019] Step 2.3, linear interpolation of derivative modulus and construction of basic cross-boundary tangent vector; Using the adjacent physical boundary lengths extracted in step 2.2, a linear interpolation equation for the derivative modulus is established in the normalized parameter domain to calculate the current boundary parameter points. s The ideal physical modulus scalar function that should be present at the given location: (6) The reference direction vector from step 2.1 With physical modulus scalar By performing scalar multiplication and combination, a fundamental cross-boundary tangent vector function with physical scale compatibility is constructed: (7) The final output yields the basic cross-boundary tangent field. .

[0020] Step 3: Using the fundamental cross-boundary tangent field constructed in Step 2 as input, accurately bridge the direction and magnitude deviations between the fundamental cross-boundary tangent field at its endpoints and the adjacent real boundary physical tangents, achieving a smooth transition across the entire domain; employing cubic Hermite interpolation basis functions, while compensating for first-order derivative errors, utilizes the mathematical property that the first-order derivative is zero at the endpoints of the basis functions to avoid introducing additional error terms in higher-order derivatives, ultimately obtaining the original corrected cross-boundary tangent field. Specifically: Step 3.1: Calculate the absolute error of the first-order cross-boundary tangent vector at the corner points; although a basic cross-boundary tangent vector field with physically compatible modulus has been constructed in Step 2, since the basic cross-boundary tangent vector field is obtained by linear interpolation of the opposite side constraints, its error at the two endpoints of the boundary is as follows. and The initial direction at a given point may not perfectly coincide with the actual tangential direction of the adjacent physical boundaries. Therefore, we first extract the physical tangential vectors at the endpoints of the adjacent boundary curves intersecting the current boundary, and then, combining this with the lengths of the two corresponding adjacent physical boundaries, calculate the target cross-boundary tangential vector at the corner point, denoted as the initial target vector. With the termination target vector Then extract the limit values ​​of the basic cross-boundary tangent vector function from step 2.3 at both endpoints. and and respectively compared with the initial target vector Termination target vector Perform vector subtraction to calculate the absolute error vector of the first-order cross-boundary tangent vector at the corner point, as shown in the following formula: (8) (9) in, The starting point of the current boundary curve The starting error vector at that point, The endpoint of the current boundary curve The endpoint error vector at that point.

[0021] Step 3.2: Perform global error allocation using Hermite basis functions; this will concentrate the starting error vector at the corner points. and endpoint error vector Smoothly and uniformly distribute the normalized parameter domain to the current boundary. Internally, a cubic Hermite interpolation basis function is introduced for global weighted allocation. Two basis functions are selected. and The influence weights corresponding to the start and end point errors are defined as follows: (10) (11) in, The starting error vector The weight allocation function, Endpoint error vector The weight allocation function.

[0022] The basis functions shown in formulas (10) and (11) have , , , The endpoint interpolation property of , and its first derivative is zero at both endpoints, i.e. This property ensures that the error compensation term will not produce additional first-order derivative changes at the endpoints.

[0023] In this step, the Hermite basis functions are a set of cubic polynomials that satisfy the interpolation conditions of endpoint function values ​​and first-order derivative values, and can smoothly distribute the error of the endpoint function values ​​or derivative values ​​over the entire domain.

[0024] Step 3.3: Synthesize the corrected cross-boundary derivative field; Based on the weighted superposition principle, correct the basic cross-boundary tangent field by combining the error vector with the basis functions and superimposing them onto the basic cross-boundary tangent field. The synthesized original corrected cross-boundary tangent field is as follows: (12) in, To obtain the original corrected cross-boundary tangent field, the cross-boundary tangent error at the corner points was compensated.

[0025] More importantly, due to the basis functions and The first derivative of is equal to zero at both endpoints, and subsequent steps... When performing differential calculations again to obtain the second-order mixed partial derivatives, the differential term of the error compensation term will automatically return to zero, thereby avoiding the introduction of additional errors in the corner-point second-order mixed partial derivatives.

[0026] Step 4: Using the original modified cross-boundary tangent vector field generated in Step 3 as input, establish a tangent plane geometric constraint mechanism. The tangent plane in this invention refers to the tangent plane at a given point on the surface, extending along... direction and Two first-order partial derivative vectors in the direction and The spanned two-dimensional plane is the local linear approximation space of the surface at a given point. To address the potential deviation of the original corrected cross-boundary tangent vector from the original supporting surface's normal vector in three-dimensional space due to linear interpolation and error compensation, the true surface normal of the original supporting surface is extracted and orthogonal projection constraints are applied to ensure that the final output cross-boundary tangent vector strictly adheres to the tangent plane of the original supporting surface, thus obtaining the final cross-boundary tangent vector field. Specifically: Step 4.1: Extract the true surface normal of the original support surface; sample any normalized parameter points on the boundary curve. First, the corresponding original physical parameters are calculated by back-calculating in step 1.3. Then determine the corresponding isoparametric coordinates. On the original support surface The first-order partial derivatives are evaluated on the surface to obtain the values ​​along the surface. u partial derivative vector of direction Along v partial derivative vector of direction To obtain the sampling points for the normalized parameters. Surface unit normal vector at the location We perform a cross product operation on these two partial derivative vectors and normalize the result. The specific formula is as follows: (13) Step 4.2: Perform Gram-Schmidt orthogonalization projection; Extract the original corrected cross-boundary tangent field vector generated in step 3 based on Hermite error assignment. Since the original modified cross-boundary tangent vector is a vector synthesized through spatial algebraic superposition, it contains a normal deviation component that deviates from the tangent plane of the original supporting surface. To completely eliminate this component, a projection operation based on the Schmidt orthogonalization principle is performed. First, the original modified cross-boundary tangent vector is calculated. normal vector on the real surface The dot product on the plane is used to obtain the normal projection scalar that deviates from the tangent plane, and the normal projection scalar is multiplied by the unit normal vector to form the normal deviation component. Subtract from the middle. This yields the final transboundary tangent field attached to the true tangent plane. As shown in the following formula: (14) Step 4.3: Output the final cross-boundary tangent vector that satisfies the condition of coplanarity of the tangent planes. ; By applying the tangent plane projection constraint, the output of step 4.2 is... Strictly confined within the local tangent space of the original supporting surface, the normal vectors of adjacent surfaces at their boundaries are ensured to achieve consistency, resulting in the final cross-boundary tangent vector field. This ensures that the reconstructed surfaces satisfy the collinearity condition of normal vectors required for G1 continuity at their boundaries, providing data support for the construction of subsequent higher-order continuous surfaces.

[0027] Step 5: The final cross-boundary tangent vector field that satisfies the tangent plane projection constraint constructed in Step 4. As input, the true torsional vectors at each boundary point are obtained by performing a minimum step-size numerical difference on the projection function. Gregory's rational harmonic formula is then introduced to address the incompatibility of the second-order mixed partial derivatives derived from different boundaries at the four corner points. Finally, the torsional vectors at the four corner points are obtained after rational harmonic harmonic treatment. Specifically: Step 5.1: Obtain the corner point torsion vector using the minimum step size numerical difference method; The final transboundary tangent vector field output from step 4 that satisfies the tangent plane projection constraint. Using a very small step size Perform numerical differentiation. This is illustrated using any boundary curve, starting from the... and the finish line At this point, using forward and backward difference algorithms, an accurate approximation is achieved. The true spatial rate of change along the direction of parameter variation. The formula for calculating the numerical difference between the start and end points is as follows: (15) (16) in, Starting point Forward difference torsion vector at the location, End point Backward differential torsion vector at the location, For the final crossover, Kiriyaba, The minimum numerical difference step size. The final cross-boundary cutting arrow at the starting point, Step size from the starting point The final cross-border cutting arrow at the location, Step length from the endpoint The final cross-border cutting arrow at the location, The final cross-boundary cutting arrow at the endpoint.

[0028] Traverse the standard boundary dataset output in step 1, and repeat the difference operations shown in formulas (15) and (16) for each boundary curve to obtain the distance along the boundary curve at each of the four corner points of the hole. direction and along Discrete torsion vectors with independent orientation approximation. Each corner point corresponds to two torsion vector values: one from... Towards the boundary, denoted as Another one from Towards the boundary, denoted as ,in , representing the corner point at and The index in the direction. Since the two boundaries intersecting at the corner are extracted from original support surfaces with different parameterizations and independent internal node vectors, an incompatibility of second-order mixed partial derivatives inevitably occurs here, i.e. .

[0029] Step 5.2, establish Gregory's rational harmonic formula; Introducing parameters independent of the original support surface Coons surface normalization parameters ,in and These are the normalized coordinates of the Coons surface in the two parametric directions, with values ​​ranging from 0 to 1. At the point of operation During parameterized evaluation, to handle incompatible torsional vectors at corner points, the Gregory rational harmonic operator is introduced. The current evaluation point is set. To the near The parametric Euclidean distance to the boundary is ,in ,Pick At the same time, set the current evaluation point. To the near The parametric Euclidean distance to the boundary is ,Pick Using the Euclidean distance between the two parameters as the inverse proportional weighting factor for rational interpolation, the following dynamic harmonic equation is established: (17) in, For the corner point by Torsional vector obtained by boundary difference , For the same corner point, by Torsional vector obtained by boundary difference .when When (i.e., located at the corner point itself), take the arithmetic mean of the two. To avoid division by zero.

[0030] Step 5.3, Global smooth transition of corner incompatible torsion vectors; In the Gregory rational harmonic formula in step 5.2, when the evaluation point inside the surface moves towards... As it gradually approaches the boundary, that is... The weight distribution automatically exhibits a nonlinear tilt, causing the mixed torsion vector to... Smoothly converges to the corresponding Difference torsion vectors towards the boundary Similarly, towards When the boundary approaches, it converges to This achieves a continuous transition of the second derivative field, eliminating surface wrinkles and specular tearing caused by torsional vector discontinuity in the diagonal region, and finally yielding the torsional vector at the four corner points after rational harmonic reconciliation. ,in, Corner point The final twisting arrow at the location, Corner point The final twisting arrow at the location, Corner point The final twisting arrow at the location, Corner point The final twisted arrow at the location.

[0031] This step overcomes the problem that traditional analytical torsion vectors are difficult to calculate directly after undergoing nonlinear mapping and tangent space projection.

[0032] Step 6: Utilize the outputs of steps 1 to 5, namely the standard boundary dataset from step 1 and the final cross-boundary tangent field from step 4. The rationally harmonic torsion vector from step 5 is used to construct a high-density spatial evaluation lattice in the normalized parameter domain. Based on the second type of Coons surface Boolean sum principle, the 3D coordinate point cloud filling the holes is calculated. Then, a high-order B-spline geometric entity satisfying industrial tolerances is generated through an inverse approximation algorithm, resulting in the final B-spline surface. Specifically: Step 6.1, High-density evaluation lattice construction and Hermite basis function preparation; exist A high-density discrete resolution is set internally to construct a spatial evaluation point matrix. This is applied to arbitrary parameter coordinates within the grid. We introduce a Hermite interpolation basis function set consisting of four cubic polynomials, where the position basis functions are the same as those in formulas (10) and (11), and the tangent basis function is denoted as... Its expression is defined as: (18) (19) in, The tangent basis function at the starting point, i.e., acting on the starting point. The weight function of the tangent vector; The endpoint tangent basis function, i.e., acting on the endpoint. Weight function of the tangent vector at the starting point. Basis function of the tangent vector at the starting point. and endpoint tangent basis functions have The endpoint tangent interpolation characteristics.

[0033] Step 6.2, Boolean sum operation for the second type of Coons surface; based on the analytical definition of the Boolean sum for the second type of Coons surface, construct three independent three-dimensional vector field components respectively. Specifically: Step 6.2.1, firstly, the first lofted ruled surface component. The construction equation is as follows: (20) in, and respectively along The position vectors of the two boundary curves of the directional distribution and The outputs of step 4 are respectively Towards the final crossover of the field and The value at; To act on The basis function for the starting position of the side boundary position vector. To act on The basis function for the endpoint position of the side boundary position vector. To act on The starting tangent basis function of the lateral cross-boundary tangent vector. To act on The endpoint tangent basis functions of the lateral cross-boundary tangent vector are expressed by formulas (9), (10), (17), and (18), respectively.

[0034] Step 6.2.2, Second Lofting Ruled Surface Component The construction equation is as follows: (twenty one) in, and respectively along The position vectors of the two boundary curves of the directional distribution and The outputs of step 4 are respectively Towards the final crossover of the field and The value at that location.

[0035] Step 6.2.3: Again, to eliminate the overlap and redundancy of the first lofted ruled surface component and the second lofted ruled surface component at the corners and boundaries of the surface, a corner correction surface component is constructed. Its equation is expressed as follows: (twenty two) in, The position vectors of the four corner points, and They are the corner points along direction and The first-order tangent vector at the endpoint of the direction.

[0036] Step 6.2.4: Finally, based on the Boolean sum definition of the second type of Coons surface, the parameter node is calculated through vector algebra superposition operations. Physical coordinates in three-dimensional space: (twenty three) Step 6.3, B-spline inverse fitting; Traverse the entire normalized parameter domain A high-density discrete lattice is generated by performing the second type of Coons surface Boolean sum operation in step 6.2. ,in , , M and N for direction and The number of sampling points in each direction. The discrete point lattice is fitted into a high-order B-spline surface using an inverse surface approximation algorithm, thus completing the reconstruction and generation of a high-quality G1 continuous Coons surface.

[0037] This invention reconstructs the generation logic of Coons surfaces from three dimensions: the numerical magnitude of the cross-boundary derivative, the spatial direction, and the compatibility of the torsional vector, resulting in the following significant benefits: 1) The transition of the cross-boundary derivative modulus is natural and the physical scale is compatible: Using the real physical arc length of the adjacent boundary extracted in step 2.2, the cross-boundary tangent vector is given a reasonable geometric scale through the linear interpolation formula (6) in step 2.3. At the same time, the first-order cross-boundary tangent vector error at the corner point is handled by formulas (10) and (11) in step 3.2, and the first-order derivative of the basis function is zero at the endpoints. , This avoids introducing additional error terms into the second-order mixed partial derivatives. It not only solves the problems of mesh stretching and distortion, but also provides a numerical basis for handling the torsion-vector incompatibility in step 5.

[0038] 2) Resolving normal offset and achieving G1 continuity for tangent plane coincidence: Step 4.2 introduces Gram-Schmidt orthogonalization projection to handle normal offset, establishing tangent plane constraints for the cross-boundary tangent vector field. Regardless of the degree of spatial deflection caused by the preceding physical interpolation and error compensation, this mechanism ensures that the reconstructed cross-boundary tangent vector adheres to the local normal of the original support surface extracted in step 4.1. Within the defined orthogonal tangent space, the reconstructed surface transitions smoothly in the zebra crossing analysis, and the angle between the normals of adjacent surfaces at the splicing point is zero, satisfying the collinearity condition of normals required for G1 continuity.

[0039] 3) Handling corner torsion incompatibility, excellent surface highlights and continuity: Combining the minimum step size numerical difference in step 5.1 with the Gregory rational harmonic formula in step 5.2 resolves the conflict between accurate calculation of the second derivative and torsion at the four corner points. The Gregory rational harmonic formula utilizes the parametric distance from the point to the adjacent boundary. As a dynamic weight, the hybrid torsion vector automatically converges spatially to the differential torsion vector at the nearest boundary. This ultimately results in a natural and smooth mesh flow in the diagonal region of the curved surface, greatly improving the specular quality of Class A curved surfaces. Attached Figure Description

[0040] Figure 1 This is a flowchart of a G1 continuous surface reconstruction and generation method based on boundary constraints according to the present invention; Figure 2 Examples of surface patching before and after using this technique on a 3D industrial model; Figure 2 (in) a This section introduces the 3D industrial model to be repaired, along with the corresponding original support surfaces, boundary curves, and holes. Figure 2 (in) b The ) represents the spatial evaluation lattice constructed in step 6.1, with the small red crosses indicating each selected sampling point; Figure 2 (in) c The high-density physical point lattice obtained in step 6.3 is represented by the green crosses, which indicate each calculated physical point. Figure 2 (in) d For the final surface patching results of the 3D industrial model, the continuity or maximum deviation angle between the B-spline surface obtained in step 6.3 and each original support surface at the corresponding boundary curve is given. Detailed Implementation

[0041] The present invention will be further described below with reference to specific implementation examples.

[0042] A method for reconstructing and generating G1 continuous surfaces based on boundary constraints, the flowchart of which is shown below. Figure 1 As shown, it includes the following steps: Step 1: Using the 3D industrial model to be repaired as input, the goal is to extract the four boundary curves of the holes, and establish a unified normalized parameter mapping through topological loop reconstruction and equal arc length discrete sampling, outputting a standard boundary dataset for subsequent steps. Specifically: The 3D industrial model to be repaired is composed of four original support surfaces with different parametric definitions, as shown below. Figure 2 (in) a As shown in the figure. In this paper, the original support surface refers to the surface patch that already exists around the hole to be repaired, which has its own independent parameterized definition and geometric shape. It is the geometric source for extracting the boundary curve. Ideally, four adjacent original support surfaces can be spatially distributed as bottom, right, top, and left surfaces, which together enclose a quadrilateral gap region that is not yet covered by the surface. The quadrilateral gap region is called the hole, as shown in the figure. Figure 2 (in) a As shown in the diagram. Each original support surface Each has its own independent parametric domain and geometry, and each contributes an isoparametric line adjacent to the hole. The isoparametric line refers to a line on the original support surface with a fixed parameter (such as...). The curve obtained It is a direct geometric method for extracting boundary curves from the original support surface. The boundary curve refers to the spatial curve that forms one side of the quadrilateral contour of the hole, which is directly extracted from the isoparametric line at the intersection of the original support surface and the hole.

[0043] Step 1.1: Analyze the model to be repaired and extract the boundary curves; The 3D industrial model to be repaired is read, and four original supporting surfaces surrounding the hole are obtained for the area to be repaired. Figure 2 (in) a The left, right, top, and bottom surfaces of the hole are defined. Boundary constraints are set, and corresponding isoparametric lines are extracted from each original support surface as the boundary curves of the hole, such as... Figure 2 The four boundary curves indicated in (a) lead to a set of four discrete space curves with independent local parameter domains: (1) Among them, the definition Let be the position vector of the i-th boundary curve in three-dimensional space, where , For the first i The original physical parameters of the boundary curve on its original supporting surface, i.e., the original supporting surface. In the parameter field u coordinates or v The coordinates depend on whether the boundary curve on the surface is a constant u-curve or a constant v-curve.

[0044] Simultaneously, extract the starting coordinates of each boundary curve in three-dimensional space. coordinates of the endpoint Where P represents a physical coordinate point in three-dimensional space, and the superscripts 0 and 1 correspond to the start and end points of the boundary curve, respectively. The original physical parameters... Starting from point 1, the original physical parameters The endpoint is at this point.

[0045] Step 1.2: Greedy evaluation of topological distance and forced loop reassembly; Due to micro-tolerances present during model format conversion, the endpoints of the four extracted boundary curves may not perfectly coincide in 3D space. To prevent these minute gaps from causing subsequent Boolean sum operations to fail, a forced topological loop closure operation is performed. First, a greedy algorithm is used to calculate the spatial Euclidean distance between the endpoints of each boundary curve sequentially. The curve segments with the closest spatial Euclidean distance are then concatenated in order, thus defining four logical roles: Bottom, Right, Top, and Left. Taking the Bottom as an example, the starting coordinates in 3D space... coordinates of the endpoint middle Let B represent belonging to the bottom edge, and then use the coordinates of the starting point of the bottom edge. and endpoint coordinates As an absolute benchmark, evaluate the directions of the remaining boundary curves separately: if a point on the left boundary is perpendicular to the starting point of the bottom edge... The distance is greater than its distance from the end point of the bottom edge. If the distance is such that the boundary direction is reversed, a reversal mark is recorded; similarly, the right and top boundaries are evaluated and corrected sequentially, thus transforming the disordered boundary curves into a closed directed quadrilateral loop in the topological structure. Finally, the recombined boundary curves are obtained.

[0046] Step 1.3: Establish the mapping between equal arc length sampling and normalized parameters; To eliminate the inconsistency between the parameter step size and the physical arc length caused by different parameterization definitions in the original boundary curves, normalized parameters are established for each boundary curve after the reorganization in step 1.2. To the original physical parameters u The equal arc length mapping model. Using any reconstructed boundary curve... An explanation is provided, in which s is the normalized parameter after normalization. .

[0047] Set the number of discrete sampling points to N To ensure that the actual physical arc lengths between two adjacent nodes are equal, a series of original physical parameters for each node are calculated. It satisfies the following integral equation of arc length: (2) in, For the first i The tangent derivative vector of the recombined boundary curve; Represents the Euclidean norm in three-dimensional space; For integration variables; is the index of the discrete node. For the first One original physical parameter node, For the first One original physical parameter node.

[0048] For normalized parameters Perform uniform discretization to obtain normalized parameter sampling points. Thus, a discrete mapping lookup table is established. Each normalized parameter sampling point The original physical parameters obtained by sampling with equal arc length One-to-one correspondence. For any given normalization parameter... First, based on the reversal marker recorded in step 1.2, set the valid parameters. The definition is as follows: when the boundary is marked as inverted, the normalization parameter is mirrored, i.e. ;otherwise Then locate in the discrete mapping lookup table. The discrete interval The corresponding original physical parameters are solved by linear interpolation, as shown in formula (3): (3) Step 1.3 outputs a set of standard boundary datasets that are closed loops in the topology and have equal physical arc lengths in the parameter domain. Each normalized boundary curve All use the normalized parameter s as the independent variable.

[0049] Step 2: The standard boundary dataset output from step 1 To address the physical scale distortion caused by parameter mismatch in different parameter domains, the basic cross-boundary tangent vector field is constructed by extracting the direction of the basic cross-boundary derivative, calculating the true physical arc length of adjacent boundaries, linearly interpolating the derivative magnitude, and constructing the basic cross-boundary tangent vector. In this paper, the cross-boundary tangent vector refers to the first-order partial derivative vector pointing from the boundary curve towards the interior of the hole. It describes the geometric rate of change of the surface along the direction inside the hole at the boundary and is a key physical quantity controlling the continuity of adjacent surfaces at the splicing boundary. Step 2 assigns a geometrically compatible magnitude to the cross-boundary tangent vector on the current boundary curve by extracting the true three-dimensional physical span of the adjacent boundary curves. Specifically: Step 2.1, extract the fundamental cross-boundary derivative directions; For any normalized boundary curve output in step 1 For the normalized parameters on the boundary curve s First, the corresponding original physical parameters are calculated using the discrete mapping lookup table in step 1.3. Then, the corresponding original support surface... Seeking s The original first-order partial derivative vector along the cross-boundary direction, that is, the direction from the current boundary to the inside of the hole. or To remove the interference of the original support surface parameterization on the vector magnitude, the partial derivative vector is... or Perform a normalization operation, retaining only the cross-boundary unit direction vector, as shown in the following formula: (4) Among them, for The cross-boundary unit direction vector at the location, For the current boundary curve on the original support surface The upper edge is fixed To the isoparametric parameter values, For the fixed boundary along the current boundary To the isoparametric parameter values, For the original supporting surface at point along First-order partial derivative vector of direction, Let Euclidean modulus operator be a vector.

[0050] Based on the reversal markers recorded in step 1.2, an orientation correction factor is introduced. To ensure that the cross-boundary unit direction vectors all point to the inside of the hole, a reference direction vector is obtained. .

[0051] Step 2.2, calculate the actual physical arc length of adjacent boundaries; Extract the two endpoints of the current boundary. and Two adjacent normalized boundary curves and ,in, Calculate the lengths of their adjacent physical boundaries in three-dimensional space, including and ,in Corresponding to the adjacent boundary length on the starting side, This corresponds to the length of the adjacent boundary on the endpoint side. The physical length of the adjacent boundary is obtained by the spatial Euclidean distance between its endpoints: (5) in, These are the three-dimensional physical coordinates of the endpoints of the two boundary curves adjacent to the current boundary start and end points, respectively. The superscripts 0 and 1 also correspond to the start and end points of each adjacent boundary curve, respectively.

[0052] Step 2.3, linear interpolation of derivative modulus and construction of basic cross-boundary tangent vector; Using the adjacent physical boundary lengths extracted in step 2.2, a linear interpolation equation for the derivative modulus is established in the normalized parameter domain to calculate the current boundary parameter points. s The ideal physical modulus scalar function that should be present at the given location: (6) The reference direction vector from step 2.1 With physical modulus scalar By performing scalar multiplication and combination, a fundamental cross-boundary tangent vector function with physical scale compatibility is constructed: (7) The final output yields the basic cross-boundary tangent field. .

[0053] Step 3: Using the fundamental cross-boundary tangent field constructed in Step 2 as input, accurately bridge the direction and magnitude deviations between the fundamental cross-boundary tangent field at its endpoints and the adjacent real boundary physical tangents, achieving a smooth transition across the entire domain; employing cubic Hermite interpolation basis functions, while compensating for first-order derivative errors, utilizes the mathematical property that the first-order derivative is zero at the endpoints of the basis functions to avoid introducing additional error terms in higher-order derivatives, ultimately obtaining the original corrected cross-boundary tangent field. Specifically: Step 3.1: Calculate the absolute error of the first-order cross-boundary tangent vector at the corner point; although step 2 has already constructed the basic cross-boundary tangent vector field with physically compatible modulus. However, since the basic cross-boundary tangent field is derived from linear interpolation constrained by the opposite sides, it has limitations at both ends of the boundary. and The initial direction at a given point may not perfectly coincide with the true tangential direction of the intersecting adjacent physical boundaries. Therefore, we first extract the physical tangential vectors at the endpoints of the adjacent boundary curves intersecting the current boundary, and then combine this with the corresponding lengths of the adjacent physical boundaries. and Calculate the target cross-boundary tangent vector at the corner point, and denote them as the initial target vector. With the termination target vector Then extract the limit values ​​of the basic cross-boundary tangent vector function from step 2.3 at both endpoints. and and respectively compared with the initial target vector Termination target vector Perform vector subtraction to calculate the absolute error vector of the first-order cross-boundary tangent at the corner point: (8) (9) in, The starting point of the current boundary curve The starting error vector at that point, The endpoint of the current boundary curve The endpoint error vector at that point.

[0054] Step 3.2: Perform global error allocation using Hermite basis functions; this will concentrate the starting error vector at the corner points. and endpoint error vector Smoothly and uniformly distribute the normalized parameter domain to the current boundary. Internally, a cubic Hermite interpolation basis function is introduced for global weighted allocation. Two basis functions are selected. and The influence weights corresponding to the start and end point errors are defined as follows: (10) (11) in, The starting error vector The weight allocation function, Endpoint error vector The weight allocation function.

[0055] The basis functions shown in formulas (10) and (11) have , , , The endpoint interpolation property of , and its first derivative is zero at both endpoints, i.e. This property ensures that the error compensation term will not produce additional first-order derivative changes at the endpoints.

[0056] In this step, the Hermite basis functions are a set of cubic polynomials that satisfy the interpolation conditions of endpoint function values ​​and first-order derivative values, and can smoothly distribute the error of the endpoint function values ​​or derivative values ​​over the entire domain.

[0057] Step 3.3: Synthesize the corrected cross-boundary derivative field; Based on the weighted superposition principle, correct the basic cross-boundary tangent field by combining the error vector with the basis functions and superimposing them onto the basic cross-boundary tangent field. The synthesized original corrected cross-boundary tangent field is as follows: (12) in, To obtain the original corrected cross-boundary tangent field, the cross-boundary tangent error at the corner points was compensated.

[0058] More importantly, due to the basis functions and The first derivative of is equal to zero at both endpoints, and subsequent steps... When performing differential calculations again to obtain the second-order mixed partial derivatives, the differential term of the error compensation term will automatically return to zero, thereby avoiding the introduction of additional errors in the corner-point second-order mixed partial derivatives.

[0059] Step 4: Using the original modified cross-boundary tangent vector field generated in Step 3 as input, establish a tangent plane geometric constraint mechanism. The tangent plane in this invention refers to the tangent plane at a given point on the surface, extending along... direction and Two first-order partial derivative vectors in the direction and The spanned two-dimensional plane is the local linear approximation space of the surface at a given point. To address the potential deviation of the original corrected cross-boundary tangent vector from the original supporting surface's normal vector in three-dimensional space due to linear interpolation and error compensation, the true surface normal of the original supporting surface is extracted and orthogonal projection constraints are applied to ensure that the final output cross-boundary tangent vector strictly adheres to the tangent plane of the original supporting surface, thus obtaining the final cross-boundary tangent vector field. Specifically: Step 4.1: Extract the true surface normal of the original support surface; for any normalized parameter on the boundary curve... First, the corresponding original physical parameters are calculated by back-calculating in step 1.3. Then determine the corresponding isoparametric coordinates. On the original support surface The first-order partial derivatives are evaluated on the surface to obtain the values ​​along the surface. u partial derivative vector of direction Along v partial derivative vector of direction To obtain the normalization parameters Surface unit normal vector at the location We perform a cross product operation on these two partial derivative vectors and normalize the result. The specific formula is as follows: (13) Step 4.2: Perform Gram-Schmidt orthogonalization projection; Extract the original corrected cross-boundary tangent field vector generated in step 3 based on Hermite error assignment. Since the original modified cross-boundary tangent vector is a vector synthesized through spatial algebraic superposition, it contains a normal deviation component that deviates from the tangent plane of the original supporting surface. To completely eliminate this component, a projection operation based on the Schmidt orthogonalization principle is performed. First, the original modified cross-boundary tangent vector is calculated. normal vector on the real surface The dot product on the plane is used to obtain the normal projection scalar that deviates from the tangent plane, and the normal projection scalar is multiplied by the unit normal vector to form the normal deviation component. Subtract from the middle. This yields the final transboundary tangent field attached to the true tangent plane. As shown in the following formula: (14) Step 4.3: Output the final cross-boundary tangent vector that satisfies the condition of coplanarity of the tangent planes. ; By applying the tangent plane projection constraint, the output of step 4.2 is... Strictly confined within the local tangent space of the original supporting surface, the normal vectors of adjacent surfaces at their boundaries are ensured to achieve consistency, resulting in the final cross-boundary tangent vector field. This ensures that the reconstructed surfaces satisfy the collinearity condition of normal vectors required for G1 continuity at their boundaries, providing data support for the construction of subsequent higher-order continuous surfaces.

[0060] Step 5: The final cross-boundary tangent vector field that satisfies the tangent plane projection constraint constructed in Step 4. As input, the true torsional vectors at each boundary point are obtained by performing a minimum step-size numerical difference on the projection function. Gregory's rational harmonic formula is then introduced to address the incompatibility of the second-order mixed partial derivatives derived from different boundaries at the four corner points. Finally, the torsional vectors at the four corner points are obtained after rational harmonic harmonic treatment. Specifically: Step 5.1: Obtain the corner point torsion vector using the minimum step size numerical difference method; The final transboundary tangent vector field output from step 4 that satisfies the tangent plane projection constraint. Using a very small step size Perform numerical differentiation. This is illustrated using any boundary curve, starting from the... and the finish line At this point, using forward and backward difference algorithms, an accurate approximation is achieved. The true spatial rate of change along the direction of parameter variation. The formula for calculating the numerical difference between the start and end points is as follows: (15) (16) in, Starting point Forward difference torsion vector at the location, End point Backward differential torsion vector at the location, For the final crossover, Kiriyaba, The minimum numerical difference step size. The final cross-boundary cutting arrow at the starting point, Step size from the starting point The final cross-border cutting arrow at the location, Step length from the endpoint The final cross-border cutting arrow at the location, The final cross-boundary cutting arrow at the endpoint.

[0061] Traverse the standard boundary dataset output in step 1, and repeat the difference operations shown in formulas (15) and (16) for each boundary curve to obtain the distance along the boundary curve at each of the four corner points of the hole. direction and along Discrete torsion vectors with independent orientation approximation. Each corner point corresponds to two torsion vector values: one from... Towards the boundary, denoted as Another one from Towards the boundary, denoted as ,in , representing the corner point at and The index in the direction. Since the two boundaries intersecting at the corner are extracted from original support surfaces with different parameterizations and independent internal node vectors, an incompatibility of second-order mixed partial derivatives inevitably occurs here, i.e. .

[0062] Step 5.2, establish Gregory's rational harmonic formula; Introducing parameters independent of the original support surface Coons surface normalization parameters ,in and These are the normalized coordinates of the Coons surface in the two parametric directions, with values ​​ranging from 0 to 1. At the point of operation During parameterized evaluation, to handle incompatible torsional vectors at corner points, the Gregory rational harmonic operator is introduced. The current evaluation point is set. To the near The parametric Euclidean distance to the boundary is ,in ,Pick At the same time, set the current evaluation point. To the near The parametric Euclidean distance to the boundary is ,Pick Using the Euclidean distance between the two parameters as the inverse proportional weighting factor for rational interpolation, the following dynamic harmonic equation is established: (17) in, For the corner point by Torsional vector obtained by boundary difference , For the same corner point, by Torsional vector obtained by boundary difference .when When (i.e., located at the corner point itself), take the arithmetic mean of the two. To avoid division by zero.

[0063] Step 5.3, Global smooth transition of corner incompatible torsion vectors; In the Gregory rational harmonic formula in step 5.2, when the evaluation point inside the surface moves towards... As it gradually approaches the boundary, that is... The weight distribution automatically exhibits a nonlinear tilt, causing the mixed torsion vector to... Smoothly converges to the corresponding Difference torsion vectors towards the boundary Similarly, towards When the boundary approaches, it converges to This achieves a continuous transition of the second derivative field, eliminating surface wrinkles and specular tearing caused by torsional vector discontinuity in the diagonal region, and finally yielding the torsional vector at the four corner points after rational harmonic reconciliation. ,in, Corner point The final twisting arrow at the location, Corner point The final twisting arrow at the location, Corner point The final twisting arrow at the location, Corner point The final twisted arrow at the location.

[0064] This step overcomes the problem that traditional analytical torsion vectors are difficult to calculate directly after undergoing nonlinear mapping and tangent space projection.

[0065] Step 6: Utilize the outputs of steps 1 to 5, namely the standard boundary dataset from step 1 and the final cross-boundary tangent field from step 4. The rationally harmonic torsion vector from step 5 is used to construct a high-density spatial evaluation lattice in the normalized parameter domain. Based on the second type of Coons surface Boolean sum principle, the 3D coordinate point cloud filling the holes is calculated. Then, a high-order B-spline geometric entity satisfying industrial tolerances is generated through an inverse approximation algorithm, resulting in the final B-spline surface. Specifically: Step 6.1, High-density evaluation lattice construction and Hermite basis function preparation; exist The internal high-density discrete resolution is set, that is, the number of sampling points on each boundary curve is predetermined, such as... Figure 2 As shown in (b), 13 points are sampled on each boundary curve, and the sampled points are indicated by small red crosses to construct a spatial evaluation point matrix. This is applied to arbitrary parameter coordinates within the grid. We introduce a Hermite interpolation basis function set consisting of four cubic polynomials, where the position basis functions are the same as those in formulas (10) and (11), and the tangent basis function is denoted as... Its expression is defined as: (18) (19) in, The tangent basis function at the starting point, i.e., acting on the starting point. The weight function of the tangent vector; The endpoint tangent basis function, i.e., acting on the endpoint. Weight function of the tangent vector at the starting point. Basis function of the tangent vector at the starting point. and endpoint tangent basis functions have The endpoint tangent interpolation characteristics.

[0066] Step 6.2, Boolean sum operation for the second type of Coons surface; based on the analytical definition of the Boolean sum for the second type of Coons surface, construct three independent three-dimensional vector field components respectively. Specifically: Step 6.2.1, firstly, the first lofted ruled surface component. The construction equation is as follows: (20) in, and respectively along The position vectors of the two boundary curves of the directional distribution and The outputs of step 4 are respectively Towards the final crossover of the field and The value at; To act on The basis function for the starting position of the side boundary position vector. To act on The basis function for the endpoint position of the side boundary position vector. To act on The starting tangent basis function of the lateral cross-boundary tangent vector. To act on The endpoint tangent basis functions of the lateral cross-boundary tangent vector are expressed by formulas (9), (10), (17), and (18), respectively.

[0067] Step 6.2.2, Second Lofting Ruled Surface Component The construction equation is as follows: (twenty one) in, and respectively along The position vectors of the two boundary curves of the directional distribution and The outputs of step 4 are respectively Towards the final crossover of the field and The value at that location.

[0068] Step 6.2.3: Again, to eliminate the overlap and redundancy of the first lofted ruled surface component and the second lofted ruled surface component at the corners and boundaries of the surface, a corner correction surface component is constructed. Its equation is expressed as follows: (twenty two) in, The position vectors of the four corner points, and They are the corner points along direction and The first-order tangent vector at the endpoint of the direction.

[0069] Step 6.2.4: Finally, based on the Boolean sum definition of the second type of Coons surface, the parameter node is calculated through vector algebra superposition operations. Physical coordinates in three-dimensional space: (twenty three) Step 6.3, B-spline inverse fitting; Traverse the entire normalized parameter domain A high-density discrete lattice is generated by performing the second type of Coons surface Boolean sum operation in step 6.2. ,in , , M and N for direction and The number of sampling points in the direction. For example... Figure 2 (in) cAs shown in the diagram, the small green crosses represent the generated physical coordinate points, and all the green crosses constitute a high-density physical point lattice. This high-density physical point lattice is then fitted into a high-order B-spline surface using an inverse surface approximation algorithm, as shown below. Figure 2 (in) d As shown in the figure, the final fitted B-spline surface achieves G1 continuity with the left, top, and right sides of the original support surface at the boundary curves. However, due to the poor parameterization of the 3D industrial model itself, the boundary curve of the bottom surface cannot simultaneously achieve G1 continuity with the left, top, and right surfaces at the boundary curves. The maximum G1 error between the B-spline surface and the bottom surface at the boundary curve is 14.55°. Therefore, a high-quality G1 continuous Coons surface reconstruction and generation is achieved.

[0070] The above embodiments are merely illustrative of the implementation methods of the present invention, but should not be construed as limiting the scope of the present invention. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the present invention, and these modifications and improvements all fall within the protection scope of the present invention.

Claims

1. A method for reconstructing and generating G1 continuous surfaces based on boundary constraints, characterized in that, The G1 continuous surface reconstruction and generation method includes the following steps: Step 1: Using the 3D industrial model to be repaired as input, the goal is to extract the four boundary curves of the hole, and establish a unified normalized parameter mapping through topological closed-loop reconstruction and equal arc length discrete sampling to obtain a standard boundary dataset. Step 2: Using the standard boundary dataset as input, the basic cross-boundary tangent field is obtained by extracting the direction of the basic cross-boundary derivative, calculating the true physical arc length of adjacent boundaries, linearly interpolating the derivative modulus, and constructing the basic cross-boundary tangent. Step 3: Using the basic cross-boundary tangent field as input, accurately bridge the direction and magnitude deviations between the basic cross-boundary tangent field and the adjacent real boundary physical tangent at the endpoints, and achieve a smooth transition throughout the entire domain; use cubic Hermite interpolation basis functions to obtain the original modified cross-boundary tangent field; Step 4: Using the original modified cross-boundary tangent field as input, establish a tangent plane geometric constraint mechanism to obtain the final cross-boundary tangent field; A tangent plane is a plane that extends from a given point on a curved surface along... direction and Two first-order partial derivative vectors in the direction and The spanned two-dimensional plane; S is the original support surface. By extracting the true surface normal of the original support surface and applying orthogonal projection constraints, the final output cross-boundary tangent vector is ensured to strictly adhere to the tangent plane of the original support surface, thus obtaining the final cross-boundary tangent vector field. Step 5: Using the final cross-boundary tangent vector field that satisfies the tangent plane projection constraint constructed in Step 4 as input, the true torsional vectors at each boundary at the corner points are obtained by performing a minimum step size numerical difference on the projection function, and the Gregory rational harmonic formula is introduced to finally obtain the torsional vectors at the four corner points after rational harmonic harmonics. Step 6: Combining the standard boundary dataset from Step 1, the final cross-boundary tangent field from Step 4, and the rationally harmonic torsional vector from Step 5, construct a high-density spatial evaluation lattice in the normalized parameter domain. Calculate the 3D coordinate point cloud filling the hole based on the second type of Coons surface Boolean sum principle. Generate a high-order B-spline geometric entity that meets industrial tolerances through an inverse approximation algorithm, thus obtaining the final B-spline surface.

2. The method for reconstructing and generating G1 continuous surfaces based on boundary constraints according to claim 1, characterized in that, Specifically, step 1 is as follows: Step 1.1: Analyze the model to be repaired and extract the boundary curves; The three-dimensional industrial model to be repaired is read, and four original support surfaces surrounding the hole are obtained for the hole area to be repaired. Boundary constraints are set, and corresponding isoparametric lines are extracted from each original support surface as the initial boundary curves of the hole, thus obtaining a set of four discrete space curves with independent local parameter domains. definition Let be the position vector of the i-th boundary curve in three-dimensional space. For the first i The original physical parameters of the boundary curve on its original supporting surface, i.e., the original supporting surface. In the parameter field u coordinates or v The coordinates depend on whether the boundary curve on the surface is a constant u-curve or a constant v-curve, where , u , v Specifically, it refers to defining the local two-dimensional parameters of the internal structure of the original supporting surface, as shown in the following formula: (1) Simultaneously, extract the starting coordinates of each boundary curve in three-dimensional space. coordinates of the endpoint Where P represents a physical coordinate point in three-dimensional space, and the superscripts 0 and 1 correspond to the start and end points of the boundary curve, respectively. The original physical parameters... Starting from point 1, the original physical parameters The endpoint is at this location; Step 1.2: Greedy evaluation of topological distance and forced loop reassembly; Perform a forced topological loop closure operation; first, using a greedy algorithm, calculate the spatial Euclidean distance between the endpoints of each boundary curve in sequence, and then concatenate the curve segments with the closest spatial Euclidean distance in order to define four logical roles: bottom, right, top, and left. Taking the bottom as an example, the starting coordinates in three-dimensional space... coordinates of the endpoint middle Let B be used to represent belonging to the bottom edge, with the coordinates of the starting point of the bottom edge as the reference. and endpoint coordinates Using the absolute benchmark, the directions of the remaining boundary curves are evaluated to determine the reversal markers, and finally the recombined boundary curves are obtained; Step 1.3: Establish the mapping between equal arc length sampling and normalized parameters; For each boundary curve recombined in step 1.2, establish a normalized parameter to original physical parameter equal arc length mapping model; take any recombined boundary curve An explanation is provided, in which s is the normalized parameter after normalization. ; Set the number of discrete sampling points to N To ensure that the actual physical arc lengths between two adjacent nodes are equal, a series of original physical parameters for each node are calculated. It satisfies the following integral equation of arc length: (2) in, For the first i The tangent derivative vector of the recombined boundary curve; Represents the Euclidean norm in three-dimensional space; For integration variables; is the index of the discrete node. For the first One original physical parameter node, For the first One original physical parameter node; For normalized parameters Perform uniform discretization to obtain normalized parameter sampling points. Thus, a discrete mapping lookup table is established. Each normalized parameter sampling point The original physical parameters obtained by sampling with equal arc length One-to-one correspondence; for any given normalization parameter First, based on the reversal marker recorded in step 1.2, set the valid parameters. Locate in the discrete mapping lookup table The discrete interval The corresponding original physical parameters are solved by linear interpolation, as shown in formula (3): (3) Step 1.3 outputs a set of standard boundary datasets that are closed loops in the topology and have equal physical arc lengths in the parameter domain. Each normalized boundary curve All use the normalized parameter s as the independent variable.

3. The method for reconstructing and generating G1 continuous surfaces based on boundary constraints according to claim 2, characterized in that, In step 1: In step 1.2, the direction of the remaining boundary curves is evaluated as follows: if a point on the left boundary is perpendicular to the starting point of the bottom edge... The distance is greater than its distance from the end point of the bottom edge. If the distance is equal to the boundary direction, the boundary direction is determined to be opposite and a reversal mark is recorded. Similarly, the right boundary and the top edge are evaluated and corrected in turn, thereby transforming the disordered boundary curves into a closed directed quadrilateral loop in the topological structure. In step 1.3, the effective parameters The definition is as follows: when the boundary is marked as reversed, the normalization parameter is mirrored, i.e. ;otherwise .

4. The method for reconstructing and generating G1 continuous surfaces based on boundary constraints according to claim 3, characterized in that, Step 2 specifically includes: Step 2.1, extract the fundamental cross-boundary derivative directions; For any normalized boundary curve output in step 1 For the normalized parameters on the boundary curve s First, the original physical parameters are calculated using a discrete mapping lookup table; then, on the original support surface... Seeking s The original first-order partial derivative vector along the cross-boundary direction, that is, the direction from the current boundary to the inside of the hole. or ; with respect to the original first-order partial derivative vector or Perform normalization, retaining only the cross-boundary unit direction vector, as shown in the formula below: (4) in, for The cross-boundary unit direction vector at the location, For the current boundary curve on the original support surface The upper edge is fixed To the isoparametric parameter values, For the fixed boundary along the current boundary To the isoparametric parameter values, For the original supporting surface at point along First-order partial derivative vector of direction, The Euclidean modulus operator for vectors; Based on the reversal markers recorded in step 1.2, an orientation correction factor is introduced. To ensure that the cross-boundary unit direction vectors all point to the inside of the hole, a reference direction vector is obtained. ; Step 2.2, calculate the actual physical arc length of adjacent boundaries; Extract the two endpoints of the current boundary. and Two adjacent normalized boundary curves and ,in, Calculate the lengths of their adjacent physical boundaries in three-dimensional space, including and ,in Corresponding to the adjacent boundary length on the starting side, The length of the adjacent boundary corresponds to the endpoint; the physical length of the adjacent boundary is obtained by the spatial Euclidean distance between its endpoints: (5) in, These are the three-dimensional physical coordinates of the endpoints of the two boundary curves adjacent to the current boundary start and end points, respectively. The superscripts 0 and 1 also correspond to the start and end points of each adjacent boundary curve, respectively. Step 2.3, linear interpolation of derivative modulus and construction of basic cross-boundary tangent vector; Using the adjacent physical boundary lengths extracted in step 2.2, a linear interpolation equation for the derivative modulus is established in the normalized parameter domain to calculate the current boundary parameter points. s The ideal physical modulus scalar function that should be present at the given location: (6) The reference direction vector from step 2.1 With physical modulus scalar By performing scalar multiplication and combination, a fundamental cross-boundary tangent vector function with physical scale compatibility is constructed: (7) The final output yields the basic cross-boundary tangent field. .

5. The method for reconstructing and generating G1 continuous surfaces based on boundary constraints according to claim 4, characterized in that, Step 3 specifically includes: Step 3.1: Calculate the absolute error of the first-order cross-boundary tangent at the corner point; Extract the physical tangent vectors at the endpoints of adjacent boundary curves intersecting the current boundary, and combine them with the lengths of the two corresponding adjacent physical boundaries to calculate the target cross-boundary tangent vectors at the corner points, denoted as the initial target vectors. With the termination target vector ; Extract the limit of the fundamental cross-boundary tangent function at both endpoints. and and respectively compared with the initial target vector Termination target vector Perform vector subtraction to calculate the absolute error vector of the first-order cross-boundary tangent vector at the corner point, as shown in the following formula: (8) (9) in, The starting point of the current boundary curve The starting error vector at that point, The endpoint of the current boundary curve The endpoint error vector at the location; Step 3.2: Use Hermite basis functions to perform global error allocation; To concentrate the starting error vector at the corner point and endpoint error vector Smoothly and uniformly distribute the normalized parameter domain to the current boundary. Internally, a cubic Hermite interpolation basis function is introduced for global weighted allocation; two basis functions are selected. and The influence weights corresponding to the start and end point errors are defined as follows: (10) (11) in, The starting error vector The weight allocation function, Endpoint error vector The weight allocation function; Step 3.3: Synthesize the corrected cross-boundary derivative field; The basic cross-boundary tangent field is corrected according to the weighted superposition principle. The error vector and basis functions are combined and superimposed on the basic cross-boundary tangent field. The synthesized original corrected cross-boundary tangent field is as follows: (12) in, To obtain the original corrected cross-boundary tangent field, the cross-boundary tangent error at the corner points is compensated.

6. The method for reconstructing and generating G1 continuous surfaces based on boundary constraints according to claim 5, characterized in that, Step 4 specifically includes: Step 4.1: Extract the true surface normal of the original support surface; For any normalized parameter sampling point on the boundary curve First, the corresponding original physical parameters are calculated by back-calculating in step 1.

3. Then determine the corresponding isoparametric coordinates. ; on the original support surface The first-order partial derivatives are evaluated on the surface to obtain the values ​​along the surface. u partial derivative vector of direction Along v partial derivative vector of direction To obtain the sampling points for the normalized parameters Surface unit normal vector at the location We perform a cross product operation on these two partial derivative vectors and normalize the result. The specific formula is as follows: (13) Step 4.2: Perform Gram-Schmidt orthogonalization projection; Extract the original corrected cross-boundary tangent field vector generated in step 3 based on Hermite error assignment. ; Perform projection operations based on the Schmitt orthogonalization principle; Calculate the original modified cross-boundary tangent field vector normal vector on the real surface The dot product on the plane yields the normal projection scalar that deviates from the tangent plane. Multiplying this normal projection scalar by the unit normal vector creates the normal deviation component. Subtract from the middle; calculate the final cross-boundary tangent field attached to the true tangent plane. As shown in the following formula: (14) Step 4.3: Output the final cross-boundary tangent vector that satisfies the condition of coplanarity of the tangent planes. ; By applying the tangent plane projection constraint, the output of step 4.2 is... Strictly confined within the local tangent space of the original supporting surface, ensuring the consistency of the normal at the boundary between adjacent surfaces, the final cross-boundary tangent vector field is obtained.

7. The method for reconstructing and generating G1 continuous surfaces based on boundary constraints according to claim 6, characterized in that, Step 5 specifically includes: Step 5.1: Obtain the corner point torsion vector using the minimum step size numerical difference method; The final transboundary tangent vector field output from step 4 that satisfies the tangent plane projection constraint. Perform numerical differentiation; illustrate with any boundary curve, starting from the point... and the finish line At this point, using forward and backward difference algorithms, an accurate approximation is achieved. The true spatial rate of change along the direction of parameter variation; the formula for calculating the numerical difference between the start and end points is as follows: (15) (16) in, Starting point Forward difference torsion vector at the location, End point Backward differential torsion vector at the location, For the final crossover, Kiriyaba, The minimum numerical difference step size. The final cross-boundary cutting arrow at the starting point, Step size from the starting point The final cross-border cutting arrow at the location, Step length from the endpoint The final cross-border cutting arrow at the location, The final cross-boundary cutting arrow at the endpoint; Introducing parameters independent of the original support surface Coons surface normalization parameters ,in and These are the normalized coordinates of the Coons surface in two mutually perpendicular parametric directions, with values ​​ranging from 0 to 1. ; Traverse the standard boundary dataset output in step 1, repeat the difference operation shown in formulas (15) and (16) for each boundary curve, and obtain the difference along the curve at the four corners of the hole respectively. direction and along Discrete torsion vectors with independent orientation approximation; each corner point corresponds to two torsion vector values: one from... Towards the boundary, denoted as Another one from Towards the boundary, denoted as ,in , representing the corner point at and Index in direction; Step 5.2, establish Gregory's rational harmonic formula; At the point of progress During parameterized evaluation, to handle incompatible torsional vectors at corner points, the Gregory rational harmonic operator is introduced; the current evaluation point is set. To the near The parametric Euclidean distance to the boundary is ,in ,Pick At the same time, set the current evaluation point. To the near The parametric Euclidean distance to the boundary is ,Pick Using the Euclidean distance between the two parameters as the inverse proportional weighting factor for rational interpolation, the following dynamic harmonic equation is established: (17) in, For the corner point by Torsional vector obtained by boundary difference , For the same corner point, by Torsional vector obtained by boundary difference ;when When the point is located at a corner point itself, take the arithmetic mean of the two. ; Step 5.3, Global smooth transition of corner incompatible torsion vectors; In the Gregory rational harmonic formula in step 5.2, when the evaluation point inside the surface moves towards... As it gradually approaches the boundary, that is... The weight distribution automatically exhibits a nonlinear tilt, causing the mixed torsion vector to... Smoothly converges to the corresponding Difference torsion vectors towards the boundary Similarly, towards When the boundary approaches, it converges to This achieves a continuous transition of the second-order derivative field, ultimately yielding the torsional vector at the four corner points after rational harmonic rendition. ,in, Corner point The final twisting arrow at the location, Corner point The final twisting arrow at the location, Corner point The final twisting arrow at the location, Corner point The final twisted arrow at the location.

8. The method for reconstructing and generating G1 continuous surfaces based on boundary constraints according to claim 7, characterized in that, Specifically, step 6 includes: Step 6.1, High-density evaluation lattice construction and Hermite basis function preparation; exist A high-density discrete resolution is set internally to construct a spatial evaluation lattice matrix; for arbitrary parameter coordinates within the grid... We introduce a Hermite interpolation basis function set consisting of four cubic polynomials, where the position basis functions are the same as those in formulas (10) and (11), and the tangent basis function is denoted as... Its expression is defined as: (18) (19) in, The tangent basis function at the starting point, i.e., acting on the starting point. The weight function of the tangent vector; The endpoint tangent basis function, i.e., acting on the endpoint. Weight function of the tangent vector at the starting point; basis function of the tangent vector at the starting point and endpoint tangent basis functions have endpoint tangent interpolation properties; Step 6.2, Boolean sum operation for the second type of Coons surface; based on the analytical definition of the Boolean sum for the second type of Coons surface, construct three independent three-dimensional vector field components respectively; Step 6.3, B-spline inverse fitting; Traverse the entire normalized parameter domain A high-density discrete lattice is generated by performing the second type of Coons surface Boolean sum operation in step 6.

2. ,in , , and They are respectively direction and The number of sampling points in the direction; the discrete point lattice is fitted into a high-order B-spline surface through the inverse surface approximation algorithm, thus completing the reconstruction and generation of a high-quality G1 continuous Coons surface.

9. The method for reconstructing and generating G1 continuous surfaces based on boundary constraints according to claim 8, characterized in that, Specifically, step 6.2 involves: Step 6.2.1, firstly, the first lofted ruled surface component. The construction equation is as follows: (20) in, and respectively along The position vectors of the two boundary curves of the directional distribution and The outputs of step 4 are respectively Towards the final crossover of the field and The value at; To act on The basis function for the starting position of the side boundary position vector. To act on The basis function for the endpoint position of the side boundary position vector. To act on The starting tangent basis function of the lateral cross-boundary tangent vector. To act on The endpoint tangent basis functions of the lateral cross-boundary tangent vector are expressed by formulas (10), (11), (18), and (19), respectively. Step 6.2.2, Second Lofting Ruled Surface Component The construction equation is as follows: (21) in, and respectively along The position vectors of the two boundary curves of the directional distribution and The outputs of step 4 are respectively Towards the final crossover of the field and The value at; Step 6.2.3, construct the corner correction surface components. Its equation is expressed as follows: (22) in, The position vectors of the four corner points, and They are the corner points along direction and The endpoint of the direction is the first-order tangent vector, where ; Step 6.2.4: Finally, based on the Boolean sum definition of the second type of Coons surface, the parametric coordinates are calculated through vector algebra superposition operations. Physical coordinates in three-dimensional space: (23)。

Citation Information

Patent Citations

  • NURBS curved surface filling method and system for N-side hole with line constraint

    CN117788771A

  • Hole repairing method, device and equipment for CFD pretreatment and medium

    CN121302533A

  • Curled edge fillet curved surface automatic generation method based on virtual constraint and self-adaptive offset

    CN122088057A

  • Second type Coons curved surface reconstruction and generation method based on arc length parameterization

    CN122176249A