A Set of Software Agents to Model Traffic

By Steve Goschnick

Deptartment of Computer Science and Software Engineering

University of Melbourne.

Date: 1999/05/14

Subject: 433-682 Intelligent Software Agents

Assignment: 2


The Assignment (set by Professor Leon Sterling):

"Develop a set of agents to model traffic in a large cuty such as Melbourne. Your agents should include some modes of transport such as cars and buses, people, traffic regulators such as policeman and traffic lights, emergency vehicles such as fire engines and ambulances.

You should have at least eight types of agents. For each agent, you should sketch the beliefs it might have, plans it might have, and events that might trigger plans being called.

You need to submit a description of the agents, their beliefs, goals and plans.

Discussion of your deliberations in designing the agents would be helpful."


1. Requirements Analysis - gathering domain specific information:

The first step needed is a Requirements Analysis, based upon a very broad single client requirement, namely to: 'Develop a set of agents to model traffic in a large city such as Melbourne'. I am assuming the whole city of Melbourne, not just the CBD, via the word 'large'.

Before modeling can begin, a collection of domain specific information, needs to be gathered as fodder for the extraction of potential entities (as candidates for: agents classes, and objects), their attributes and behaviours.

The Journey:

It is worth noting early on, that the reason for traffic is the journey, and all journeys have some common attributes:

Journey: The main attributes of a journey are: start; destination; purpose (work; shopping; visiting; servicing; emergency, etc); route.
Journey-route: The particular route that a vehicle takes to get from the start to the destination of a Journey. This is usually a sequence of links in the road network, but it can also include bus routes or train routes, when modes of transport other than the car, are included - as in most cities.
Traffic: - is the summation of a whole lot of individual journeys.

The information outlined below will initially be unstructured, however it will be divided into two areas, even at this early stage of analysis: information related to Environment; and information related to possible Agents. Even though the assigned task is to develop the agents, the environment very much needs to be taken into consideration, to tease-out the various roles, responsibilities, expertise, capabilities, services, interactions, protocols, beliefs, goals and plans, of the agents needed.

Little attempt is being made to put things into preconceived structures, at this preliminary stage. This is primarily an excise in collecting a sufficiently wide set of artefacts to achieve a plausible model.

Environment:

Road Link: The section of road between intersections. Each direction has a maximum capacity, a maximum advised speed, a number of lanes in one or two directions.

Lanes: The number of lanes in a road link, a separate count in each direction (nb. some roads change the direction of the central lane/s on a fixed-time basis, to cope with AM and PM peaks, using overhead illuminated lane markers)

Intersections: Three main categories of intersection are: traffic-light controlled; roundabouts; signed (stop-sign/giveway sign; right of way).

Link classifications: In traffic engineering terms, there are 5 main categories of road network links: local street (eg. residential area); collector road (more significant roads through local areas, leading from local streets and cul-de-sacs to sub-arterial and arterial roads); sub-arterial road (two lanes in either direction, controlled intersections); arterial road (two or more lanes in each direction, service lanes to enable relatively unimpeded driveway access), bus stops off the side of the road, divided carriage-way; freeway (overpasses instead of intersections).

Home (driveway): The start of most journeys - spread alone most of the road network links, particularly along local streets and collector roads, and alone the service lanes of arterial roads, but not freeways.

Workplace: Attracts a known number of journeys-to-work.

ShoppingCentre: Where one buys things (goods and services).

Firestation: Home-base of fire trucks.

Ambulance Station: Home-base of ambulance vehicles.

Police Station: Home base of police vehicles.

Hospital: Destination for ambulance in an emergence, after picking up patient.

Zones: A geographic area containing a number of homes, places-of-work, shops, etc. Note: In an aggregated model of an environment, a zone might be treated as a single.point, connected to the transport network, in a number of places (eg. connected to surrounding roads - see Fig. 1 below), with journeys distributed amongst those connected links. A zone can be both a sink (destination) and a source of various journeys.

Parking-lot: Off-street parking area, accessed along links. Has a known number of parking spots, and a known cost per time period.

Parking spot: On-street parking, along sections of links.

Parking times: Duration; certain time periods which affect parking duration including exclusion times (eg. clearway) - to provide another lane.

Rail line: For fixed track vehicle (trains). Known stops. Known timetable. Known duration of journey.

Tram line: For light-weight fixed track vehicle (often shares a lane with cars). Known stops to pickup and put down passengers.

Stations: A fixed location to catch a train. People often walk or drive or catch a bus or tram to or from a station, in what constitutes a multi-modal journey.

Tramstop: Fixed locations to catch a tram.

Stalled vehicle/accident: A stalled vehicle on the roadway, or one or more in an accident, becomes a part of the environment, which others need to negotiate around, and which can have a significant reaction upon traffic flows.

Roadworks: Roadworks are another situation which, like a stalled or damaged vehicle, are out of the ordinary and which other vehicles must negotiate.

Weather: Wet weather will affect driver speeds and hence the maximum capacities of a given road link. Other weather conditions affect traffic:sun-glare, fog; driving rain and wind; etc.

 

