Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 UDK - UDC 621.914:004.8 Izvirni znanstveni članek - Original scientific paper (1.01) Ustvarjanje modela rezalnih sil z uporabo umetne inteligence Generation of a Model for Cutting Forces Using Artificial Intelligence Matjaž Milfelner - Uroš Župerl - Franci Čuš Napovedovanje rezalnih sil pri frezanju z oblikovnim krogelnim frezalom je zelo pomembno za določitev optimalnih rezalnih parametrov pri postopku frezanja. Razviti modeli rezalnih sil pri frezanju z oblikovnim krogelnim frezalom, ki so predstavljeni v raziskavah, temeljijo na analitičnih metodah in so določeni z uporabo teoretičnega in praktičnega znanja ter preizkusov. V prispevku je predstavljen razvoj genetskega modela rezalnih sil za oblikovno krogelno frezalo z umetno inteligenco (genetsko programiranje). V genetskem modelu so upoštevani vsi vplivni parametri, ki vplivajo na velikost rezalne sile med postopkom frezanja. Predstavljeni model je ustvarjen iz preizkusnih podatkov za jeklo Ck45 pri različnih rezalnih parametrih. Dobljeni rezultati prikazujejo, da genetski model rezalne sile ustreza preizkusnim podatkom. © 2005 Strojniški vestnik. Vse pravice pridržane. (Ključne besede: modeli genetski, sile rezanja, frezanje, frezala krogelna) Being able to predict the cutting forces during milling with a ball-end milling cutter is very important for determining the optimal cutting parameters in the milling process. The already developed models of cutting forces in ball-end milling are based on analytical methods and are determined by means of theoretical and practical knowledge as well as experiments. This paper presents the development of a genetic model of cutting forces for a ball-end milling cutter using artificial intelligence (genetic programming). In the genetic model, all the parameters influencing the size of the cutting forces during the milling process are considered. The presented model is generated from experimental data for Ck45 steel with different cutting parameters. The results indicate that the genetic model of the cutting force agrees with the experimental data. © 2005 Journal of Mechanical Engineering. All rights reserved. (Keywords: genetic models, cutting forces, milling, ball-end mill) 1 UVOD V prispevku je predstavljen razvoj genetskega modela rezalnih sil z oblikovnim krogelnim frezalom. Postopek frezanja z oblikovnim krogelnim frezalom je v zadnjem času ob razvoju sodobnih večosnih obdelovalnih centrov in postopkov obdelave z velikimi hitrostmi postal eden izmed najpomembnejših postopkov obdelave materiala, s katerim lahko obdelujemo zapletene površine in oblike izdelkov. Za povečanje zmogljivosti tehnološkega postopka je nujna integracija metod za modeliranje postopkov obdelave ter napovedovanje in optimiranje parametrov v proizvodnem postopku. Nove metode umetne inteligence omogočajo ustvarjanje novih modelov ter iskanje boljših rešitev 1 INTRODUCTION This paper presents the development of a genetic model of cutting forces for a ball-end milling cutter. With the development of modern multi-axes machining centers and high-speed processes of ma-chining, ball-end milling has become one of the most important processes for the machining of material when complicated product surfaces and shapes need to be machined. The integration of methods for modelling the machining processes, prediction and the optimi-zation of parameters in the production process are required to increase the capacities of the techno-logical process. The new methods of artificial intelli-gence ensure the generation of new models and the search for better solutions in the area of cutting. 41 Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 na področju odrezovanja. Prednosti novih metod so v tem, da so univerzalne in robustne in jih je mogoče uporabiti na vseh raziskovalnih področjih za modeliranje in optimiranje splošnih in zelo zapletenih problemov, kar je postopek odrezovanja. Vključevanje sodobnih metod modeliranja in optimiranja v postopek odrezovanja je še v fazi razvoja. Uporaba le-teh pa omogoča povečanje prilagodljivosti, produktivnosti, zanesljivosti, natančnosti in kakovosti samega postopka ter izdelkov. 1.1 Opis problema Neugodni pojavi pri odrezovanju so: obraba orodja, lom orodja, nastanek nalepka na rezalnem robu, čezmerna deformacija in vibracije orodja. Ti imajo škodljiv vpliv na postopek odrezovanja in kakovost izdelave. V odvisnosti od rezalnih parametrov in materiala obdelovanca se lahko pojavi eden ali več teh neugodnih pojavov med odrezovanjem. Zato je treba odkriti te pojave čim prej in s spremembo rezalnih parametrov izboljšati postopek odrezovanja. Tem problemom se lahko izognemo, če uporabimo določene rezalne parametre, to so: majhna podajanja, optimalne rezalne hitrosti ter majhna vzdolžna in prečna globina. Vendar pa določeni rezalni parametri ne izkoristijo zmogljivosti in zmanjšujejo izkoristek stroja. Čeprav z izbiro optimalnih rezalnih parametrov odstranimo nekatere probleme pri postopku odrezovanja, to ne zagotovi optimalnega postopka odrezovanja. Brez teoretičnega razumevanja postopka odrezovanja ter dragih preizkusov ne moremo določiti optimalnih rezalnih parametrov. Z uporabo krmilnih strategij, ki povečujejo zmogljivost obdelave, lahko optimiramo postopek odrezovanja ter znižamo stroške obdelave. Naš namen je razviti genetski model rezalne sile za oblikovno krogelno frezalo, s katerim lahko zanesljivo opišemo postopek frezanja. Model bo razvit na podlagi zbiranja vplivnih veličin pri postopku frezanja, analitičnega modela rezalnih sil za oblikovno krogelno frezalo, tehnološkega znanja, metod optimiranja na temelju umetne inteligence in izkušenj iz prakse. 1.2 Rezalne sile Frezanje z oblikovnim krogelnim frezalom je zelo pogost postopk obdelave in se uporablja za obdelavo prosto oblikovanih površin, npr. utopi, The advantages of the new methods are that they are universal and robust and that they can be used in all research areas for the modelling and optimiza-tion of general as well as complicated problems like the cutting process. The integration of modern meth-ods of modelling and optimization into the cutting process is at the development stage. The use of such modelling methods ensures an increase in flexibility, productivity, reliability, accuracy and the quality of the process and the products. 1.1 Description of the problem The unfavourable phenomena in cutting are as follows: tool wear, tool breakage, built-up edge formation, excessive deformation and tool vibrations. These phenomena negatively influence the cutting process and the quality of manufacture. Depending on the cutting parameters and the workpiece material one or several of these unfavourable phenomena can occur during cut-ting. Therefore, it is necessary to detect these phenom-ena as soon as possible and to improve the cutting proc-ess by changing the cutting parameters. These problems can be avoided if the specified cutting parameters, such as small feed rates, optimum cutting speeds and small axial and radial depth, are used. However, the an-ticipated cutting parameters do not make use of the ca-pacity and reduce the machine’s efficiency. Although proper selection of the optimum cutting parameters elimi-nates some problems in the cutting process, this does not ensure an optimum cutting process. Without a theoretical understanding of the cutting process and expensive experiments the optimum cutting parameters cannot be determined. How-ever, by using control strategies and increasing the machining capacity the cutting process can be optimized and the machining costs reduced. The aim of this study is to develop a genetic model of the cutting force for a ball-end milling cutter, enabling us to reliably describe the milling process. The model’s development will be based on collecting the influencing variables in the milling process, an analytical model of the cutting forces for the ball-end milling cutter, technological know-how, methods of optimization based on artificial intelligence and experience from practice. 1.2 Cutting forces Milling with a ball-end milling cutter is a very common machining process and is used for machining freely shaped surfaces such as dies, 42 Milfelner M. - Župerl U. - Čuš F. Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 matrice, votlice, kalupi, turbine, propelerji in letalski konstrukcijski elementi. Geometrijske oblike izdelkov postajajo vedno bolj zahtevne in jih lahko izdelamo le z oblikovnim krogelnim frezanjem na sodobnih RNK obdelovalnih centrih. Napovedovanje rezalnih sil pri frezanju z oblikovnim krogelnim frezalom je zelo pomembno. V fazi načrtovanja rezalnega postopka znanje o rezalnih silah pomaga tehnologu pri določevanju rezalnih parametrov za obdelavo. Napovedovanje rezalnih sil je v podporo pri načrtovanju postopka, izbiri primernih rezalnih razmer za zmanjšanje obrabe, deformacije in loma orodja ter pri konstruiranju boljših vpenjalnih priprav, kar izboljša kakovost izdelka. Glavni modeli rezalnih sil pri frezanju z oblikovnim krogelnim frezalom, ki so bile predstavljene v raziskavah, so določene z uporabo teoretičnega in praktičnega znanja ter preizkusov ([2] in [3]). Za določitev modela rezalnih sil pri frezanju z oblikovnim krogelnim frezalom potrebujemo vhodne parametre, to so: rezalni parametri, geometrijska oblika frezala, material frezala in obdelovanca. Izhodni parameter oz. rezultat modela je rezalna sila. Predstavljen je analitični model rezalne sile za oblikovno krogelno frezalo. Rezalna sila na rezalnem robu frezala je: [T] KR KT K moulds, turbines, screw propellers and structural components for aircraft. The geometrical shapes of the product become more and more complex and can be made only with ball-end milling on modern CNC machining centers. The prediction of the cutting forces during milling with a ball-end milling cutter is very impor-tant. In the cutting-process planning stage a knowledge of the cutting forces helps the technologist to determine the cutting parameters for machining. A prediction of the cutting forces supports the proc-ess planning, the selection of suitable cutting con-ditions to reduce wear, tool deformation and break-age and the design of better fixing devices that im-prove the product quality. The basic models for cutting forces in mill-ing with a ball-end milling cutter, presented in previ-ous research, are determined by means of theoretical and practical knowledge and experiments ([2] and [3]). The input parameters, such as cutting parameters, cutter geometry, cutter and workpiece material, are needed for the determination of the model of cutting forces in ball-end milling. The output parameters and/or the model results are the cutting force. The analytical cutting-force model for a ballend milling cutter is presented in our work. The cutting force on the cutting edge of the cutter is: kjer je fz-sin [Y]•dz where [T] -sink sinY -cosY -cosk sin Y sinkcosY sinY -cosk cos Y cosk 0 -sink (1) (2), in: dz - debelina vzdolžnega diferencialnega elementa, fz - podajanje na zob, Y - kot rezalnega robu pri odrezovanju v smeri vrtenja frezala, k - kot v smeri osi z od središča polkrožnega dela do točke na rezalnem robu, KT - obodni koeficient materiala, K -prečni koeficient materiala, K - vzdolžni koeficient materiala. 2 MODELIRANJE POSTOPKA FREZANJA 2.1 Uvod Modeliranje in optimiranje postopka odrezovanja sta pomembna elementa v proizvodnem and: dz - thickness of axial differential element, fz -feeding per tooth, Y - angle of cutting edge during cutting in the direction of rotation of the milling cutter, k - angle in the direction of Z axis from the center of the hemispherical part to the point on the cutting edge, KT - tangential coefficient of material, KR - radial coef-ficient of material, KA - axial coefficient of material. 2 MODELING OF MILLING PROCESS 2.1 Introduction Modeling and optimization of the cutting process are important elements in the production Ustvarjanje modela rezalnih sil - Generation of a Model for Cutting Forces 43 Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 postopku. Proizvodni postopek je ovrednoten z dinamičnimi in med seboj povezanimi spremenljivkami [7]. Zahteva po natančnosti, kakovosti, učinkovitosti in gospodarnosti v proizvodnem postopku je vedno večja. Glede na to je zelo pomembna natančna določitev modela in opis postopka ter izbira optimalnih rezalnih parametrov. Razvoj modela rezalnih sil za napovedovanje in optimiranje postopka frezanja terja podrobno raziskavo vplivnih parametrov in robnih pogojev ([1] in [8]). V zadnjem obdobju so se za optimiranje rezalnih parametrov začele uporabljati metode umetne inteligence, npr.: nevronske mreže, genetski algoritmi [9] in mehka logika ([10] in [11]). Število modelov za optimiranje rezalnih parametrov z genetskimi algoritmi je v literaturi zelo omejeno ([4] in [5]). Večina modelov je matematičnih in empiričnih, ki temeljijo na eksperimentalnih rezultatih. Splošno gledano imajo ti modeli zelo celovito zgradbo in temeljijo na medsebojni povezavi med rezalnimi parametri, materialom obdelovanca in orodjem. Opis postopka odrezovanja z uporabo umetne inteligence je nova metoda za določevanje modelov ter napovedovanje in optimiranje postopkov na področju strojništva [1]. Iz tega razloga smo za določitev genetskega modela rezalnih sil uporabili metodo genetskega programiranja, ki temelji na načelu naravne biološke evolucije. V prispevku je predstavljen genetski model za določitev oz. napovedovanje rezalnih sil pri frezanju z oblikovnim krogelnim frezalom. 2.2 Evolucijske metode Evolucija je temelj sodobne teorije o razvoju življenja. Sama beseda evolucija pomeni postopno spreminjanje neke veličine (ali več veličin) običajno v boljše, popolnejše oblike. Darvinistična biološka misel je, da razvoj življenja določajo postopki, kakor so reprodukcija, mutacija, križanje, tekmovanje in selekcija. Reprodukcija je glavno načelo nadaljevanja vrste živih organizmov. Mutacija je tista komponenta evolucije, ki prinaša novosti. Tekmovanje in selekcija sta postopka, ki se vedno pojavljata tam, kjer ima več osebkov na voljo omejene količine dobrin. Tako lahko evolucijo opredelimo kot postopek optimiranja, pri katerem postajajo organizmi čedalje bolj prilagojeni na okolje, v katerem živijo [12]. Pri tem pojem evolucije ni omejen samo na žive organizme. Evolucijo lahko process. The production process is evaluated with dynamic and interconnected variables [7]. The re-quirements for accuracy, quality and cost-effective-ness in the production process is of increasing im-portance. In this respect a precise determination of the model, a process description and the selection of optimum cutting parameters are very important. The development of a cutting force model for the prediction and optimization of the milling process requires detailed research of the influencing parameters and the boundary conditions ([1] and [8]). Re-cently, artificial intelligence methods, such as neural networks, genetic algorithms [9] and fuzzy logic ([10] and [11]), have started to be introduced for the opti-mization of cutting parameters. The number of models for the optimization of the cutting parameters using genetic algorithms is very limited in the literature ([4] and [5]). Most models are mathematical and empirical and are based on experimental results. In general, these models have a very complex structure and are based on interconnections between the cut-ting parameters, the workpiece and the tool material. A description of the cutting process using artificial intelligence is a new method for the determination of modes and the prediction and optimiza-tion of processes in the area of mechanical engineering [1]. For this reason the genetic programming method based on the principle of natural biological evolution has been used to determine of the genetic model of cutting forces. This paper presents a ge-netic model for the determination and/or prediction of the cutting forces in ball-end milling. 2.2 Evolutionary methods Evolution is the basis for the modern theory of the development of life. The term evolution itself means gradual changing of some value (or several values), usually into better, more perfect forms. The Darwinian biological idea implies that the development of life is determined by processes such as repro-duction, mutation, crossover, competition and selec-tion, with reproduction being the basic principle for the continuation of a species of living organisms. Mutation is the component of evolution that brings nov-elties. Competition and selection are two processes that occur whenever several organisms have avail-able a limited quantity of goods. Thus, evolution can be defined as the optimization process that applies when organisms become increasingly adapted to the environment in which they exist [12]. Here, the term 44 Milfelner M. - Župerl U. - Čuš F. Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 simuliramo tudi na računalniku in jo izkoristimo za reševanje problemov na najrazličnejših področjih [12]. Glavni značilnosti evolucijskih metod sta v tem, da se rešitve ne iščejo po vnaprej postavljenih (determinističnih) poteh in da se sočasno obravnava množica preprostih predmetov [12]. Strukturna rešitev je prepuščena evolucijskemu postopku. Ker smo pri reševanju z evolucijskimi metodami zvesti biološkim izhodiščem, pravimo rešitvam organizmi ali kromosomi. Zaradi verjetnostne narave metod evolucijskega računanja ni nobenega zagotovila, da prav vsaka evolucija pripelje do zadovoljivega izida. Obstaja več različnih metod evolucijskega računanja. Najbolj znane so: - genetski algoritmi; - genetsko programiranje, to je razširitev genetskih algoritmov. S to metodo se ustvarjajo programi, išče se tisti program, ki najbolje reši dano nalogo; - evolucijske strategije, te temeljijo na populaciji s samo enim članom in samo enim opravilom (mutacijo); - evolucijsko programiranje, to napoveduje, na podlagi prejšnjih členov, neke vrste naslednji člen vrste. 2.3 Genetsko programiranje Genetsko programiranje je posebna veja strojnega učenja, ki ga definiramo kot učenje računalniškega programiranja s posnemanjem naravne evolucije. Začetnik genetskega programiranja je J. R. Koza [13]. Pri genetskem programiranju je uporabil zamisel o genetskih algoritmih, pri katerih populacijo sestavljajo računalniški programi, ki se med evolucijo s selekcijo, križanjem in mutacijo avtomatsko izpopolnijo. Za genetsko programiranje se uporabljajo programski jeziki C, Lisp in Java, pri katerih je programe mogoče predstaviti v obliki dreves. Glavni algoritem genetskega programiranja se ne razlikuje veliko od genetskega algoritma. Vhodni parametri genetskega programiranja so: - M - velikost populacije, - G -število generacij, -pr - verjetnost reprodukcije, -pc - verjetnost križanja, -p - verjetnost mutacije. m Pri genetskem programiranju je populacija sestavljena iz računalniških programov. Pri tem je evolution is not limited only to living organisms. Evolution can also be simulated on the computer and can be used to solve problems in a variety of areas [12]. The two main characteristics of evolutionary methods are that the solutions are not searched for in ways defined in advance (deterministic), and that a large variety of simple objects are dealt with simultane-ously [12]. The structural solution is left to the evolu-tionary process. As when solving with evolutionary methods we stick to biological starting points, the solutions are called organisms or chromosomes. Due to the probabilistic nature of the evolutionary computa-tion methods there is no guarantee that each evolution will lead to a satisfactory outcome. From the several available evolutionary com-putation methods, the most widely known are as follows: - genetic algorithms, - genetic programming – an extension of genetic algo-rithms, where programmes are created and the programme that best solves the set task is searched for, - evolutionary strategies - based on a population with only one member and only one operation (mutation), - evolutionary programming - on the basis of previ-ous members of a species it predicts the next mem-ber of the species. 2.3 Genetic programming Genetic programming is a special branch of machine learning, defined as the learning of computer programming by simulating the natural evolution. The father of genetic programming is J. R. Koza [13]. In genetic programming he used the idea of genetic algorithms where the population is formed by computer programmes automatically improving in the course of evolution by means of selection, crossover and mutation. For genetic programming the programme languages C, Lisp and Java are used, where the programmes can be represented in the form of trees. The basic algorithm of genetic programming does not differ much from the genetic algorithm. The input parameters of genetic programming are: - M - population size, - G - number of generations, - pr - probability of reproduction, - pc - probability of crossover, - pm - probability of mutation. In genetic programming the population con-sists of computer programmes. Here it is necessary to Ustvarjanje modela rezalnih sil - Generation of a Model for Cutting Forces 45 Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 treba poudariti pomembno razliko med bitnimi nizi nespremenljive dolžine in programi, pri katerih se oblika in vsebina dinamično spreminjata med evolucijskim postopkom. Torej velikost in oblika programov ni vnaprej definirana, kakor je to v primeru bitnih nizov nespremenljive dolžine. Prostor iskanja je prostor vseh programov, ki jih lahko sestavimo s funkcijami in sklepnimi simboli, primernimi za uporabo. Program sestavimo iz množice funkcij F = {f1, f2,.. ., fNf} in množice sklepov T = {a f a2, ..., a Nt}, pri čemer ima vsaka posamezna funkcija/ iz nabora F določeno število argumentov z(f). Ustrezno število argumentov za funkcije iz nabora F je potemtakem določeno s seznamom P = {z(f1), z(f2), ..., z(fNf)}. Primeri funkcij so lahko: - aritmetična opravila (+, -, *, /), - matematične funkcije (sin, cos, exp, ln), - logična opravila ( AND, OR, NOT), - krmilni operatorji (npr. IF-THEN-ELSE), - druge funkcije. V množici terminalov običajno najdemo spremenljivke, ki pomenijo vhodne podatke, zaznavala, spremenljivke sistema, in stalnice. Na začetku je treba najprej naključno ustvariti začetno populacijo programov z zahtevo, da je raznolikost začetne populacije 100%. Programi so prikazani v obliki hierarhičnega programskega drevesa, ki so omejeni z globino. Program je sestavljen iz osnovnih računskih opravil in številskih stalnic ter spremenljivk. Na sliki 1 je prikazan primer sestave iz treh notranjih in štirih zunanjih vozlišč. Notranja vozlišča predstavljajo funkcije +, - in *, zunanja pa sklepi x, y 2 in 5. Program sestavljajo funkcije iz nabora F = {+, -, *} in sklepi iz nabora T = {x, y, N}. Simbol N pomeni naravna števila. Množici funkcij F določimo tudi seznam argumentov P = {2, 2, 2}. emphasize the important difference between the bit strings of constant length and the programmes, where the form and contents dynamically change in the course of the evolutionary process. Consequently, the size and form of programme is not defined in advance like in the case of bit strings of constant length. The search space is the space of all programmes that can be composed with functions and terminal symbols that are suitable for use. The programme is composed of a set of functions F = {f1, f,..., fNf} and a set of terminals T = {a1, a2,..., aNt}, each individual function fi from string F having a certain number of arguments z(f). Thus, the appropriate number of arguments for functions from the string F is determined by the list P = {z(f1), z(f2), ..., z(fNf)}. The examples of functions can be as follows: - arithmetic operations (+, -, *, /), - mathematical functions (sin, cos, exp, ln), - logical operations ( AND, OR, NOT), - control operators (e.g. IF-THEN-ELSE), - other functions. In the set of terminals the variables representing the input data, sensors, system variables and constants are usually found. In the beginning it is necessary to first generate the random initial population of programmes with the requirement that the multiplicity of the initial popu-lation must be 100%. The programmes are presented in the form of a hierarchical programme tree limited in depth. The programme consists of basic arithmetic operations, number constants and variables. In Figure 1 the case shows the structure from three internal and four external nodes. The internal nodes are represented by the functions +, - and * and the external ones by terminals x, y 2 and 5. The programme consists of functions from the string F = {+, -, *} and terminals from the string T = {x, y, N}. The symbol N represents the natural numbers. Moreover, the list of arguments P = {2, 2, 2} is determined by the set of functions F. (2-x)-(y + 5) 46 Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 Po ustvarjanju začetne populacije je treba za posamezne programe določiti funkcijo uspešnosti. Uspešnost oz. prilagojenost je gonilna sila naravne selekcije. Uspešnost posameznega programa določimo glede na napako oz. razdaljo do rešitve. Čim manjša je napaka, tem bolj je rešitev uspešna. Po ovrednotenju oz. določitvi uspešnosti vsakega posameznega programa sledi postopek selekcije in uporabe operatorjev, ki modificirajo posameznika v populaciji. Pri genetskem programiranju operatorje delimo na primarne in sekundarne operatorje. Primarna operatorja sta reprodukcija in križanje, sekundarni operatorji pa so mutacija, permutacija in poenostavljanje. Pri reprodukciji se program, ki je izbran na podlagi selekcije, prenese v naslednjo generacijo nespremenjen. Odstotek reprodukcije pr je vhodni parameter algoritma genetskega programiranja in običajno znaša 10%, kar pomeni, da bo približno 10% programov celotne populacije v naslednji generaciji nespremenjenih. Križanje je najpomembnejši operator pri genetskem programiranju. Glede na uspešnost v postopku selekcije izberemo dva programa ter naključno izberemo dve točki križanja. Poddrevesi, After generation of the initial population it is necessary to determine the fitness function for the indi-vidual programmes. Success and/or adaptation are the driving force of natural selection. Success of the indi-vidual programme is determined with respect to the error and/or distance from the solution. The smaller the error the more successful is the solution. The evaluation and/ or determination of success for each individual programme are followed by the selection process and the use of operators modifying the individual in the population. In genetic programming the primary and secondary operators are distinguished. The two primary operators are reproduction and crossover; the secondary operators are mutation, permutation and simplification. In the reproduction the programme selected on the basis of selection is transferred unchanged into the next generation. The percentage of reproduction pr is an input parameter of the genetic programming algo-rithm and usually amounts to 10%; this means that about 10% of the programmes of the entire population will be unchanged in the next generation. Crossover is the most important operator in genetic programming with respect to success in the selection process two programmes are selected and two crossover points are randomly selected. The KRIŽANJE / CROSSOVER starš 1 / parent 1 starš 2 / parent 2 <2) x) y C.5J (2-x)-(y + 5) x) 3+(yx) potomec 1 / offspring 1 * (2-x)-y potomec 2 / offspring 2 xj 3 + (y + 5)-x Sl. 2. Križanje Fig. 2. Crossover Ustvarjanje modela rezalnih sil - Generation of a Model for Cutting Forces 47 Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 MUTACIJA / MUTATION starš 1 / parent 1 potomec 1 / offspring 1 (2-x)-(y + 5) 2 (x x (2 - x)-x-y Sl. 3. Mutacija Fig. 3. Mutation ki sta določeni s točkama križanja, v obeh starših zamenjamo (sl. 2). Pri mutiranju se v drevesu naključno določi točka mutiranja. Poddrevo, ki je določeno s točko mutiranja, se odstrani in se naključno ustvari novo poddrevo. Globina poddrevesa, ki ga lahko vstavimo pri mutiranju, je običajno enaka največji globini drevesa začetne populacije. Globina drevesa, ki ga dobimo, ne sme preseči največje globine drevesa, ki je določena pri operatorju križanja (sl. 3). Po določenem številu generacij so programi vedno bolje prilagojeni glede na vhodne podatke. Zadana naloga je rešena, ko vsaj en program v populaciji izpolni ustavitveno merilo kar pomeni, da najboljši program pomeni rešitev problema. Cilj genetskega programiranja je najti tisti program iz ogromne množice računalniških programov, ki najbolje reši postavljeno nalogo. 3 GENETSKI MODEL REZALNIH SIL Za določitev genetskega modela rezalne sile in določitve odvisnosti rezalne sile od rezalnih parametrov smo uporabili metodo genetskega programiranja. V nadaljevanju je opisan razvoj genetskega modela rezalnih sil z genetskim programiranjem (sl. 4). Potek razvoja genetskega modela rezalnih sil z genetskim programiranjem: - iz preizkusov dobimo vrednosti rezalnih sil F, FY in FZ pri pripadajočih rezalnih parametrih (različni rezalni hitrosti V, podajanju fz, globini frezanja AD, širini frezanja RD); two sub-trees, determined by the two crossover points, are interchanged in both parents (Fig. 2). In the mutation, the mutation point is randomly determined in the tree. The sub-tree, determined by the mutation point, is removed and a new sub-tree is randomly generated. The depth of the sub-tree, which can be put in during mutation, is usually equal to the maximum depth of the initial population tree. The tree depth obtained must not exceed the maximum tree depth determined in the case of the crossover operator (Fig. 3). After a certain number of generations the programmes are better and better adapted with respect to the input data. The set task is solved when at least one programme in the population meets the stopping criterion, which means that the best programme represents the solution to the problem. The aim of genetic programming is to find the programme from the vast multitude of computer programmes that best solves the set task. 3 GENETIC MODEL OF CUTTING FORCES The genetic programming method was used to determine the genetic model of the cutting force and to determine the dependence of the cutting force on the cutting parameters. The development of the genetic model of cutting forces by genetic programming is described below (Fig. 4). Stages of development of the genetic model of cutting forces by genetic programming: - values of the cutting forces F, FY and FZ with relevant cutting parameters (different cutting speed V, feeding fz, milling depth AD, milling width RD) are obtained from experiments, 48 Milfelner M. - Župerl U. - Čuš F. Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 - določimo vhodne parametre za genetsko programiranje (velikost populacije, število generacij, verjetnost reprodukcije p, verjetnost križanja pc in mutacije pm ); - izberemo vhodne spremenljivke - množica sklepov T = {RD, AD, f, V, R}, nabor računskih opravil -množica funkcij F = {+, -, *, /} in število argumentov P ={2, 2, 3, 2}; - naključno ustvarimo začetno populacijo s stvarjenjem naključnih računalniških programov, ki so sestavljeni iz matematičnih funkcij in sklepov; - ovrednotimo populacijo, tako da izračunamo prilagojenosti posameznikov na okolje; - izberemo programe za reprodukcijo. Program, ki je izbran na podlagi selekcije, se v naslednjo generacijo prenese nespremenjen - verjetnost reprodukcije; - križamo programe - glede na uspešnost v postopku selekcije izberemo dva programa, ki jih bomo križali; - mutiramo programe; - celoten postopk ponavljamo tako dolgo dokler ni izpolnjeno ustavitveno merilo, kar pomeni, da najboljši program pomeni rešitev problema. Rezultat je genetski model največje rezalne sile F v odvisnosti od rezalnih parametrov širine frezanja RD, globine frezanja AD, podajanja fz in 4 GENETSKI MODEL REZALNIH SIL ZA OBLKOVNO KROGELNO FREZALO Za določitev genetskega modela rezalnih sil smo opravili obsežno število preizkusov na NK frezalnem stroju, pri različnih parametrih frezanja. V tem poglavju so predstavljeni rezultati preizkusov in prikaz rezalnih sil v odvisnosti od rezalnih parametrov. 4.1. Uporabljena preizkusna oprema Za preizkuse smo uporabili: - RNK frezalni center MORI SEIKI FRONTIER - M, - merilno ploščo KISTLER 9259A, - material obdelovanca Ck45, - oblikovno krogelno frezalo tip R216.44-10030-040-AL10G s premerom 10 mm, kotom vijačnice 30° in štirimi rezalnimi robovi, - material frezala GC 1010. - input parameters for genetic programming (population size, no. of generations, probability of reproduction p , probability of crossover p and mutation pm) are determined, - input variables - set of terminals T = {RD, AD, fz, V, R}, the string of arithmetic operations - set of functions F = {+, -, *, /} and the number of arguments P ={2, 2, 3, 2} are selected, - the initial population is randomly generated by creating random computer programmes consisting of mathematical functions and terminals, - the population is evaluated by computing the adaptations of individuals to the environment, - the programmes for reproduction are selected. The programme selected in accordance with the selection is transferred unchanged into the next generation - probability of reproduction, - the crossover of programmes - depending on the success in the selection process. Two programmes, which will be crossed over, are selected, - the programmes are mutated, - the entire process is repeated until the stopping criterion has been met, which means that the best programme represents the solution of the problem. The result is the genetic model of the maximum cutting force F , depending on the cutting parameters: milling w ma dth RD , milling depth A , feeding fz, and cutting speed Vc. 4 GENETIC MODEL OF CUTTING FORCES FOR BALL-END MILLING CUTTER An enormous number of experiments on an NC milling machine with different milling parameters have been carried out to determine the genetic model of the cutting forces. This chapter presents the results of experiments and the cutting forces depending on the cutting parameters. 4.1 Experimental equipment used The following equipment was used for the experiments: - CNC milling center MORI SEIKI FRONTIER - M, - measuring plate KISTLER 9259A, - workpiece material Ck45, - ball-end milling cutter type R216.44-10030-040-AL10G, diameter 10 mm, helix angle 30° and four cutting edges, - milling cutter material GC 1010. Ustvarjanje modela rezalnih sil - Generation of a Model for Cutting Forces 49 Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 Reprodukcija Reproduction r < pr i Križanje / Crossover Mutacija / Mutation r < pc r < pm Genetski model rezalnih sil Genetic model of cutting forces Fmax=f(AD, RD, fz, vc) Sl. 4. Genetski model rezalnih sil Fig. 4. Genetic model of cutting forces 4.2 Genetski model rezalnih sil pri frezanju z oblikovnim krogelnim frezalom Za določitev povezave med rezalno silo in rezalnimi parametri smo razvili genetski model rezalne sile na podlagi genetskega programiranja. Za določitev genetskega modela rezalne sile z genetskim programiranjem smo pri frezanju s frezalom R216.44-10030-040-AL10G izbrali 45 preizkusnih podatkov. Vrednosti največjih rezalnih sil smo izmerili pri različnih rezalnih parametrih (širina frezanja RD = 0,2 do 0,6 mm, globina frezanja A = 0,2 do 0,6 mm, podajanje fz = 0,08 do 0,12 mm/zob in rezalna hitrost V = 125 do 250 m/min). 4.2 Genetic model of cutting forces during milling with a ball-end milling cutter The genetic model of cutting forces was developed on the basis of genetic programming to determine the relation between the cutting force and the cutting parameters. To determine the genetic model of the cut-ting force by genetic programming the data from 45 experiments were selected during milling with the cutter R216.44-10030-040-AL10G. The values of the maximum cutting forces were measured with different cut-ting parameters: milling width RD = 0.2 to 0.6 mm, mill-ing depth AD = 0.2 to 0.6 mm, feeding fz = 0.08 to 0.12 mm/tooth and cutting speed Vc = 125 to 250 m/min). 50 Milfelner M. - Župerl U. - Čuš F. Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 Na podlagi vhodnih in eksperimentalnih podatkov in ob izbiri ustreznih računskih opravil ustvarimo model za določitev rezalne sile: On the basis of the input and the experi-mental data and by selecting suitable arithmetic op-erations the model for the determination of the cut-ting force is generated: Fmax =f(RD AD fz Vc (1). Za določitev genetskega modela izberemo vhodne spremenljivke - množica sklepov: For the determination of the genetic model the input variables - terminal set are selected: T = {x, y , z , w , R } kjer je x - širina frezanja R , y - globina frezanja A , z - podajanje fz, w - rezalna hitrost V in R - realna števila na intervalu od -10 do 10, nabor računskih opravil - množica funkcij: F = {+, -, *, /}, kjer so “+” - opravilo seštevanja, “-” - opravilo odštevanja, “*” - opravilo množenja in “/” -računsko opravilo deljenja, in število argumentov: P = {2, 2, 3, 2}. Za določitev genetskega modela rezalnih sil smo izbrali velikost populacije organizmov M = 1000 in število generacij G = 100. Uporabili smo genetske operacije: reprodukcijo, križanje in mutacijo. Verjetnost reprodukcije pr = 0,1, križanja pc = 0,6 in 200- where x is the milling width RD, y is the milling depth AD, z is the feeding fz, w is the cutting speed Vc, and R are real numbers over the interval from -10 to 10, the string of the arithmetic operation - function set is selected: F = {+, -, *, /}, where “+” is the operation of addition, “-” is the operation of subtraction, “*” is the operation of multiplication and “/” is the operation of division and the number of arguments is selected: P = {2, 2, 3, 2}. The size of the population of organisms M = 1000 and the number of generations G = 100 were selected for the determination of the genetic model of cutting forces. The genetic operations of repro-duction, crossover and mutation were used. The 180 160 140 120 100 80 60 40 20 VA Velikost populacije / Population size: M=1000 Število generacij / No. of generations: G=100 Verjetnost reprodukcije / Probability of reproduction: p=0,1 Verjetnost križanja / Probability of crossover: pc=0,6 Verjetnost mutacije / Probability of mutation: p =0,1 0-I------ 0 10 20 30 40 50 60 70 Generacija / Generation 80 90 100 Sl. 5. Krivulja evolucijskih potencialov najboljših organizmov Fig. 5. Curve of evolutionary potentials of best organisms Ustvarjanje modela rezalnih sil - Generation of a Model for Cutting Forces 51 Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 mutacije je pm = 0,1. Razvoj modela je končan, ko je doseženo največje predpisano število generacij. Slika 5 prikazuje krivuljo evolucijskih potencialov najboljših organizmov. Pri frezanju s frezalom R216.44-10030-040-AL10G dosežemo najboljšo prilagojenost v osemindevetdeseti generaciji, ta je 3,83%. V osemindevetdeseti generaciji dobimo najboljšo prilagojenost organizma, ki ustreza eksperimentalnim podatkom. Genetski model rezalne sile pri frezanju z oblikovnim krogelnim frezalom R216.44-10030-040-AL10G prikažemo z enačbo: probability of reproduction is pr = 0.1, that of crosso-ver pc = 0.6 and that of mutation pm = 0.1. The development of the model is finished when the greatest specified number of generations has been reached. Figure 5 shows the curve of the evolution-ary potentials of the best organisms. During milling with the cutter R216.44-10030-040-AL10G the best adaptation is reached in the 98th generation, i.e., 3.83%. In the 98th generation the best adaptation of the organism agreeing with the experimental data is obtained. The genetic model of the cutting force dur-ing milling with the ball-end milling cutter R216.44-10030-040-AL10G is represented by the equation: Fmax=11,0486 + RD-AD+Vc-RD-AD-58,5012-(-8,2466 + AD)-AD + 58,5012-(-8,2524 + AD)-(0,0058 + AD) + Vc -(-0,7975-0,2868-fz) Vc -(2,802 + RD).(2,7956-AD)-fz2 Vc-RD (2,802+ RD) (2). 0,1012-Vc-2-RD-AD+fz-0,5736-Vc-fz Primerjava preizkusnih vrednosti z A comparison of the experimental values vrednostmi genetskega modela rezalne sile je with the values of the genetic model of the cutting prikazana v diagramu (sl. 6). force is shown in a diagram (Fig. 6). 450 420 390 360 330 300 270 240 210 180 150 120 90 60 30 0 Velikost populacije / Population size: M=1000 Število generacij / No. of generations: G=100 Verjetnost reprodukcije / Probability of reproduction: p =0,1 Verjetnost križanja / Probability of crossover: pc=0,6 Verjetnost mutacije / Probability of mutation: pm=0,1 Preizkus / Experiment: ________ Genetski model / Genetic model: 0 3 6 9 12 15 18 21 24 27 30 33 36 39 42 45 Eksperimentalni podatki / Experimental data Sl. 6. Primerjava preizkusnih vrednosti z vrednostmi genetskega modela Fig. 6. Comparison of experimental values with the values of the genetic model 52 Milfelner M. - Župerl U. - Čuš F. Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 5 SKLEP 5 CONCLUSION V prispevku je predstavljen razvoj This paper presents the development of a ge- genetskega modela rezalnih sil pri postopku frezanja netic model of the cutting forces in the process of mill- z oblikovnim krogelnim frezalom. Model je namenjen ing with a ball-end milling cutter. The model is intended za napovedovanje rezalnih sil in optimiranje rezalnih for the prediction of cutting forces and the optimization parametrov pri postopku frezanja. Ustvarjen in of the cutting parameters during milling. It has been gen- preizkušen je na podlagi velikega števila preizkusov, erated and tested on the basis of a large number of ex- z različnimi rezalnimi parametri. periments with different cutting parameters. Osnovna zamisel, ki je predstavljena v The basis of the paper is the presentation prispevku, je prikaz odnosov med orodjem in of the relations between the tool and the workpiece obdelovancem med postopkom obdelave, ki je during the machining process described with the opisan z genetskim modelom rezalnih sil. genetic model of cutting forces. Predstavljen model lahko uporabimo za The presented model can be used for the napovedovanje rezalnih sil, optimiranje rezalnih prediction of cutting forces, the optimization of cut- parametrov, zmanjšanje celotnega časa obdelave, ting parameters, the reduction of the total machin- povečanje natančnosti, zanesljivosti, produktivnosti ing time, for an increase of accuracy, reliability, pro- in zmanjšanje stroškov obdelave. ductivity and for decreasing the machining costs. 6 LITERATURA 6 REFERENCES [I] Luttervelt, V., T. H. C Childs, I. S. Jawahir, F. Klocke, PK. Venuvinod (1998) Present situation and future trends in modeling of machining operations, Annals of CIRP, Vol. 47(2), 578-626. [2] Yucesan, G., Y. Altintas (1993) Mechanics of ball end milling postopks, ASME Winter Annual Meeting, PED, Vol. 64, 543-551. [3] Tai, C. C, K.H. Fuh (1994) A predictive force model in ball-end milling including eccentricity effects, International Journal of Machine Tools and Manufacturing, Vol. 34(7), 959-979. [4] Hinduja, P. J., D.J. Petty, M. Tester, G. Barrow (1985) Calculation of optimum cutting conditions for turning operations, Proceedings of the Institution of Mechanical Engineers, Vol. 199(B2), 81-92. [5] Arsecularatne, J. A., S. Hinduja, G. Barrow (1992) Optimum cutting conditions for turned components, Proceedings of the Institution of Mechanical Engineers, Vol. 206(B2), 15-31. [6] Milfelner, M., F Čuš (2003) Simulation of cutting forces in ball-end milling. Robotics and Computer Integrated Manufacturing Vol. 19 (1/2), 99-106. [7] Liao, T. W., L.J. Chen (1998) Manufacturing process modeling and optimization based on multi-layer perceptron network, ASME, Journal of Manufacturing Science and Engineering, Vol. 120, 109-119. [8] Motghare, P. R.: Monitoring of cutting tools by the estimation of tool wear, Masters Thesis, Indian Institute of Technology, Delhi, India. [9] Čuš, F, J. Balič (2003) Optimization of cutting postopks by GA approach, Robotics and Computer Integrated Manufacturing, Vol. 19, (1/2), 113-121. [10] Liu, Y, T. Chen, L. Zuo, S. Yang (1996) K-L optimization of cutting parameters in machining, Journal of Huazhong University of Science and Technology, Vol. 24(5), 50-52. [II] Xu, X. (1996) Fuzzy optimization of metal cutting parameters, Journal of Huabei Power Institute, Vol. 23(3), 65-69. [12] Brezočnik, M. (2000) Uporaba genetskega programiranja v inteligentnih proizvodnih sistemih, Fakulteta za strojništvo, Maribor. [13] Koza, J. R. (1994) Introduction to genetic programming. in: Advances in genetic programming, The MIT Press, Cambridge, Massachusetts. Ustvarjanje modela rezalnih sil - Generation of a Model for Cutting Forces 53 Strojniški vestnik - Journal of Mechanical Engineering 51(2005)1, 41-54 Naslov avtorjev: dr. Matjaž Milfelner dr. UrošŽuperl prof. dr. Franci Čuš Univerza v Mariboru Fakulteta za strojništvo Smetanova 17 2000 Maribor matjaz.milfelner@uni-mb.si uros.zuperl@uni-mb.si franc.cus@uni-mb.si Authors’ Address: Dr. Matjaž Milfelner Dr. UrošŽuperl Prof. Dr. Franci Čuš University of Maribor Faculty of Mechanical Eng. Smetanova 17 SI-2000 Maribor, Slovenia matjaz.milfelner@uni-mb.si uros.zuperl@uni-mb.si franc.cus@uni-mb.si Prejeto: Received: 22.6.2004 Sprejeto: Accepted: 2.12.2004 Odprto za diskusijo: 1 leto Open for discussion: 1 year 54 Milfelner M. - Župerl U. - Čuš F.