8
Introduction The emerging technologies known as rapid prototyping are concerned with the automatic generation of physical parts from geometrical descriptions created in CAD systems. Unlike traditional part fabrication processes (such as NC machining, in which the desired shape is generated by material removal) rapid proto- typing or “layered fabrication” processes employ material deposition or solidification in a layer-by-layer fashion in order to create a part. Although parts fabricated by such processes generally lack the strength, rigidity and durability of production parts, they nev- ertheless serve important roles in providing speedy design verifications and allow limited testing of fit and functionality; see [1] for a recent review of the state-of-the-art. Since the acceleration of product develop- ment cycles is a primary goal of rapid proto- typing systems, their accuracy, efficiency and reliability are of paramount concern. An impediment to the realization of these attribut- es, however, is the rather crude geometrical model representation format, known as the “STL file”, that has become a de facto standard for commercial rapid prototyping systems (the STL format, which approximates the bound- ary of a solid by an unordered set of triangular facets, was developed by 3D Systems, Inc., as an expedient and easily-interpretable scheme for describing part geometry in the stereolitho- graphy process; see [2, Chapter 5]. In this paper we report on empirical inves- tigations into the advantages of model repre- sentations for rapid prototyping that are less data intensive and geometrically more sophis- ticated than the STL file. An object-oriented system, based initially on quadric surface models but extensible to more general sur- faces, has been implemented to give systemat- ic and equitable comparisons of parameters such as cpu time, data volume and “robust- ness” in the processing of both STL and analytic part representations. The geometrical computations performed on both representations of any given part amount to computing a sequence of parallel planar slices through the model and then “filling” each section curve by equidistant offset curves, in accordance with the path planning strategy described in [3]. This approach helps to minimize the need for support structures in parts with “overhanging” features; see also [4]. Most systems employ at 41 Rapid Prototyping Journal Volume 2 · Number 3 · 1996 · pp. 41–48 © MCB University Press · ISSN 1355-2546 Computational methods for rapid prototyping of analytic solid models Rida T. Farouki and Thomas König The authors Rida T. Farouki and Thomas König are in the Depart- ment of Mechanical Engineering and Applied Mechanics, University of Michigan, Ann Arbor, Michigan, USA. Abstract Looks at how layered fabrication processes typically entail extensive computations and large memory requirements in the reduction of three-dimensional part descriptions to area-filling paths that cover the interior of each of a sequence of planar slices. Notes that the polyhedral “STL” representation exacerbates this problem by necessitating large input data volumes to describe curved surface models at acceptable levels of accuracy. Develops a geometrical modelling system that captures and processes analytic slice representations, based on models bounded by the natural quadric surface. Finds that empirical results from this system of representative parts systematically yield improvements of between one and two orders of magnitude in efficiency, accuracy and data volume over an equivalent processing of the STL model. Furthermore, discovers that the analytic form is significantly more reliable, since it is not subject to the geometrical or topological defects frequently encountered in STL files generated by commercial CAD systems. This work was supported by the Office of Naval Research under grant N0001495-].-0767.

Computational methods for rapid prototyping of analytic solid models

  • Upload
    thomas

  • View
    213

  • Download
    1

Embed Size (px)

Citation preview

Introduction

The emerging technologies known as rapidprototyping are concerned with the automaticgeneration of physical parts from geometricaldescriptions created in CAD systems. Unliketraditional part fabrication processes (such asNC machining, in which the desired shape isgenerated by material removal) rapid proto-typing or “layered fabrication” processesemploy material deposition or solidification ina layer-by-layer fashion in order to create apart. Although parts fabricated by suchprocesses generally lack the strength, rigidityand durability of production parts, they nev-ertheless serve important roles in providingspeedy design verifications and allow limitedtesting of fit and functionality; see [1] for arecent review of the state-of-the-art.

