cad – project medium and machine tool - · pdf filecad – project medium and...

6
CAD – Project Medium and Machine Tool DINEL POPA, NICOLAE–DORU STĂNESCU Department of Automotive and Transportations University of Piteşti 1, Târgul din Vale, Piteşti, Argeş, 110040 ROMANIA [email protected], [email protected] Abstract: - In this paper we present general aspects concerning cylindrical and elliptical gears. In the introduction we highlight the technical aspects and the ways to obtain gears, by classical procedures. In the next paragraph is presented a five steps algorithm in AutoCAD, with the aid of AutoLisp functions, to obtain gears by rolling without sliding, no matter external shape of them, or the motion of the generating tool. The next paragraphs are dedicated to describe the AutoLisp function created for this goal. Finally, we highlight the advantages obtained using CAD and future ways to use the presented functions to generate gears of variable modulo, or other shapes than those presented in the paper. Key-Words: - Gears, solid, AutoCAD, AutoLisp, machine tools 1 Introduction The nowadays CAD softs offer not only facilitates for project, but also the transfer of the model to the machine tool. They also have in their structure different modulus that permit numerical simulations, which finally lead either to the obtaining of the work-piece, or at its optimization. The facilities of these programs are direct proportional to their prices and for this reason in the most cases the access at such soft is limited. With the aid of a programming language, in a CAD medium, one can easily perform simulations. Further on, using some simple algorithms, we will obtain in AutoCAD some solids which materialize circular or elliptic gears with straight or inclined teeth. The way to obtain them is identical to the real cutting process on a machine tool. For this reason, excepting the didactical goal, the method is very useful in simulation of the gears’ modeling, in the validation of the correctness of the performed calculation, and in obtaining the geometric parameters. In two previous papers were presented methods to obtain the teeth for the cylindrical gears [5], and elliptical gears [6], respectively. In the present paper we will develop a general algorithm and AutoLisp functions which permit the obtaining of gears, no matter their shape. 2 Working algorithm AutoCAD is one of the oldest project soft, being implemented on personal computers. The huge popularity of the soft was also obtained because of the existence of the programming language AutoLisp, integrated in AutoCAD. The Visual Lisp version of AutoLisp, combined with other programming media (VBA, C++), permits the development of applications to interact with objects created in AutoCAD. The work with solids in AutoCAD and the existence of Boolean operations which permit the obtaining of composite solids is a facility which, further on, will be used to obtain the teeth of the gears. The procedure to obtain the teeth is copied from the real practice. The technological processes for obtaining the gears can be classified in two categories: by copying and by rolling. The most used is that by rolling which assumes the gearing between the tool and the raw work-piece which will be cut. The tool can be a cylindrical gear or a rack. The most used tooth profile is the evolventic one. It is obtained by rolling without sliding, the two profiles in gearing running over equal arcs or distances. The algorithm used to obtain gears in AutoCAD consists of the following steps: I. obtaining the solid that materializes the tool, II. positioning of a solid (raw work-piece) that approximates the gear, in an advantageous position; Advances in Production, Automation and Transportation Systems ISBN: 978-1-61804-193-7 277

Upload: vanthuan

Post on 24-Mar-2018

217 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: CAD – Project Medium and Machine Tool - · PDF fileCAD – Project Medium and Machine Tool DINEL POPA, NICOLAE–DORU STĂNESCU Department of Automotive and Transportations ... one

CAD – Project Medium and Machine Tool

DINEL POPA, NICOLAE–DORU STĂNESCU Department of Automotive and Transportations

University of Piteşti 1, Târgul din Vale, Piteşti, Argeş, 110040

ROMANIA [email protected], [email protected]

Abstract: - In this paper we present general aspects concerning cylindrical and elliptical gears. In the introduction we highlight the technical aspects and the ways to obtain gears, by classical procedures. In the next paragraph is presented a five steps algorithm in AutoCAD, with the aid of AutoLisp functions, to obtain gears by rolling without sliding, no matter external shape of them, or the motion of the generating tool. The next paragraphs are dedicated to describe the AutoLisp function created for this goal. Finally, we highlight the advantages obtained using CAD and future ways to use the presented functions to generate gears of variable modulo, or other shapes than those presented in the paper.

