Systematic raptor codes for safety broadcast in an unsaturated vehicular highway environment

Active safety broadcast is one of the most fundamental services in intelligent transportation systems. The repetition code proposed in wireless access for vehicular environment (WAVE) standard is inefficient in realistic channel conditions and rapidly changing network topologies. In this study, we propose the use of systematic raptor codes as a forward error correction (FEC) scheme at the MAC layer. This code is optimised for short packet lengths, as are expected in safety applications. We have developed a multi-layered simulator that consists of realistic IEEE 802.11p physical layer results, an analytical random access MAC model and FEC codes implemented at different OSI layers. The model considers safety messages under non-saturated channel conditions according to the vehicular IEEE 802.11p standard. Issues such as the hidden nodes problem, interference and vehicles leaving the communication area are considered. The performance evaluation of raptor codes against repetition codes in the shared control channel with different antenna schemes is also presented.


Introduction
In Europe, more than one million road traffic accidents occur each year, resulting in around 40,000 fatalities, 1.6 million non-fatal injuries and €160 billion in economic loss [1]. This motivates increased interest on the development of intelligent transportation system (ITS) from the research societies, car manufacturers, government organisations and standardisation bodies. In 1999, the FCC allocated 75 MHz frequency spectrum known as direct short-range communications (DSRC) in the 5.9 GHz band to be used exclusively for vehicle-to-vehicle (V2V) and infrastructure-to-vehicle (I2V) communications. The IEEE 802.11p and IEEE 1609 standards are being developed to support vehicular communication requirements and collectively known as wireless access for vehicular environment (WAVE).
The IEEE 802.11p [2] covers the physical (PHY) and medium access control (MAC) layers specifications. The PHY layer is based on IEEE 802.11a/g but with half bandwidth and data rate, thus doubling the time domain parameters such as OFDM symbol duration, guard time interval and preamble time [2]. This results in better tolerance to multipath fading and delay spread. On the other hand, by keeping the same FFT size and number of occupied subcarriers, WAVE potentially has lower tolerance to Doppler spread due to the reduced subcarrier spacing [3]. A higher maximum transmission power of 33 dBm EIRP for the 10 MHz channel is also proposed. The IEEE 802.11p MAC layer is a modified version of the IEEE 802.11e mainly to enable different priority classes and unique quality of service (QoS) for new types of applications proposed in WAVE. Meanwhile, the IEEE 1609 standard deals with higher layer services such as multichannel operation, networking, security and resource allocation services.
The objective of WAVE is to allow fast and reliable exchange of safety messages combined with the knowledge of other moving vehicles and upcoming events on the road which are not visible to the drivers. It can also be used to improve traffic efficiency such as avoiding road congestion, as well as for mobile business or entertainment applications such as toll collection and multimedia http://jwcn.eurasipjournals.com/content/2012/1/213 download on the road. A V2V communication reduces dependency on high cost infrastructure roll-out and coverage restrictions. The single hop V2V broadcast data dissemination is most suitable for a simple, quick and large-scale information delivery. It also removes the need for complex routing [4][5][6].
Since broadcasting usually lacks a feedback channel, repetition coding of safety message is proposed in the WAVE standard [7]. However, it is known that repetition codes have shortcomings such as high latency and inefficient use of bandwidth that leads to network congestion problems. With the development of fountain codes that are most suitable for broadcasting, these codes have recently been studied for vehicular communications [8][9][10]. However, their work steers towards I2V communication for non-safety value-added services. This article focuses on fountain codes for safety applications which provide a very short latency and highly reliable V2V exchanges by broadcasting vital safety messages to all surrounding vehicles.
We present three key contributions in this work. Firstly, we propose a novel coding approach for V2V automatic collision notification (ACN) warning using a systematic raptor code as implemented in the 3GPP MBMS (Multimedia Multicast/Broadcast Service) standard [11]. This code is optimised for short source symbols (SSs) length as are expected in a safety broadcast application. With the systematic code construction, users experiencing good channel conditions can immediately recover the original message, while users with bad channel conditions will make use of the redundant symbols. Secondly, we develop a multi-layered simulator combining a realistic IEEE 802.11p PHY layer, a random MAC under unsaturated conditions, as well as raptor codes and repetition codes forward error correcting schemes for V2V safety broadcasting applications. Altogether, the multi-layered model considers interference from vehicles within the sensing range and hidden nodes that change according to the highway traffic density, average speed and channel erasure probability. Finally, we propose an analytical model that represents raptor codes and repetition codes average end-to-end delay and packet reception rate performance. The performance is compared for the cases when raptor codes are implemented as an extension to the MAC layer against the performance when implemented at the application layer as usually proposed in the literature and in our previous works in [12,13]. Performance of the codes is also compared for different antenna schemes, such as single antenna and multiple antennas spatial diversity schemes as an extension to our previous work in [14].
The rest of the article is organised as follows. Section "Forward error correcting coding schemes for safety data dissemination" briefly describes the design of a repetition code and systematic raptor code for safety broadcast and Section "Safety broadcast system model" explains the building blocks of the system model. Raptor codes and repetition codes numerical results and analytical representations are discussed in Section "Numerical results and discussions". Finally, Section "Conclusions" concludes the article.
Forward error correcting coding schemes for safety data dissemination