Since the acceleration of product develop-ment cycles is a primary goal of rapid proto-typing systems, their accuracy, efficiency andreliability are of paramount concern. Animpediment to the realization of these attribut-es, however, is the rather crude geometricalmodel representation format, known as the“STL file”, that has become a de facto standardfor commercial rapid prototyping systems (theSTL format, which approximates the bound-ary of a solid by an unordered set of triangularfacets, was developed by 3D Systems, Inc., asan expedient and easily-interpretable schemefor describing part geometry in the stereolitho-graphy process; see [2, Chapter 5].

In this paper we report on empirical inves-tigations into the advantages of model repre-sentations for rapid prototyping that are lessdata intensive and geometrically more sophis-ticated than the STL file. An object-orientedsystem, based initially on quadric surfacemodels but extensible to more general sur-faces, has been implemented to give systemat-ic and equitable comparisons of parameterssuch as cpu time, data volume and “robust-ness” in the processing of both STL andanalytic part representations.

The geometrical computations performedon both representations of any given partamount to computing a sequence of parallelplanar slices through the model and then“filling” each section curve by equidistantoffset curves, in accordance with the pathplanning strategy described in [3]. Thisapproach helps to minimize the need forsupport structures in parts with “overhanging”features; see also [4]. Most systems employ at

41

Rapid Prototyping JournalVolume 2 · Number 3 · 1996 · pp. 41–48© MCB University Press · ISSN 1355-2546

Computational methods for rapid prototyping of analyticsolid models

Rida T. Farouki and Thomas König

The authorsRida T. Farouki and Thomas König are in the Depart-ment of Mechanical Engineering and Applied Mechanics,University of Michigan, Ann Arbor, Michigan, USA.

AbstractLooks at how layered fabrication processes typically entailextensive computations and large memory requirements inthe reduction of three-dimensional part descriptions toarea-filling paths that cover the interior of each of asequence of planar slices. Notes that the polyhedral “STL”representation exacerbates this problem by necessitatinglarge input data volumes to describe curved surfacemodels at acceptable levels of accuracy. Develops ageometrical modelling system that captures and processesanalytic slice representations, based on models boundedby the natural quadric surface. Finds that empirical resultsfrom this system of representative parts systematicallyyield improvements of between one and two orders ofmagnitude in efficiency, accuracy and data volume over anequivalent processing of the STL model. Furthermore,discovers that the analytic form is significantly morereliable, since it is not subject to the geometrical ortopological defects frequently encountered in STL filesgenerated by commercial CAD systems.

This work was supported by the Office of NavalResearch under grant N0001495-].-0767.

least a few offset paths from the boundary ofeach slice to ensure a smooth surface finish.Offsets, rather than hatching, are also bettersuited to building thin-walled “shell” models,and may help to reduce distortion owing todifferential shrinkage as the part cures[5]. Forquadric models, the slices can be representedexactly in piecewise rational Bézier form,although the offsets are not rational and mustbe approximated. In progressing to free-formsurfaces, the capacity for exact (rational) slicerepresentations is also relinquished.

Figure 1 gives an idea of the “data explo-sion” incurred by the STL format in rapidprototyping computations. The constructionof a single offset to a slice through the STL fileof an automotive part is shown. The slicecomprises 235 line segments, most of whicharise in approximations to curved portions ofthe exact boundary. The “untrimmed” offsetis first generated by sweeping a normal vector,of length equal to the offset distance d, aroundthe curve – including appropriate rotations attangent discontinuities. In the present case,this yields a piecewise-linear/circular curve of410 segments.

The true or “trimmed” offset is thenobtained by splitting the untrimmed offset atits self-intersections, and performing distance

tests to the original curve for the resultingsubsegments[6]. Each convex corner of thepolygonal slice curve induces a “fishtail” onthe untrimmed offset, characterized by twocusps and a self-intersection, and hence thetotal number of self-intersections is enormous(many fishtails are so small that they are“hidden” behind the dots identifying self-intersections in Figure 1). Of 10,136 subseg-ments thus generated, only 48 pass the dis-tance test to form the trimmed offset.

The case study shown in Figure 1 is not a“concocted” example – it came to our atten-tion by causing a rapid prototyping systemunder development to crash in the processingof an actual customer part. As corroboratedby the “Implementation and test results”section, much of the “wasted” computationevident in this case may be obviated by usinganalytic, rather than piecewise-linear, repre-sentations for the circular boundarysegments. (The offset trimming may bespeeded up by precomputing the medialaxis[7,8] of the boundary – this is, however, aformidable task in its own right: in the case ofpolygonal boundaries, the medial axis com-prises a graph with linear and parabolic edges,and it includes a linear segment terminating atevery convex vertex of the polygon. )

