Application of Fuzzy-Genetic Algorithms to Mechanical Optimization

3 downloads 710 Views 263KB Size Report
The use of a fuzzy-logic algorithm to drive the search of the genetic algorithm [1, 2] ... Linguistic target functions are handled (inference engine) according to a ..... [9] Vanderplaats, G., Numerical Optimization Techniques for Engineering Design ...
Application of Fuzzy-Genetic Algorithms to Mechanical Optimization Gianni Caligiana, Gian Marco Saggiani, Tiziano Bombardi Dipartimento di Ingegneria delle Costruzioni Meccaniche, Nucleari, Aeronautiche e di Metallurgia – DIEM – Facoltà di Ingegneria, Viale Risorgimento, 2 – 40136 Bologna Italy e-mail: [email protected]

Abstract Work’s purpose is to ascertain the suitability of the fuzzy-genetic algorithm (FGA) methodology, introduced by two of the authors in previous papers [1, 2], for the optimization of mechanical components subject to several design criteria and constraints. This approach is applied to the choice of modulus and pitch diameters of pinion or gear for a reduction spurgear train, knowing input power, pinion revolutions per minute and velocity ratio. The search is performed for a minimal gear centre distance, while meeting the requirements for geartooth surface fatigue strength and for fatigue gear-tooth-bending strength. FGA optimization results are arranged by an “ad hoc” MDL program, written by one of the authors, which automatically draws the 3D model in MicroStation environment. So the designer can directly visualize or plot a true scale picture of the solution for the problem considered. 1.

INTRODUCTION

This paper is part of a larger effort devoted by the authors to the development of computerized tools in assisting designer’s activity. Authors focused their attention on the preliminary phase of engineer’s design activity where the most influencing decisions are assumed for the successive development of a project. First of all, a fuzzy design tool has been developed [3] to perform a rough component sizing and a sensitive analysis of the most influencing parameters for the design, by accounting for any objective constraint or for pre-existing subjective experience of the designer. Then several component optimization programs have been written by the authors following different methodologies: genetic algorithms [4], fuzzy-cellular automata algorithms [5, 6], fuzzy-genetic algorithms (FGAs) [1, 2]. Aim of the paper is the further verification of this latter methodology in mechanical component optimization through the connection of the mathematical modelling to a CAD straightforward visualization of the FGA results. FGAs have been proposed to alternatively face some of the difficulties the classical optimization methods show in treating multi-objective and multi-constraint problems. Several standard approaches have been proposed in literature. One of those assumes a weighted global objective function summarizing, inside the same expression, optimization criteria and

constraints while requiring the proper settings of some weighting parameters [7, 8]. Another approach considers the evaluation of the minimum or maximum of each design function, independently from the others, and, then, it derives the solution by minimizing the normalized distance of each design function from individual optima [9, 10]. In the former case, there is, often, a subjective influence of the designer and several iterations are needed for the calibration of the global objective function. In the latter, penalty function or multiplier methodologies must be utilized to account for the constraints. The use of a fuzzy-logic algorithm to drive the search of the genetic algorithm [1, 2] has been proposed to substitute the utilization of the already mentioned weighting parameters or the search for the minimum distance from individual optima. In this paper different examples of spur-gear reduction train optimization are considered. For all cases, automated 3D pictures can be derived to directly check the suitability of the results. 2.

FGA OPTIMIZATION

A brief description of the FGA methodology is given here (Fig. 1), while details can be found elsewhere [1].

FITNESS FUNCTION TARGET FUNCTIONS Ti

Tentative population

Design functions Genetic decoding

Design parameters

Fuzzy-logic algorithm

Fitness value

Constraint functions New population Selection Crossover Mutation

Checks for unphysical solutions

Fig. 1. Scheme of the fuzzy-genetic algorithm. Each set of design variables identified in the optimization problem are suitably codified to represent a virtual individual (possible problem-solution string) of a geneticalgorithm virtual population. For each individual, the genetic algorithm derives the corresponding crisp values of the design and constraint functions (globally called, by the authors, target functions). The new method, exposed in paper [1], consists in deriving the merit function (fitness) of each individual through a fuzzy logic algorithm, instead of utilizing the classical