Repetition codes
Repetition codes are one of the simplest coding schemes. They are especially beneficial for a safety broadcast implementation that does not have a specific node destination. The WAVE standard proposed the use of repetition codes by means of periodic message arrival rates where the safety message is sent repeatedly N r times until the message is successfully received by all nodes within a communication range or until the message timer expires. In safety broadcast applications where the feedback channel or acknowledgement (ACK) packets are not normally used to ensure fast message exchanges, this coding technique can congest the channel and worsen the already present problems in the random access MAC. Due to these limitations, we propose the use of high reliability rateless codes with a low encoding and decoding complexity, known as raptor codes.

Raptor codes
Raptor codes [15] originate from the family of fountain codes, also known as rateless codes. Their highly scalable and fault-tolerant properties make them a promising area of research. These codes are set apart from other fixed rate codes (e.g. convolution code, Reed-Solomon code, Turbo code and Low Density Parity Check code) by their flexible and reconfigurable coding rate that can be determined on-the-fly. Conventional codes with fixed coding rates require prior knowledge of the channel conditions, which is a challenge for the varying or unknown channel conditions that is prevalent in a vehicular environment. Rather than designing a fixed coding scheme that is only suitable for a given channel model, the aim of fountain coding is to design a coding scheme which would perform at near optimal in varying or unknown channel conditions.
Raptor codes were first introduced as an enhancement to the Luby Transform (LT) code. Raptor codes have been adopted in a number of standards, namely the 3GPP MBMS [11] and the DVB-H standard [16]. In these standards, raptor codes are implemented as the application layer forward error correction (FEC) mechanism. Raptor codes are known to perform best in erasure channels i.e. they are universal, capacity approaching codes. Since packet transmission at higher layers behaves similarly to a binary erasure channel (BEC), this offers a perfect opportunity for implementation of raptor codes. http://jwcn.eurasipjournals.com/content/2012/1/213 Fundamentally, raptor codes are a concatenated code approach with a high performance outer code (also known as precode) and a weakened LT code as the inner code. The weakened LT code has a lower average degree of about 3 compared to the general LT code. Because the bound on a code complexity is controlled by the choice of its degree distribution [17], this approach significantly reduces the encoding and decoding computational complexity, from O K log K to O(K), where K is the number of SSs in the source block. However, this comes at the cost that a fraction of the message block remains in error at the LT decoder. Therefore, the outer code is used to correct the SSs that are not recovered by the weakened LT code.
Although the original design of raptor codes by Shokrollahi [15] is non-systematic by construction, direct access to the original data can often be beneficial especially for nodes with good channel conditions. This property is made available by designing a systematic code through appropriate linear transformation of the input before the LT encoding step at the transmitter. Users which do not observe the systematic symbols are still able to reconstruct the set of the intermediate symbols by exploiting the redundant packets in the raptor encoded bit stream. Our multi-layered simulator is designed based on the systematic raptor codes in the 3GPP MBMS standard [11]. In the standard, the precode scheme itself is a concatenation of LDPC (Low-Density Parity Check) code (of length S symbols) and high-density parity check from binary Gray sequence (of length H symbols). The combination of SSs and redundant symbols from precoding is called intermediate symbols (of length L symbols, where L = K + S + H). A crucial design requirement is to ensure that the precode matrix A (of size L × L) has full rank and is therefore invertible. Two popular methods to solve this are by using the Gaussian elimination or the belief propagation decoding. The Gaussian elimination method is usually used for smaller K block lengths, while belief propagation method is used for larger K. We utilised the Gaussian elimination method in our scenario as proposed in the standard and due to the short source block length of safety messages.