The remainder of this paper is organized asfollows. In “Geometrical algorithms” we givea brief review of the geometrical algorithmsused in the modelling system. Further detailsconcerning its implementation, and themethodology and comparative results of testson both STL and analytic part representa-tions, may be found in the “Implementationand test results” section. Finally, we summa-rize our results, and discuss issues that arise inextending the present study to a broaderrange of surface types.

Geometrical algorithms

The natural quadrics were selected as thedomain of surface types that the modellingsystem would encompass. This subset of thefull range of quadrics – comprising planes,spheres, cylinders and cones – is capable ofdescribing precisely (modulo blends andfillets) the majority of engineering parts[9,10].The system was implemented with a modular,object-oriented architecture that facilitatessubsequent extension to more general surfaces.Our present intent was to develop a system,commensurate with our limited resources, thatnevertheless encompassed a sufficiently richdomain to offer a realistic perspective for prac-tical engineering applications.

42

Computational methods for rapid prototyping of analytic solid models

Rida T. Farouki and Thomas König

Rapid Prototyping Journal

Volume 2 · Number 3 · 1996 · 41–48

Figure 1 An offset to the polygonal slice through an STLpart

Trimmed offset

Untrimmed offset

Note: The slice curve comprises 235 line segments, whilethe final trimmed offset has just 48 linear and circularsegments. In computing the latter, however, the untrimmedoffset – comprising 410 linear/circular segments – mustbe split at its self-intersections (indicated by dots). Thisyields a total number of 10,136 subsegments!

Unevaluated solid representationsAs our basic three-dimensional part defini-tion, we adopted an “unevaluated” construc-tive solid geometry (CSG) combination ofthree solid primitive types, specified by ele-mentary geometrical parameters (these sufficefor our limited demonstration purposes; othertypes can readily be incorporated):• the sphere is specified by its centre p and

radius r;• the parallelepiped is described by a vertex

p and vectors v1, v2, v3 defining the lengthsand orientations of its edges;

• the (right circular) cone/cylinder is definedby the two centre points p0, p1 and radii r1,r2 of its end caps (the case r1 = r2 gives acylinder).

Even with such simple primitives, exact(rational) boundary representations of solidmodels specified as their Boolean combina-tions lie beyond the scope of CAD systems,since the general intersection of two quadricsurfaces is a non-rational quartic space curve.We take advantage of the explicitly two-dimensional nature of layered fabrication tobypass this problem.

For each sectioning plane, the exact (piece-wise) conic description of every primitive iscomputed, and the Boolean operations indi-cated by the CSG tree are then performed onthese planar section curves. Since the inter-sections of conics may be formulated as rootsof quartic polynomials, this approach is inprinciple capable of yielding exact descrip-tions of each planar section of the three-dimensional part.

Piecewise-conic curve representationsWe adopt the rational quadratic Bézier form

to represent finite conic segments. One mayalways take w0 = w2 = 1, which corresponds toa specific parameterization, in (1) – this thendefines[11] an ellipse, parabola, or hyperbolaaccording to whether w is less than, equal to,or greater than 1. For a circular arc of angularextent φ, the control polygon defined by p0,p1, p2 is symmetric, and w1 = cos 1⁄2φ.Howev-er, although both linear and circular segmentsare subsumed under (1), it is more convenientto represent them by simple geometricalparameters (the end points for a line segment;and the centre, radius and angular limits for acircle segment).

The determination of planar z-sections ofthe solid primitive types listed in “unevaluatedsolid representations” as piecewise-linear/circular/conic curves is relatively straightforward the details will be omitted, since theyare too voluminous for inclusion here. Notethat the form (1) is, in principle, capable ofrepresenting conic arcs of angular extent up to180°. To ensure reasonably uniform parame-terizations, however, segments of extent nogreater than 90° are used – thus, a completeellipse would be represented by four of thesegments (1).

Boolean combination of section curvesThe principal computational problem inperforming Boolean combinations of theprimitive section curves is the determinationof their intersection points. Sederberg andParry[12] have shown that, for cubic or lower-order curves, the most efficient approach is toimplicitize one curve and then substitute theparametric form of the other to obtain aunivariate polynomial equation whose rootsidentify parameter values of the intersections.

Suppose p(s), s ∈ [0, 1] and q(t), t ∈ [0, 1]are two conic segments of the form (1) whoseintersections we wish to compute. If (xk, yk)for k = 0, 1, 2 and w1 are the control-point co-ordinates and weight for p(s), with w0 = w2 =1, its implicit equation may be expressed[11]in the form

