Order this book
Juan de Lara Jaramillo
Escuela Politécnica Superior, Ingeniería Informática, Universidad Autónoma de Madrid, Spain.
This book gives an overview of the analysis, design and implementation of real time and distributed applications. Real time applications must react in the presence of external events within strict time limits. In distributed applications, the processing units are scattered among processors and must communicate through a network to perform the computation. In the course of the book, the author introduces concepts of parallel programming in PVM (Parallel Virtual Machine), client/server programming (under Unix), CORBA technology and formal specification for this kind of application by means of PROLOG III, a kind of PROLOG with constraints (Colmerauer 1990). The book is an English translation of the French original version from 1997. It has 455 pages and is divided into ten chapters and five appendices. In each section the concepts introduced are illustrated by means of numerous practical examples and code listings.
The meaning of the term "multi-agent system" as it is used in this book could be confusing to JASSS readers. In this journal, we use multi-agent systems in social and natural sciences for the experimental and theoretical analysis of self-organisation mechanisms and emergence phenomena that arise when several entities (agents) interact. But the concept of multi-agents system can also be used in the area of information technology and telecommunications to build distributed artefacts able to perform complex tasks by means of co-operation and interaction. The book follows the latter direction. The term "agent" is used in the book to refer to the interacting components of real-time control systems. In spite of its technological orientation, this book is still of potential interest to JASSS readers because it presents theoretical concepts and useful technologies for the distributed and parallel implementation of agent-based applications. A more detailed view of the book follows.
Chapter one ("Problems Encountered with Distributed Systems") presents the basic concepts of distributed systems. Here the author shows the problems distributed applications must face (which include synchronisation of processes, resource management and validation protocol design) together with the solutions and techniques available to minimise these problems.
Chapter two ("Interaction Models") presents the technologies, principles and techniques for the construction of distributed and parallel applications. The different types of parallel architectures are presented according to the classification proposed by Flynn (1972). This classification considers on the one hand theway in which memory is accessed, and on the other hand the control mechanism. It distinguishes between SISD (Single Instruction Single Data), SIMD (Single Instruction Multiple Data), MISD (Multiple Instruction Single Data) and MIMD (Multiple Instruction Multiple Data) machines. This classification has subsequently been extended with SPMD (Single Process Multiple Data) and multi-SISD, which take into account the notion of parallel distributed programming. The chapter then presents the basic principles of distributed programming and the different models that these applications may follow. Some examples are provided by the client/server and actor models. The latter are identical processes which communicate to perform a computation, and can be organised in a master-slave relationship (a master process controls the creation and/or execution of a fixed number of slaves) or in the form of a tree (actors are created dynamically during execution). Later, the author introduces some techniques for distributed programming, in particular for synchronisation (Hoare monitors and semaphores) and communication ("channels" and their manipulation primitives). Finally, a brief overview of CORBA (Common Object Request Broker Architecture) is presented. This is a technology promoted by the OMG (Object Management Group) for distributed programming, which permits the communication of distributed objects, possibly specified with heterogeneous programming languages.
Chapter three ("Parallel Programming Tools") gives an introduction to PVM. This comprises a popular set of libraries and tools for parallel programming in C or C++. The libraries offer primitives for the configuration of the virtual machine (that is, the actual machines where the application processes are going to be executed), remote execution of processes, sending and receiving messages (including the conversion between different machine formats) and synchronisation. As an example of the use of PVM the author presents the numerical resolution of the heating equation in one dimension. For this purpose, the equation is discretised using a finite differences scheme, and each process in the virtual machine calculates the heat in a portion of the domain.
Chapter four ("Distributed Programming Under Unix") introduces client/server programming under Unix. The chapter gives an overview of some basic concepts for this kind of application, such as TCP/IP and UDP protocols, the format of IP addresses and so on. It presents the basic primitives for the creation and synchronisation of Unix processes (such as fork, exec, wait, etc.), exception handling and pipes. It shows how the programming interface to the TCP/IP protocols works (sockets), and gives examples of client/server applications built using TCP/IP and UDP.
Chapter five ("Principles of Real Time Data Processing") presents the basic principles of automated systems. These are composed of an operative part (mechanical components which should be controlled by means as actuators, such as engines) and a command part (which implements the control of the operative part). The command part can be implemented either in software or in hardware. In the latter case, the logic can be based either on combinatorial circuits (where output does not depend on previous states) or sequential ones (where output depends on the system history). The author proposes the GRAFCET tool for the graphical specification of the command part. The tool provides a formalism similar to state automata, in which states are associated with actions, and transitions occur due to logic conditions on the variables of the operative or command parts. Although the tool is useful for simple command parts, when these are more complicated, the author proposes following the SA/RT methodology (in which at some point GRAFCET can also be used). The SA/RT methodology recommends the elaboration of a Control Flow Diagram together with the Data Flow Diagrams so common in structured analysis and design (Yourdon 1989).
Real-time control applications face several problems associated with the dynamics of the process to be controlled. (For example, the response time of the operative part and its reaction speed.) On the one hand, there are physical processes with slow dynamics compared with the execution speed of the command part. On the other hand, there are physical processes with fast dynamics. This means that the process part must have much more stringent temporal constraints for the execution of tasks. This may lead to the temporal suspension of a task for the execution of another higher-priority task (called task pre-emption).
The chapter then presents the structure and basic functions of Real Time Kernels. These include multi-tasking, task pre-emption and fast synchronisation and communication mechanisms. As an example, the chapter presents the development of real-time applications under VxWorks, together with brief code samples. Later, the author presents an overview of local industrial networks. These are hierarchical, specialised networks for the transport of data in manufacture environments. In particular, the FIP (Factory Information Protocol) protocol for this kind of network is shown. The chapter ends with some small excerpts of real-time applications written in CORBA.
Chapter six ("PROLOG III and Real Time Systems Engineering") is in my opinion the most interesting part of the book, and I certainly would have liked much more space dedicated to these matters. In this chapter, the author gives an introduction to formal specification of real-time systems with PROLOG III. He also presents a theoretical introduction to Discrete Event Systems (DES) together with their specification by means of Max-Plus automata (Gaubert 1997). Some examples are shown in which combinational systems and more complex ones (such as a simple production system and a distributed file system) are modelled with PROLOG III. In these examples, the system is divided into agents, and their behaviour is specified by means of PROLOG rules. These rules take into account the reception and emission of messages, the agent's state and various temporal constraints.
The four last chapters present one example each. Chapter seven discusses an example of a parallel application, which performs parallel processing of images using PVM. Chapter eight presents a distributed client-server application under Unix, which implements primitives for the execution of tasks with temporal constraints (soft real-time applications). Chapter nine describes a real-time system involving a controller for a product processing chain using the SA/RT methodology. Finally, chapter ten describes a persistency manager for objects implemented using the client/server model. In this last chapter, the author also presents an application that uses this system which he specifies in PROLOG III.
Finally, the appendixes give details about the low-level controllers, peripheral handling, process and memory management in operating systems, and logic programming with constraints.
This book might be useful for readers interested in parallel, distributed or real-time programming, although in my opinion it has severe limitations. These include a translation that sometimes makes the book difficult to read and poor presentation quality for some of the code examples. In my opinion the book particularly neglects this aspect of presentation, which leads to frustration if one tries to read and understand the code.
Too much material is presented in the book for my taste and often not in a very structured way. This makes the book a bit unfocussed. This problem is aggravated by the fact that a great deal of the material presented (the discussion of PVM and client/server programming under Unix, for example) can easily be found in the literature. Reading these sections, one has the impression that the author has either put in too much code samples (if he just intended to provide an informal introduction) or has explained too little (if the code listings are supposed to be understood by a beginner). As already stated, I also missed a deeper (and clearer) treatment of the subjects presented in chapter six, especially the sections dealing with formal specification of multi-agent systems. On the positive side, the book has numerous examples, which illustrate the kind of applications that can be built with the technologies that have been introduced.
In conclusion, I personally found the book a bit disappointing. It could be worthwhile for readers who are merely curious about the kind of technologies introduced, but not for those who want a deep knowledge of them. These readers should consult much more specific publications.
COLMERAUER A. 1990. An introduction to PROLOG III. Communications of the ACM, 28:412-418.
FLYNN M. J. 1972. Some computer organizations and their effectiveness. IEEE Transactions on Computers, C21:948-960.
GAUBERT S. and M. Plus 1997. Methods and applications of (max, +) linear algebra. Research Report Number 3088, INRIA.
YOURDON E. 1989. Modern Structured Analysis. Prentice-Hall, Englewood Cliffs, NJ.
Return to Contents of this issue
© Copyright Journal of Artificial Societies and Social Simulation, 2003