Safety broadcast system model
The safety broadcast system model is developed in MATLAB, and is it consists of three separate building blocks: a realistic OFDM-based PHY layer simulator, the IEEE 802.11p MAC analytical model and different FEC schemes. The FEC schemes developed are: (1) repetition coding implemented at the application layer (APP) as proposed in the standard solution, (2) repetition coding based on packets that are fragmented at the MAC layer, (3) Raptor codes implementation at the APP as usually proposed in the literature that is common for large source block sizes, and (4) Raptor codes implementation at the MAC layer, which is our recommended approach for safety application due to its small source block length. This is explained in more details in sections below.

Safety broadcast scenario setup
The WAVE standard proposes that the control channel (CCH) should be regularly monitored by all vehicles and optimised for a low latency channel usage scheme. Therefore, CCH will mainly be used for 1-hop broadcast high priority safety messages and the cooperative safety messages. In our vehicular environment system model, we consider two types of safety messages, namely the ACN and the Cooperative Awareness Message (CAM) in the CCH. The ACN is used to warn drivers of crash occurrence and avoid chain collision. There are a number of event-driven critical collision risk notification services defined in WAVE basic applications standard [18] such as pre-crash sensing, cooperative forward collision, intersection collision and hazardous location warning. Meanwhile, CAM is used to periodically communicate routine vehicular status such as GPS coordinates, speed, direction and vehicle class. It is expected that the two types of safety messages share the same CCH [4,19,20]. It is also reasonable to assume that the ACN in CCH suffers no interference from background unicast traffic that is usually transmitted in service channels (SCHs). Therefore, interference is only due to the CAM messages. Figure 1 shows a ACN warning scenario on a six-lane bidirectional highway. This is one of the most challenging scenarios in vehicular communications because highest relative speeds are found on highways and this causes the network topology to change more frequently and more rapidly. In this scenario, the vehicle involved in the accident, also known as the tagged vehicle will trigger a ACN broadcast warning message. It is assumed that all vehicles in the environment are interested in the ACN information. We assume that vehicles are equipped with an omnidirectional antenna with road width that is much smaller than the communication range. Therefore in the figure, R covers all lanes at both sides of the tagged vehicle. Performance evaluation is performed on three classes of vehicular traffic densities, β: low, medium and high having 12, 36 and 66 vehicles/km respectively. This follows the Fleetnet European project [21] mobility model.
Active safety is the focus of our work due to human vision limitations and large processing delay to react to emergency events. Timely delivery of the safety information must be catered to ensure that enough time is reserved for the surrounding vehicles to react to the event. In [22], it is estimated that the driver reaction time (which is defined as the time from seeing the brake light from the car in front, to stepping on the brake) typically ranges from 0.7 to 1.5 seconds and 60% of road collisions could be avoided if the driver was given warning of at least 0.5 s http://jwcn.eurasipjournals.com/content/2012/1/213 prior to its collision. Article [23] showed that a delivery latency of less than 0.4 s is required to avoid chain collision on highways. The ETSI standard in [7] specifies that pre-crash sensing has the most stringent latency requirement of 50 ms, while 100 ms maximum latency is specified for other safety applications.