Hence, if X(t), Y(t), W(t) are the homoge-neous co-ordinate polynomials for q(t), sub-stituting x = X(t)/W(t) and y = Y(t)/W(t) intothis equation and then multiplying through byW2(t) yields a quartic

The arithmetic procedures for polynomials inBernstein form[13] are used in constructingthis equation, to enhance the numerical stabil-ity of its roots[14]. A quartic may be solved byradicals[15], but numerical schemes – basedon the subdivision and variation-diminishingproperties of the Bernstein form[16] – areoften more efficient in practice (in particular,the absence of roots on t ∈ [0, 1] can rapidly bedetected). Note also that sufficient conditionsfor guaranteed convergence of Newton-

c t c t t c t t

c t t c t

04

13

22 2

33

44

1 4 1 6 1

4 1 0

( – ) ( – ) ( – )

( – ) .

+ +

+ + =

f x y x x x

y y y

w x x x

y y y

x x x

y y y

( , )

– . ( )

=

=

1 1 1

4

1 1 1 1 1 1

0 2

0 2

0 2

2

12

1 2

1 2

0 1

0 1

r( )

( – ) ( – )

( – ) ( – ),

[ , ] ( )

u

w u w u u w u

w u w u u w u

u

=

+ ++ +

0 02

1 1 2 22

02

1 22

1 2 1

1 2 1

0 1 1

p p p

43

Computational methods for rapid prototyping of analytic solid models

Rida T. Farouki and Thomas König

Rapid Prototyping Journal

Volume 2 · Number 3 · 1996 · 41–48

Raphson iterations may be expressed[17] interms of sign variations in the Bernstein coeffi-cients and their differences. A switch fromsubdivision to Newton’s method, once theconditions are met, yields a root-finding algo-rithm that is efficient, accurate and robust.

In order to qualify as an intersection of thefinite segments p(s), s ∈ [0, 1] and q(t), t ∈ [0,1], a root t∗ on[0, 1] of the above quartic mustcorrespond to a parameter value s∗ along theother conic that also lies on[0, 1]. Writingq(t∗ ) = (x∗ , y∗ ), the parameter value s∗ of theintersection point on p(s) is given by the“inversion” formulae

where (xk, yk) for k = 0, 1, 2 and w1 nowdenote the control points and weight for p(s),again with w0 = w2 = 1 (the equality of the twoexpressions in (3) follows from the fact thatthe point (x∗ , y∗ ) must satisfy equation (2)).

Another approach to finding s∗ is to repeatthe intersection calculation with the roles ofp(s) and q(t) swapped, but this is obviouslyless efficient than using the above inversionformulae. For further details on computingparametric curve intersections by implicitiza-tion and inversion, see [18]. The intersectionalgorithm is, of course, subject to simplifica-tions if either curve segment is linear or circular, and bounding-box tests can helpbypass cases in which there are obviously nointersections.

Once all intersection points of the primitiveslice curves are determined, the curves aresplit at these points. The slice boundary forthe entire model comprises a subset of thesesplit primitive slices. The portions to beretained can be identified by containmenttests as one traverses the CSG tree. On assem-bling them into a system of oriented, nestedloops, one obtains directly an exact represen-tation of the slices as piecewise-linear/circu-lar/conic curves from the analytic modeldescription (see also “Implementation andtest results” below for further details).

Area filling with offset curvesIn addition to computing slices through themodel, most rapid prototyping processesrequire the interior of each slice to be filled bypaths along which a laser beam, nozzle, orother device will be driven. A variety ofapproaches, including offsets from the sliceboundary, zigzag paths and rasterization ofthe slice area, are in use. We focus on comput-ing offset curves; see [4] for a discussion oftheir applications and advantages in rapidprototyping.

The (untrimmed) offset at distance d froma curve r(u) is defined by

where n(u) is the unit normal to r(u). Piece-wise-linear/circular curves have offsets thatare likewise piecewise-linear/circular. Howev-er, for more general curves the offsets do nothave exact (i.e. rational) representations, andmust be approximated. This is true even ofthe conics, with the sole exception of parabolae,which Lü[19] has shown to have rational offsetsof degree six (the construction of their exactrepresentations is rather involved; see [4]).