weighted objective function [7, 8]. Inside the fuzzy engine, the fitness and both the design and constraint functions (target functions) are transformed in linguistic variables (expressed through fuzzy numbers, [11]). The fuzzy algorithm behaves like a controller and is composed of three major components: an input interface, an inference engine and an output interface [1, 6, 12]. a) The input interface (fuzzification module) performs a crisp to fuzzy transform of the target functions into linguistic variables (for details, see [6]). b) Linguistic target functions are handled (inference engine) according to a heuristic rule base, suitably settled [1, 2], to obtain linguistic values for the linguistic fitness. c) The output interface (defuzzification module) allows to derive the crisp output (the crisp value of the fitness) from the fuzzy output obtained during the inference phase, by applying the centre of gravity method or the height method [1, 6, 12]. Crisp fitness is, as usually, utilized by the genetic algorithm (selection, crossover and mutation, [13]) to improve the population of the solutions and to derive the near optimum suitable virtual individual (Fig. 1). 3.

REDUCTION GEAR TRAIN

The sizing of a reduction gear train is examined. In particular, spur gears are considered. In this case a known theoretical solution [14, 15, 16] can be easily derived and compared with the numerical evaluation performed by the FGA. Assumed data for the problem are: input power (P) in W, revolutions per minute of the pinion (np) and velocity ratio (τ), together with pinion and gear materials. The design parameters are: module (m) and number of teeth (zp) of the pinion (those relative to the gear can be obtained as a consequence). They are coded to a 10 bit string, corresponding to 32 discrete values for each design parameter, accounting for commercial availability. Suitable constraints are considered to avoid teeth interference and to ensure a proper contact length. The target functions, Ti, (with the meaning specified in § 2 and in [1]) are the centre distance (c) and the surface gear-tooth fatigue stress (σH):

T1 = c = d p

1 + (1 / τ ) 2

T2 = σ H = C p

Ft b dp I

Ko Kv Km

(3)

with the known meaning of the defined symbols and where [16]: C p = 0.564

1 1 −ν Ep

Ep, Eg νp , νg Ft =

60 P π np d p

2 p

+

1 −ν g2

is the elastic coefficient;

Eg are, respectively, the Young’s moduli of pinion and gear; are, respectively, the Poisson’s ratios for pinion and gear; is the tangential component of the load between teeth;

I=

sen ϕ cos ϕ R 2 R +1

is the geometry factor;

ϕ R=

is the pressure angle; dg

is the ratio of gear and pinion diameters;

dp

b=λm dp Ko Kv Km

is the tooth width (λ = 10 is assumed); is the pitch diameter; is the velocity or dynamic factor; is the overload factor; is the mounting factor.

Let SH be the gear-tooth surface fatigue strength:

S H = S fe C Li C R

(4)

where: Sfe CLi CR

is the surface fatigue strength (metallic spur gears, 107-cycle life, 99% reliability); is the life factor (= 1 at 107 cycles); is the reliability factor (= 1 for 99% reliability).

A safety factor, Fs = SH/σH = 1.4, is considered in reducer optimization so that an allowable surface fatigue strength Sall = SH/1.4 is actually utilized. Aim of the search is to find the configuration corresponding to the minimum centre distance (c), while maintaining the gear-tooth surface stress for the pinion and for the gear (generally pinion is the more critical one) lower than the allowable surface fatigue strength (Sall), but as near as possible to Sall itself: A check is also performed relative to the effective fatigue gear-tooth-bending stress, which can be expressed as:

σ =

Ft bmJ

Ko Kv Km

(5)

with the known meaning of the defined symbols and where J is the geometry factor. For every feasible solution, effective bending stress must always be lower than the corresponding fatigue strength:

S n = S ' n C L C G C S k r k t k ms

(6)

where, [16]: S’n CL CG CS