Detailed PHY layer system model
The detailed PHY layer system model is based on a simulation approach that we have developed and verified in [14]. This model takes into consideration an accurate packet error rate (PER) analysis based on the IEEE 802.11p orthogonal frequency division multiplexing (OFDM) scheme, a time-correlated fast fading Rayleigh channel and a training-aided channel estimation. The model is developed for both single antenna and spacetime block code (STBC) multiple antenna schemes. A PER-reception model obtained from a detailed PHY layer model is more computationally exhaustive and improves the accuracy of the vehicular communication system, instead of the pre-built SNR threshold model usually used in a typical network simulator [24].
We have chosen the data rate of 6 Mbps (QPSK 1/2) in our simulations because it is one of the most robust communication modes suitable for safety messages and it is the IEEE 802.11p default data rate [25]. To represent the time evolution of the Rayleigh channel multipath fading and Doppler shifts (e.g. due to vehicles mobility, low transmitter/receiver antenna heights, reflection from huge vehicles and lamp posts), we developed a timecorrelated channel using Clarke's model in [26]: where c is the Doppler spread, v r is maximum relative vehicular speed in m/s, f is the 5.9 GHz IEEE 802.11p CCH frequency and c = 3 × 10 8 m/s. There are L multipath components of unit fading amplitude A n , with a varying phase φ n and arrival azimuth α n that are uniformly distributed over (π, −π). This Rayleigh channel is multiplied with an 8-tap exponentially decaying power delay profile (PDP) that is modified from the ETSI Channel B model [27] having a mean rms delay spread of 100ns, in agreement with highway measurements reported in [28].
To combat multipath delay and Doppler shifts in vehicular environments, the preamble long training sequence is inserted at a predetermined symbol duration throughout the frame, also referred to as midamble data-aided channel tracking [29]. Midamble spacing can be determined from the space-time correlation function, ρ (Δt) [30]: where J 0 (.) is the zero-th order Bessel function of the first kind, v r is the maximum relative velocity, f d is the Doppler spread and Δt is the distance traversed. In the PHY layer simulation in Figure 2, the midamble spacing is fixed to 30 OFDM symbols throughout the simulation. Note that the SISO 574B curve can be improved by choosing a smaller midamble spacing, for example ten symbols.
With plenty of space availability on vehicles, the diversity benefit of STBC multiple antenna schemes can also be exploited because antennas can be placed sufficiently apart and are spatially decorrelated. The PER curves obtained from our detailed PHY layer simulator for different antenna schemes at an average speed of 200 km/h is shown in Figure 2. In the figure, we assume a payload size of N payload = 512 bytes at the application layer and higher layer headers of N layer headers = 62B that consists of 8 bytes UDP header, 20 bytes IP header and 34 bytes MAC header. The 574 bytes PER curves refer to the PSDU (PHY layer service data unit) size when repetition coding in the standard solution is used. The 126 bytes packet refers to raptor codes implementation at the application layer, http://jwcn.eurasipjournals.com/content/2012/1/213  while the 72 bytes PER curves refer to repetition codes or raptor codes implementation at the MAC layer. This can be determined from: It is seen that STBC 2 × 2 and STBC 4 × 4 provide a diversity gain of around 5-10 dB at PER of 10 −2 . The figure also shows the benefit of fragmenting the safety message into K = 8 smaller SSs as proposed in Section "FEC system model" where 2-5 dB gain is seen at PER of 10 −1 . This is because smaller packets are less susceptible to channel estimation errors compared to longer packets. Therefore, shorter SSs due to fragmentation of source block has better PER performance because the preamble and pilot bits that are used to estimate the channel state information are sufficient to cater the rapidly time-varying multipath channel in a highway environment. These PER curves at specific signal to noise ratio (SNR) levels are translated into distance of a receiving vehicle from the tagged vehicle using the log-distance path loss model [30]: The path loss exponent, γ of 2.4 as proposed in [31] is used for non-line-of-sight (NLoS) V2V highway scenario.
Using this path loss model, an on-board unit (OBU) with a typical receiver sensitivity of -89 dBm and transmitting at 23 dBm EIRP will have a communication range of around 500 m.

