DEFINING AND VISUALIZING MODELS OF URBAN TRAFFIC Shannon Borho, Jan Pittner, Gabriel Wainer Department of Systems and Computer Engineering Carleton University 4456 Mackenzie Building. 1125 Colonel By Drive Ottawa, ON. K1S 5B6. CANADA gwainer@sce.carleton.ca ABSTRACT ATLAS is a modeling language that permits defining a static view of a city section for simulating traffic in an area. The models are formally specified, avoiding a high number of errors in the application, thus reducing the problem solving time. The system required the manual generation of ATLAS files, a tedious process that did not lend itself for rapid changes to the system input. The output of the system also suffered from a non-user friendly interface. The solutions to these problems were addressed in two parts: a front-end system allowing the user to draw city sections (and then parse the drawing to create a valid ATLAS file), and an output subsystem permitting showing cars with realistic 3D graphics. 1. INTRODUCTION Urban traffic analysis and control is a problem of such a complexity that it is difficult to be analyzed with traditional analytical methods. Modeling and simulation techniques, instead, have shown a certain degree of success, and they have been gaining popularity as an analysis tool. Simulation permits studying particular problems using virtual experimentation. We have developed a toolkit for modeling and simulation of traffic in urban centers. This project followed a rigorous approach that we introduce here. The first stage was devoted to define and validate a high level specification language representing city sections [1]. This language, called ATLAS (Advanced Traffic LAnguage Specifications) focuses on the detailed specification of traffic behavior. The models are represented as cell spaces, allowing elaborate study of traffic flow according to the shape of a city section and its transit attributes. A static view of the city section can be easily described, including definitions for traffic signs, traffic lights, etc. A modeler can concentrate in the problem to solve, instead of being in charge of defining a complex simulation. The constructions defined in this language are mapped into DEVS [2] and Cell-DEVS models [3]. DEVS provides high performance for discrete-event systems simulation [4]. Similar results were obtained for Cell-DEVS models [5]. It also provides a formal framework that can be used to validate and verify the models. This approach permits us to reuse the models created and integrate with others using different formalisms (for instance, using Petri Nets or Finite State Machines to specify the behavior of traffic lights or railway controllers). A real system modeled using the DEVS formalism can be described as being composed of several submodels. Each of them can be behavioral (atomic) or structural (coupled). A DEVS atomic model is described as: M = < X, S, Y, dint, dext, l, D > Here, X is the input events set, S is the state set, and Y is the output events set. We also use four functions: dint manages internal transitions, dext external transitions, l the outputs, and D, the lifetime of a state. The interface is composed of input and output ports to communicate with other models. Each port is defined as a pair, including a port name and its type. The input external events (those coming from other models) are received in input ports. A DEVS coupled model is defined as: CM = < I, X, Y, D, {Mi}, {Ii}, {Zij} > Here, I is the model interface, X is the set of input events, and Y is the set of output events. D is an index of components, and for each i Œ D, Mi is a basic DEVS model (atomic or coupled). Ii is the set of influencees of model i. For each j Œ Ii, Zij is the i to j translation function. Each coupled model consists of a set of basic models connected through the input/output ports. The influencees of a model will determine to which models one send the outputs. The translation function is in charge of translating outputs of a model into inputs for the others. To do so, an index of influencees is created for each model (Ii). For every j in this index, outputs of the model Mi are connected to inputs in the model Mj. The Cell-DEVS formalism was proposed as an extension to DEVS permitting to describe cellular models. Cell-DEVS allows the definition of complex cellular models that can be integrated with other DEVS. Here, each cell of a space is defined as an atomic DEVS with explicit timing delays. Transport and inertial delays define the timing behaviors of each cell in an explicit and simple fashion. A transport delay allows us to model a variable response time for each cell. Instead, inertial delays are preemptive: a scheduled event is executed only if the delay is consumed. Figure 1: Informal Definition of Cell-DEVS. Cell-DEVS atomic models can be formally specified as: .....