Abstract:
A solid modeling method for modeling solids which include free-form surfaces calculates intersecting portions of two solids and storing calculated results as first data, stores free-form shapes of the two solids as second data, approximates free-form surface portions of the two solids by polyhedrons so as to describe the two solids in a form of polyhedrons, obtains a union, a difference or an intersection of the two solids by carrying out set operations on the polyhedrons, and returns the polyhedrons obtained by the set operations into solids including free-form surfaces based on the stored first and second data.

Description:
This application is a continuation of U.S. patent application Ser. No. 07/321,295, filed Mar. 8, 1989, now abandoned. 
    
    
     BACKGROUND OF THE INVENTION 
     The present invention generally relates to solid modeling methods for modeling solids which include free-form surfaces, and more particularly to a solid modeling method which uses a boundary representation to describe the solids. 
     In computer aided design (CAD) systems for designing a three-dimensional structure, there are CAD systems which are based on a solid modeler. Such CAD systems are presently used in various fields and has become popular. For this reason, there are demands for a powerful solid modeler. Presently, one of the highest of such demands is the realization of an improved CAD system for modeling solids which include free-form surfaces by carrying out a set operation. Several of such CAD systems have been proposed, but there are problems in that the processing speed is slow and the reliability is poor. 
     According to the conventional method of modeling a solid having free-form surfaces, an intersecting line of a curved surface and a plane and an intersecting line of a curved surface and a curved surface are first calculated. The methods of calculating the intersecting lines can be generally categorized into two, a first method being the method disclosed in E. G. Houghton et al., &#34;Implementation of a Divide-and-Conquer Method for Intersection of Parametric Surfaces&#34;, Computer Aided Geometric Design, Vol. 2, No. 1, pp. 173-183, 1985 and a second method being the intersection tracing method disclosed in R. E. Barnhill et al., &#34;Surface/Surface Intersection&#34;, Computer Aided Geometric Design, Vol. 4, No. 1, pp. 3-16, 1987. The set operation is carried out based on the intersecting lines calculated according to the first or second method. 
     The curved surface obtained by the set operation is generally described by a trimmed surface patch disclosed in M. S. Casale, &#34;Free-Form Solid Modeling with Trimmed Surface Patches&#34;, IEEE CG &amp; A, Vol. 7, No. 1, pp. 33-43, 1987. For example, the trimmed surface patch uses a portion of a patch to describe a shape as shown in FIG. 1. In FIG. 1, regions r1 and r2 are used to describe the shape. 
     However, the above described method suffers the following problems. 
     Firstly, when a bicubic parameter surface is used as the curved surface, an intersecting line of a curved surface and a curved surface becomes a 324-degree polynomial and an intersecting line of a curved surface and a plane becomes an 18-degree polynomial, as discussed in R. T. Farouki, &#34;Direct Surface Evaluation&#34;, Geometric Modeling&#34;, G. Farin, Ed., SIAM, Philadelphia, pp. 319-334, 1987. Accordingly, it is not easy to stably obtain the intersecting lines for all cases, and for this reason, the reliability of the set operation which is based on obtaining the intersecting lines is not high. 
     Secondly, the degree of the intersecting lines is generally high and it is difficult to analytically obtain the intersecting lines. Thus, the intersecting lines are conventionally approximated by a large number of line segments or spline curves. In structural design, the intersecting lines play an important role and it is natural that the designer wishes to be able to modify the curves. But a local modification of edge lines of the solid described by the trimmed surface patches is not permitted. 
     Therefore, a known method describes the curved surfaces of the solid by the trimmed surface patches which describe the curved surface by an equation and a boundary of a region occupied by the curved surface, and calculates the intersecting portions of two solids when carrying out the set operation of the two solids. However, it is difficult to accurately and stably obtain the intersecting lines of the curved surfaces according to this method. For example, when a bicubic parametric surface is used as the curved surface, an intersecting line becomes a curved described by a 324-degree polynomial. In addition, according to this method, the generated intersecting lines cannot be modified. When the calculation of the intersecting line is in error, for example, there is also a problem in that the set operation becomes in error. 
     SUMMARY OF THE INVENTION 
     Accordingly, it is a general object of the present invention to provide a novel and useful solid modeling method in which the above described problems are eliminated. 
     Another and more specific object of the present invention is to provide a solid modeling method for modeling solids which include free-form surfaces, comprising the steps of calculating intersecting portions of two solids and storing calculated results as first data, storing free-form shapes of the two solids as second data, approximating free-form surface portions of the two solids by polyhedrons so as to describe the two solids in a form of polyhedrons, obtaining a union, a difference or an intersection of the two solids by carrying out set operations on the polyhedrons, and returning the polyhedrons obtained by the set operations into solids including free-form surfaces based on the stored first and second data. 
     According to the solid modeling method of the present invention, it is possible to realize the set operation of the free-form solid by adding a pre-process and an after-process to the set operation of the polyhedron. As a result, the method of the present invention is simple and the reliability thereof is high. When applied to a solid modeling system, it is possible to carry out the set operation on the solids including free-form surfaces, and the generated intersecting lines of the solids can be freely modified afterwards. 
     Other objects and further features of the present invention will be apparent from the following detailed description when read in conjunction with the accompanying drawings. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     FIG. 1 is a perspective view for explaining trimmed surface patches; 
     FIG. 2 is a flow chart for explaining an embodiment of a solid modeling method according to the present invention; 
     FIGS. 3A through 3D respectively are perspective views for explaining a set operation of a free-form solid; and 
     FIGS. 4A and 4B respectively are perspective views for explaining the set operation. 
    
    
     DETAILED DESCRIPTION 
     The present invention realizes a free-form solid by adding a pre-process and an after-process to a set operation of a polyhedron. According to the present invention, the trimmed surface patches are regenerated by Gregory patches which are known from the conventional repatching disclosed for example in R. F. Sarraga et al., &#34;Free-Form Surfaces in GMSolid: Goals and Issues&#34;, Solid Modeling by Computers from Theory to Applications, M. S. Picket and J. W. Boyse Eds., Plenum Press, New York, pp. 237-253, 1984. 
     FIG. 2 is a flow chart for explaining an embodiment of the solid modeling method according to the present invention. In this embodiment, the set operation process of the free-form solid basically includes five operations (1) through (5). 
     (1) Calculation of the Intersections: 
     The intersecting lines of the curved surfaces of two solids are calculated. When the intersecting line cannot be obtained stably, it is sufficient to obtain an appropriate approximation of the intersecting line. The calculated results are stored as data in a table which is prepared in advance. 
     (2) Polyhedral Approximation: 
     Curved edge lines are converted into straight edge lines and the original curved line data are stored in a table. In addition, when there exits a surface which is not a plane, the solid is described in a form of a polyhedron by appropriately interpolating linear edge lines within the surface. 
     (3) Set Operations of the Polyhedrons: 
     The set operations of the solids described in the form of polyhedron are carried out. The conventional method of carrying out the set operation may be employed. 
     (4) Rounding of the Polyhedron: 
     The solids described in the form of the polyhedrons are regenerated as solids having the free-form surfaces, so as to return the polyhedrons into the solids including the original free-form surfaces based on the data stored in the tables by the operations (1) and (2). 
     (5) Regeneration of the Curved Surfaces: 
     The free-form surfaces are regenerated using the conventional repatching technique. 
     The conventional techniques may be employed to carry out the operations (1) and (2). 
     FIGS. 3A through 3D respectively are perspective views for explaining a set operation of a free-form solid. When it is assumed that set operations of two solids I and II shown in FIG. 3A are to be carried out, intersecting portions of the two solids I and II are first calculated and stored as data. Next, the solids I and II are approximated in the form of polyhedrons as shown in FIG. 3B, and set operations of the polyhedrons are carried out as shown in FIG. 3C. Finally, the curved surfaces are regenerated as shown in FIG. 3D based on the data of the curved lines which are stored in advance. 
     Next, a description will be given of the algorithm of the solid modeling method according to the present invention. The algorithm for carrying out the set operation of the free-form solid comprises five stages of processes which are highly independent of each other. 
     [1] Generation of the Intersections: 
     The intersecting points of all of the curved edge lines of one solid and the plane or curved surface of the other solid are obtained. Vertexes are generated on the intersecting points by use of the Euler operation. This process is also applicable to the all of the curved edge lines of the other solid. Next, the intersecting line of the curved surface and the curved surface and the intersecting line of the curved surface and the plane are calculated, and the calculated results are approximated by the Bezier curves. The calculated curves are not added to the original solids but are stored in a table. FIG. 3A shows the two solids applied with the set operation in conformance with the present invention. 
     [2] Approximation by Polyhedrons: 
     The solids including the curves are approximated by the polyhedrons. In order to make this approximation, the curved edge lines are first approximated by linear lines. Next, linear edge lines are generated within a surface which is not a plane, and the surface is divided into a plurality of planes. FIG. 3B show the polyhedrons obtained by these processes. 
     [3] Set Operations of the Polyhedrons: 
     Set operations of the approximated polyhedrons are carried out. FIG. 3C shows the solids after the set operations. 
     [4] Rounding of the Polyhedrons: 
     Unnecessary edge lines which were formed for the purpose of describing the original curved surfaces in the form of planes are eliminated, and the boundary edge lines of the surfaces are described by curves. In addition, intersecting lines described by the linear edge lines are approximated by Bezier curves. Finally, accurate edge lines are obtained from the table which is made in the stage [1], and these edge lines are replaced by approximated curved edge lines. FIG. 3D shows the solids obtainedc as a result of the these processes. 
     [5] Regeneration of the Curved Surfaces: 
     After carrying out the set operation, a portion of some curved surfaces are eliminated and triangular or pentagonal curved surfaces appear as a result. These triangular or pentagonal curved surfaces are interpolated by Gregory patches disclosed for example in H. Chiyokura, &#34;Localized Surface Interpolation Method for Irregular Meshes&#34;, Advanced Computer Graphics, T. L. Kunii, Ed., Springer-Verag, Tokyo, pp. 3-19, 1986. 
     FIGS. 4A and 4B respectively show the solids before and after carrying out the stages [1] through [5] of the processes. 
     Therefore, according to the solid modeling method of the present invention, the following advantageous features are obainable. 
     Firstly, when the set operation of the polyhedron is given, a most general method of application to the free-form surface is to make a modification within the process. However, since the algorithm of the set operation itself is complex, such a modification is difficult. On the other hand, according to the present invention, the set operation of the polyhedron is treated as a black box, and only the pre-process and the after process are made. For this reason, the realization and maintenance of the modeling process is facilitated. 
     Secondly, the intersecting line of the curved surface and the curved surface, and the intersecting line of the curved surface and the plane are calculated in the pre-process, but the set operation can be carried out even if the intersecting line cannot be calculated. When the intersecting line cannot be found, the intersecting line is given as line segments by the set operation of the polyhedron, and these line segments are converted into the curve by the after-process. Hence, the set operation can be carried out stably. 
     Thirdly, because the solid modeling method according to the present invention regenerates the curved surfaces, the designer can freely modify the intersecting lines generated by the set operation. In addition, the patches for describing the shape are used as a whole and not in portions, thereby simplifying the data structure and facilitating the development of the application program. 
     Further, the present invention is not limited to these embodiments, but various variations and modifications may be made without departing from the scope of the present invention.