Agents - listing of Potential candidates for the model:

Intersection Controller: Main role is to maximize the through-put of vehicles in all directions. Conventional controllers have a number of plans, for different times of the day (more on this later). Inputs to intersections include transducers in the road (a loop of wire embedded in asphalt), which detect a vehicle passing over, so they can perceive gaps in traffic, as well as good estimates of current flow.

Arterial Section: To achieve a better flow of traffic (the so called 'green wave') - which in turn reduces: fuel consumption; journey time; frustration; the need for freeways - a number of consecutive intersection controllers, can be linked and run according to a group plan.

Emergence Vehicle Dispatcher: Receives calls for urgent assistance, locates available emergency vehicles; then assigns one optimally, time wise.

Transport Mode Selector: These use models that use Utility and other theories, to optimise/synthesise the choice of transport mode (train, bus, tram, car, walk, multi-modal). Obviously, most people don't change modes of transport very often, unless some event prompts them to consider the alternatives. For example: steep escalation in fuel costs; loss of license; gain of a license; toll roads introduced; new major destinations - some of these events are the driving force for traffic engineers to build models in the first place.

Route Selection: While most vehicle drivers don't change modes of transport very often, many do change route often, influenced by such things as: time-of-day; weather; radio traffic reports; perceived blockages ahead.

Car: The predominant vehicle used to make a journey in a city such as Melbourne.

Truck: Large dimension, slower acceleration and braking speeds, means that trucks affect traffic in different ways than cars.

Motorbike: Are very flexible with regard to straying from traffic lanes, and they have significantly greater accelerations than most other vehicles, requiring other drivers to be more cautious in their movements, such as changing lanes.

Civilian Driver: Need to be alert at all times reacting to situations as they arrive. Need to negotiate the vehicle safely at all times. Need to signal intentions to other drivers. Ability to select a parking spot.

Emergency Driver: Highly reactive individual, for whom many of the rules and protocols of the road, don't apply.

Policeman: A driver of a police car, or a pedestrian who can control an intersection.

Train: Follows fixed tracks. Only planned stops are at stations. Sticks to a timetable.

Tram: Tries to stick to a timetable.

Home: Generates journeys.

Commuter: Uses train, tram or bus within journey.

Pedestrian: Travels all or part of their journey on foot.

Workplace: Generates journeys.

Major Events: Generates large numbers of out-of-the ordinary journeys.

Out of Scope:

The modeling of the environment is not within the scope of this assignment. However, I will assume the existence of a complex model of the environment: a computerized version of the transport network, complete with: multiple lanes; parking spots; parking lots; train lines; tram lines; train signal crossings; bus stops; train stations; home sites, places of work and shops - all statistically distributed about the network approximating the actual city being modeled - within which the agents can interact, to model traffic - the summation of all their individual journeys.

The assumed level of model of sources and destinations of Journeys, within model of environment:

The modeling of a city, could be done at several levels, consider the following two options:

1. The individual buildings (homes, flats, work premises, shops) usually placed along road-links, can be modeled with driveways and parking lots, representing the physical location of the start and end of journeys, from the traffics point of view.

2. Zones can be used to aggregate many details, effectively becoming sources and sinks, for journeys. Zones are compatible with geographic areas about which various organisations within society, gather and aggregate statistical data. Eg. LGAs - Local Government Areas; Postal Code area; etc. The sort of data aggregated at a zone includes: number of journey-to-work trips generated; number of shopping trips generated; number of emergence calls generated; number of workplaces within; number of off-street parking spaces within; etc.

While the level of modeling of the city is an environment modeling concern - which I have deemed as 'out of scope' - the level of modeling of the environment, is pertinent to some of the agents to be modeling. Therefore, I do need to select which level of the environment, that I will assume is modeled elsewhere.

 

Fig.1 - Aggregated Zone connected to road network model - not used herein.

Aggregating the data from areas within a transport network model, to zones represented as points, is well understood and quite achievable in pre-agent simulation technologies. Agents have particular strengths when it comes to modeling individual units (autonomous, internally motivated) with know plans and able to select between them, reacting in an uncertain environment, with many possible ways to achieve objectives. For this reason I'm going to assume option 1 above for modeling a city: down to the level of individual buildings: ie. driveway, parking spots and parking lots - along the road links, within the network. Road link types will include all types: local streets; collector roads; sub-arterials; arterials; and freeways.

 

Fig.2 - the Assumed Discrete Model.

This level of modeling of the environment will also include the number of lanes in each direction on any given link in the road network. The will allow for interesting modeling of car-driver agents that: change lane, and stop and start in a manner similar to human drivers, giving a level of high fidelity in modeling traffic, above what an aggregated zone model could hope to achieve.

2. Methodology for BDI Agents

The methodology used here for agent analysis is one outlined in:

David Kinny, Michael Georgeff and Anand Rao (1996). A Methodology and Modelling Technique for Systems of BDI Agents.

It involves identifying and spelling out, the following Common Analysis Concepts, about the individual candidate Agents:

3. The Analysis of Agents to Model Traffic

