% Template GRASS newsletter - Article
% Language: Latex
%

% Head

\title{The DIVERT Project: Development of Inter-Vehicular Reliable Telematics}
%\subtitle{An Open-Source Simulator}
\author{by Hugo Concei\c{c}\~{a}o, Lu\'{\i}s Damas, Michel Ferreira and Jo\~{a}o Barros}

\maketitle

\section{Introduction}
\label{sec:introduction}

The advent of wireless ad-hoc car-to-car (C2C) networks, i.e. groups
of spatially-aware vehicles equipped with the ability to communicate
over the ether and to self-organize into a collaborative mesh, opens a
myriad of possibilities towards sharing and exploiting highly dynamic
geospatial information. The CAR 2 CAR Communication Consortium
Manifesto~\cite{car2car} describes several scenarios where these
networks are used for purposes such as the improvement of driving
safety~\cite{1161067}, optimization of traffic efficiency or to
provide information and entertainment to the driver. Examples of
safety applications are \emph{cooperative forward collision warning}
(see e.g.~\cite{DBLP:conf/mobiquitous/YangLZV04}), \emph{pre-crash
sensing/warning} or \emph{hazardous location notification}.

Regarding traffic efficiency, applications include \emph{enhanced
  route guidance and navigation}, where equipped vehicles use
information collected either from road infrastructures of from other
vehicles about current traffic conditions to calculate optimal routes
to destinations. Another application is the \emph{green light optimal
  speed advisory}, where a traffic sign is able to transmit to
vehicles the optimal speed to make their driving smoother and avoid
stopping. Similarly, wireless communication between nearby vehicles
can provide a \emph{C2C merging assistance} to allow cars to join
flowing traffic without disrupting it.

Wireless ad-hoc C2C networks will also enable applications not
directly connected to safety or traffic efficiency, such as
\emph{point of interest notification} broadcasted to vehicles from
local businesses or tourist attractions, or \emph{remote diagnostics}
of vehicles. Another application will be \emph{internet access in
  vehicle} through the C2C network, allowing multi-hop routes to
internet access points.

The deployment of a C2C network and its applications face some
relevant challenges. It is clear that an inter-vehicular communication
technology requires a significant distribution in the market before it can
show any effect. The C2C Communication Consortium has estimated a
required penetration rate of about 5\% to enable traffic information
propagation. A reluctant introduction may refrain potential new
customers from equipping their vehicles with such communication
systems. The scalability of the C2C communication system is another
important issue that has to be studied. The system must work in
scenarios with very small density of road traffic and in situations
with a very high traffic density, which cause different technical
challenges. The development of collaborative navigation protocols is
another major challenge faced by C2C networks. The goal of propagating
traffic information is to allow vehicles to dynamically calculate the
fastest route to their destination. Clearly, such dynamic calculation
must be based on inter-vehicular collaboration, diverting routes in a
global optimization perspective of the road network.

Given these challenges and the complexity in modeling the mobility
behavior of large-scale distributed traffic systems (see
e.g. ~\cite{saha:04}), the development of realistic simulation tools
is arguably a vital element towards the success of the implementation
of a C2C network. Motivated by this need, we present an open-source
real-time simulation framework for moving vehicles in different road
environments, that includes multiple driving states, inter-vehicle
communication and sophisticated visualization. Our simulator provides
the basis for a systematic approach towards quantifying the performance
trade-offs between relevant metrics such as transmission radius,
fraction of communicating vehicles, freshness of data, and network
connectivity, thus highlighting the dynamics of cooperative
navigation.

\section{The DIVERT Simulator}

\label{sec:divert}

From an abstract point of view, the road network can be seen as a
large graph, whose topology is static and determined by geography, on
top of which we have a random communications graph, whose spatial
realization and connectivity pattern at each point in time is
determined both by the position of the vehicles moving on the road
network and by the transmission aspects of the wireless interface they
use to communicate. To obtain a realistic road graph model, we may
resort to increasingly available geospatial information, whereas the
wireless transmission characteristics have been the object of intense
study yielding useful random models with varying complexities (see
e.g. ~\cite{gupta2000cwn}). Given these two aspects, we structured our
simulation prototype (named DIVERT - Development of Inter-VEhicular
Reliable Telematics) in two layers: a traffic simulation layer based on
the road network graph; and a wireless telematics layer, based on the
random communications graph. We next describe these layers.

\subsection{Traffic Layer}

The geospatial information over which the traffic simulation layer
operates is conveyed to DIVERT using widely used formats, such as
shapefiles, which describe the geometry and connectivity of the road
network. DIVERT includes a sophisticated user interface which allows
editing the basic road segments enriching them with low-level
information describing traffic entities. A screenshot of this
interface is shown in Fig.~\ref{figure:interface}.

\begin{figure}[htbp]
  \centering
  \includegraphics[width=0.95\columnwidth]{images/interface.jpg}
  \caption{The DIVERT road editing interface}
  \label{figure:interface}
\end{figure}

Currently, DIVERT has been setup using geospatial information of the
city of Porto, the second largest in Portugal.  Its road network
covers an area of 62 square kilometers, with 1941 streets summing up
to 965 kilometers of extension.

In DIVERT we model two types of vehicles: vehicles which circulate and
communicate, called \emph{sensors}; and vehicles which just
circulate. Within each type of vehicle, DIVERT further distinguishes in
normal and large-sized vehicles, associating appropriate mobility
patterns to each. These mobility patterns are also individually
influenced by random initialization of attributes such as
acceleration, braking, aggressiveness and risk tolerance. Sensors add
an attribute of wireless transmission range.

DIVERT uses the following layers of geospatial information about the
road network:

\begin{enumerate}

\item Two simple layers of the road central axles, representing,
  through polylines, the geometry of intersection free road segments,
  and their topological connectivity. These layers can be given to DIVERT
  as shapefiles. A copy of these layers is present in every sensor, and
  is used for positioning of GPS readings and for the collaborative
  propagation of mobility conditions on road segments.
 
\item Low-level layers describing in detail the road network of Porto,
  including information of road segment lanes, lane-level
  connectivity, intersection visibility, traffic lights location,
  traffic lights inter-relationships, speed limits on segments, and
  parking. These layers must be edited through the DIVERT interface
  and are used by the traffic simulator.

\end{enumerate}

A raster layer from satellite images of the simulation area further
improves the visualization of traffic in our prototype, which is
currently based on 2D data. Work is undergoing for a 3D model, which
will not only allow more realistic accelerations parametrized by
steepness, but also enable an improved modeling of wireless
transmission ranges, which accounts for fading, reflection and
shadowing effects based on a 3D layer for buildings.

Regarding vehicle routes, DIVERT currently uses an hybrid model of
pre-defined routes and randomly generated routes. For randomly
generated routes, our system arbitrarily selects an origin and a
destination and calculates the route based on a shortest-path
algorithm, either parameterized by distance or by time. Shortest-path
based on time uses not only the speed limits of segments, but mainly
the dynamic calibration of average mobility derived from previous
simulation results. Pre-defined routes have an associated frequency
and have been carefully chosen to approximate the simulation to our
perception of traffic distribution in our current work case, the city
of Porto. Figure~\ref{figure:routes} shows the DIVERT interface for
setting up a pre-defined route.

\begin{figure}[htbp]
  \centering
  \includegraphics[width=0.95\columnwidth]{images/routes.jpg}
  \caption{Setting up pre-defined routes in DIVERT}
  \label{figure:routes}
\end{figure}

Traffic simulation is parameterized by the number of vehicles and the
percentage of these vehicles which are sensors. Simulation is
initialized by randomly placing each vehicle in an arbitrary point of
its route. Vehicles which arrive at their destination are removed. New
vehicles also show up during the simulation, either from entry points in
the map, or from parking lanes of segments, as DIVERT tries to
maintain the targeted number of vehicles for the simulation. 

It should be noted that the simultaneous micro-simulation of thousands
of vehicles, with the degree of sophistication offered by DIVERT,
poses major challenges in term of optimization of algorithms and
efficiency of data-structures. In particular, DIVERT implementation is
multi-threaded, exploring multi-core architectures of current
processors. A geographic partitioning of the simulation region is
performed, allowing each partition to be independently simulated in a
thread.

\subsection{Wireless Telematics Layer}

In order to capture the inter-vehicle communication aspects it is
necessary to define the level of abstraction with respect to the
physical communication channel and the protocol architecture.  At the
current preliminary stage, we opted for a very simple model, in which
vehicles communicate with each other if their distance is below a
certain threshold, determined by the transmission radius.
The resulting random geometric graph is widely accepted as a simple
yet reasonable first-order approximation of the connectivity pattern
attained by a mobile ad-hoc network~\cite{xue2004nnn}. A more
elaborate approach would be to consider path loss, multi-path and
shadowing effects, however this would incur in a high penalty in terms
of simulation complexity. Another alternative would be to consider
collisions and packet losses over the wireless medium.  We are
currently considering the possibility of integrating these aspects in
our simulation in order to obtain a richer connectivity profile.

The wireless telematics layer simulates the communication between
vehicles. Several inter-vehicular protocols can be implemented in
this layer, such as protocols for safety applications or for traffic
conditions propagation and collaborative navigation. The
implementation of this wireless telematics layer is supported by the
traffic simulation layer, which acts as a global positioning server,
emulating a GPS receiver in each of the sensors. The interface between
the two layers is thus done through GPS-like sentences, where the
traffic simulator generates the position of each sensor, in terms of
latitude and longitude, and its velocity vector, together with a
global timestamp which provides the time-synchronization among the
inter-vehicle data exchange. It is a task of the wireless telematics
layer to calculate the vehicles in the (parameterized) transmission
range of a given sensor, to implement the message exchange protocols
between vehicles, and to trigger actions based on the information
collected, such as a route modification. The architecture of the two
layers in DIVERT allows that a triggered action such as
route modification can be conveyed back to the traffic simulation
layer, affecting the behaviour of the vehicle.

Currently, the protocols we have implemented using DIVERT aim at the
collaborative propagation of mobility information about road
segments. Each sensor stores a common data structure, where the pair
$(AverageSpeed,Freshness)$ describes the average speed attained by
sensors traversing each of the road segments, together with a
quantification of the timeliness of average speed estimate. These
pairs are updated either by each sensor based on the road it is
traversing and its GPS information, or by aggregated information
collected from the wireless communications broadcasted by other
sensors. Typically, sensors only transmit information about road
segments for which the freshness value is above a predefined
threshold. DIVERT is able to simulate the propagation of this mobility
information using different wireless transmission radii.  Our results
show that there exists a critical value for the transmission radius
after which the dissemination of traffic information is sufficient for
a large number of vehicles to be able to compute a comprehensive and
accurate congestion map. This observation is strikingly related to the
physical phenomenon of percolation, which is well known to govern the
connectivity of large classes of wireless
networks~\cite{booth2003cac}. Once the transmission radius is above
the critical threshold, the graph representing wireless connectivity
has a giant component on which traffic information flows very fast and
over long distances.


\section{Future Developments}

\label{sec:future}

DIVERT is under constant development. Currently the implementation
lists $50000$ lines of C++ code, including the graphical interface and
visualization component. The DIVERT interface also allows launching
simple programs written in Python, which are very useful to make the
simulator produce several types of reports, generate videos of a
simulation or help in the edition of maps. A redefinition of the
simulator architecture in several independent modules is
undergoing. Our goal is to have a larger number of independent modules
which will make it simpler for a large community of users to modify
the simulator to their specific needs. 

A particular effort is being put on the development of a specification
language that will allow making easier the setting up of DIVERT with
different geospatial data. The geographic layers underpinning the
simulation are already based on open standards, but there are still a
number of areas where the lack of automation constitutes an obstacle
to the wide use of DIVERT. In particular, the realistic calibration of
routes and their frequency is a crucial problem. We are trying to
approach such automation through the analysis and processing of
cellular phone logs, a technique known as \emph{floating car data},
which in urban environments are able to provide high-precision
descriptions of travels in the road network. The automation of the
construction of realistic origin/destination matrices, together with
geospatial data defining the road network based on widely used
standards, would provide the necessary data to test DIVERT in
different scenarios. 

We will continue designing, implementing and testing different
protocols for inter-vehicular communications through DIVERT. Our focus
will continue to center in traffic efficiency, where we have been able
to find challenging problems related to collaborative optimization of
traffic flow. We hope to see alternative protocols developed worldwide
using the DIVERT framework, in all areas of C2C communication. 

For those who missed the FOSS4G2007 DIVERT demonstration, a video of a
  simulation is available at \url{http://myddas.dcc.fc.up.pt/divert/}.
     
\begin{footnotesize}

\begin{thebibliography}{99}

\bibitem{car2car}
CAR 2 CAR  Communication Consortium Manifesto. Version 1.1
\newblock http://www.car-2-car.org/, 2007.

\bibitem{1161067}
C.~L. Robinson, L.~Caminiti, D.~Caveney, and K.~Laberteaux.
\newblock Efficient coordination and transmission of data for cooperative
  vehicular safety applications.
\newblock In {\em VANET '06: Proceedings of the 3rd international workshop on
  Vehicular ad hoc networks}, pages 10--19, New York, NY, USA, 2006. ACM Press.

\bibitem{DBLP:conf/mobiquitous/YangLZV04}
X.~Yang, J.~Liu, F.~Zhao, and N.~H. Vaidya.
\newblock A vehicle-to-vehicle communication protocol for cooperative collision
  warning.
\newblock In {\em MobiQuitous}, pages 114--123. IEEE Computer Society, 2004.

\bibitem{saha:04}
A.~K. Saha and D.~B. Johnson.
\newblock Modeling mobility for vehicular ad-hoc networks.
\newblock In {\em VANET '04: Proceedings of the 1st ACM international workshop
  on Vehicular ad hoc networks}, pages 91--92, New York, NY, USA, 2004. ACM
  Press.

\bibitem{gupta2000cwn}
P.~Gupta and P.~Kumar.
\newblock {The capacity of wireless networks}.
\newblock {\em Information Theory, IEEE Transactions on}, 46(2):388--404, 2000.

\bibitem{xue2004nnn}
F.~Xue and P.~Kumar.
\newblock {The Number of Neighbors Needed for Connectivity of Wireless
  Networks}.
\newblock {\em Wireless Networks}, 10(2):169--181, 2004.

\bibitem{booth2003cac}
L.~Booth, J.~Bruck, M.~Franceschetti, and R.~Meester.
\newblock {Covering algorithms, continuum percolation and the geometry of
  wireless networks}.
\newblock {\em Ann. Appl. Probab}, 13(2):722--741, 2003.


\end{thebibliography}
\end{footnotesize}

\address{Hugo Concei\c{c}\~{a}o\\ DCC-FC \& LIACC, University of Porto\\
%  \url{your homepage}\\
  \email{hc AT dcc.fc.up.pt}}

\address{Lu\'{i}s Damas\\
  DCC-FC \& LIACC, University of Porto\\
%  \url{your homepage}\\
  \email{luis AT dcc.fc.up.pt}}

\address{Michel Ferreira\\
  DCC-FC \& LIACC, University of Porto\\
%  \url{your homepage}\\
  \email{michel AT dcc.fc.up.pt}}

\address{Jo\~{a}o Barros\\
  DCC/FC \& IT - University of Porto \\
%  \url{http://www.dcc.fc.up.pt/~hc}\\
  \email{barros AT dcc.fc.up.pt}}

%%% Local Variables: 
%%% mode: latex
%%% TeX-master: main_document.tex
%%% End: 