We have adopted an approach in which theoffsets to general conics are approximatedusing conics, as suggested in [20] and furtherelaborated on in [21]. This has the majoradvantage that, when the self-intersections ofthe untrimmed offsets are computed in thetrimming procedure, we may invoke exactly thesame algorithms as used in “Boolean combina-tion of section curves” for the Boolean combi-nations of the primitive slices (see [6] for detailson trimming offset curves). A conic has, ingeneral, five degrees of freedom. The approxi-mant to (4), for any conic segment r(u), isdefined as the unique conic that interpolatesthe two end points and end tangents of rd(u),and also its parametric mid-point.

The offset segment is guaranteed to besmooth if, as a preprocessing step, we splitr(u) at points where its curvature attains the“critical” value k(u) = –1/d[21]. The schemethen gives approximants with O(h5) conver-gence to the exact offset[22], where h is ameasure of the “size” of r(u).

The construction of the conic approximantr(u) to the offset of (1) at any distance d isrelatively straightforward. The two endcontrol points are given by p0 = p0 + dn(0)and p2 = p2 + dn(1), while the middle control point p1 is the intersection of linesdrawn through p0 and p2, parallel to p1 – poand p2 – p1. Finally, denoting the co-ordi-nates of rd(

1⁄2) = r(1⁄2) + dn(1⁄2) by (xm, ym), themiddle weight w1 is the positive value definedby[21]:

r r nd u u d u( ) ( ) ( ) ( )= + 4

12

1 1 1

1 1 1

12

1 1 1

1 1 13

1

1 2

1 2

0 2

0 2

1

0 2

0 2

0 1

0 1

( )

ss

w

x x x

y y y

x x x

y y y

w

x x x

y y y

x x x

y y y

∗=

=

44

Computational methods for rapid prototyping of analytic solid models

Rida T. Farouki and Thomas König

Rapid Prototyping Journal

Volume 2 · Number 3 · 1996 · 41–48

(and, as usual, we take w0 = w2 = 1).A rigorous characterization of the geometri-

cal error incurred by this offset approximationscheme is described in[21]. Thus, by adaptivesubdivision, the approximants may be made tosatisfy any prescribed tolerance. Ordinarily,however, quite high accuracy (fractional dis-tance errors ~< 10–3) is attained without theneed for further subdivision beyond that usedto split the conic segments at points wherek(u) = – l/d, as discussed above.

Implementation and test results

The guiding principle in the design of oursystem was the concept of an open architec-ture, i.e. the core functionality should not bespecific to a limited set of curved surfacedprimitives, but should rather be extensible forfuture enhancement. In particular, it should beextensible in such a manner that no changes tothe core algorithms and data structures arenecessary when introducing new curve types.This goal was accomplished through the use ofobject-oriented programming methods.

Processing of solid modelsAs noted above, the efficiency and exactnessof our modelling system result from the factthat nearly all the geometrical computationsare performed on 2D entities. An unevaluated3D solid representation (such as a CSG model)is processed according to the following steps:(1) compute planar slice contours of the

individual primitives that define the part;(2) perform Boolean combinations of these

contours to obtain the boundary of a slicethrough the entire part;

(3) calculate a family of offset curves to theslice boundaries to fill their interior area.

The input data for the system may be either aCSG representation or a part-build history, asmaintained by many commercial CAD/CAMpackages. In our implementation, the calcula-tion of the primitive slice curves is performedas a preprocess step. Since all primitivesdescribe closed volumes, these slice curvesform closed loops in the 2D domain. Aschematic structure of the input format,except for various identifiers that are needed

to associate individual loops with informationon the Boolean combinations, is as follows:

(number of layers for entire part)[FOR ALL LAYERS](number of loops in layer)(topology information)[FOR ALL LOOPS ](number of segments in loop)(geometry data).

Example processing of a modelThe 2D section through an entire part isrepresented by a hierarchy of closed loops,with each loop comprising a set of contiguoussegments and associated topology data. Seg-ment types supported in the current imple-mentation are lines, circular arcs and rationalquadratic Bézier curves – all plane sections ofthe natural quadrics can be described exactlyby these types. Our C++ implementationallowed these “curve segments” to be definedas derived types of an abstract base class. Allthe algorithms work on references to instancesof that base class, a technique known as poly-morphism in object-oriented programming.Hence, all algorithmic aspects are readilyextensible to new curve types without incur-ring major changes to the system.