MAC layer system model
The IEEE 802.11 access the medium by the distributed coordination function (DCF), which is based on CSMA/CA (carrier sense multiple access/collision avoidance) with a window-based backoff mechanism. According to the DCF, a station must sense the medium for a specific time interval known as distributed interframe space (DIFS). If the medium is idle, the station can start transmitting the packet. Otherwise, the transmission is deferred and a backoff process begins after the end of the current transmission. A uniformly random backoff time from the interval [ 0, W + 1] is chosen, where W is the contention window with an initial value of W min . The backoff counter is decremented when the medium is idle. Once the backoff time has expired, the station can access the medium. The interval size will be doubled if the subsequent transmission attempt fails until W = W max . A positive ACK is sent after a short interframe space (SIFS) time interval to notify that a data frame has been successfully received [32]. In safety broadcast there is no ACK and retransmission mechanism. Thus, W will always be W min . MAC parameters such as SIFS, DIFS and slot time (σ ) are longer in the IEEE 802.11p standard compared to the IEEE 802.11a as shown in Table 1.
A number of analytical studies using Markov Chains and stochastic processes to analyse the performance of the IEEE 802.11 DCF have been proposed. Bianchi [33] utilised a bi-dimensional Markov chain as a function of backoff stage (m) and backoff counter (b k ) to define the http://jwcn.eurasipjournals.com/content/2012/1/213 saturation throughput of a finite number of stations with always non-empty transmission queue, in an ideal condition with no channel errors and no hidden nodes. This assumption is not accurate for safety broadcast because of the short safety message length and the lower packet arrival rate, that occupies much less than the channel available capacity. Due to small frame size and low arrival rate of the safety messages, the MAC system model at each vehicle has been classified as a non-saturation condition [20,34]. In our analysis, we enhanced the analytical model for safety broadcast in unsaturated condition proposed in [20]. Our contribution to improve the accuracy of this model is by integrating our PER curves from the PHY layer simulator results in Section "Detailed physical layer system model". We also extended the analytical model for raptor codes and repetition codes using the concept of packet fragmentation at different OSI layers. In addition, the model is further improved to consider that the safety ACN and CAM messages traffic prioritization is achieved using the MAC Enhanced DCF channel access (EDCA) feature as proposed in the IEEE 802.11p standard [2]. With EDCA, the DIFS channel sensing time is replaced with Arbitration inter-frame space (AIFS) which can be determined from [32]: At each vehicle, these messages can be represented by two discrete-time M/G/1 queues [34] with different priorities. We consider that the ACN warning has a higher priority access category (AC3) and the CAM message has a lower priority access category (AC0) with different arbitration inter-frame space number (AIFSN) values. According to [2], AC3 has AIFSN = 2 and AC0 has AIFSN = 9, while the minimum contention window of each of the safety messages is given by: For the case of the ACN message using repetition codes and raptor codes at the application layer, the AIFS in (5) applies. However, with raptor codes implementation at MAC layer, AIFS = 0 because we assume that the K = 8 packets are sent one after another within the source block interval, following the block ACK (B-ACK) scheme proposed in the IEEE 802.11e standard [32]. The AIFS value is also used in the average channel busy time due to successful transmission, T s and the average channel busy time due to collision, T c : where σ is the slot time, δ is the propagation delay and T DATA is the packet (SS) transmission time. Additionally, we improve the T DATA to follow IEEE 802.11p OFDM system: where T DATA is a function of the SS packet size N PSDU in (3). The term T PSDU header consists of the PLCP preamble, the PLCP header (as defined in [32]) and the other training symbols at the PHY layer, N DBPS = 48 is the number of coded bits per OFDM symbol for 6 Mbps QPSK 1/2, and T OFDM = 8μs is the OFDM symbol duration [2]. To simplify the analysis, it is assumed that the average number of vehicles within the carrier sensing range (N cs ) is the same as the average number of vehicles in the transmission range of the tagged vehicle (N tr ) [20]: where β is the vehicular highway density (in vehicles/km). Meanwhile, the average number of potential hidden nodes, N hn from both sides of the tagged vehicle is [20]: With R = 500 m, N cs = N hn is 12 vehicles for low traffic density, 36 vehicles for medium traffic density and 66 vehicles for high traffic density. The unsaturated analytical MAC of safety messages for uncoded and repetition coding scenarios have been verified using a network simulator simulation in [20]. However, it has not been studied yet for raptor codes, which we will cover in the next section of this article. http://jwcn.eurasipjournals.com/content/2012/1/213

FEC system model
Previous works in [6,35] used the assumption that safety messages have a small packet length in the range of a few hundred bytes. We adopt this assumption by considering a 512 bytes source block for both ACN and CAM safety messages. This is a reasonable average packet size to carry data and security information [36]. For an unsaturated condition, the packet generation rate (λ) is lower than the service rate (μ) i.e. λ/μ < 1 [20]. We assumed that a safety message in the CCH has a basic packet generation rate of λ SB = 10 packets/s (i.e. packet generation interval of 100 ms), in accordance to the standard [7]. The CAM messages are not encoded due to its periodically changing content, while the ACN message has different packet generation rates depending on the FEC scheme employed. For ACN message in uncoded and repetition coding at application layer (K = 1) scenarios, this packet generation rate is directly adopted in the MAC analytical model during the investigation (λ SS uncoded = λ SS repetition(APP) = λ SB ). However, for raptor coding, we assume that the safety messages are fragmented into K = 8 smaller packets (also known as SSs) and encoded before transmission, which will give an average packet generation rate of λ SS raptor = λ SB K = 80 packets/s. For a more complete analysis of the two coding schemes, repetition code fragmented at the MAC layer (λ SS repetition(MAC) = λ SS raptor ) will also be studied.
For uncoded ACN warning, the whole 512 bytes payload is only transmitted once. For ACN warning using repetition codes, the K SSs are resent approximately N r times and the packet needs to be received correctly at least once for the receiver to recover the warning message. Meanwhile, for the ACN warning using raptor codes, we sent the systematic K = 8 encoded symbols (ESs) the first time, and subsequent transmissions will consists of the non-systematic repair symbols. The raptor codes decoder needs only to collect K ESs in order to successfully decode the ACN original source block, where K = K + ε is only slightly larger than K with good channel conditions, and ε is the number of ESs overhead received to successfully decode the packet. Each transmitted encoded symbol is attached with a sequence number known as ESI (encoded symbol identifier), which can be used to determine the average delay.
For K = 8, the raptor decoder probability of decoding successp raptor is shown in Figure 3, which translates to a receiver successfully recovering the complete ACN message. This numerical analysis is obtained at 95% median of the Monte Carlo simulation and assuming that the channel erasure rates are uniformly distributed in (0,1). It is seen that a maximum of ε = 4 is required at the receiver. Note that in the highway scenario simulation in the next section, the channel erasure rate values will be obtained from SS packet loss rate(1 − p SS ) that is dependent upon our the PHY layer simulator and MAC model as presented in the previous sections.
In this article, we propose the implementation of raptor codes as an extension to the MAC layer to reduce unnecessary overheads from higher layers. The implementation of raptor codes at the MAC layer can be seen as a modified approach to the optional B-ACK scheme proposed in the IEEE 802.11e standard [32]. In our scenario, it is assumed that packets arriving at the MAC layer are fragmented into a number of raptor ESs and transmitted one after another without channel sensing. ACK packets are not implemented because we are dealing with a broadcast channel. Once a vehicle has successfully decoded a specific emergency message, it will simply ignore further duplicate message received. This can be determined by using a few packet identification bits in the MAC header. In the numerical analysis, it will be shown that the adoption of raptor codes at MAC layer offers significant savings to the average end-to-end delay and packet reception rate as compared to implementation at the application layer (as proposed in the standard [7] and recent works [20]). This is due to less overhead requirement and improved packet error performance.

