Comparison between genetic and gradient-based

IEEE TRANSACTIONS ON MAGNETICS, VOL 31, NO 3. MAY 1995
1932
COMPARISON BETWEEN GENETIC AND
GRADIENT-BASED OPTIMIZATION ALGORITHMS
FOR SOLVING ELECTROMAGNETICS PROBLEMS
Randy Haupt
HQ USAFADFEE
2354 Fairchild Dr, Suite 2F6
USAF Academy, CO 80132
Abstract -- This paper compares the application of genetic
algorithms and traditional gradient-based algorithms to various
optimization problems in electromagnetics. Gradient algorithms
work well for a small number of continuous parameters. Genetic
algorithms are best for a large number of quantized parameters.
Both antenna array and scattering optimization examples are
shown.
I. INTRODUCTION
Genetic algorithms are "global" numerical optimization
methods based on genetic recombination 'and evolution in
nature. The algorithms encode par'meters into bin'q
sequences called genes. The genes undergo natural selection,
mating, and mutation to arrive at the final optimum solution.
These algorithtns have been applied to a variety of
optimization problems [l] 'and only recently have been applied
to optimize electromagnetics problems [2, 3, 41.
Gradient based algorithms have traditionally been used to
find the optimum solution to electromagnetics problems.
They tend to be fast, but they require the computation of
derivatives ,and tend to get stuck in local minima. In addition,
they can only optimize a. few continuous puruneters.
This paper presents z u n y and RCS (radar cross section)
optimization problems tackled with genetic algorithms and/or
gradient-based algorithms. A comparison of the applications
and ndvantrtges/disadw~tagesof the two types of algorithms
will be presented.
11. GENETIC ALGORITHMS
Genetic dgorithms are quite simple to program.
following steps explain the basic algorithm:
The
2. Generate M r'andom genes that represent M possible
cornbinations of the parameters a, b,
C.
gene1
gene2
111010001
100011101
geneM
011001111
3. Calculate the cost function associated with each gene.
Each combination of parameters (gene) has an associated cost
function like sidelobe level, null depth, etc. The genes are
ranked from best to worst.
&z!e
cost
1 1 1 0 1 0 0 0 1 -9dB
1 0 0 0 1 1 1 0 1 -8dR
0 1 1 0 0 1 1 1 1 -7dB
4. Discard genes with poor cost functions. Sometimes just
the bottom half of the genes are discarded.
keep
keep
gmg
COSt
1 1 1 0 1 0 0 0 1 -9dB
1 0 0 0 1 1 1 0 1 -8dB
discard
0 1 1 0 0 1 1 1 1 -7 dB
5. The remaining genes pair and mate. Pick two genes <and
calculate a random crossover point. Two new genes called
offspring are generated by the parents swapping their genetic
sequence to the right of the crossover point.
1. Encode pmmeters in a binary sequence called a gene.
For instance, if pmmeters a, b, 'and c are encoded using 3
bits for each parameter, the gene would look like
parents
U
gene
parameters
a
b
t
reproduction
crossover
11
1
ofipring
111011101
100010001
-101111001
=,
111010001
100011101
c
0018-9464/95$04,00
1995 IEEE
1933
6. R'andom mumions (a 1 is changed to a 0 or a 0 ch'anged
to a 1) occur in the new set of genes.
7. Go to step 3 'and r e p i t the process until a set number of
iterations is completed.
The previous steps are easy to implement with a computer
program. I used MATLAB [5] to program the genetic
algorithms for this paper.
The adv"iiges of genetic algorithms are they cLan
1. optimize a large number of par'ameters,
2. optimize discrete parameters,
3. perform a "global" optimization, 'and
4. optimize without the calculation of gradients.
Their main disadvantage is that they are slow. The next two
sections show the application of optimization algorithms to the
optimization of antenna ranay far field patterns and strip
scattering patterns.
x,=2.3531 x2=3.0931 ~,=4.0371
where 3L is the wavelength. Fig. 1 shows the resulting far
field pattem with a mrurimum relative sidelobe level of -21.6
dB. Convergence time for this problem only depends on the
number of edge elements to be optimized 'and not the total
number of elements in the " a y (unless mutual coupling is
taken into account).
The cost surface for this optimization problem gets
extremely complicated as the number of element spacings to
be optimized increases. The additional local minima confuses
the algorithm and m'akes convergence on the "global"
minimum extremely unlikely. This three parcameterproblem
is easily solved with the BFGS algorithm. Tackling a larger
problem requires either a more sophisticated approach or a
global approach that is offered by genetic algorithms or
simulated anneding. Genetic algorithms CM also optimize
this three par'meter problem. They are not very efficient,
though, because there ;are only a few parameters. The
continuous optimization algorithms avoid the quantization
error associated with the genetic algorithms.
111. OPTIMIZED ANTENNA ARRAYS
maxsiddobelevel=-21.5 dB N-4 M-3
Consider optimizing a partically tiipered <anay. A partially
tapered 'may has the center 2N elements uniformly weighted
'and spaced, but the 2M edge elements are nonuniformly
weighted ,and/or spaced. The equation for a parti,ally tapered
array lying along the x-,wis is
O
k
.j/ \
.IO
N+M
where
2N = number of uniform elements in the center of the <anay
2M = number of nonuniform edge elements
= 21tdc0~$
d = unifonn spacing in wavelengths
$ = observation 'angle from x-,wis
x,,= distzince of element n from 'anay center in wavelengths
The partid taper results in a modest sidelobe reduction
while simplifying the m a y feed network. The goal is to
produce a partial taper that results in the lowest m'wimum
sidelobe level. This problem only has a few parameters, so
traditional optimization methods work well.
The Broyden-Fletcher-Goldfarb-Shanno(BFGS) 161 quasiNewton algorithm was used to optimize an m a y with the
eight center elements uniformly weighted ,and spaced and the
three edge elements on either side nonuniformly spaced. The
optimized spacings are
Fig. 1 Far field pattern of a partically tqered <may
optimized with the BFGS algorithm.
A more difficult optimization problem is to optimize the
spacings for all the elements in the 'may. Consider a 24
element 'may with sin@element patterns. The 'anay is to be
optimized to obtziin the lowest possible sidelobe levels in the
far field pattem. The number of par'meters to be optimized
is too large for most optimization algorithms. The spacings
of the elements are quantized to three bits. A gene is
converted to a spacing by
#bits
d,
bitn 2l-" A
=
n=l
1974
where
bit,, = 1 or 0 representing bit n in the gene,
A = m,aximum possible spacing for an element, and
d, = spacing in wavelengths between elements m-1 'and m
The possibilities for array optimization %-eunlimited. Genetic
algorithms are well suited to (may optimization because lanays
often have a kvge number of elements and have qu'mtized
panmeters such as 'amplitude ,and phase.
Fig. 2 is the resulting far field pattern. The spacings in
wavelengths are given above the figure. These spacings
produce a maximum relative sidelobe level of -22 dB.
IV. OPTIMIZED SCATTERING PATI'ERNS FROM
x=025051 125162521252528753375412547555
I
I7
0,
i
# elemenls- 24
"hi)
element panern
max sll--22 04
number of bits = 3
5-10-
-
z-15-
-m
I
I
STRIPS
This example demonstrates how to use optimization
algorithms to find resistive loads that will produce the lowest
maximum backscatter relative sidelobe level from a perfectly
conducting strip. The example is a 6h perfectly conducting
strip. The maximum backscatter sidelobe level is a little more
thaw 13 dB below the pe'ak of the main bean. The number
of resistive loads added to the edges of the strip is set, but the
width and resistivity of the strips are parameters to be
optimized by the algorithms.
The BFGS algorithm produced excellent results for 1 to 5
loads. For five loads the values are given by
q, = 0.21, 0.53, 1.05, 2.74, 4.98
W, =
U
Fig. 2 Far field pattern of an optimized nonuniformly
spaced array.
Thinning 'ways is a natural extension of the genetic
algorithm [7]. Encoding the parameters is quite simple: a
zero represents an element that is turned off while a one
represents an element that is tumed on. Fig. 3 shows the far
field pattem of a 200 element thinned may. The elements
are separated by 0.5 wavelengths and have a sin$ element
pattern. This optimized ;nay is 75% filled 'and has a
maximum relative sidelobe level of -23.7 dl3.
1.56, 1.38, 0.97, 1.28, 1.061
To get these values, however, the algorithm was run five
times with the output of one iteration being the starting point
Fig. 4 shows the resulting
for the next iteration.
backscattering pattern. It has a maximum relative sidelobe
level of -32.9 dB.
max rdaove sldelobe lev& -32 9
301
11111111111111111111111111111111111111111111101111
11101101011110100101101010100wlo1010010110010010101
I
0,
# elemen1s-X)O
75% filled
sln(phi) element pattern
d=O 5
VI
C
2 -10
-20
-"o
02
06
o8
U
3
I..
......
._........ma!?!--??
74.. .........
.
.......... ........... ..........
._I
Fig. 4 Backscattering pattern from a 6h strip with 5 loads
optimized with the BFGS algorithm.
This same problem was optimized with a genetic algorithm.
If five bits are allocated to encode each parameter, then the
gene is 50 bits long. The width quantization is given by
U
Fig. 3 Optimized pattern of a 200 element thinned array
with element spacing 0.Sh.
#bits
w,
=
1-Cbit,,0.5" + 0.5
n=l
(3)
1935
'and the normalized resistivity is represented as
#bits
q,
=
5c bit,, 0.5"
(4)
n=l
With minimum quantization levels of w=O.Sh and q=2.5 the
optimized loads have
q, = 0.31, 0.31, 0.78, 250, 4.53
w,,= 1.00, 056, 1.31, 1.13, 1.132
Fig. 5 shows the optimized backscattering pattem with a
maximum relative sidelobe level of -29.6 dB.
cns@hi)
max rsla@veddelcbe level. -29.6
301
Fig. 6 Backscattering pattem of a thinned camay of 40 strips
with d=O.lh and 2w4.037h. There are 24 strips present
'and 16 removed. The relative sidelobe level is -17.1 dB.
V. CONCLUSIONS
-20
2
0.4
0.6
0.8
U
Fig. 5 Backscattering pattem from a 6h strip with S loads
optimized with the genetic algorithm.
Another possible application for genetic algorithms is the
thinning of grids of perfectly conducting strips [31. An array
of 40 perfectly conducting strips were modeled using the
method of moments. The strips are 2w=0.037h wide, and
they are separated by d=O.lh. Strips are removed from the
grid until the lowest m'aximum sidelobe level in the
backscattering pattem occurs. Gradient based optimization
methods gave the best results for optimizing the resistive
loads. Genetic algorithms worked best for thinning the grid
of perfectly conducting strips, because there were a large
number of discrete parameters.
Genetic algorithms have a niche in optimizing
electromagnetics problems. They work well for problems
with a large number of discrete pammeters. On the other
hand, gradient based algorithms work well for a small number
of continuous parameters.
Qu'mtizing the p m e t e r s may not always be advisable. In
which case, a gradient based method might be best. However,
genetic algorithms can be useful in finding good starting
points for continuous optimization algorithms.
REFERENCES
[l] J. H. Holland, "Geneticalgorithms,"Scientific American, Jul 1992, pp.
66-72.
[2] R. L. Haupt, "Thinnedarrays using genetic algorithms." 1993 IEEE AP-S
Symposium Digest, Ann Arbor, MI, Jun 1993, pp. 712-715.
131 R. L. Haupt and A. S. Ali, "Optimized backscattering sidelobes from an
array of strips using a genetic algorithm," 1994 ACES Symposium Digest,
Monterey. CA, Mar 1994, pp. 266-270.
[4] E. Michielssen, J.M. Sajer, S. Ranjithan, and R. Mittra, "Design of
lightweight,broad-band microwave absorbersusing genetic algorithms,"IEEE
Trans. M'IT. vol. 41, J w u l 1993, pp. 1024-1030.
[5] MATLAB, The Math Works, Inc. South Natick, MA.
[6] D.G. Luenberger, Linear urd Nonlinear Programming,Reading, MA:
Addison-Wesley Publishing Co., 1984.
[7] R.L. Haupt. "Thinned arrays using genetic algorithms," IEEE APS
Trans. Vol. 42, No. 7, Jul 1994, pp. .