We use the part shown in Figure 2 to clarifythe various steps involved in the processing ofa 3D solid model. To reveal its internal struc-ture, Figure 3 shows a vertical section cutthrough a wireframe representation of thepart. A total of 17 primitives (namely, sevenparallelepipeds, nine cylinders and one cone)were required to model the part. The primi-tives are defined in terms of basic dimensionaland orientation parameters (see “Unevaluat-ed solid representations”), i.e. sufficientinformation for obtaining their cross-sections.

w

x x x

y y y

x x x

y y y

x x x

y y y

m

m

m

m

m

m

12

0 2

0 2

2

1 2

1 2

0 1

0 1

1 1 1

4

1 1 1 1 1 1=

45

Computational methods for rapid prototyping of analytic solid models

Rida T. Farouki and Thomas König

Rapid Prototyping Journal

Volume 2 · Number 3 · 1996 · 41–48

Figure 2 Hidden line view of the valve part

We shall call this model, a simplified form ofpart geometry found in vacuum machinery,the “valve” part.

The contours shown in Figure 4 areobtained from plane sections of all the primi-tives at a specific height (in this case, the heightof the inner ring in the part). These contoursare then intersected and merged according tothe specified Boolean operations: curve seg-ments are split into subsegments at the inter-section points, and the subsegments that formthe final boundary, as shown in Figure 5, aredetermined by containment tests.

The Boolean combination process is essen-tially exact – its accuracy is limited only by thetermination criterion used in the Bernsteinpolynomial root solver (used in intersectingrational quadratic Bézier curves); in ourimplementation a tolerance of 10–12 was used.In the final step, the interior of the part slice isfilled by offset curves. The resolution of thisstep can also be fine-tuned – depending onthe ratio of the offset distance to the curvatureof the conics, their offsets are approximatedby one or more conic segments as described in“Area filling with offset curves” (examples ofthis may be seen in Figure 6).

Representative resultsPresented now comparative performance datafor two relatively simple parts that are repre-sentative of improvements we observe usingthe analytic model in lieu of the STL model.The “valve” part has already been describedabove; see Figures 2 and 3. The “connector”part, illustrated in Figure 7, comprises tenprimitives (namely, four parallelepipeds, fivecylinders and one cone). A sequence of planarsection cuts through this part is shown inFigure 8.

STL descriptions for these two parts weregenerated by modelling them in AUTOCADand using its STL-file generator. Unfortu-nately, no means was available to assess quantitatively the accuracy of the polyhedral

46

Computational methods for rapid prototyping of analytic solid models

Rida T. Farouki and Thomas König

Rapid Prototyping Journal

Volume 2 · Number 3 · 1996 · 41–48

Figure 4 Planar slices through primitives for the valve part

Figure 5 Resolved Boolean combination of primitive slicesfor the valve part

Figure 6 Area of slice through the valve part filled withoffset curves

Figure 7 Wireframe view of the connector part

Figure 3 A vertical section cut through the valve

models thus generated. It was deemed thatthe default STL output from AUTOCAD wasof only “average” accuracy – the valve partcomprised 1,130 triangular facets, while theconnector had 638. The faceted nature of theSTL representations was clearly apparent incomparison with the analytic models.

Approximately 40 equidistant slices throughboth the analytic and STL models were com-puted – note that Boolean combinations arerequired only for the analytic models. A prob-lem immediately encountered was that is notuncommon with STL files generated by com-mercial CAD systems, namely, geometricaland/or topological defects that prevented theslicing procedure from computing valid sectioncurves for a few slices (the analytic models, onthe other hand, proved very reliable in thisrespect – no failures were observed in slicingthem). To ensure a “fair” comparison, slicesthat failed with the STL model on a trial runwere flagged to be subsequently bypassed inthe processing of both the STL and analyticparts when compiling the performance data.The successful slices were then filled withoffset curves, at increments such that eachlayer required about 12 offsets to cover its area.Note that, other than slicing, the same algo-rithms and same implementation are used inprocessing both the STL and analytic models.

Tables I and II summarize the performancemeasurements for both part descriptions inthe following categories:(1) the total cpu time for computing the slices

and filling them with offsets;(2) the size of the input file describing the 3D