Numerical results and discussions
The aim of this numerical approach is to analyse the multi-layered and real-time properties of the coding schemes described in Section "Forward error correcting coding schemes for safety data dissemination". The transport protocol used for the safety messages is the user datagram protocols (UDP) that has minimal latency as compared to normal data transfer using transmission control protocol (TCP). In TCP, reliability is usually provided by retransmission and congestion control mechanisms. However in safety broadcast applications using UDP transport, reliability is measured by the average frame (source block) packet reception rate p SB , which is an estimate of the probability that a vehicle will successfully receive at least one ACN safety message. Latency is measured by average end-to-end source block delay, τ SB which is defined as the total time from when the ACN packet is generated by the tagged vehicle until it is successfully received at the receiver. Measurements in [37] show that the processing delay from raptor encoding and decoding procedure is no longer than 1 ms and fast implementations of raptor codes chipsets are readily available on the market. Thus, this processing delay is not taken into consideration for the raptor codes end-to-end delay calculation. Throughput is not of primary importance for short length VANETs safety messages and therefore it is not used as a performance metric in this analysis.
In order to find the ACN warning and CAM status source block average end-to-end delay τ SB and packet reception rate p SB , we first need to find the values for each SS. Based on the PER curves from our detailed PHY layer simulator in Section "Detailed physical layer system model" and the MAC model in Section "MAC layer system model", the SS packet reception rate is a function of density β and distance d from the tagged vehicle given by p SS (β, d). Meanwhile, in [20] a SS average endto-end delay is only a function of density β given by the term τ SS (β). When N r > 1, the average end-to-end delay becomes a function of density and distance i.e. τ SB (β, d). We shall first investigate the impact of the contention window on different safety messages due to the hybrid EDCA in order to find the optimal IEEE 802.11p parameters to be used for safety broadcasts when no FEC scheme is applied i.e uncoded scenario. This also implies that N r = 1 or no repetition coding is in place (i.e. τ SB uncoded (β) = τ SS (β) and p SB uncoded (β, d) = p SS (β, d)). The selection of the minimum contention window (W min ) will influence these two metrics, both of which are important to ensure reliability and real-time delivery of safety messages.
According to [7], most safety messages have the requirement of average delay τ SB <100 ms and [20] indicates that they have the p SB requirement of ∼ 99%. Based on the results from Figure 4, we chose W min = 31 (which gives W ACN = 31 and W CAM = 7 according to (6)) because it gave one of the best packet reception rates for the ACN warning, while at the same time having an acceptable increase to the average delay of the ACN warning (<2 ms) and CAM status message (<5 ms). It can also be seen that prioritization of ACN warning over CAM status message in EDCA comes at the cost of increasing the delay of the CAM message. However, this can be overlooked for the importance of detecting the short interval safety critical ACN message. Since the two types of safety messages transmit in a common CCH, their packet reception rates are identical as shown in Figure 4b. The figure also shows that even with best channel conditions (PER = 0), which can only occur at very high SNR or close distances to the tagged vehicle, the ACN p SB uncoded ∼ 99% requirement cannot be met even for very low traffic densities considered. When W min = 15, the maximum achievable p SB uncoded is ∼ 75% for low density traffic (12 vehicles/km), ∼ 60% for medium traffic density (36 vehicles/km) and ∼ 45% for high traffic density (66 vehicles/km). Poorer τ SB uncoded and p SB uncoded performance will be experienced at higher PER due to packet loss and errors. Therefore, a FEC scheme is necessary.
The repetition coding at the application layer [7,20] has the advantage of a low complexity design. However, it is inefficient when dealing with lossy channels such as vehicular environments. In this article, we propose an implementation of a low complexity coding scheme that is suitable for broadcast channels, known as raptor codes which has been adopted in the 3GPP MBMS and the DVB-H standards [11,16]. We define the ACN warning average end-to-end delay for the FEC schemes as: In the simulation, the τ SS repetition(APP) refers to latency of a 574B PSDU similar to uncoded scenario, τ SS repetition(MAC) refers to 72B PSDU, τ SS raptor refers to 72B if they are applied at the MAC layer or 126B if they are applied at the APP layer.
To determine the average end-to-end ACN warning delay, we find the minimum values of N r (for repetition codes) and ESI K+ε (for raptor codes) for different channel erasure rates at different d distances and β densities by using a Monte Carlo simulation approach. Figure 5 shows the performance of raptor codes against repetition codes at different traffic densities and different antenna schemes. It can be seen that raptor codes have much higher tolerance against the packet error or channel erasure. With raptor codes, only at high distance (d>600 m), will the average delay performance τ SB raptor starts to fall outside the maximum latency requirement. This corresponds to very high packet erasure rate. We assume that this impact is negligible since receivers do not usually operate in this region. This threshold is seen at much lower distances for repetition codes, i.e. τ SB repetiton(APP) > 100 ms before the intended communication range R = 500 m for SISO and STBC 2 × 2 schemes, and d = 650 m for STBC 4 × 4 scheme. In all cases, it is verified that raptor codes have τ SB raptor <10 ms even at the edge of the communication range (R = 500 m). This meets even the most stringent latency requirements for pre-crash sensing applications, which are defined as 50 ms in [7]. The numerical analysis also shows that the most prominent delay reductions are seen at high density traffic (worst case scenario) in all antenna schemes. Raptor codes gave the most substantial average delay savings (>5 times average delay reduction at d = 500 m for SISO and STBC 2 × 2, and d = 650 m for STBC 4 × 4) for high traffic density when compared to delay reduction for lower density traffic. This validates the benefits of raptor codes in very difficult channel conditions. It is noted that at close distances with very good channel conditions (PER→ 0%), the repetition coding will perform slightly better than raptor codes due to the minimum raptor overhead ε requirement of as seen in Figure 3.
Finally, the ACN warning packet reception rate (p SB ) for different vehicle densities and antenna schemes is analysed. Assuming a fixed maximum allowable latency T max = 50 ms, this translates to different upper limit N r max repetition factor and ESI(K + ε max ) for raptor codes, given by: repetition code: low density raptor code: low density repetition code: medium density raptor code: medium density repetition code: high density raptor code: high density  The ACN warning source block packet reception rates are given by: where the raptor codes p SB raptor (β, d) is dependent upon the raptor decoder probability of successp raptor at each specific i received overhead as presented in Figure 3. It is seen in Figure 6 that high traffic density has the worst packet reception rate p SB performance. This is due to the increase in the number of interfering nodes and hidden terminals in the environment. The 99% p SB repetition(APP) is retained up to a distance of ∼ 400 m for SISO, ∼ 450 m for STBC 2 × 2 and ∼ 600 m for STBC 4 × 4. This indicates that for a higher diversity order multiple antenna schemes such as STBC 4 × 4, the communication range is extended while still maintaining the same packet reception rate and low delay because there is no adverse effect from the interfering nodes. For raptor codes, the 99% p SB raptor is extended to ∼ 550 m for SISO  and STBC 2 × 2, and ∼ 750 m for STBC 4 × 4 (i.e. 20 − 30% improvement as compared to repetition codes). This further justifies the benefit of implementing raptor codes for safety messaging.
In summary, multiple antenna schemes STBC 2 × 2 and STBC 4 × 4 always have better or equivalent τ SB repetition(APP) and p SB repetition(APP) performance as compared to SISO scheme. In the case of τ SB raptor and p SB raptor , at closer distances to tagged vehicle until the intended 500 m cell edge, the STBC 2 × 2 scheme (Figures 5b and 6b) performs better than SISO (Figures 5a  and 6a). However, worse raptor codes performance for STBC 2 × 2 scheme as compared to SISO is seen at distances >550 m (i.e. corresponding to SNR<3 dB and PER>0.7). This is due to the channel estimation accuracy that affects STBC 2 × 2 scheme more (four spatial channels) than SISO scheme (one spatial channel). The STBC 4 × 4 scheme shows the best τ SB and p SB performance at the cost of reduced throughput due to the 3/4 code rate (rank) as compared to STBC 2 × 2 code rate of 1.
In the previous analysis, we have only compared the performance of repetition code at the application layer (APP) as proposed in the WAVE standard [7] with raptor codes at MAC (our proposed method). In Figure 7, we included the performance evaluation of repetition codes based on packet fragmentation at MAC layer and raptor codes implementation at APP as recommended in the 3GPP standard [11]. The evaluation is performed for the SISO scheme in the low density scenario. It can be seen that repetition(MAC) has better delay performance than repetition(APP) i.e. τ SB repetition(MAC) < τ SB repetition(APP) . With regards to packet reception rate at T max = 50 ms, repetition(MAC) always outperformed repetition(APP) i.e. p SB repetition(MAC) > p SB repetition(APP) . Therefore, we see that by fragmenting the ACN message (adopted from the raptor codes approach) at the MAC layer, significant delay improvement can be achieved due to the reduced overhead requirements. On the other hand, fragmenting the packet at the application layer has adverse delay and packet reception rate performance as seen by the http://jwcn.eurasipjournals.com/content/2012/1/213 τ SB raptor(APP) > τ SB repetition(MAC) and p SB raptor(APP) < p SB repetition(MAC) curves. This is due to the higher layer headers (62B) that are almost the same as the SS fragmented at APP (64B). However, raptor codes (APP) still outperforms repetition codes (APP). Our proposed approach of raptor codes implementation at the MAC layer offers the best delay and packet reception rate performance. This is due to the best PER curve (72B) observed in Figure 2, as well as the reduction in overhead and channel sensing requirement. Analysis has been performed for the STBC multiple antenna schemes and similar trends are observed. Besides that, we have also performed the analysis of safety broadcast in an urban scenario using a Manhattan Grid road structure as proposed in [38]. It is observed that the urban scenario has similar trends as the highway scenario. However, these results are not included in this article due to space limitation.