is the standard endurance limit (in rotating bending; R.R. Moore testing machine); is the load factor (= 1 for bending loads); is the gradient factor; is the surface factor;

Actually, the same safety factor assumed for the surface fatigue stress (Fs = 1.4) is considered in comparing the effective fatigue gear-tooth-bending stress to the corresponding fatigue strength. The membership functions assumed for linguistic values of T1, T2 and fitness are similar to those assumed in the test case reported in [1] for the cantilevered tube in bending and torsion.

4.

MDL INTERFACE NUMERICAL PROGRAM

MDL (MicroStation Development Language) is the classical development environment of MicroStation (MS) delivered with MS itself. It is an ANSI C based language supplied with compiler, linker, make utilities, libraries and debugger, without additional costs. MDL allows to develop applications to suit the CAD program to customer peculiar requirements. The representation of gearing system components has been performed through an “ad hoc” application software tool called Gencad (developed by one of the author). Gencad user interface, shown in Fig. 2, is specialized in handling parametric geometric solid shapes (features) for mechanical assembly component representation. This application tool allows to define 2D entities (like points, segments, arcs, circles, generic profiles), 3D entities (like parallelepipeds, cylinders, cones, spheres, tori, extrusion or revolution solids, CSG solids, etc.). Boolean operators, displacement or rotational operators can be applied to the cited primitives. The generalized shape for component representation is described in a text file, with a suitable syntax. Inside Gencad, generalized shapes can be utilized to generate a new one, while maintaining their parametric characteristics. For example, the primitive of a nut (dado3D) is defined through parametric height (k), and parametric width across flats (ch) of the hexagon.

Fig. 2. Gencad graphical interface. This primitive can be utilized to define a new generalized shape (Fig. 3), which collects a modified version of the nut with a threaded cylindrical body, to obtain, as a Boolean union, a screw (vite3D), with the already defined parameters “ k ” and “ch”, and with additional parameters, like, for example (Fig. 2), screw nominal diameter (d) and screw length (lg) measured underneath the head.

In the actual gear train FGA optimization, Gencad source program has been modified to be interfaced with Mathematica. Gencad records assigned input data of the reduction gear train (gear and pinion materials, transmitted power, pinion revolutions per minute, velocity ratio) and supplies them to the FGA, written in Mathematica language. A “RunMath” command is introduced to let FGA program running and, automatically, sending back optimized parameters to Gencad, in the form of a suitable text file. Then Gencad allows Microstation to represent the optimized reduction gear train.

# Generico vite3d d ? "diametro bullone" 10; ch ? "chiave" 17; k ? "altezza dado" 8; lg ? "lunghezza gambo" (5*d); # -----------------------------------------------s1 : load_generico dado3d( ch=ch,k=k); s1m : s1 mby movz=(-k); s2 : cil( (0.5*d), lg ); bullone : s1m un s2; return vite3d disegna vite3d ?

Fig. 3. Generalized shapes representing a screw obtained by suitably merging two other primitives (a modified nut and a threaded cylinder).

5.

RESULTS AND DISCUSSION

Several tests were performed about possible influence on results of the number of linguistic values (or number of independent fuzzy numbers) defining linguistic target functions or linguistic fitness. Those tests are performed by assuming: input power (P = 5000 W), revolutions per minute of the pinion (np = 1400 rpm) and velocity ratio (τ = 0.2). A 18NiCrMo5 steel is considered for the pinion and a 16CrNi4 for the gear. In Table 1 the test named “m_n” means “m” linguistic values for the target functions and “n” linguistic values for the fitness (expressed, respectively, by “m” and “n” corresponding fuzzy numbers). Normalized run time is evaluated by dividing the time of each run by the lowest value obtained. At the end of 20 independent runs of the FGA, the mean values for the normalized centre distance (better numerical estimate of the centre distance/known value of the calculated solution, c/co) and the mean value for the normalized surface stress (ratio between the surface stress and the allowable corresponding surface fatigue strength, σH/Sall) are recorded. Owing to the higher number of rules fired simultaneously in the inference phase [1], the increment of the number of linguistic values utilized increases hugely the relative run time. No other clear trend can be inferred, probably owing to the randomness, always present