part geometry;(3) the size of the output file describing the

entire set of offset paths for all slices; and(4) the geometrical error of the slices.

These data are meaningful only in a relativesense, since much depends on specifics of theimplementation, the compiler and the com-puter. These tables also indicate the percent-age reductions in cpu time, data volume andgeometrical error that the analytic modelsachieve over the STL representations.

It is evident that the analytic representationoffers very significant benefits in every

respect. The disparity between the input andoutput data volumes is especially dramatic,amounting to a reduction by about two ordersof magnitude! The analytic models also incurprocessing times about one order of magni-tude smaller than the STL files. These factorswould, of course, be even more dramatic if“accurate” STL models – involving furthertriangular facets – were used (note that,whereas the time taken to slice the STL fileincreases in proportion to its accuracy, itremains constant for the analytic model).

Concluding remarks

The principal virtues of the STL file, current-ly established as the standard means of repre-senting part geometry in rapid prototyping,are its simplicity, portability and ease of inter-pretation. These come at the price of ratherpoor accuracy, large input/output data vol-umes and high computational expense. More-over, the algorithms used in many CADsystems to tesselate three-dimensional modelsinto STL files are of mediocre reliability,necessitating the use of “clean-up” proce-dures before the files can be downloaded.

We have shown that, for parts bounded byelementary (planar, spherical, cylindrical andconical) surfaces, dramatic improvements incpu time and memory requirements can berealized through the adoption of analyticalpart representations. Moreover, this approachoffers “perfect” accuracy – each slice isdescribed exactly – and the unevaluatedmodel representation, based on CSG combi-nations of quadric primitives, transpires to bemore “robust” than the STL files obtainedfrom a commercial CAD system.

Our present results are, of course, specificto models describable in terms of naturalquadric surfaces. While the bulk of the dataembodied in STL files of typical engineering

47

Computational methods for rapid prototyping of analytic solid models

Rida T. Farouki and Thomas König

Rapid Prototyping Journal

Volume 2 · Number 3 · 1996 · 41–48

Figure 8 Planar slices through the connector part Table I Test results for the connector part

STL model Analytic model % reduction

Cpu time (sec.) 615 69 88.8Input data (kB) 176 0.98 99.4Output data (kB) 13,308 100 99.2Error (mm) Indeterminate 0 100

Table II Test results for the valve part

STL model Analytic model % reduction

Cpu time (sec.) 2011 167 91.7Input data (kB) 312 1.74 99.4Output data (kB) 13,141 290 97.8Error (mm) Indeterminate 0 100

parts is probably incurred in approximatingspherical, cylindrical and conical surfaces bytriangular facets, one cannot discount theimportance of blend surfaces, surfaces ofrevolution, free-form surfaces, and “amor-phous” geometries in many (e.g. biomedical)application contexts. Unfortunately, thisextended domain of surface types does notadmit exact slice representations, and analyticmethods must be based on carefully craftedapproximation schemes, in which accuracy isbalanced against speed and data volume. It isuncertain whether, in this domain, improve-ments as significant as those observed for thenatural quadric models will be attained.

As a practical means for taking advantageof the results reported herein, we suggest anextension of the STL format to allow for:solids defined by CSG combinations, ratherthan just “evaluated” boundary representa-tions; and inclusion of quadric primitives,described by elementary geometrical parame-ters, in addition to the polyhedra. This strate-gy would circumvent the wasteful aspect ofSTL files – using large amounts of data toapproximate simple surfaces – while stillretaining their “flexibility” for more compli-cated surfaces. Our investigations havedemonstrated that the algorithms required toprocess such a representation are implement-ed easily and reliably, and can be expected toyield significant benefits.

In extending the present work to free-formsurfaces, a promising idea is to employ thePythagorean-hodograph curves – which admitexact rational offset representations[23] – inthe slicing algorithms. This can be expectedto yield significant reductions in cpu time anddata volume, especially with the developmentof real-time CNC interpolators[24] for suchcurves, that allow the curve coefficients to bedownloaded directly to the machine (ratherthan being first approximated by linear andcircular segments, as most CNC interpolatorscurrently require).

References

1 Ashley, S., “Rapid prototyping is coming of age”,Mechanical Engineering, Vol. 117 No. 7, 1995, pp. 62-8.