Conclusions
In this article we have investigated the latency and reliability performance of a V2V communication system using raptor codes and compared them to repetition codes as proposed by the WAVE standard. The detailed PHY layer simulation is integrated with an analytical multilayer model with consideration of random access MAC problems such as hidden nodes and effect of vehicles leaving the coverage area. An unsaturated channel condition that is more accurate to model safety messages packet arrival rates at each vehicle is assumed. Important performance metrics for safety messages broadcast such as the average end-to-end frame delay and the packet reception rate for repetition codes and raptor codes are presented. Two types of safety broadcasts, ACN warning messages and periodic status beacon (also known as CAM) presence in the CCH have been considered. The impact of STBC multiple antenna schemes is also presented. Numerical results on the ACN warning application in a highway scenario reveal that: (1) due to very small safety broadcast SS size, we propose the implementation of raptor codes at the MAC layer in order to minimise the higher layer overheads. The implementation of raptor codes at the MAC and the application layer outperforms the repetition codes at both layers; (2) raptor codes give robust delay performance even at high channel erasure rates. This is in http://jwcn.eurasipjournals.com/content/2012/1/213 contrast to the repetition codes that show very early performance degradation at close distances to the tagged vehicle; (3) safety message packet reception rate ∼ 99% can be achieved with raptor codes with minimal delay and bandwidth requirements as compared to repetition codes; (4) spatial diversity is an efficient method for vehicular communication as it not only improves the delay and packet reception rate, but at the same time extends the communication coverage; (5) high traffic density (for example during rush hours) is a critical scenario for safety broadcast because it introduces higher average delay and reduced the ACN warning packet reception rate due to the increased number of interfering vehicles in the environment. This is where raptor codes are shown to give the most significant improvement to the packet reception rate and delay reduction impact.