in the otherwise “fitness-driven” genetic algorithm. For example, when 5 fuzzy numbers are considered for the target functions (series 5_n), an increase of the fitness linguistic values “n” seems to lead to a worst performance relative to the normalized surface stress (values of σH/Sall are farther from the target value, equal to 1), while a not clear tendency appears for the normalized centre distance (c/co). Table 1 Mean values obtained on 20 independent runs of the FGA

Series

σH/Sall

c/co

3_3 3_5 3_7 5_5 5_7 5_9

0.910 0.903 0.913 0.915 0.901 0.898

1.073 1.072 1.077 1.074 1.091 1.075

Normalized run time 1.108 1.000 1.013 3.687 5.633 6.709

Occurrences

Attention must be paid in examining these results. Any consideration derives from the examination of the mean value tendency and, therefore, a very unlucky run of the FGA can penalize several good results. Nevertheless, the analysis shows that configurations 3_n and 5_n are both suitable and practically equivalent, so that the less time consuming 3_n can be utilized. Optimization objective is reached, because the results are always near to the theoretically evaluated solution. If a sufficient numbers of independent runs were performed, a solution very near to optimum can be derived. See, for example the histograms of Fig. 4 e 5 where 42 independent runs of the algorithm corresponding to a 3_7 series (3 fuzzy numbers for the target functions and 7 fuzzy numbers for the fitness) are considered.

30 25 20 15 10 5 0 0,65

0,75

0,85

0,95

1,05

Normalized fatigue stress (adim.) Fig. 4.

Typical occurrences of normalized surface fatigue stress values (σH/Sall) in 42 independent FGA runs.

Occurrences

In Fig. 4 the values obtained by the FGA for the normalized surface stress (σH/Sall) are recorded as abscissas, while the number of times each value occurs is shown as ordinate. The greater part of the 42 values concentrates near the known solution (σH/Sall = 1). The error between the numerical data and the known solution can be less than 7%. For the normalized centre distance (c/co) a better trend can be observed (Fig. 5). The major part of the runs of the FGA gives results differing from the known solution for less than 5%. In this case, however, a particularly bad run of the FGA can be identified (Fig. 5). This outlines how important is, for a genetic algorithm (and, consequentely, also for the FGA) to repeat, for at least 20 times, the independent program runs, as suggested in literature [17], to avoid the attainment of bad results due to an unlucky event.

30 25 20 15 10 5 0 0,95 1,05 1,15 1,25 1,35 1,45 1,55 1,65 Normalized centre distance (adim.)

Fig. 5. Typical occurrences of normalized centre distance values (c/co) in 42 independent FGA runs. The values of the errors between FGA results and known solution must not be misleading. In this example, discrete values for the design parameters are utilized, so that convergence to solution of the genetic engine of the FGA is hampered. Lower errors can be observed when continuous values for the design parameters can be allowed (see, for example, the test case in [1]). In Fig. 6 an example of optimized reduction gear trains is shown in MicroStation environment. Assumed data for the configuration of Fig. 6 are: input power (P = 4000 W), revolutions per minute of the pinion (np = 1400 rpm) and velocity ratio (τ = 0.45); a 18NiCrMo5 steel is considered for the pinion and a 16CrNi4 for the gear, as before (but, obviously, properties relative to any other couple of materials can be introduced). The advantage of the methodology is that a 3D model is allowable to eventually perform, automatically, the 2D layout of the assembly drawing.

6.

CONCLUSIONS

In this paper optimization of reduction spur gear trains is considered. Knowing power to be transmitted, gear ratio and revolutions per minute of the pinion, the search is performed for a minimal centre distance meeting the requirements for fatigue surface and bending strength of the teeth. Instead of using classical optimization criteria, a fuzzy-genetic algorithm (FGA) is considered. The combined algorithm consists of a genetic algorithm (GA) in which fitness is inferred by a fuzzy engine transforming design and constraint functions in linguistic variables expressed by fuzzy numbers. The methodology is described in details elsewhere [1, 2]. A 3D model of the optimized gearing system is automatically obtained through an MDL application (Gencad) which extract data from the FGA and allows MicroStation program to perform the drawing. The methodology is very versatile and its straightforward extension to other mechanical assemblies can be considered.

