Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Trail Following Ants (Cont.)

0 views
Skip to first unread message

Agnes

unread,
Aug 1, 1998, 3:00:00 AM8/1/98
to
Greetings.

First of all, I would like to thanks for those who replied my article
posted last time… Your ideas with regards to the “Trail Following Ants”
topic are very helpful and I appreciate it very much… I tried to look
around for the books details given in local book stores and libraries…
Unfortunately, I failed to locate most of the books… May be not much
people using those books though it’s useful… Therefore, I hope you can
supply me with any URL or web site containing relevant information… or
let me know if you have other ways of obtaining those books…

Here is the follow-up of my topic and I have discover some problems… Of
course, I would be pleased to receive your professional ideas and
expertise experiences on solving those problems…

Now, the ant in my program (bear in mind that there is only 1 ant moving
around at a time) has successfully initialize its trail to the food… And
my next task is to break the trail into pieces and try to simulate
ant’s mind in reallocating back the trail… I need to use the Finite
State Machine approach in searching for the nearest next piece of trail
and basically I will create 16 states in providing the solutions…
Meanwhile, Genetic algorithm will be used in breeding and mutate new
virtual ant from other ants with high successful hitting rate… As the
final outcomes, I also need to generate some graphs showing the
generations against the average successful hitting rate… (These graphs
should prove that virtual ants mutated getting more and more intelligent
in newer generation)…

For me to do so, I know I should store up each ant’s properties in some
form of repositories… Do you think it will be better to store in
database (eg. MS Access) or sequential file ? How should those
information been stored so as to provide effective way of retrieval and
updates (this would correspond to the Finite State Machine concept in
storing the current, previous and new states) ? And at which point I
should have updated the data ?

In Genetic Algorithm, I understand that there are reproduce, mutation
and crossover method in producing new generations… I have chosen
crossover and mutation in my case… Can someone tells me what is the
basic elements needed for me to start working on these 2 methods ? what
information is required in performing it and how ? If possible, can you
send me some programs using crossover / mutation method (the program
doesn’t have to be in simulating ants) ? I believe, it would be faster
and easier to learn through codes rather than expressing in words, agree
?

That’s all for now… Last but not least, thanks for spending time in
reading this article… as I’m still kind of new into Genetic algorithm
and Finite State Machine… please do guide me along… Hope to hear from
you as soon as possible… Thank you.

P/S: if you haven’t read the previous article and interested with it,
drop me a mail in lo...@pl.jaring.my and I can send you a copy of it…

Regards.
Agnes.


Rick De Haven

unread,
Aug 1, 1998, 3:00:00 AM8/1/98
to
Back in my DOS days I wrote an ant program using GA in C++. The first time I
ran the program
after removing the major bugs. The ants within several generations found a
flaw in my program
(of course I hadn't found all the bugs) and proceeded to follow the trail
right off of the left
side of my monitor and disappeared!!! I had to laugh at my folly.

Rick "I almost had a psychic girlfriend but she left before we met." De
Haven

swaits

unread,
Aug 3, 1998, 3:00:00 AM8/3/98
to Agnes
Agnes wrote:
>
[...]

> Here is the follow-up of my topic and I have discover some problems… Of
> course, I would be pleased to receive your professional ideas and
> expertise experiences on solving those problems…
[...]

I think I referred you to John Koza's "Genetic Programming" last time
you posted this question. It would seem that this particular text still
applies to your questions.

Get the book -- you will be glad you did..

--Steve

swaits.vcf

Keith Wiley

unread,
Aug 3, 1998, 3:00:00 AM8/3/98
to Agnes
> Now, the ant in my program (bear in mind that there is only 1 ant moving
> around at a time) has successfully initialize its trail to the food… And

Is this to imply that what an ant is carrying around its brain is a mental
sequence of steps, that will eventually lead it to the food? I don't think
such a thing is particularly accurate. Humans may memorize a sequential list
of commands for doing things, but ants don't. They react to what's around
them and that "drives" them towards their goal. This is why they can follow
any trail, not just one predetermined trail. Perhaps I misunderstand you though.

> my next task is to break the trail into pieces and try to simulate
> ant’s mind in reallocating back the trail… I need to use the Finite
> State Machine approach in searching for the nearest next piece of trail
> and basically I will create 16 states in providing the solutions…

Okay. Sounds possible. Do it.

> Meanwhile, Genetic algorithm will be used in breeding and mutate new
> virtual ant from other ants with high successful hitting rate… As the

You need to decide how to implement your genotype. Crossover and mutation are
easiest (and far more objective) if you can define your genome in some sort of
a bitstring or some other DNA like entity, as opposed to registers or
variables that are filled with particular values. The is an inherant bias
associated with such a genome, as you can't prove that your mutations and
crossovers aren't being guided by you, the programmer's, subconscious desire
for success.

> In Genetic Algorithm, I understand that there are reproduce, mutation
> and crossover method in producing new generations… I have chosen
> crossover and mutation in my case… Can someone tells me what is the
> basic elements needed for me to start working on these 2 methods ? what
> information is required in performing it and how ? If possible, can you

You need a genome. Like I said, bitstrings are good, if you can figure it
out. An ASCII string could definitely work too, but remember not to start
encoding actual values into the genome. Then it's just a bunch of variables
again. If you decide to store the genome as a bunch of data like variables or
something, then mutation is still pretty easy. Crossover could sort of be
implimented by taking some variable values from one parent and some from another.

. . .. ... ..... ........ ............. .....................
.. ... ..... ....... ........... ............. .................
. .. .... ........ ................ ................................
*
Keith Wiley * * * * * *
Email: kwi...@tigr.org *** ** * * ** *
WWW: http://www.tigr.org/~kwiley/ * ** ** ***

Blake Kadatz

unread,
Aug 4, 1998, 3:00:00 AM8/4/98
to

swaits wrote in message <35C5EE85...@ix.netcom.com>...

On Amazon.com:

Genetic Programming : On the Programming of Computers by Means of
Natural Selection (Complex Adaptive Systems) ~ Usually ships in 24
hours
John R. Koza / Hardcover / Published 1992
Our Price: $68.00

http://www.amazon.com/exec/obidos/ASIN/0262111705/qid=902256837/sr=1-1
/002-0548909-5368442

--
-----------------------------------------------------------
Blake Kadatz phone: 604-420-3931
BitMotion Software Inc. fax: 604-420-3921
304 - 7321 Halifax Street mailto:bl...@bitmotion.com
Burnaby, BC, Canada V5A 4R5


Stephen Boswell

unread,
Aug 7, 1998, 3:00:00 AM8/7/98
to
Acutally a series of steps is accurate to some degree. I had a class once
called, "Brain and its functions". In this class I remember an experiment
where a Wasp had killed a cricket and had drug it to the entrance of its
burrow. The Wasp would leave the Cricket, go inside the hole, return from
the hole and drag the Cricket into the burrow. If during the time the Wasp
was in the hole, the scientist would move the Cricket back a few inches,
when the Wasp exited the hole it would search for the Cricket, bring it back
to the entrance, leave it and re-enter the hole again. This was repeated
numerous times. Thus leading the scientist to assume the Wasp was repeating
a sequence of necessary steps before bringing food into its home. If I
remember right, this was the function of the Hypathalmus, but that class was
a long time ago...


Keith Wiley wrote in message <35C5B29C...@tigr.org>...

Keith Wiley

unread,
Aug 10, 1998, 3:00:00 AM8/10/98
to
Yeah, that's a famous experiment. Still, a progression of steps in completing
a task is feasible, while I believe a progression of steps in traversing a
trail is more unlikely.

0 new messages