Key-Words: - Gears, solid, AutoCAD, AutoLisp, machine tools

1 Introduction The nowadays CAD softs offer not only facilitates for project, but also the transfer of the model to the machine tool. They also have in their structure different modulus that permit numerical simulations, which finally lead either to the obtaining of the work-piece, or at its optimization. The facilities of these programs are direct proportional to their prices and for this reason in the most cases the access at such soft is limited. With the aid of a programming language, in a CAD medium, one can easily perform simulations. Further on, using some simple algorithms, we will obtain in AutoCAD some solids which materialize circular or elliptic gears with straight or inclined teeth. The way to obtain them is identical to the real cutting process on a machine tool. For this reason, excepting the didactical goal, the method is very useful in simulation of the gears’ modeling, in the validation of the correctness of the performed calculation, and in obtaining the geometric parameters. In two previous papers were presented methods to obtain the teeth for the cylindrical gears [5], and elliptical gears [6], respectively. In the present paper we will develop a general algorithm and AutoLisp functions which permit the obtaining of gears, no matter their shape.

2 Working algorithm AutoCAD is one of the oldest project soft, being implemented on personal computers. The huge popularity of the soft was also obtained because of the existence of the programming language AutoLisp, integrated in AutoCAD. The Visual Lisp version of AutoLisp, combined with other programming media (VBA, C++), permits the development of applications to interact with objects created in AutoCAD. The work with solids in AutoCAD and the existence of Boolean operations which permit the obtaining of composite solids is a facility which, further on, will be used to obtain the teeth of the gears. The procedure to obtain the teeth is copied from the real practice. The technological processes for obtaining the gears can be classified in two categories: by copying and by rolling. The most used is that by rolling which assumes the gearing between the tool and the raw work-piece which will be cut. The tool can be a cylindrical gear or a rack. The most used tooth profile is the evolventic one. It is obtained by rolling without sliding, the two profiles in gearing running over equal arcs or distances. The algorithm used to obtain gears in AutoCAD consists of the following steps: I. obtaining the solid that materializes the tool, II. positioning of a solid (raw work-piece) that approximates the gear, in an advantageous position;

Advances in Production, Automation and Transportation Systems

ISBN: 978-1-61804-193-7 277

Page 2: CAD – Project Medium and Machine Tool - · PDF fileCAD – Project Medium and Machine Tool DINEL POPA, NICOLAE–DORU STĂNESCU Department of Automotive and Transportations ... one

it must have a dimension which, finally, permits the gear (a sufficient cutting addition of material), III. positioning of the solid that materializes the tool in contact with the solid that materializes the raw work-piece, IV. one gives a constant rotational motion to the raw work-piece that materializes the gear simultaneously with the displacement or rotation of the solid that materializes the tool, V. elimination of the solid that materializes the tool from the solid that materializes the gear. To obtain a gear with this algorithm we have to perform at least 360 operations of tool from the material of raw work-piece. Comparing to the classical technological procedure, in AutoCAD the gear is obtained after one single rotation, the addition of material being eliminated in a single step.

3 AutoLisp function to realize the