Fig. 6. Isometric view of the optimized reduction gear train corresponding to P = 4 kW, np = 1400 rpm, t = 0.44.

7.

ACKNOWLEDGEMENTS

The authors like to thank Prof. Franco Persiani for the foundamental support during ideation and development phases of FGA methodology. Furthermore they are grateful to D.U. Engineer Gemma Foschi for the hard work carried on during the successive application steps.

REFERENCES [1] [2] [3] [4] [5]

[6] [7] [8] [9] [10] [11] [12] [13] [14] [15] [16] [17]

Caligiana, G., Persiani, F., Saggiani, G.M., Fuzzy-Genetic Optimization for Engineering Problems, Part I: Theory, Pubblicazione interna del DIEM, n° 100, Bologna, 1999. Caligiana, G., Persiani, F., Saggiani, G.M., Fuzzy-Genetic Optimization for Engineering Problems, Part II: Aeronautical and Mechanical Applications, Pubblicazione interna del DIEM, n° 101, Bologna, 1999. Caligiana, G., Fuzzy Logic in Engineering Applications, Österreichische Ingenieurund Architekten Zeitschrift, ÖIAZ, 140 Jg., Heft 9, pp. 275-280, Wien, 1995. Caligiana, G., Cesari, F., Saggiani, G.M., Ottimizzazione ed analisi dei costi di un telaio per il trasporto di biciclette mediante algoritmo genetico, Il Progettista Industriale, Tecniche Nuove S.p.A., pp.50-57, Milano, Luglio 1999,. Persiani, F., Piancastelli, L., Ottimizzazione della laminazione di pannelli in materiale composito mediante automi cellulari, Atti del IX Convegno Nazionale ADM, Officine grafiche Francesco Giannini & Figli, pp. 715-723, Caserta - Aversa 27-29 Settembre 1995. Caligiana, G., Saggiani, G.M., Controllo dell'evoluzione degli automi cellulari mediante algoritmo fuzzy: teoria e casi esemplificativi, Scritti per Ettore Funaioli, Progetto Leonardo, Esculapio Ed. s.r.l., pp. 35-50, 1996. Galante, M., Genetic Algorithms as an Approach to Optimize Real-World Trusses, International Journal for Numerical Methods in Engineerings, 39: 361-328, 1996. Goldberg, D.E, Asce M., Samtani M.P., Enginerering optimization via genetic algorithm, Proceedings of the ninth Conference on Electronic Computation, ASCE, New York, 1986. Vanderplaats, G., Numerical Optimization Techniques for Engineering Design, McGraw-Hill, 1984. Arora, J.S., Introduction to Optimum Design, McGraw-Hill, 1989. Zimmermann, H.J., Fuzzy Set Theory and its Applications, Kluwer Academic Publishers, Dordrecht, The Netherlands, 1993. Brubaker, D.I., Fuzzy-Logic basics: intuitive rules replace complex math, EDNDesign Feature, pp. 111-116, 1992. Leite, J.P.B., Topping, B.H.V., Improved genetic operators for structural engineering optimization, Advances in Engineering Software, Elsevier Science Ltd, Great Britain, 29, pp.529-562, 1998. Shigley, J.E., Minschke, C.R., Mechanical Engineering Design, McGraw-Hill, New York, 1989. Spotts, F.M., Design of Machine Elements, Prentice-Hall, Inc., Englewood Cliffs, N. J., 1985. Juvinall, R.C., Marshek, K.M., Fundamentals of Machine Component Design, John Wiley & Sons, New York, 1991. Davis, L., Handbook of Genetic Algorithms, Van Nostrand Reinhold, New York, 1991.