Newsgroups: comp.ai.genetic
Path: cantaloupe.srv.cs.cmu.edu!das-news2.harvard.edu!oitnews.harvard.edu!purdue!lerc.nasa.gov!magnus.acs.ohio-state.edu!math.ohio-state.edu!howland.reston.ans.net!news.sprintlink.net!nexus.coast.net!harbinger.cc.monash.edu.au!yarrina.connect.com.au!labtam!labtam!chris
From: chris@labtam.labtam.oz.au (Chris Taylor)
Subject: Re: A cute landscape for playing with GA's
Message-ID: <chris.803866333@labtam>
Organization: Labtam Australia Pty. Ltd., Melbourne, Australia
References: <1995Jun22.061433.25317@labtam.labtam.oz.au> <3sbn71$jss@tabloid.amoco.com>
Date: Fri, 23 Jun 1995 00:12:13 GMT
Lines: 91

mdbush@amoco.com (Michael Bush) writes:

>In article <1995Jun22.061433.25317@labtam.labtam.oz.au>, chris@labtam.labtam.oz.au (Chris Taylor) writes:
>> Here's a fitness landscape that seems quite appropriate
>> for general purpose testing of GA's and such like.
>> 
>> The problem is simply to make the genome correspond to a string of
>> ASCII characters (i.e values 0-255), and look for a match with one
>> particular string (e.g "ABC").
>> 
>> I chose this problem just because it seemed nice and visual.
>> Watching the genomes throughout the generations one should hopefully
>> get a visual impression of the evolution converging.
>> 
>> I rated fitness by the sum of how well each character matches
>> with it's referance character.
>> The corresponding fitness landscape contains a multitude of local optima
>> - with mountains upon mountains upon mountains.
>> 
>> For a three character genome (i.e 3 * 8 bit = 24 bit),
>> the landscape contains 256*256 local optima.
>> These are arranged on a three level 'mountain range'.
>> There are 256 mini-triangles within 256 triangles within a mega-triangle.
>> 
>> (For an N character genome there is a N level hierarchy of triangles)
>> 
>> This is a hill-climbers' nightmare.
>> A hill-climber will quickly find it's way up to one of the local optima,
>> but there are varying degrees of difficulty in jumping between hills.
>> 
>> It is prone to get stuck in optima like "?BC" which appear seductively
>> close to the ideal "ABC". This is because '?' is 0x3f and 'A' is 0x41 and
>> so to escape requires a rather specific multi-bit mutation (or series thereof).
>> 
>> This landscape seems well suited to testing the basic ability of
>> a GA to cope with a sea of local optima. 
>>
> 
>rest deleted

>Actually this is a trivial problem and is a hill-climbers sweetest dream.
>It only appears to be a problem if one tries to fit the string as a single variable,
>which give the jagged line derived by the original poster. It is a good test problem
>for a GA however since it is easy to increase the length of the character strings
>to see if one's code really is a good as one leads oneself to believe.
>The easy hill climbing solution follows:-
>....deleted


Yes but that's not the point.
Solving the 'problem' wasn't the interesting thing.

The particular fitness landscape presented was the interesting thing
since it has the sort of characteristics that you hope a GA can cope with.

In principle any problem can be expressed in some form that
will suit a hill-climber. (i.e there is some way of expressing
the fitness that will just be a single hill!)

The trouble is that for a real non-trivial problem you generally
don't know how to do that, nor is it even practical to calculate the whole
fitness landscape for the fitness rating method you do use.
(Hence GA's and all that)

Obviously if I wanted a trivial landscape for solving a match
with the string "ABC" I would just rate genome fitness by treating it
as a single 24 bit unit and calculating the linear distance.
That gives you a single hill. Boring.


Reinterating, the point of the post was the landscape.
The 'problem' is just a toy, representing a hypothetical
real world problem that you can not solve by analysis.

Note that variations on the landscape can be made by varying the
weightings of the gene fits.
e.g
 replace  (fit(a,'A') + fit(b,'B') + fit(c,'C))
 with something like
 replace  (4 * fit(a,'A') + fit(b,'B') + 10 * fit(c,'C))


Note also that a 'biased' hill-climber that knows which bits
in the genome correspond to the least significant bits in the
genes (i.e has inside-knowledge) can find it's way to the
global optimum of this ragged landscape no problem.

But again that is not the point. If this was a real problem
then you wouldn't know which bits in the genes were the
least significant bits - and so you have to apply mutation to
all bits equally. That's when the difficulties arise. 