2 Jacobs, P.F., Rapid Prototyping and Manufacturing:Fundamentals of Stereolithography, SME, Dearborn,MI, 1992.

3 Abrams, S.R., Batchelder, J.S., Farouki, R.T., Korein,J.U., Korein, J.D., Mackay, J., Srinivasan, V. and Taraba-nis, K., A Method for Fabricating Mechanical Parts andModels by Shelving, US Patent application, IBMDocket YO994-006, 1994.

4 Farouki, R.T., König, T., Tarabanis, K., Korein, J.U. andBatchelder, J.S., “Path planning with offset curves for

layered fabrication processes”, Journal of Manufac-turing Systems, Vol. 14, 1995, pp. 355-68.

5 Jacobs, P.F., “The role of rapid prototyping andmanufacturing”, in Machover, C. (Ed.), The CAD/CAMHandbook, McGraw-Hill, New York, NY, 1996, Ch. 10.

6 Farouki, R.T. and Neff, C.A., “Analytic properties ofplane offset curves” and “Algebraic properties ofplane offset curves”, Computer Aided GeometricDesign, Vol. 7, 1990, pp. 83-99, 100-27.

7 Held, M., On the Computational Geometry of PocketMachining, Springer Verlag, Berlin, 1991.

8 Persson, H., “NC machining of arbitrarily shapedpockets”, Computer Aided Design, Vol. 10, 1978, pp. 169-74.

9 Hakala, D.G., Hillyard, R.C., Nourse, B.E. and Malrai-son, P.J., “Natural quadrics in mechanical design”, inProceedings of Autofact West 1, Anaheim, CA, 1980,pp. 363-78.

10 Samuel, N.M., Requicha, A.A.G. and Elkind, S.A.,“Methodology and results of an industrial partsurvey”, Tech. Memo No. 21, Production AutomationProject, University of Rochester, Rochester, NY, 1976.

11 Farin, G., Curves and Surfaces for Computer AidedGeometric Design, 3rd ed., Academic Press, Boston,MA, 1993.

12 Sederberg, T.W. and Parry, S.R., “Comparison of threecurve intersection algorithms”, Computer AidedDesign, Vol. 18, 1986, pp. 58-64.

13 Farouki, R.T. and Rajan, V.T., “Algorithms for polyno-mials in Bernstein form”, Computer Aided GeometricDesign, Vol. 5, 1988, pp. 1-26.

14 Farouki, R.T. and Rajan, V.T., “On the numericalcondition of polynomials in Bernstein form”, Comput-er Aided Geometric Design, Vol. 4, 1987, pp. 191-216.

15 Uspensky, J.V., Theory of Equations, McGraw-Hill,New York, NY, 1948.

16 Lane, J.M. and Riesenfeld, R.F., “Bounds on a polyno-mial”, BIT, Vol. 21, 1981, pp. 112-17.

17 Farouki, R.T., “Computing with barycentric polynomi-als”, The Mathematical Intelligencer, Vol. 13, 1991,pp. 61-9.

18 Sederberg, T.W., Anderson, D.C. and Goldman, R.N.,“Implicitization, inversion, and intersection of planarrational cubic curves”, Computer Vision, Graphics,Image Procession, Vol. 31, 1985, pp. 89-102.

19 Lü, W., “Rational offsets by reparameterizations”,unpublished manuscript, 1992.

20 Farin, G., “Curvature continuity and offsets forpiecewise conics”, ACM Trans. Graphics, Vol. 8, 1989,pp. 89-99.

21 Farouki, R.T., “Conic approximation of conic offsets”,Journal of Symbolic Computations, forthcoming.

22 Degen, W.L.F., “High accurate rational approximationof parametric curves”, Computer Aided GeometricDesign, Vol. 10, 1993, pp. 293-313.

23 Farouki, R.T., “Pythagorean-hodograph curves inpractical use”, in Barnhill, R.E. (Ed.), GeometryProcessing for Design and Manufacturing, SIAM,Philadelphia, 1992, pp. 3-33.

24 Farouki, R.T. and Shah, S., “Real-time CNC interpola-tors for Pythagorean-hodograph curves, ComputerAided Geometric Design, Vol. 13, forthcoming.

48

Computational methods for rapid prototyping of analytic solid models

Rida T. Farouki and Thomas König

Rapid Prototyping Journal

Volume 2 · Number 3 · 1996 · 41–48