proposed algorithm We realized the following AutoLisp function to perform the previous presented operations with solids: (Defun C:Roata () (SetVar "CMDECHO" 0) (Command "-OSNAP" "OFF" "ORTHO" "OFF" "Erase" "All" "") (Date) (Command "Zoom" "W" W1 W2) (CremalieraGeneratoare) (Setq P(List (* 5 Pi m) (+ R mx)) P5(List (* 5 Pi m) (+ R mx) (/ gros 2))) (Command "Copy" Cremaliera "" "0,0" "0,0") (Setq Scot(Entlast)) (Material) (If (/= alfa 0) (Command "Rotate3D" Scot "" "Y" P5 alfa) ) (Command "Subtract" Semifabricat "" Scot "") (Setq Roata(Entlast)) (Initializare) (While (< fi 360) (Deplasez) (Command "Copy" Cremaliera "" "0,0" C) (Setq Scot(Entlast)) (If (/= alfa 0) (Command "Rotate3D" Scot "" "Y" P5 alfa) ) (Command "Subtract" Roata "" Scot "") (Setq Roata(Entlast)) )

(SetVar "CMDECHO" 1) ) The function has no local parameters or variables and calls four function with the aid of which we define the dimensions of the gear (Date), the solid that materializes the tool (CremalieraGeneratoare), the solid that materializes the raw work-piece (Material) and the displacement of the gear simultaneously with the rack (Deplasez). The function is called Roata and it realizes in order: – setting of some system variables which permits the work and calling the function "Date" that defines the dimensions of the gear, – setting of a space of seeing and calling of the function "Cremaliera generatoare" to construct the solid that materializes the raw work-piece, this solid being called "Cremaliera", – setting of point P and 5P , two points of the rotational axis of the gear, – copies the solid that materializes the tool, the new solid being called "Scot", – construction of the raw work-piece that materializes the gear with the function "Material" and calling "Semifabricat" the resulted solid, – extraction of the solid "Scot" from the solid "Semifabricat" and calling "Roata" the resulted solid, – in a loop "while" one gives values to the angle ϕ from degree to degree in the interval ( )π2,0 ; in

function of the angle ϕ we rotate and position the

solid that materializes the raw work-piece with the aid of AutoLisp function "Deplasez", position the solid that materializes the generating rack and extract the generating rack from the raw work-piece; the resulted solid is called "Roata" and we pass to the next step. In the next paragraph, depending on the type of the gear mechanism, we will present the four AutoLisp function called by the previous function.

3 AutoLisp functions to define the

gears In the case of the circular gears the dimensions are function of the gear modulo (m), number of teeth (z), displacement of profile (mx) and the angle of inclination of the teeth (alfa). At the linear dimensions we add the width of the gear (gros). By "pas_ung" we denoted the step, in degrees, used to obtain the gear (maxim 1o). Further on, we defined two points which establish the corner of the

Advances in Production, Automation and Transportation Systems

ISBN: 978-1-61804-193-7 278

Page 3: CAD – Project Medium and Machine Tool - · PDF fileCAD – Project Medium and Machine Tool DINEL POPA, NICOLAE–DORU STĂNESCU Department of Automotive and Transportations ... one

visualization window of the construction in AutoCAD. For a gear with the modulo 2=m mm, with

20=z teeth, the width of teeth equal to 30 mm and the angle of inclination of the teeth °=α 10 the following AutoLisp function is written: (Defun Date () (Setq m 2 z 20 gros 30.0 mx 0 alfa 10.0 pas_ung 1.0 R(* m z 0.5) Re(/ 44.00 2) W1(List (* -1 m) (* -2 m)) W2(List (* 7 Pi m) (* 10 Pi m))) ) In the case f an elliptical gear we have to define the rolling ellipse. Ellipse is a closed curve and it is defined ([4]) as the geometric locus for which the sum of their distances at two fixed points called foci is constant. For the ellipse in Fig. 1, the foci are )0,(' cF −

and )0,(cF , where 22 bac −= )( ba > and,

according to the previous definition,

aMFMF 2' =+ ; a (the segment OA ) and b (the

segment OB ) being called the semi-axes of the ellipse. The points A , A′ , B , B′ are called the

vortices of the ellipse, while the segments 'AA and

'BB are the large and the small semi-axes of the ellipse, respectively.

B(0,b)

B'(0,-b)

A(a,0)A'(-a,0)

F'(-c,0) F(c,0)C(0,0)

M(x,y)

x

y

ac

2( , 0)a(- , 0)c

2

∆∆

θ

Fig. 1. Ellipse.

For the ellipse in Fig. 1, the parametrical equations are

