Download as pdf
Download as pdf
You are on page 1of 18
Types and Mathematical Representations of Curves 4.1 = INTRODUCTION CAD tools have been defined in Chapter 1 as the melting pot of three disciplines: design, geometric modeling and computer graphics, While the latter discipline is covered in Part III, this part discusses geometric modeling and its relevance to CAD/CAM. Early CAD/CAM systems focused on improving the productivity of drafismen, More recently, they have focused on modeling engineering objects. As a result, geometric models that once were more than adequate for drafting purposes are not acceptable for engineering applications. A basic requirement, therefore, is that a geometric model should be an unambiguous representation of its correspond- ing object. That is to say, the model should be unique and complete to all engineer- ing functions from documentation (drafting and shading) to engineering analysis to manufacturing. ‘A geometric model,of an object and its related database have been defined in Chapter 3. The three types of geometric models, wireframes, surfaces and solids, are covered in Chapters 4, 5 and 6 respectively. Each chapter presents the available types of entities of the modeling technique and their related mathematical representations to enabl standing of how and when to use these entities in engineering application have to decide on the type of modeling technique based on the ease of usit 136 = CAD/CAM : ase and during the construction phi eae database later in the design an : user constructs a object data as required Dy oftware. The sof geometric mode technique, the “ aE tem by inputting the re rovided by the s¢ user interface P into a mathematical rep The user may retri¢ resentation which it stores 19 ©) Vor modify the model d eve anc use manufactring Proce «of geometric modeling to the CADICAM 5, eae to other engineering disciplines and make the followin Geometric modeling to CAD/C AM is as importal ae oe i to classical engineering fields as mechanics and thermal fluids f view, modeling of objects is by itself unimpor: le useful engineering analysis and judgmen: s, ffort a designer spends in crez s utilized equations i an engineering point of it is a means (tool) to enable us matter of fact, the amount of time and el ate geometric model cannot be justified unless the resulting database applications module discussed in Chapter. 3. ; . The need to study the mathematical basis of geometric modeling is m: From a strictly modeling point of view, it provides a good understandi: terminology encountered in the CAD/CAM field as well as CAD/CAM sy documentation. It also enables users to decide intelligently on the types necessary to use in a particular model to meet certain geometric require: such as slopes and/or curvatures. In addition, users become able to interpret = unexpected results they may encounter from using a particular CAD/CAMs) Moreover, those who are involved in the decision-making process and evaluzt: of CADICAM systems become equipped with better evaluation criteria. From an engineering and design point of view, studying geometric model provides engineers and designers with new sets of tools and capabilities that can use in their daily engineering assignments. This is an important issue bec historically, engineers cannot think in terms of tools they have not learned 0% oF been expoved to, The tools are powerful if utilized innovatively in engine? pti Nt is usually left to the individual imagination to apply thes? © y ; i ly tapi tions in a new context. For example, the mere fact that ca 1M database ‘are centralized and associative provides great capabilities thet wilized 1n See, 4.8 of this chapter. These capabilities are usually more eftc®* Cae nt and plotting programs on conventional computers. prone, lipitshed the need for eometsie modeling, what is the most 8 Anwar Wo this ae nog applications? Unfortunately, there is n° ny this bone, the hs H Me it heless, the following answer may be offere® (Hl prem edit tw levels, Atone level, en Jett ep ntdtted to carry engine a wn yan procedur 016 OH ci He HO model the OH Hunted ce comNpone Ce HH HOTHED Oveani incers may agree thats. ng analysis, The degree of geome that utilizes the geometry. Engin At is sufficient to study ail beh), Ml or a system. A machine part, for exam ini body on one oceasion or as a disttib™ On, ical Representations of Curves. & 137 evel. the adequacy of ae ‘ometry or a geometric model to an ided by its related useful attributes to that procedure. issue for manual procedures because the dinates all the related facts and information. In computer- sis, attributes attached to geometric models determine clevance to design, analysis and manufacturing. Current geometric models eed by CAD/CAM systems seem to have adequate and enough geometric and on (colo ades) attributes. Based on these attributes, they are scessfully in applications such as mass property calculations, mechanism : finite elem ent modeling and NC. If these attributes are insufficient or te reorganized for other applications. then new software must be written 2 the existing database structure of the geometric model which may be sed to accept new attributes: or a completely new structure may: have to be ed. In conclusion. the study of existing geometric models provides and engineers with the capabilities and limitations of these models and for them to utilize the attributes of these models or create new relev chapter covers the available types and most useful mathematical cecentations of curves. Sections 4.1 through 4.7 cover the basic related topics. ‘a 4.8 applies these topics to design and engineering applications to crate their usefulne: WIREFRAME MODELS ‘A wireframe model of an object is the simplest, but mose verbose, geometric model that can be used to represent it mathematically in the computer, It is connstimes referred t0 as a stick figure or an edge representation of the object. The word “wireframe” is related to the fact that one may imagine a wire that is bent to follow the object edges to generate the model, Typically, a wireframe model consists entirely of points, lines, arcs and circles, conics and curves. Wireframe modeling is the most commonly used technique and all commercial CAD/CAM systems are wireframe-based. Early wireframe modeling techniques developed in the 1960s were strictly two dimensional and were designed to automate drafting and simple NC. Two- dimensional wireframe models ‘contained enough useful information to perform the NC work. Users had to construct geometry in the desired various views independently due to the Jack of centralization and associativity of the resulting database, Later in the early 1970s, the centralized associative database concept enabled modeling of three-dimensional objects as wireframe models that can be subject to three-dimensional tran formations. Creating geometry in one view is automatically projected and displayed in other views. ‘This represents a substantial saving and flexibility over manual design and drafting. In constructing a wireframe model on a CADICAM system, the user should follow the modeling guidelines discussed in Chapter 3. The detailed step-by-step procedures to create models may vary according to system capabilities and the user’s individual habits. In addition to the commands required to create the common wireframe entities, users are provided with other tools that facilitate the “ANA oryand Practice 138 CADICAM Thee nie in detail. The ! covers these (06 + MESE toot, pant TV of the book : : © tool, made! conetnction, Part T retry ag well as 10 avoid unnecess. 1 manage peom \ ‘ in general. belp 7 Ga mp ADICAM ayatems provide Users With pogip ample. tpt ealentatians Bar ek ly cal, of spherical, Y andinatee: cartesian, cylindric ae en wu Each mop, three eters to tn CS pana, Hapikett iegnit ecmule be psoute oF increment "Mi ie" KA fee eapicdt on implic iinvotuce nce digiti7es Another , ip ' Boome, ccvatiniaten tint inhi dontify epecific locations such as end OF midtprjn: ty id pee which murtevyntie + : rien fees ey . sonveniont ty aceees ONCE these entities ate created by 4) at entities that are Ce agate e advantage of wireframe mod Deapite ite mnny disadvantages, aes ee ae Hate rig ae ee I modeling. However. the user or termiye ae ae ada input data is substan ial and increases rapidly with bai oan i al sa object being modeled. Wireframe modeling is considereg 4 ean icin of traditional methods of drafting. Consequently it des : require extensive training of users; nor docs it demand ae of unusuaj terminology as surfaces and solids. Wireframe models form the basis for surface models Most existing surface algorithms require wireframe entities to generate | surfaces (refer to Chap. 5). Lastly, the CPU time required to Tetrieve, edit, of | update a wireframe model is usually small compared to surface or solid models The disadvantages of wireframe models are manifold. Primarily, these models «are usually ambiguous representations of real objects and rely heavily on humas interpretation, A wireframe model of a box offers a typical example where the mode} may represent more than one object depending on which face(s) is assumed to exist Models of complex designs having many edges become very confusing and perhaps even impossible to interpret. To overcome this confusion, lines cat be tidden, dashed, or blanked. If done manually, these operations are very tedious error-prone and can result in “nonsense” objects. Automatic hidden line removal algonthms base as the lack of vi ‘d on Wireframe modeling are usually helpful. Another disadvantaz? ‘sual coherence and information to determine the object pro ‘The obvious example is the representation of a hole the hole length. Some systems ma : systems may connect a line bel e two circles & one side of the hole In many between the two cite Y cases, users add edges of the hole for appear ¥ use a cylindrical surface to cepreseat cr on during the model cle: up phase between the hole cine Pets tend (0 attempt to create tage il | ength, width and height # vy COOrds ane rdinates of at least four corners” ¢ ypes and Mathematical Representations of Curves VW face, the depth and the edge connectivity are required compidesing, the hon Wi 4 Foandsi-hall-dimensional abject. In other wards, both topological aud Momettical data are needed 10 constct yaireframe models vile wali euiTe only geometrical data Geter to Chap. 6 for the difference between topology and geometry). I addition, WCSs and construction plines always need 10 be defined facilitate model constrnetion as) LIN (a) No edges displayed (hb) One edge displayed (0) Uner-createh gps tof Fig. 41 Displaying Holes and Curved Ends in Wireframe thodele From an application and consequently engineering, point of view, wirelrame models are of limited use. Unless the object is two-and-a-half dimensional, volume and mass properties, NC tool path generation, cross" ectioning and interference detections cannot be calculated, The model can, however, be used in manual finite clement modeling and tolerance analysis. Despite the above-mentioned limitations, wireframe models are expected to last and may extend to certain classes of solid modeling, For example, some solid modelers (such as Medusa) are based on wireframe input. The simplicity of the geometrical concepts based on wireframe modeling makes them attractive to use to introduce users to the CADICAM field. In addition, at carly design stages, designers might just need a sketchpad (0 try various ideas, Wireframes are ideal toprovide them with such a capability. From an industrial point of view, wireframe models may be sufficient to many design and manufacturing needs. From a practical point of view, many companies have large amounts of wireframe databases that are worth millions of dollars and man-hours and thefefore make it impossible to get rid of wireframe technology. 4.3 WIREFRAME ENTITIES Allexisting CAD/CAM systems provide users: with basic wireframe entities which can be divided into analytic and synthetic entities. Analytic entities are points, fines, arcs and circles, fillets and charters and conics (ellipses, parabolas and hyperbolas), Synthetic entities include various types of spline [cubic spline, B-spline, /(beta)-spline, vinu) spline] and Bezier curves The mathematic: properties of each ity and how its used in engineering applications or converted Inte a acer interface are covered in the remainder of the chapter It is quite common for a user wo be faced with many modifiers that can be used to create a particular entity on a particular CAD/CAM system Knowledge of the basics of buch an entity can only increase user productivity. Choosing the proper modifier for a given input can save unnecessary calc ulations, Also, knowing a curve behavior in relation to its input data can wave time trying to achieve the impossible. 140 & CAD/CAM Theory and Practice . 4.1 to 4.5 show the most common melons Ula" by CADICA Tables hone wireframe entities, Readers are advised compare a systems 2 “ methods to what their respective systems of er and what eee he systems require, As an example, defining a POINE usin, eae . i equires the “END" of “PND (point end)’ modifier on y endpoint aan . ene regpectively, Such similarities among Systeme Ren Jers ce also advised to find commands corresponding to these tables «, ir partoular CAD/CAM systems. The following are some ee \0 lust using wireframe modeling techniques. These cxamples are in pa lent of any eystem or user interface and readers can simply convert them into a commang sequence of their choice. Mey us Table 4.1 Methods of Defining Points Explicit methods Implicit methods 1. Absolute cartesian co-ordinates my +Px,y.2) +d A digitize d (with or without an active grid) Coordinates of resulting point can be obtained by using the “verify” command, i Coordinates are measured relative to the 7 's dis sed in Chap. 3 2. Absolute cylindrical coordinates { PUR, @,2) ly a A , Endpoint of an existing entity? (Spherical coordinates are seldom used in practice) 3 Incremental canerian Pid Aaya by. coordinates Ay Keferpnce pomt Po (4, y, 2) Table 4.1 (Contd) explicit methods Implicit methods 4 “Incremental cyTindtical coordinates Intersection point of two existing entiiest TiR+ AR, 04.40) an Lay ‘Reference point M9 (RM TF - 1 Rome CADICAM systems require moving the current WCS to the reference point Py to avoid unexpected reeults) See. 10.2. Chap. 10. 4 More details: of these methods are covered it Table 4.2 Methods of Defining Lines Method Illustration 1. Points defined by any method of Table 4.1 2 Horizontal (parallel to the X ‘axis of the current WCS) or te e Xe vertical (parallel to the Y' axis, =e of the current WCS) + ' th ae ow 3 Parallel or perpendicular to an existing line 4. Tangent to existing entities a : Ces \_ Orne of das Hoe prrwaitnclatiees ber bined depending on vane digiiace UE ve Gu sidele® a Ones oi ts Soe pwosibililiss lo ubiatned CAD/CAM Theory and Practice Table 4.3 Methods of Defining Illustration 142 Ares and Circles lethod 2 Three points defined by any method of Table 4.1 1. Radius or diameter and center. In the case of an are, beginning and ending angles @, and 8, are required SS 3. Center and a point on the circle + Tangent to line, pass through a given point and with a given radius "el Table4.4 Methods of Definine Fifi, a De i haeae of Defining Ellipses and Parabolas Mlustration 1 Ellipses (4) Center and axes Jengths (%) Four points (cy) ji )T Wo conjugate diameters Types and Mathevnation! Representations af Chegee BE Ua Tabled (Contd) is Methods : Ulastrationt 2 Parabolas fa) Vertex and focus (d) Three points Method Mlustration ry 1. Cubic spline A given set of data points and 4 3. B-spline curves (a) Approximate a given set of data points (b) Imerpolate a given set of data points 45 PARAMETRIC REPRESENTATION OF ANALYTIC CURVES This section covers the basics of the parametric equations of analytic curves that & most widely utilized in wireframe modeling. These developments are related, whenever possible, to the common practice encountered on CAD/CAM systems. This should enable users to fully realize the input parameters they deal with and Usually find in system documentation. It should also help developers who may be ‘Olerested in writing their own CAD/CAM software. __ Parametric equations and their developments are presented in vector form, The benefits of the vector form include developing a unified approach and Consistent notation to treat both two-dimensional and three-dimensional curves In addition to yielding concise equations that are More convenient to program ae 160 4.5.2 = CAD/CAM Theory and Practice Lines i es are derived here with yy, equations of straight cat vane cap ee een nd. Es how is a tine equation co estion mind, First, he questions in he two endpoints oy Jatabase which is ata minimum att » the line databa software into the tone t i ec (is offered by common “a Jifiers available with line command: various modifi He with Tine eo it fe faces? Consider the following two c interfaces 1 Fhe te User re i 8 equation corres mathematical requirements of an om Second, how at ‘ig. 4.14, Jefine ints P, "a as shown in Figs. 4.14. Define , line conneeting two points P, and Ye d tan? pe “tbe er w sch that it has the values 0 an parameter 1 s Ctively i a can be written; the triangle OPP,, the following equation can be w 7 Utilizing eee - , } the veeter (P — P,) is proportional to the vector P 2 ~ P; such However, 1 “ (4.10 P-P,=«P,-P,) ) unt Pia Fig.4.14 Line Connecting Two Points Pyand 4 +(e ~ 2) Equation (4.11) defines a tin ne bounded by the endpoints Py and P, whose “sociated parametric values are ( | respectively, Any other point of the line or its extension has « certain value of POINt Joe; ee c ¢ “which is Proportional to " Coordinates of any point it a “orresponding w value in Eq. (4.1): The Hon, as Fig. 4.15 shows. 4 ned by sub tituting the figure are obtain Types and Mathematical Rep: sof Curves 2 161 The tangent vector of the line is given by P=P,-p, (4.13) or, in scalar form, (4.14) ‘The independence of the tangent vector from 1 reflects the constant slope of the straight line, For a two-dimensional line, the known infinite (vertical line) and zero (horizontal line) slope conditions can be generated from Eq. (4.14). ‘The unit vector ii in the direction of the line (Fig. 4.14) is given by wa-1S Fig. 4.15 Locating Points on an Existing Line s of the user input to create a line, a line database stores its ‘additional information such as its font, width, color and and (4.13) show that the endpoints are enough to jes and characteristics of the line. They are vie sufficient to construct and display the line, For reference purposes, CADICAM software usually identities the Tirst point input by the during line construction as P,, where 0, Me se Ce anes programmed into @ subroutine that can reside ina graphics library of the defame end which oan dre carokacartin ce tiset dnieiiage, to. consiiict lines. Point commands (or definitions) on most systems prov ide users, with a modifier to specily a value rekative oan entity 0 are on it, In the case of a fine, the value is substituted into Eq. C4. UL) to find the Alin Sen point P; ina direction defined by the unit vector a i C16). Ca e | is considered the basic method to create a line because Fig. 4.16). Case | is cons Regardles: two endpoints and layer. Equations (4.11) provide all geometric propert CAD/CAM Theory and Practice 162 y with the two endpoints. This, ASC ang ase direct! 2 Use les the Hine database dire endpoints from the user input or ies in generating the esull others usually rest ; given data, as disenssed below Ty develop the Tine equation ; the ine at a distanee Z from Py. The for this case, consider a general point pg, vector equation of the line becomes (woe triangle OPP) P]ePpah osbso (4.17) and Lis given by P-Pl (4.18) Lis the parameter in Eq. (4.17). Thus, the tangent vector is n. Once the user inputs P,, i and L, the point P is calculated Using Bq. (4.17) and the line has the two endpoints P, and P with w values of 9 and 1 as discussed in case 1. : i ‘The following examples show how parametric equations of various line forms can be developed. The examples relate to the most common line commands offered by CAD/CAM software. P ya equations al. Each Line begins e1Ven point and endpoints o fF Wo Lin i! es, one ata at and passes t S, one horizo Mrough a given point and is Solution Horzontal an WCS axes. Horizontal fin Y axis. Figure 4.17 sho differen orientation troy nd Vertical lines are y ually doting # vena ed in ve Fe aut Parallel tothe X axis and mene ference to the current SS OPICal User Working envine etl fies are parallel tothe mthe MCS. Inui se uMEAL Where the WCS has 8 case, the Woe ett he WCS ha bhai 'e WCS isequivatent to the conndinate © the endpoints tons, Ones S tre calculated from ine display or storage, "they are transformed tg the Mes before the Types and Mathematical Representations of Curves 163 Assume that three points P,, P, and P, are given The vertical line passes through p, and ends at P, while the horizontal line passes through P, and ends at P3. In general, the two lines cannot pass through points P, or P3. Therefore, the ends are determined by projecting the points onto the lines as shown, Using Eq. (4.17), the line equations are Vertical: P=P,/+La,, OSLSL, or where L1= Yaw= Yaw and the endpoints are (Xj iyo Zw) ANd (Ky, Vw + Ly Zw) Horizontal: P=P,+Liy, 0SLSL, ap Poa x Zz Fig. 4.17 Horizontal and Vertical Lines or y= Mw tb where and the endpoints are jus Yaw Zt) ANG Cy Ly Yi Zw) rete’ lod EB CALCAM Phony and Panett y that panies Hhrouph yndpolnbe al a tine tid Pt an A Avante Hh , af ov ano dingy Hane an point 2 parallel to anoint r ) mn Ms a o hy \ " : We sp, x 418 Line Parallel toan Existing Line Vig Solution To minimize confusion, the differentiation between the orientations of the WES and the MCS is ignored and the position vectors of the various points are omitted from the figure, Assume that the existing fine has the two endpoints Py and Py, alength L; and a direction defined by the unit vector fy, ‘The new line has the same direction mya fength L and endpoints Py and Ps, Ps is the projection of P, onto the line. The equation of the new line is found by substituting the proper vectors into Eq. (4.17). The unit vector fi, is given by . _ BP, iy= oly L, where L isa known value IEq. (4.16)]. 1, can be found from the following equation: Ly= ity (P,P) P, -P, 2h 1, ; = M4 OQ =a) + (yy, . Vox — ayy? Hy The equation of the new line become: PEP 4+hiy, OsLs and its two endpoints are Py(ny, y,, ) and PSA Lats yy 4 L numerical examples, consider the simple two-dimensional Parallel to existing horizontal and vertical ones. Vein allel Fl ‘i » Verily the above equations for the Hosizoml Unes “ise P13, 2), Pa(1. 4), Py(2, 3) and Py(5, 3), Repeat for the vertical lines case P48, 9), P2(9, 2), P(5, 3) and P45, 9). R ders can also utilize the corresponding La Mays 1 + Lyn, nal case of constructing Types and Mathematical Representations of Curves 165 command (0 this example to construct the line on their CAD/CAM systems, verify the ine to obtain its length and 1 fe t engin and endpoints and then compare with the results obtained ere. Example 2 4.8 Rich wc Bee, late the following CAD/CAM commands to their mathematical foundations: (a) The uesaar and that measures the angle between two intersecting lines. (b) The command that finds the distance between a point and a line. Solution (a) Ifthe endpoints of the two lines are P,P, and Ps, P, (Fig. 4.19a), the angle measurement command uses the equation cos 6= (P, =P) (Py Py) IP, =P, 11P, - Py! . (y= Ay = 93) + (2 = Wg = V3) +p = Ws = 3) Vs =a)? + 02 = 9? + @ — aly 5)? + Ou GY] (b) Figure 4-19 shows the distance D from point P; to the line whose endpoints are P, and P, and direction is ii. Its length is L. D is given by D=\(P, -P,) xfil = |(P, -P,) x Py Py Py (a) Angle measurement command (b) Distance measurement command Fig.4.19 Data Related to Line Commands (ovhere, on the furtherest right-hand side, the inner vertical bars indicate the determinant and the outer vertical bars indicate the magnitude of the resulting vector) or D= + SERTUO-¥ (-202-y)h" $ ly m)ea—a)~ s- E—eyP + 4y—x)O2—9 (by -Ve2—AVP I} PARAMETRIC REPRESENTATION OF SYNTHETIC CURVES 4.6 ction, are usually not sufficient to Analytic curves, described in the previous tric design requirements of mechanical parts. Products bodies, ship hulls, airplane fuselage and wings, propeller blades, shoe insoles ind bottles are a few examples that require free-form, or synthetic, cur S The need for synthetic curves in design arises on two occasions: when a curve ts represented by a collection of measured data points and when an existing curve must change to meet new design requirements. In the latter occasion, the designer would need a curve representation that is directly related to the data points and is flexible enough to bend, twist, or change the curve shape by changing one or more data points. Data points are usually called control points and the curve itself is called an interpolant if it s through all the data points. Mathematically, synthetic curves represent acurve-fitting problem to construct a smooth curve that passes through given data points. ‘Therefore, polynomials are the typical form of these curves. Various continuity requirements can be specified at the data points to impose various degrees of smoothness of the resulting curve. The order of continuity becomes important when a complex curve is modeled by several curve segments pieced together end to end. Zero-order continuity (yields 8 position continuous curve. First (C'!)- and second (C*)-order continuities imply slope and curvature continuous curves respectively. A C' curve meet geomet is the minimum a 194 2 CAD/CAM Theory and Practice : @ geometr. esign. Figure 4.39 shows @ geometrie,g ble curve for engineering design, nial is the mi acceptable : f nimy hese orders of continuity. A cubic poly pe stimu cant snarantee the generation al that permits inflec onler polynomial that can a a win ain lows representation of nonplana A) the, within acurve segment and ine supieeercat racine tc AN eens they tendte asia bout control points, are ationg aed enelteeon the computer Tangents Center of curvature J + Control point (2) Zero-order continuity (C° curve) <— Tangent Center of curvature (6) First-order continuity (C! curve) (©) Seconds Fig. 4.39 Various Orders of Continuit The type of input data at curve determine the use order continuity (C? curve) Ly of Curves ind its influence on and effectiv ve in design, For example, curve segments that require positions these points are easier to deal with and gather data for than those th curvature information, Aly signer may prefer to ¢ curve locally insteg es of synthetic curv cub s: Hermite ic spline curve passes throu «1 B-spline curves in genet ete ass through them. Under certai Sec. 4.6.3, B i Polant, as will be seen if : cl S have a first -order continu! and the ‘ ey i order conti ° ion of eac Curve is di tinuity, The formulation o! aa,

You might also like