Identifing Agents via Roles:

1. Intersection Controller
2. Arterial Section Controller
3. Car Driver
4. Car
5. Truck Driver
6. Truck
7. Route Selector
8. Emergency Vehicle Driver / Emergency Vehicle
9. Emergence Vehicle Dispatcher
10. Household
11. Workplace
12. End of Link Simulator
13. Commuter
14. Train Driver / Train (from a traffic modeling view, I'll combine driver and vehicle)
15. Tram Driver / Tram (ditto)
16. Bus Driver / Bus

 

 

To simplify the model a little, the roles Car Driver, Car, Truck Driver and Truck, are folded into a single generic role: Driven Vehicle. Note: I've already combined: Police; Ambulance and Fire engine, into generic Emergency Vehicle. I'll combine that driver and vehicle into Emergency Driven Vehicle. The same goes for Bus Agent.

 

The Selected Set of Agents and their Responsibilities:

Agent

Responsibilities

1. Intersection Controller Agent

  • In a safe manner, optimise vehicle through-put for the intersection as a whole, for competing traffic cross-flow.
  • Give all links some green time, within a reasonable time frame.
  • Adopt different light cycle plans, for different time periods (AM peak; PM peak; Low Off peak; High Off peak)
  • Count traffic numbers and gaps between cars.
  • For an adopted plan, ensure green times are between the minimum and maximum time periods, based on traffic stream (ie. if a significant gap in traffic is detected, cut short the cycle, before maximum green time is achieved)

2. Arterial Section Controller Agent

  • Maximize aggregate traffic flows along a particular section of arterial (ensuring a 'green wave' for the direction carrying most vehicles).
  • Distribute different light cycle plans, for different time periods (AM peak; PM peak; Low Off peak; High Off peak) to achieve green wave.

3. Driven Vehicle Agent

  • Don't injure any people (eg. pedestrians).
  • Don't damage any vehicles.
  • Drive at a safe speed always within the speed limit.
  • Minimise time spent driving along a link.
  • Indicate to other nearby agents, intentions of changing lanes, stopping, or turning.
  • Accelerate or decelerate in a smooth and consistent manner.
  • Find parking as close as possible to journey destination.

4. Route Selection Agent

  • To find the best route plan for any given journey, without favour (to any individual agent).

5. Emergency Driven Vehicle Agent

  • To save lives.
  • To save property, in the case of fire engine and policeman.
  • To respond as quickly as possible to a request for assistance.

6. Emergence Vehicle Dispatcher

  • Find all unoccupied emergence vehicles capable of dealing with a given emergency.

7. Household Agent

  • Send out all resident Driven Vehicle Agents by the appropriate time, to begin their respective daily journeys.
  • Send out all resident Commuter Agents by the appropriate time, to begin their respective daily journeys.
  • Keep households free of fire and civil disobedience.

8. Workplace Agent

  • Send all workers and students (I'm counting schools as a workplace) home on their return journey, at the appropriate time.
  • Dispatch vehicles to deliver goods and services, during work hours, as necessary.
  • Keep workplace free of fire and civil disobedience.

9. End of Link Simulator Agent

  • Where links reach the boundary of the city being modeled, this agent has responsibility to generate traffic (with known destinations), that approximate known observed flows of such links.
  • To be the destination of certain journeys.

10. Commuter

  • Minimise time spent getting to a journeys destination.
  • Must not cross road links at any place other than at intersections controlled by Intersection Controller agents.

11. Train Agent

  • To stops at all stations on the train route, for the current timetabled train service.
  • To get to each station on the timetabled route, on time.
  • Not to cross a road if the crossing signals aren't working.

12. Tram Agent

  • To stops at all tram stops on the tram route for the current timetabled tram service, which have Commuter Agents waiting there
  • To get to each stop on the timetabled route, as close to the timetabled time as possible.

13. Bus Agent

  • To stops at all bus stops on the bus route, for the current timetabled service.
  • To get to each station on the timetabled route, on time.
  • Apart from pulling out of a bus stop at any time, with caution, abide by the road rules that the Driven Vehicle Agent is subject to.

 

 

 

Selected Set of Agents and their Expertise:

Agent

Expertise (Knowledge about behaviour)

1. Intersection Controller Agent

  • Holds a number of cycle plans for the particular intersection. The cycle includes green-time, red-time, right-arrow time, left-arrow time, pedestrian-time - for each of the links that meet at the intersection.
  • Knows when AM and PM peak times occur for the represented intersection.
  • Knows how long it takes for a pedestrian to cross a particular link.
  • Knows how much amber time is needed to safely alert vehicles of a forthcoming red light.
  • Knows maximum capacity of each link coming into the intersection.

2. Arterial Section Controller Agent

  • Knows which intersections and which Intersection Controller Agents, constitute an Arterial section.
  • Has a number of aggregated (global) cycle plans, which include coordinated individual intersections plans, for those intersections, that constitute an Arterial section.
  • Knows when AM and PM peak times occur for this arterial section.

3. Driven Vehicle Agent

  • Knows the planned route to complete the current journey.
  • Holds maximum speed limit from environment.
  • Holds the estimated speed of the vehicle in front.
  • Knows if the vehicle in front intends to slow down.
  • Knows if a turn is required at the next intersection, and knows whether itís a left or right turn.
  • Knows if there is a candidate gap in traffic in adjacent lanes.
  • Knows all parking lots in close proximity to route destination.

4. Route Selection Agent

  • Knows the origin and the destination of any given journey, within the transport network of the environment.
  • Knows all links and intersections within the entire road network.
  • Knows all Intersection Controller Agents and all Arterial Section Controller Agents.
  • Knows all train stations, tram stops and bus stops.
  • Knows timetables for all trains, buses and trams.

5. Emergency Driven Vehicle Agent

  • Knows where the nearest available appropriate service is (hospital in the case of an ambulance; a water hydrant in the case of fire truck)
  • Knows where the current client in need of assistance is, ie the destination of a journey.

6. Emergence Vehicle Dispatcher

  • Knows all available Emergency Driven Vehicle Agents.
  • Knows what type of emergency vehicle agent, each of them is: Ambulance; Fire fighter; Police.
  • Knows the location of the current call for assistance: either a Household Agent; a Workplace Agent; a Driven Vehicle Agent or a Commuter Agent; Tram, Train or Bus Agent.
  • Knows the location of all services: hospitals; fire hydrants.

7. Household Agent

  • Knows the day of week and the time of day.
  • Knows how may journeys to work, to shops and to school will be generated in a given day.
  • Knows when a Journey-to-work for a Driven Vehicle Agent must begin.
  • Knows when a commuter journey must begin.
  • Knows if an accident has occurred.
  • Knows if a fire has begun.
  • Knows if some civil disobedience has occurred.
  • Knows how to initiate a call to the Emergency Dispatch Agent.
  • Has a driveway with a certain number of off-street parking spots

8. Workplace Agent

  • Knows the day of week and the time of day.
  • Knows how many goods-and-services journeys will be generated in a day and when.
  • Knows when to send Driven Vehicle Agents home.
  • Knows when to send Commuter Agents home.
  • Knows if an accident has occurred.
  • Knows if a fire has begun.
  • Knows if some civil disobedience has occurred.
  • Knows how to initiate a call to the Emergency Dispatch Agent.
  • Has a parking lot with a certain number of off-street parking lots.

9. End of Link Simulator Agent

  • Knows the destinations beyond the modeled city, which it represents.
  • Knows all the current Driven Vehicle Agents current residing within it, and when they are due to return to the modeled environment.

10. Commuter Agent

  • Knows how to get to the nearest Train station, Tram stop and Bus stop.

11. Train Agent

  • Knows the train timetables in which it participates.
  • Knows all the stations along the route.
  • Knows the time and day.
  • Knows its passenger capacity.

12. Tram Agent

  • Knows the tram timetables in which it participates.
  • Knows all the stops along the route.
  • Knows the time and day.
  • Knows its passenger capacity.

13. Bus Agent

  • Knows the bus timetables in which it participates.
  • Knows all the bus stops along the route.
  • Knows the time and day.
  • Knows its passenger capacity.

 

 

Selected Set of Agents and their Capabilities, Permissions and Resources:

Agent

Capabilities, Permissions, Resources

1. Intersection Controller Agent

  • Ability to count each vehicle passing through the intersection in each direction (eg. via transducer set in asphalt in actual roads)
  • Ability to measure gaps between vehicles passing through.
  • Ability to count vehicles queued to turn right.
  • Ability to count vehicles queued to turn left.
  • Able to abide by instructions from an Arterial Section Controller Agent, if currently connected to one.
  • Ability to interrupt cycle plan, to cater for approaching Emergency Vehicle Agent

2. Arterial Section Controller Agent

  • Ability to summate traffic flowing in both directions, along the arterial section under its control.
  • Ability to perceive blockages along any link within the section, by comparing entries and exits over a period of time.
  • Ability to change cycle plan for any Intersection Controller Agent under its control.

3. Driven Vehicle Agent

  • Can perceive maximum speed limit for current link, from environment.
  • Can perceive the speed of vehicle in front.
  • Can perceive if the vehicle in front is stalled or broken down.
  • Can perceive an accident.
  • Can make a call to the Emergence Vehicle Dispatcher Agent.
  • Can perceive if the current link being traversed is significantly sub-optimal.
  • Can call upon the Route Selection Agent for a revised route, in the case of the current link being deemed sub-optimal, declaring current link as: 'not to be used' in selection.
  • Can take the vehicle from stationary, up to a cruising speed.
  • Can get into appropriate lane, with regard to next intersection (eg. getting in or staying out of turning lanes).
  • Can estimating a gap in traffic in adjacent lane, large enough to move into.
  • Can brake at a steady deceleration, to a stop if necessary, when an obstacle ahead is perceived.
  • Can brake at a steady deceleration, to a lesser cruising speed, when vehicle ahead is perceived to be slowing down.
  • Can perceive a parking lot and know its cost.
  • Can perceive a vacant parking spot and its candidature as the journeyís destination.

4. Route Selection Agent

  • Has ability to find the optimum route for a journey between known origin and destination.
  • Has ability to find closest train station, bus stop or tram stop, for a commuter journey.
  • Has ability to look up timetables of trams, trains and buses.

5. Emergency Driven Vehicle Agent

  • Has the ability to flash warning lights and sound siren, to signal its presence to other vehicle agents.
  • Has the ability to instruct Intersection Controller Agent, immediately forward of its current position, to turn the appropriate light green.
  • Has the ability to place itself 'on call' with the Emergence Vehicle Dispatcher Agent, after completion of a previous journey (task).

6. Emergence Vehicle Dispatcher Agent

  • Has ability to answer client calls for assistance (from a: Household Agent, a Workplace Agent or a Driven Vehicle Agent).
  • Has ability to identify if call is a new call or one already serviced.
  • Has ability to prioritise calls waiting (queued) for service.
  • Has ability to select appropriate Emergency Driven Vehicle Agent, to service a client call for assistance.
  • Has ability to instruct an Emergency Vehicle Agent to service a particular call.
  • Has the ability to locate and select an appropriate service (hospital or fire hydrant) to service current request for assistance.

7. Household Agent

  • Ability to initiate: journeys-to-work; journeys-to-shops, journeys elsewhere.
  • Has ability to call Emergency Dispatch Agent in case of fire, accident or civil disobedience, or a non-return home of a member agent (Commuter or Driven Vehicle Agent).

8. Workplace Agent

  • Ability to initiate the return; journeys-to-work; journeys-to-shops, journeys elsewhere.
  • Ability to initiate inter-work journeys for delivery of goods and services.
  • Has ability to call Emergency Dispatch Agent in case of fire, accident or civil disobedience.
  • Has ability to report to Driven Vehicle Agents, how many parking spots it has free in its parking lot/s.

9. End of Link Simulator Agent

  • Ability to generate traffic (with known destinations) that approximates observed flows of such links, using a mathematical simulation.
  • Ability to store Commuter and Driven Vehicle Agents, whose journey destination is beyond the boundary of the modeled city.

10. Commuter

  • Has the ability to walk to a station, bus stop or tram stop.
  • Can wait at a bus stop, train station or tram stop, for the next appropriate Train Agent, Tram Agent or Bus Agent.
  • Can identify the correct Train Agent, Tram Agent or Bus Agent, that constitutes a part of its multi-modal journey.
  • Can activate a request for a 'Walk' signal from an Intersection Control Agent.
  • Can wait at an intersection until a 'Walk' signal is given.

11. Train Agent

  • Has the ability to follow railway tracks in the environment model.
  • Has the ability to stop at a station
  • Has the ability to carry Commuter Agents.
  • Has ability to call Emergency Dispatch Agent in case of fire, accident or civil disobedience.

12. Tram Agent

  • Has the ability to stop at a tram stop, if a Commuter Agent is waiting at the stop.
  • Has the ability to follow a tram track in the environment model.
  • Has ability to call Emergency Dispatch Agent in case of fire, accident or civil disobedience.

13. Bus Agent

  • Has the ability to follow a bus route in the environment model.
  • Has the ability to stop at a bus stop, if a Commuter Agent is waiting at the stop.
  • Has the ability to diverge from a bus route, in some circumstances (eg. bad accident).
  • Has ability to call Emergency Dispatch Agent in case of fire, accident or civil disobedience.

 

 

Selected Set of Agents and their Services, Interactions and Protocols:

Agent

Services, Interactions, Protocols

1. Intersection Controller Agent

  • Passes on accumulated vehicle counts to any overseeing Arterial Section Controller Agent
  • Interrupts cycle to give an approaching emergency vehicle a green light.

2. Arterial Section Controller Agent

  • Has ability to pass on current link traffic flow (vs maximum capacity) information to the Route Selection Agent, for its route planning.
  • Distributes coordinated customised cycle plans to those individual Intersection Controller Agents, which constitute an Arterial section.

3. Driven Vehicle Agent

  • Indicates to other nearby agents, its intentions of changing lanes or turning.
  • Indicates to agents behind, its intentions of stopping.
  • Ability to stay within speed limit.
  • Ability to stop ASAP to let an emergency vehicle agent through.

4. Route Selection Agent

  • Ability to find the optimum route for a journey (known origin and destination) for a vehicle using the road network.
  • Ability to find the optimum route for a journey (known origin and destination) for an Emergency Driven Vehicle Agent, using the road network, using different criteria than for normal vehicle agent.
  • Can find the optimum route for the continuance of a journey, given a vehicle agents current location, and a request from that agent, for a revised route to the destination.
  • Find the optimum route for a journey (known origin and destination) for a Commuter Agent, which includes combinations of walking, train, bus, tram.

5. Emergency Driven Vehicle Agent

  • Can call upon the Route Selection Agent for best route to locate client.
  • Having received an instruction from the Emergency Dispatcher Agent on which is the best hospital service to use, can call upon the Route Selection Agent, for the optimum route.

6. Emergence Vehicle Dispatcher Agent

  • Can instruct an Emergency Vehicle Agent as to which service to proceed to (hospital or fire hydrant), after locating the client.

7. Household Agent

  • Can determine if any or all Household member agents (Commuter and Driven Vehicle Agents) are currently home.

8. Workplace Agent

  • Can determine if a Commuter Agent or Driven Vehicle Agent, is still at the workplace.

9. End of Link Simulator Agent

  • Can reply to the Route Selection Agent, indicating if a particular End of Link Simulation Agent, is a proxy for some journey destination it doesn't currently have a location for, within the known city area/network.
  • Can report how many Commuter and Driven Vehicle Agents are current residing at this agent, as if on an out-of-model journey.

10. Commuter

  • Can report where it currently is.
  • Can report how many Commuter Agent seats remain within it.

11. Train Agent

  • Can report where it currently is.
  • Can report how many Commuter Agent seats remain within it.

12. Tram Agent

  • Can report where it currently is.
  • Can report how many Commuter Agent seats remain within it.

13. Bus Agent

  • Can report where it currently is.
  • Can report how many Commuter Agent seats remain within it

 

The selected Agents as BDI Agents (Name, Description, Beliefs, Goals and Plans):

Recall that Intentions (also knowns as Tasks), are those Goals an agent is committed to achieve. An Agent selects a Plan to enact a Task.

The column in the table below headed 'Beliefs and Knowledge', also includes knowledge about behaviour, which is restated here, from the above table on 'Expertise'. Note: The difference between Knowledge and Beliefs: the first are facts known to the agent, while the second are used by the Agent in the absense of fact where there is incomplete information.

 
Name: 1. Intersection Controller Agent
Description: Controls all that passes through a single intersection via red, green and amber lights, including through traffic, left and right turning traffic via arrows, and pedestrian's via walk and don't walk lights.
Beliefs and Knowledge
Goals
Plans
  • Holds a number of cycle plans for the particular intersection. The cycle includes green-time, red-time, right-arrow time, left-arrow time, pedestrian-time - for each of the links that meet at the intersection.
  • Knows when AM and PM peak times occur for the represented intersection.
  • Knows how long it takes for a pedestrian to cross a particular link.
  • Knows how much amber time is needed to safely alert vehicles of a forthcoming red light.
  • Knows maximum capacity of each link coming into the intersection.
  • To optimise vehicle through-put for the intersection as a whole, for competing traffic cross-flow, in a safe manner.
  • Give all links some green time, within a reasonable time frame.
  • Adopt best cycle plan for current time periods.
  • Count traffic numbers and gaps between cars in all directions.
  • Ensure green times are between the minimum and maximum time periods, based on traffic stream
  • There are a number of different cycle plans, for different traffic flows observed at different times. Plans include: AM Peak Plan; PM Peak Plan; Low Flow Off Peak; High Flow Off Peak. The AM Peak Plan and the PM Peak Plan are both time based. The other two are determined via perceived traffic counts from the environment.
  • If a significant gap in traffic is detected, then cut short the cycle, before maximum but after minimum green time is achieved.
  • If this (2) happens regularly, change to an appropriate cycle plan.
 
Name: 2. Arterial Section Controller Agent
Description: To achieve better flow of traffic along a section of road (a so called 'green wave'), a number of consecutive intersection controllers can be linked in a group plan. This agent overrides the plans of the individual Intersection Controller Agentís autonomy (and plans).
Beliefs and Knowledge
Goals
Plans
  • Knows which intersections and which Intersection Controller Agents, constitute an Arterial section.
  • Has a number of aggregated (global) cycle plans, which include coordinated individual intersections plans, for those intersections, that constitute an Arterial section.
  • Knows when AM and PM peak times occur for this arterial section
  • To Maximize aggregate traffic flows along a particular section of arterial, ensuring a 'green wave' for the direction carrying most vehicles.
  • Distribute different light cycle plans, for different time periods (AM peak; PM peak; Low Off peak; High Off peak) to achieve a green wave.
  • To override all Intersection Control Agent represented in the arterial section, at most times.
  • Give control back to the Intersection Control Agent if any participating Intersection Control Agent reports in faulty.
  • Give control back to the Intersection Control Agent if any links between participating Intersection Control Agent is servicing a request of an Emergency Vehicle Agent.
 
Name: 3. Driven Vehicle Agent
Description: Represents a vehicle plus the driver within the vehicle working as one, from the point of view of modeling traffic. It can represent a car or a truck, by varying size, speed and acceleration parameters.
Beliefs and Knowledge
Goals
Plans
  • Knows the planned route to complete the current journey.
  • Holds maximum speed limit from environment.
  • Holds the estimated speed of the vehicle in front.
  • Knows if the vehicle in front intends to slow down.
  • Knows if a turn is required at the next intersection, and knows whether itís a left or right turn.
  • Knows if there is a candidate gap in traffic in adjacent lanes.
  • Knows all parking lots in close proximity to route destination
  • Don't injure any people (eg. pedestrian Commuter Agents).
  • Don't damage any vehicles.
  • Drive at a safe speed always within the speed limit.
  • Minimise time spent driving along a link.
  • Indicate to other nearby agents, its intentions of changing lanes, stopping, or turning.
  • Accelerate or decelerate in a smooth and consistent manner.
  • Find parking as close as possible to the journey destination.
  • Gets route plan from Route Selection Agent.
  • If a link on the planned route becomes blocked or clearly sub-optimal, contact the Route Selection Agent for a revised plan.
 
Name: 4. Route Selection Agent
Description: An optimising agent which determines the best route for a journey given the origin and destination of that journey.
Beliefs and Knowledge
Goals
Plans
  • Knows the origin and the destination of any given journey, within the transport network of the environment.
  • Knows all links and intersections within the entire road network.
  • Knows all Intersection Controller Agents and all Arterial Section Controller Agents.
  • Knows all train stations, tram stops and bus stops.
  • Knows timetables for all trains, buses and trams.
  • To find the best route plan for any given journey.
  • To find the best route plan for any given journey, taking into consideration current network loads.
  • Use an algorithm such as the so called gravity model, or some similar optimising technique.
  • In the case of a Driven Vehicle Agent reporting a blocked link, remove that link from the internal network model and recalculate a revised optimum route.
  • Compare alternative Train, Tram and Bus routes for Commuter Agent journeys.
 
Name: 5. Emergency Driven Vehicle Agent
Description: To service calls for assistance as dispatched by the Emergency Vehicle Dispatcher Agent.
Beliefs and Knowledge
Goals
Plans
  • Knows where the nearest available appropriate service is (hospital in the case of an ambulance; a water hydrant in the case of fire truck)
  • Knows where the current client in need of assistance is, ie the destination of a journey.
  • To save lives.
  • To save property, in the case calls for assistance of fire brigade and police.
  • To respond as quickly as possible to a request for assistance.
  • Flash warning lights and sound siren, to signal its presence to other vehicle agents.
  • Instruct the Intersection Controller Agent, immediately forward of current position, to turn the appropriate light green.
  • Place itself 'on call' with the Emergence Vehicle Dispatcher Agent, after completion of a previous journey (task).
 
Name: 6. Emergence Vehicle Dispatcher Agent
Description: Takes calls from all agents calling for emergency assistance, then dispatches an Emergency Vehicle Agent to the appropriate destination.
Beliefs and Knowledge
Goals
Plans
  • Knows all available Emergency Driven Vehicle Agents.
  • Knows what type of emergency vehicle agent, each of them is: Ambulance; Fire fighter; Police.
  • Knows the location of the current call for assistance: either a Household Agent; a Workplace Agent; a Driven Vehicle Agent or a Commuter Agent; Tram, Train or Bus Agent.
  • Knows the location of all services: hospitals; fire hydrants.
  • Find all unoccupied Emergency Vehicle Agents capable of dealing with a given emergency.
  • To answer client calls for assistance (from a: Household Agent, a Workplace Agent or a Driven Vehicle Agent, or a Tram, Train or Bus Agent).
  • To identify if a call is about a new emergency, or one already being serviced.
  • To prioritise calls waiting (queued) for service.
  • To select appropriate Emergency Driven Vehicle Agent, to service a client call for assistance.
  • To instruct an Emergency Vehicle Agent to go to a particular call.
  • To locate and select an appropriate service (hospital or fire hydrant), in order to respond to current request for assistance.
  • Check with all Emergency Vehicle Agents and ask them if they are currently servicing a task or are idle.
  • Constantly monitor client call line (thread) for assistance.
  • Check a new calls location, and nature of request, and then check against current queued calls, to estimate if another agent is reporting the same emergency.
  • Tally up multiple emergency calls for the same situation, and give a higher priority to those that have higher tallies.
  • Of the available appropriate Emergency Vehicle Agents, dispatch the one closest to the destination of the emergency.
 
Name: 7. Household Agent
Description: Represents a household with a location in the environment model. It is the generator of most journeys that add up to traffic.
Beliefs and Knowledge
Goals
Plans
  • Knows the day of week and the time of day.
  • Knows how may journeys to work, to shops and to school will be generated in a given day.
  • Knows when a Journey-to-work for a Driven Vehicle Agent must begin.
  • Knows when a commuter journey must begin.
  • Knows if an accident has occurred.
  • Knows if a fire has begun.
  • Knows if some civil disobedience has occurred.
  • Knows how to initiate a call to the Emergency Dispatch Agent.
  • Has a driveway with a certain number of off-street parking spots
  • Send out all resident Driven Vehicle Agents by the appropriate time, to begin their respective daily journeys.
  • Send out all resident Commuter Agents by the appropriate time, to begin their respective daily journeys.
  • Keep households free of fire and civil disobedience.
  • Check the departure time (alarm setting) for each resident agentís journey-to-work and dispatch them when that time arrives.
  • On the return from work, check with each agent, on whether they got to work on time - if not, adjust the alarm time for the following days journey.
  • Call Emergency Vehicle Dispatcher in case of fire or civil disobedience.
 
Name: 8. Workplace Agent
Description: Represents a workplace with a location in the environment model. It is the generator of many journeys that add up to traffic.
Beliefs and Knowledge
Goals
Plans
  • Knows the day of week and the time of day.
  • Knows how many goods-and-services journeys will be generated in a day and when.
  • Knows when to send Driven Vehicle Agents home.
  • Knows when to send Commuter Agents home.
  • Knows if an accident has occurred.
  • Knows if a fire has begun.
  • Knows if some civil disobedience has occurred.
  • Knows how to initiate a call to the Emergency Dispatch Agent.
  • Has a parking lot with a certain number of off-street parking lots.
  • Send all workers and students (I'm counting schools as a workplace) home on their return journey, at the appropriate time.
  • Dispatch vehicles to deliver goods and services, during work hours, as necessary.
  • Keep workplace free of fire and civil disobedience
  • Check the clock-out-time for each agent that works there, and dispatch them when that time arrives.
  • Call Emergency Vehicle Dispatcher Agent in case of fire or civil disobedience.
 
Name: 9. End of Link Simulator Agent
Description: Simulates Driven Vehicle Agents and Commuter Agents and their journeys, that come from outside the modeled city. Also acts as the singular destination for multiple destinations beyond the boundary of the modeled city.
Beliefs and Knowledge
Goals
Plans
  • Knows the destinations beyond the modeled city, which it represents.
  • Knows all the current Driven Vehicle Agents current residing within it, and when they are due to return to the modeled environment.
  • Where links reach the boundary of the city being modeled, this agent generates traffic (with known destinations), that approximates know observed flows of such links.
  • To be the destination (store) of certain Driven Vehicle Agents.
  • Present itself to the Route Selection Agent as both an origin and destination of journeys.
  • Hold Driven Vehicle Agents for a fixed period of time, simulating a journey with a destination beyond the modeled area.
  • Keep a database/lookup table of the destinations and their travels time, that this agent has to simulate.
 
Name: 10. Commuter
Description: This represents a person who takes some form of public transport to work, be it train, tram or bus.
Beliefs and Knowledge
Goals
Plans
  • Knows how to get to the nearest Train station, Tram stop and Bus stop.
  • Minimise time spent getting to a journeys destination.
  • Don't cross road links at any place other than at intersections controlled by Intersection Controller agents.
  • Gets route plan from Route Selection Agent.
  • Walk to a station, bus stop or tram stop.
  • Wait at a bus stop, train station or tram stop, for the next appropriate Train Agent, Tram Agent or Bus Agent.
  • Identify the correct Train Agent, Tram Agent or Bus Agent, that constitutes a part of its multi-modal journey.
  • Request for a 'Walk' signal from an Intersection Control Agent.
  • Wait at an intersection until a 'Walk' signal is given.
 
Name: 11. Train Agent
Description: Represents a train able to carry Commuter Agents.
Beliefs and Knowledge
Goals
Plans
  • Knows the train timetables in which it participates.
  • Knows all the stations along the route.
  • Knows the time and day.
  • Knows its passenger capacity.
  • To stops at all stations on the train route, for the current timetabled train service.
  • To get to each station on the timetabled route, on time.
  • Not to cross a road if the crossing signals aren't working.
  • Follow a railway track in the environment model.
  • Stop at a Station.
  • Carry Commuter Agents.
  • Call Emergency Dispatch Agent in case of fire, accident or civil disobedience.
 
Name: 12. Tram Agent
Description: Represents a tram, able to carry Commuter Agents.
Beliefs and Knowledge
Goals
Plans
  • Knows the tram timetables in which it participates.
  • Knows all the stops along the route.
  • Knows the time and day.
  • Knows its passenger capacity.
  • To stops at tram stops on the tram route for the current timetabled tram service, which have Commuter Agents waiting there.
  • To get to each stop on the timetabled route, as close to the timetabled time as possible.
  • Stop at a Tram stop, if a Commuter Agent is waiting at the stop.
  • Follow a tram track in the environment model.
  • Call Emergency Dispatch Agent in case of fire, accident or civil disobedience.
 
Name: 13. Bus Agent
Description: Represents a Bus able to carry Commuter Agents.
Beliefs and Knowledge
Goals
Plans
  • Knows the bus timetables in which it participates.
  • Knows all the bus stops along the route.
  • Knows the time and day.
  • Knows its passenger capacity.
  • To stops at all bus stops on the bus route, for the current timetabled service.
  • To get to each station on the timetabled route, on time.
  • Apart from pulling out of a bus stop at any time, with caution, abide by the road rules that a Driven Vehicle Agent is subject to.
  • Follow a bus route in the environment model.
  • Stop at a bus stop, if a Commuter Agent is waiting at the stop.
  • Diverge from a bus route, in some circumstances (eg. bad accident).
  • Call emergency Dispatch Agent in case of fire, accident or civil disobedience.
 

 

 

Copyright 1999, Steve Goschnick. All rights reserved.