tax cos= , ta sin= , (1) where t takes values from 0 to π2 . In equation (1) the parameter t , called anomaly

in astronomy, is not the angle between OM and the horizontal direction. Denoting this angle by θ , it results

=θ − ta

btantan 1 . (2)

The length of a curve is given by the relation

tt

y

t

xs

t

dd

d

d

d

0

22

+

= (3)

and keeping into account the relation (1) it results

ttbtaL

t

dcossin0

2222∫ += . (4)

The integral (5) is an elliptical one of second order and according to [8] the total length of an ellipse, denoted by L is obtained by development in series. Because the length of an ellipse is not precise determined by an analytical formula, we will prefer to determine the length L of the ellipse by approximation with 360 segments. In a loop, one sums the 360 segments and therefore

∑=

−−−+−=

360

1

22 )()(11

i

PPPP iiiiyyxxL . (5)

After running the loop, one determines the modulus with the relation

mz

Lm = (6)

We can also proceed in a reverse mode, for an a and a given m (standard), one determines b . For a gear with the dimensions mm 70=a ,

mm 55=b , 48=z teeth, width of the teeth mm 10 and the angle of inclination of the teeth °=α 0 , the following AutoLisp function is written (Defun Date () (Setq aa 70.0 bb 55.0 z 48 pas_ung 1.0 gros 40.0 mx 0 alfa 0.0 R bb) (setq W1(List (* -1 aa) (* -0.2 bb)) W2(List (* 3 aa) (* 3 bb))) (Setq fi 0 xm aa ym 0.0 Lungime 0.0) (While (< fi 360) (Setq fi(+ fi pas_ung)) (Setq firad(/ (* fi pi) 180)) (Setq xmic(* aa (Cos firad)) ymic(* bb (Sin firad))) (Setq lungime(+ Lungime (Sqrt(+(* (- xmic xm) (- xmic xm))(* (- ymic ym) (- ymic ym)))))) (setq xm xmic ym ymic) ) (setq m(/ lungime Pi z)) )

4 AutoLisp functions to define the tool For the generation of the gears with generating rack, one uses the following AutoLisp function (Defun CremalieraGeneratoare ()

Advances in Production, Automation and Transportation Systems

ISBN: 978-1-61804-193-7 279

Page 4: CAD – Project Medium and Machine Tool - · PDF fileCAD – Project Medium and Machine Tool DINEL POPA, NICOLAE–DORU STĂNESCU Department of Automotive and Transportations ... one

(Setq sinx(sin (/ Pi 9)) cosx(cos (/ Pi 9)) dx(* (/ sinx cosx) m) A(List 0 m) B(List (- (/ (* m Pi) 4) dx) m) C(List (+ (/ (* m Pi) 4) dx) (* -1 m)) E(List (/ (* m Pi) 2) (* -1.25 m)) F(List (/ (* m Pi) 2) 0) raza(* 0.38 m)) (Command "Pline" A B C "A" "R" raza "A" "70" "-35" E "") (Command "Mirror" "L" "" E F "") (Setq dist(* Pi m) copii(+ z 25)) (Command "Array" "All" "" "R" "1" copii dist) (Setq P10(List (* copii Pi m) m) P11(List (* copii Pi m) (* 2 m)) P12(List 0 (* 2 m))) (Command "Pline" P10 P11 P12 A "") (Command "Pedit" "M" "All" "" "J" "" "") (Command "Mirror" "All" "" "0,0" "10,0" "Y") (Command "Extrude" "L" "" (* 3 gros) "0") (Setq Jos(List 0 0 (* gros -1))) (Command "Move" "L" "" "0,0,0" Jos) (Setq Cremaliera(Entlast)) ) The function is described in [5], [6] and it constructs the reference rack and its complementary (generating rack Maag), starting from the dimensions of the reference rack, specified in standards. To obtain the generating rack, the reference rack is mirrored with respect to the horizontal axis, the obtained solid being called "Cremaliera". When one wishes as a tool a previous obtained gear, this is called "Cremaliera" from the status bar of AutoCAD ((Setq Cremaliera(EntLast)).

5 AutoLisp functions to obtain the

raw work-piece The raw work-piece is a solid with a sufficient dimension to finally obtain the gear. For a cylindrical gear the raw work-piece is a cylinder with the external diameter positioned at the point P , of radius eR , and width "gros" of the gear.

The obtained cylinder is called "Semifabricat". The AutoLisp function is (Defun Material () (Command "Cylinder" P Re gros) (Setq semifabricat(Entlast)) ) In the case of the elliptical gears, the raw work-piece is an ellipse constructed with the aid of three

points (Fig. 1): A , 'A and B , at which the dimensions are enlarged by the modulo m . The ellipse is extruded at the width "gros" of the gear and is called "Semifabricat". The AutoLisp function is (Defun Material () (setq xP1 (- (* 5 pi m) aa m) yP1 bb P1(List xP1 yP1) xP2 (+ (* 5 Pi m) aa m) yP2 bb P2(List xP2 yP2) xP3 (* 5 Pi m) yP3 (* -1.0 m) P3(List xP3 yP3)) (Command "Ellipse" P1 P2 P3) (Command "Extrude" "Last" "" gros "0") (Setq semifabricat(Entlast)) )

6 AutoLisp functions for the

positioning of the raw work-piece For the positioning of the raw work-piece in the case of cylindrical gears, the problem is simple. The operation consists in the rotation about the point P , with an angular step (usually 1o), while the displacement of the rack is made with the distance

180/ϕ=θ= RRd (the angle ϕ is in degrees, and

the angle θ in radians). The value obtained is memorized in the point C abscissa. The AutoLisp function is (Defun Deplasez () (Command "Rotate" Roata "" P (* -1 pas_ung)) (Setq fi(+ fi pas_ung)) (setq deplasare(/ (* R fi Pi -1) 180)) (Setq C(list deplasare 0)) ) In the case of the elliptical gears the problem is more complicate. For a correct gearing, the motion which takes place between the two bodies in contact is a rolling without sliding. Hence representing the gearing between an ellipse and a rack, the ellipse rolls on the reference line (Fig. 2).

C*

xy

ϕ

M*M

M'

CX

Y

rolling ellipse

reference line

Fig. 2. Rolling without sliding of the ellipse on the

reference line.

Advances in Production, Automation and Transportation Systems

ISBN: 978-1-61804-193-7 280

Page 5: CAD – Project Medium and Machine Tool - · PDF fileCAD – Project Medium and Machine Tool DINEL POPA, NICOLAE–DORU STĂNESCU Department of Automotive and Transportations ... one

At any moment the space run over on the exterior of the rolling ellipse *' MMs = must be

equal to the displacement *MMd = of the rack. Unlike the rolling of a cylindrical wheel on a plan, when the centre remains at the same high, at the rolling without sliding of an ellipse on the same plan, the centre moves on vertical direction. To determine the vertical displacement of the centre C , we will consider the ellipse in two reference frames: one fixed XCY and the other mobile xCy , solidary with the ellipse inclined with

the angle ϕ (Fig. 3).

X

Y

xy

ϕ

M*

M(x,y)

C

Fig. 3. Reference frames

A point M in the general reference frame has the coordinates

ϕ−ϕ= sincos yxX , ϕ+ϕ= cossin yxY (7)

or, keeping into account the relations (1) ϕ−ϕ= sinsincoscos tbtaX ,

ϕ+ϕ= cossinsincos tbtaY (8)

To determine the coordinates of the point *M , the point with the highest negative y (the lowest one), we put the condition

0d

d=

t

Y, (9)

which becomes ϕ=ϕ coscossinsin tbta , (10)

resulting the solutions

ϕ= − cottan 11

a

bt , π+= 12 tt . (11)

The AutoLisp function which realizes this positioning of the raw work-piece is (Defun Deplasez () (Setq fi(+ fi pas_ung)) (Setq firad(/ (* fi pi) 180)) (If (= (Sin firad) 0) (Setq teta1 (/ pi 2)) (Setq teta1 (Atan (/ (* bb (Cos firad)) aa (Sin firad)))) )

(Setq teta2(+ teta1 pi)) (Setq Y1(+ (* (* aa (Sin firad)) (Cos teta1)) (* (* bb (Cos firad)) (Sin teta1)))) (Setq Y2(+ (* (* aa (Sin firad)) (Cos teta2)) (* (* bb (Cos firad)) (Sin teta2)))) (If (<= Y1 y2) (Setq yP (Abs Y1)) (Setq yP (Abs Y2)) ) (setq P(List xp3 yP)) (Command "Move" Roata "" Pvechi P) (Command "Rotate" Roata "" P (* -1 pas_ung)) (Setq Pvechi (List xp3 yp)) (Setq xmic(* aa (Cos firad)) ymic(* bb (Sin firad))) (setq deplasare(+ deplasare (Sqrt(+ (* (- xmic xm) (- xmic xm)) (* (- ymic ym) (- ymic ym)))))) (setq xm xmic ym ymic) (Setq C(list (* -1 deplasare) 0)) ) In the Figs. 4 and 5 were represented two gears, the first circular with inclined teeth, and the second elliptical with straight teeth. Their dimensions are those given by the two functions Date from the paragraph 3.

Fig. 4. Circular gear.

7 Conclusions The method presented in the paper requires minimum theoretical knowledge of the theory of the gears’ generation. The principle of the method bases on the capacity of a CAD soft to use Boolean operations (addition, subtraction, intersection etc.) in the case of solids. In this way one can gear either circular and non-circular gears, extracting the solid that materializes the tool or the generating gear from the solid that materializes the raw work-piece.

Advances in Production, Automation and Transportation Systems

ISBN: 978-1-61804-193-7 281

Page 6: CAD – Project Medium and Machine Tool - · PDF fileCAD – Project Medium and Machine Tool DINEL POPA, NICOLAE–DORU STĂNESCU Department of Automotive and Transportations ... one

Fig. 5. Elliptical gear.

The operation is performed assisted by the programming language AutoLisp, because of the huge number of operations. In this way are virtually obtained gears similar to those obtained on a classical machine tools specialized in gearing. The algorithm of the method is easily modified for the case of other non-circular gears with constant or variable modulo. References:

[1] Manolescu, N., Kovacs, Fr., Oranaescu, A., Teoria mecanismelor şi a maşinilor, Editura Didactică şi Pedagogică, Bucureşti, 1972 (in Romanian)

[2] Pandrea, N., Popa, D. (2000), Mecanisme.

Teorie şi aplicaŃii CAD, Editura Tehnică, Bucureşti, 2000 (in Romanian).

[3] Manolea, D., Programare în AutoLisp sub

AutoCAD, Editura Albastră, Cluj-Napoca, 1996 (in Romanian).

[4] Vrânceanu, Gh., Geometrie analitică,

proiectivă şi diferenŃială, Editura Didactică şi Pedagogică, Bucureşti, 1974 (in Romanian).

[5] Popa, D., Popa C-M, Stanescu N-D, Stan, M., Parlac, S., Generation of the gears with a CAD soft with the AutoLisp functions, 2nd

International Conference on Experiments /

Process / System Modelling / Simulation &

Optimization, Athens, 4-7 July, 2007. [6] Popa D., Stănescu, N-D., Popa, C-M.,

Cinematica şi generarea roŃilor dinŃate eliptice, Buletin ştiinŃific al UniversităŃii de ConstrucŃii

Bucureşti, vol. XX, pp. 191 – 200. [7] Popa, D., Stănescu, N.D., Popa C.M., Elliptical

gear, Scientific Bulletin Automotive series, XVII, no. 24, pp. 108-113.

[8] http://en.wikipedia.org/wiki/Ellipse

Advances in Production, Automation and Transportation Systems

ISBN: 978-1-61804-193-7 282