Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] Playing Soccer with OCaml
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Rafael 'Dido' Sevilla <sevillar@t...>
Subject: Re: [Caml-list] Playing Soccer with OCaml

On Mon, Oct 29, 2001 at 06:39:00PM +0100, Kai Kaminski wrote:
> Hi,
> I'm currently taking part in a university project, which is about
> teaching robots to play soccer. My task is the path-finding module. It
> is responsible for finding short paths, while considering moving
> obstacles (team mates, enemy robots and the ball). I will probably use
> Dijkstra or Markov Decision Processes to accomplish this. Not because
> I'm a great friend of these algos (in fact I don't know nothing about
> them yet) but my lecturer told me that these were suitable.

I have an idea for you if you're making such a system that should be an
approximation to an autonomous mobile robot (looks like it).  Maybe, as
opposed to doing the classical sense-model-plan-act (SMPA) paradigm of
robotics (as it looks like you're doing, as you're looking for
pathfinding algorithms) you can try doing research on the behavior-based
subsumption approach to robotic control, pioneered by Prof. Rod Brooks
at MIT.  The basic idea is that your robotic beings are controlled by
behaviors which run in parallel, which are activated by various sensory
inputs, and are prioritized in control of their actuators.  The seminal
paper that describes this approach is Rodney A. Brooks, "A Robust
Layered Control System for a Mobile Robot", MIT AI Lab Memo 864,
September 1985.  You can find an electronic version of this paper and
many more on the behavior-based approach at Brooks' home page 

In order to implement a subsumption architecture in OCaml you would
probably need to use the threads library to make one thread for each
behavior you wanted to make the robot perform, and two more threads to
get inputs from the robots sensors and arbitrate the access of behaviors
to the robot's actuators.

Which brings me to a somewhat related question: just how real-time is
OCaml's runtime environment?  Is the garbage collection algorithm
real-time, i.e. it uses its own thread to perform GC in parallel to
processing or uses some other technique which guarantees that every cons
performed has an upper bound on the amount of time it will take,
regardless of GC?  Most garbage collection algorithms I've seen are not
real-time, in that they can potentially take an unbounded amount of time
that depends on the number of allocated cells.  For robotics and other
real-time control and processing problems this is an important question.

Rafael R. Sevilla <>   +63(2)   8177746 ext. 8311
Programmer, Inter.Net Philippines                +63(917) 4458925                OpenPGP Key ID: 0x5CDA17D8
Bug reports:  FAQ:
To unsubscribe, mail  Archives: