Safety analysis of freeway on-ramp merging with the presence of autonomous vehicles

.


Background and objectives
Freeway on-ramp merging areas are typical bottlenecks of the freeway network, not only because of the reduced capacity, but also because of the high risk of crashes and conflicts caused by frequent lanechanging, intricate geometric design, and the variety in driving behaviors in these areas.According to NHTSA, drivers are identified as the critical reason in 94 % of the reported road crashes (Singh, 2015).The main driver-related causes include errors in the recognition, decision-making, and performance process.Due to the complex vehicle negotiations and interactions at merging, drivers must complete multidimensional information processing and vehicle control tasks within a limited distance and time, which greatly increases drivers' workload and the probability of errors (Hu et al., 2020).
The emerging technology of Autonomous Vehicles (AVs) has the potential to eliminate the critical human factors in driving, and thus is highly expected to bring substantial improvements in traffic operational safety.Many studies have been conducted to assess the safety impacts of AVs in various situations, such as the (signalized or unsignalized) intersections (Li et al., 2013;Morando et al., 2018), roundabouts (Morando et al., 2018), freeway corridors (Jeong et al., 2017;Papadoulis et al., 2019), and at the traffic network level (Kockelman et al., 2016).All these studies report a remarkable reduction in the number of traffic conflicts with the presence of AVs, especially at a high AV market penetration rate.The findings are in line with the expectation of AV's positive role in traffic safety.However, although AVs' safety performance in various types of traffic bottlenecks have been well discussed in the literature, there are only very few studies focusing on AVs' driving behaviors and the resulted safety consequences in the freeway on-ramp merging bottlenecks.
The existing studies on the AV's impacts in the freeway on-ramp merging areas focus more on the operational efficiency rather than safety.For example, Park and Smith (2012) propose a merging advisory algorithm utilizing detailed vehicular data and personalized information provision.The authors claim that the algorithm reduces merging conflicts by encouraging early lane-changes on the mainline to create more space for the merging vehicles.However, the paper only reports quantitative changes in vehicle hours traveled and average speed, while the specific number of conflicts reduced by the algorithm is not mentioned.Wang et al. (2013) propose a cooperative algorithm for the collision-free merging of connected vehicles, which ensures merging safety by mapping the mainline and ramp vehicles to each other's lane as virtual vehicles and limiting the minimum gap between the actual and mapped vehicles.Some other studies on freeway on-ramp merging algorithms integrate safety requirements into the joint trajectory planning of the mainline and ramp vehicles to ensure traffic safety (Letter and Elefteriadou, 2017;Rios-Torres and Malikopoulos, 2017).However, these studies usually aim at promoting the efficiency of merging, while the safety requirements are only indirectly considered as a constraint in the models.In addition, all above-reviewed studies propose novel cooperative merging algorithms based on the advanced vehicle communication technology.In this way, the improvement in merging safety is more related to the enhanced vehicle cooperation (e.g.early mainline lane-changes, cooperative deceleration, joint planning of vehicle trajectories) rather than the elimination of critical human factors (e.g.delays, errors, aggressiveness of human drivers).Therefore, the safety effects related to the AVs' autonomous driving capability (i.e. by replacing human control with autonomous control and eliminating critical human factors at merging) are still largely unrevealed in the literature.
In this regard, the objective of this study is to assess the safety impacts of AVs in the freeway on-ramp merging areas with a focus on the special features of autonomous vehicle control compared to human control.Specifically, the following questions are investigated: (1) How (positive/negative) and to what extent will (uncoordinated) AVs affect the safety performance of traffic at freeway on-ramp merging by eliminating the critical human factors in the process of recognition, decisionmaking, and performance?(2) Despite the elimination of critical human factors, will autonomous driving lead to new safety concerns at merging?

Key points of methodology
Given the limited access to the real-world data on AVs, the safety impacts of AVs are usually investigated by combining surrogate safety measure and microscopic simulation (Shahdah et al., 2015;Kockelman et al., 2016;Morando et al., 2018;Papadoulis et al., 2019;Zhu and Krause, 2019).Studies have shown that, with suitable settings of simulation environment and indicator thresholds, the combination of simulation and safety surrogates can predict a number of conflicts which reliably reflect traffic operational safety (Fan et al., 2013;Shahdah et al., 2015).There are various surrogate safety measures proposed in the literature, such as Time-to-Collision (TTC), Post-Encroachment Time (PET), velocity change, and deceleration rate.Previous studies have shown the adequate performance of the existing surrogate safety measures in describing various types of traffic conflicts (Minderhoud and Bovy, 2001;Jin et al., 2011;Kockelman et al., 2016;Morando et al., 2018;Papadoulis et al., 2019).However, the abilities of the existing measures to capture the merging conflicts between a Ramp Merging Vehicle (RMV) and its Mainline Following Vehicle (MFV) is somewhat limited.Note that, as the initial parts of the trajectories of the RMV and the MFV are separate, and the final parts of their trajectories overlap, both longitudinal conflicts and lateral conflicts are present in the on-ramp merging areas.The longitudinal conflicts refer to the rear-end conflicts caused by the speed difference between the MFV and the RMV after they are merged into the same lane.This type of conflict is essentially the same as the normal car-following rear-ends, which can be well assessed by TTC and its variations such as TIT and TET (Jin et al., 2011;Shahdah et al., 2015).The lateral conflicts refer to the conflicts that occur during the merging maneuver (i.e. the lateral movement) of the RMV.The cause of this type of conflicts is very similar to the cause of intersection conflicts, that is, vehicles initially occupying different roadway spaces enter a common area in their trajectories at very similar time.TTC is unable to recognize this type of lateral conflicts, because it only applies in the cases where the following vehicle is faster than the preceding one, which is not always true at merging.Moreover, the existing surrogate measures for intersection conflicts, such as PET, ET (encroachment time), and GT (gap time), cannot be directly applied to lateral merging conflicts as well, because these measures usually require an explicit definition of the start and end of the encroachment, which is not applicable for the merging situations, where the final trajectories of the conflicting traffic overlap (Archer, 2005).As a result of the limitations of the existing surrogate safety measures in assessing lateral merging risk, we are motivated to modify the concept of PET and propose a new conflict index which are more applicable for the merging situations.
In addition, it should be noted that there are many uncertainties in the traffic conditions (e.g. the varying vehicle speed, the existence of mainline gaps) and variations in the road users and the roadway design (e.g. the personality, experience, and condition of a human driver, the geometric configuration of the merging area).These uncertainties and variations should not be disregarded in the safety investigation, because the introduction of uncertainties and variations can reduce the bias produced by any specific cases and provide a more comprehensive insight into traffic safety (Althoff et al., 2010;Yang and Ozbay, 2011;Kuang et al., 2015).
In this paper, we first introduce the new conflict index, called Conflicting Merging Headway (CMH), as a specific indicator for the critical merging events (i.e.near-crashes and conflicts).We also present a merging conflict model that describes the interactions between the RMV and the MFV to estimate the value of CMH in various cases.Then, we conduct a case study of AV safety impact analysis for a typical freeway on-ramp merging area.The safety investigation accounts for real-world uncertainties and variations in various factors by running Monte-Carlo simulation on the merging conflict model with probabilistic distributions as the model inputs.Scenarios with different AV market penetration rates are modeled and compared to a base scenario of Normal human-driven Vehicles (NVs).The input distributions for NVs are calibrated using the data collected under the Next Generation Simulation (NGSIM) program, and the distributions for AVs are derived from the expected capabilities and operating methods of AVs as reported in the published literature and technical reports.The Monte-Carlo simulation study outputs distributions of the CMH index under various AV penetration rates.Statistical analysis on the CMH distributions gives an insight into the potential safety impacts of AVs in the freeway on-ramp merging areas.
The paper is structured as follows.Section 2 defines the conflict index CMH and introduces the merging conflict model in detail.The calibration of input distributions and the implementation of Monte-Carlo simulations are presented in Section 3. Section 4 shows the results of the simulation study and provides a comprehensive discussion on the potential safety impacts of AVs.Section 5 discusses the limitations of the current work and provides a guideline for the future research.The conclusion is drawn in the last section.
Table 1 provides a summary of abbreviations that are frequently used in this paper.

Freeway merging conflict model
In this section, a merging conflict model describing vehicle decisions and actions in the on-ramp merging areas is presented.The model estimates the value of CMH index between each pair of RMV and MFV based on their interactive behaviors at merging.Since the ramp merging process includes a series of decisions and actions, this process is modeled in a sequence of three consecutive event processes: 1) the RMV gap selection process, which describes how the RMV identifies a mainline gap as the target gap to merge into; 2) the RMV merging maneuver process, which determines the specific position of the RMV within the selected target gap; and 3) the MFV evasive action process, which describes the evasive action of the MFV in response to an aggressive merging attempt.

Conflicting merging headway
The conflict index CMH is defined as the time interval between a ramp merging vehicle (i.e. the RMV) arriving at the Merging Point (MP) and the mainline vehicle that directly follows this RMV after merging (i.e. the MFV) arriving at the same position, as shown in Fig. 1.
Note that even though CMH is defined as a measure of time headway, it is essentially different from the car-following headway that describes the relationship between vehicles in the same lane, such as the widely known TTC and its variations.CMH is measured at the initial state of merging, when the RMV and the MFV are still in different lanes.Thus, the value of CMH reflects the potential of the vehicles conflicting with each other in the subsequent merging process.Specifically, the smaller the CMH value is, the closer the initial longitudinal positions of the RMV and the MFV are, and the more likely they will conflict as the RMV moves laterally.In fact, CMH is, by definition, a variant of the widely used surrogate measure PET, as it adopts PET's inherent idea of assessing the conflict risk based on the time that the vehicles occupy a common area where the conflict may occur.The difference between CMH and PET is that, PET describes the time interval between two vehicles occupying a common spatial zone and is primarily designed for places with a clear end of the encroachment (e.g.intersections), while CMH describes the time interval between vehicles passing the merging point, from which the potential of conflict arises.With CMH, a clear determination of the end of the encroachment is not required, and thus it is more applicable for the merging situations, where the (final) trajectories of the conflicting vehicles overlap.Nevertheless, CMH retains the underlying idea of PET in its definition.Please note that, in this paper, the efficiency of the CMH index is demonstrated from a theoretical perspective, with real-data supported estimation method.A more detailed validation on this index is expected in the future research efforts.A detailed discussion on this point is available in Section 5.

RMV gap selection process
As the first step of the merging conflict model, the RMV gap selection process determines which mainline gap an RMV will merge into.Fig. 2 shows a hypothetical merge segment with one lane per direction.When the RMV arrives at the Decision Point (DP) on the ramp, it looks at gaps on the mainline and accepts the first gap that satisfies both of the following conditions: 1) the RMV should have enough time to merge into the gap, meaning that the time the target gap passes the Merging Point (MP) should be no earlier than the earliest time that the RMV can arrive at the MP; 2) the gap should be big enough, which means that the size of the target gap should be no smaller than the acceptable gap of the RMV.These two conditions are expressed as (1) and where, t target is the time that the MFV arrives at MP (i.e. the target gap passes MP), t earliest is the earliest time that the RMV can arrive at MP, g target is the size of the target gap in second, and g acc is the acceptable gap of the RMV in second (i.e. the minimal time gap in the mainline traffic stream that the RMV can accept to merge into).
As depicted in Fig. 2, t target can be formulated as the sum of all gaps in front of the target gap, including the target gap itself, namely The value of t earliest depends on the distance that the RMV cruises on the ramp and its speed trajectory.It is the shortest time the RMV can spend travelling from the DP to the MP, namely first accelerating at the maximum acceleration until the speed limit is reached, then keeping the speed until arriving at MP. Namely, where, S rcd is the ramp cruising distance of the RMV (i.e. the distance between the DP and the MP); a max is the maximum acceleration of the RMV, v r is the speed of the RMV at DP, v limit -is the on-ramp speed limit.
A step-by-step procedure of the RMV gap selection process is given in Fig. 3.

RMV merging maneuver process
Once the RMV has selected its target gap on the main road and decided to merge, the RMV's exact position in the target gap and the initial headway between the RMV and the MFV should be determined in this process.This is decided by comparing two factors: the desired position of the RMV and the earliest-achievable position of the RMV.
As shown in Fig. 4a, it is assumed that the RMV prefers to keep a distance of 1 2 g acc from the Mainline Leading Vehicle (MLV) when no other restriction applies, as it is reasonable to expect that the driver of the RMV will prefer to be equally apart from its leading and following A conflict index, referring to the time interval between an RMV arriving at the merging point and the MFV that directly follows this RMV arriving at the same position vehicles on the mainline.Thus, the desired position of the RMV is assumed as The earliest-achievable position is the foremost position that the RMV can reach, namely the position when the RMV arrives at its earliest arrival time (t earliest ).
Fig. 4b and c show the two cases when comparing the desired position to the earliest-achievable position.The RMV will take the desired position if it is later than the earliest-achievable position (Fig. 4b).Otherwise, the RMV will either take the earliest-achievable position (Fig. 4c) or change its target gap.Whether the target gap is changed depends on two factors: 1) whether the initial headway between the MFV and the earliest-achievable position of RMV is too critical (i.e.there is a need to change); 2) whether another gap is available within a reasonable distance (i.e.there is a possibility to change).In this model we assume that, the RMV will only give up the current gap if the initial headway h 0 is smaller than a critical headway h c and an  alternative gap is available.
After determining the RMV's target gap and its actual position within the gap (t actual ), the initial headway between the RMV and the MFV is expressed as or equivalently where, h 0 is the initial headway between the RMV and the MFV, t earliest is the earliest arrival time of the RMV, t desire is the desired position of the RMV, t actual is the actual position of the RMV in the target gap.The rest of  J. Zhu and I. Tasic the parameters are defined the same as previously.
Note that the initial headway h 0 obtained in this step differs from the final value of the CMH which results after the evasive braking action of the MFV, as will be explained in the next step of the model.Fig. 5 is an overview of the RMV merging maneuver process.

MFV evasive action process
The MFV evasive action refers to the behavior that the MFV brakes to maintain a desired/safe distance from the RMV when the initial headway is too small, resulting in the final CMH as the expected conflict index for the merging process.In this process, a total of four merging situations are distinguished according to the evasive action of the MFV.The evasive braking rate (b) and the resulted final CMH are estimated for each situation.
First, it is assumed that each MFV has a desired headway h d .The value of h d depends on driver aggressiveness (for NVs) or driving mode (for AVs).If h d is smaller than the initial headway h 0 , the initial headway is acceptable, and no evasive action is needed, namely Otherwise, the MFV should brake for safety reasons.We consider that the MFV can only be aware of the merging intention of the RMV a certain time before arriving at MP.If the reaction time of the MFV (τ) is longer than this awareness time (t aware ), the MFV does not have time to react and is forced to accept the initial headway h 0 , namely: In the case where h 0 < h d and τ < t aware , the MFV will react by braking at a certain deceleration rate and achieve a final headway (i.e. the CMH) which is larger than the initial headway.
Fig. 6a depicts the determination of the braking rate that is required to achieve the desired headway h d .The origin of the time axis is the time when the MFV becomes aware of the RMV.Thus, the MFV will arrive at MP in a time of t aware without deceleration (black solid line in Fig. 6a).As the initial headway between the RMV and the MFV is h 0 , the arrival time of the RMV is t aware − h 0 .If the MFV intends to keep a headway of h d from the RMV, its arrival time should be t aware − h 0 + h d .To achieve this desired arrival time, it is assumed that the MFV will first retain the initial speed v m within the reaction time τ and then brake at the deceleration b 0 (red solid line in Fig. 6a).Note that the distance the MFV travels before arriving at MP remains the same, namely the area enclosed by the black line and the axes should equal the area enclosed by the red line and the axes.Therefore, the value of b 0 is computed by jointly solving (8) and ( 9) Fig. 6.Evasive braking rate of the mainline following vehicle.
(Eq. ( 8) describes the constancy of travel distance, and Eq. ( 9) describes the change in speed): where, v m is the initial speed of the MFV, v ' m is the reduced speed of the MFV when arriving at MP, t aware is the awareness time of the MFV (i.e. the time from the MFV's awareness of the merging intention of the RMV to the arrival of the MFV at MP), τ is the reaction time of the MFV, h 0 is the initial headway between the RMV and the MFV, h d is the desired headway of the MFV, and b 0 is the required braking rate of the MFV to maintain a desired headway of h d .
We obtain the value of b 0 to achieve the desired headway as: If this required braking rate b 0 is no greater than the maximum technically allowable deceleration (b max ), the MFV can brake at b 0 and achieve a CMH equal to h d , namely 6b depicts the situation when b 0 is larger than b max .In this case where b 0 is not available, the MFV brakes at b max and accepts a CMH between h 0 and h d in size.To estimate the value of CMH for this case, the actual arrival time of the MFV (t arrival ) should be determined (the red point in Fig. 6b).Similar to previously, this is done by jointly solving the Eqs.( 11) and ( 12) which describe the MFV's travel distance and change in speed, respectively: These give and the CMH is computed as Here, we have the case where the MFV achieves its maximum braking rate, and the resulted CMH is larger than the initial but smaller than the desired distance between the RMV and MFV: Situation 4: If h 0 <h d ANDτ<t aware AND b 0 >b max ,then b=b max AND CMH by ( 14) Fig. 7 illustrates the event tree of the MFV evasive action process with the final situations highlighted in red.

Monte-Carlo method
The merging conflict model introduced in the previous section describes the deterministic relationship between a certain pair of RMV and MFV and estimates the value of the proposed conflict index, the CMH, which can readily be used as an indicator of how close the two vehicles in the merging process were to a conflict or a crash.
In order to more closely represent real-world traffic conditions, which may help to achieve more accurate safety assessment, we need to acknowledge that there are many uncertainties and variations in the traffic conditions, the road user behaviors, and the roadway design.Thus, the parameter values of the merging conflict model are more likely to vary within a certain range than to be deterministic.A way to accommodate these uncertainties and variations is to use probabilistic distributions (instead of deterministic values) as inputs of the merging conflict model and conduct simulation study through the Monte-Carlo method.Specifically, in each simulation run, we randomly draw a value from the input distribution of each parameter (Table 2) and use these values to perform a deterministic computation of the CMH value Fig. 7. Evasive action process of the mainline following vehicle.
based on the equations derived in the merging conflict model.After repeating this simulation process for a large-enough number of times, we aggregate the outputs and obtain a distribution of CMH that is considered to be subject to various uncertainties and variations.Through the CMH distribution, we can assess the risk of merging and infer the probabilities of particular critical merging events, such as conflicts and near-crashes.
The Monte-Carlo simulation is performed by using the software MATLAB, version R2020a.For each study scenario, 50,000 simulation runs are conducted to ensure a satisfying reliability level of the results.In addition to CMH, the values of evasive braking rate are also obtained from the simulation and used to derive conclusions about the conflict severity.

Study scenarios
Given that the main purpose of this study is to examine the ramp merging safety with the presence of AVs, four simulation scenarios with incremental market penetration rates of AVs are developed and compared to a base scenario with only manually-driven NV.
The five study scenarios are: • 100 % NV scenario (NV100) • 20 % AV and 80 % NV mix-scenario (AV20) • 50 % AV and 50 % NV mix-scenario (AV50) • 80 % AV and 20 % NV mix-scenario (AV80) • 100 % AV scenario (AV100) In the mix-scenarios (AV20, AV50, and AV80), vehicles are randomly assigned as NV or AV based on the corresponding AV penetration rate.For example, in the AV20 scenario, a random number between 0 and 1 is drawn at each vehicle creation, if the number is smaller than 0.2, the newly-created vehicle is assigned as AV, otherwise it is tagged as NV.This procedure is repeated for each vehicle in the mix-scenarios.
The following assumptions on AVs are adopted based on existing practice and research findings: • All AVs are at the highly automated level corresponding to SAE automation level 4 (SAE, 2016).The vehicles are capable of longitudinal and lateral driving tasks without any expectations of human assistance.Communication capabilities of AVs are only partially considered in the sense that AVs possess more comprehensive information on the traffic conditions.• AVs have various driving modes (i.e. a configuration of parameters that decide the aggressiveness of AV driving behaviors) to accommodate various preferences of AV users.Three driving modes (an aggressive mode, a normal mode, and a conservative mode) and a 30 %-40 % -30 % share across the modes are assumed.

A case study
To demonstrate the proposed method of AV safety investigation at freeway on-ramp merging, a case study of the Powell Street on-ramp merging area on the eastbound Interstate 80 in California, USA is conducted.As shown in Fig. 8, the study area is about 503 m long with six lanes on the main road.The Powell Street on-ramp is connected to the main road through an acceleration lane with a length of approximately 100 m.
In order to reflect the real-world traffic conditions, we use fieldcollected traffic data to calibrate the input distributions of the merging conflict model for NVs.Then, we validate the calibrated model by comparing the model-estimated CMH values to the empirical CMH values derived from data.The data used in the calibration are collected under the Next Generation Simulation (NGSIM) program (FHWA, 2016).The dataset contains vehicle trajectory data at every 0.1 s collected in the study area from 4:00 to 4:15 on April 13, 2015, providing detailed information on the NV driving behaviors at merging.The probabilistic distributions are fitted with the distribution fitter tool in MATLAB.For each model parameter, we fit various types of distribution to the observed data and choose the distribution with the maximum log-likelihood value.For AVs, the determination of distribution parameters is relatively difficult due to the lack of empirical data on traffic flow including AVs.In this case study, we adopt hypothetical parameter values based on the expected capabilities and operating methods of AVs noted in the published literature and technical reports.The input distributions used in the case study are summarized in Table 2.

Parameter calibration
Here we describe in detail how the parameters of the merging conflict model are obtained from the available traffic database and assumptions (please refer to the notation in Table 2 as a summary of model parameters).

Mainline gap.
The distribution of mainline gap size is fitted to the time headway data collected on the road section upstream of the merging area in the rightmost lane on the main road (yellow-shaded area in Fig. 8).The data with a headway value of 0 or 9999.99 are removed (0 represents no preceding vehicle, and 9999.99 indicates that the vehicle speed is zero).With a total of 21045 records, a Burr distribution with an expectation of 2.94 s and a variance of 4.14 (95 % confidence interval: 1.07 s -7.45 s) is fitted.As a parameter reflecting the traffic conditions, the same distribution of mainline gap size is used for NVs and AVs.

Initial speed of the RMV. The distribution of RMV initial speed
for NVs is fitted to the vehicle speed data collected on the ramp (blueshaded area in Fig. 8).The data with a speed value of 0 are removed.With a total of 988 data records, we fit a normal distribution with a mean of 36.50 km/h and an approximate range of 6.20 km/h to 67.28 km/h (95 % confidence level) for NVs.A deterministic value equals the mean of NV speed is used as the RMV initial speed for AVs, because it is expected that the variation in vehicle speed will be substantially reduced by AVs' capabilities of precise speed control (Krause et al., 2017).

Ramp remaining distance/ ramp cruising distance. The ramp cruising distance (S rcd
) is defined as the length of the road section between the DP and the MP, on which the RMV adjust its trajectory to meet the chosen target gap.In this case study, we assume that the DP is the gore point at which the mainline and the on-ramp connect.As most ramp vehicles recorded in the dataset merge at a position very close to the end of the acceleration lane, there is no suitable distribution form for the ramp cruising distance.Thus, we use the ramp remaining distance (S rd ) for fitting instead.As shown in Fig. 9, the remaining distance is defined as the distance between the MP and the end of the acceleration lane, and the sum of the ramp cruising distance and the remaining distance equals the length of the acceleration lane, which is approximately 100 m in this study area, namely With the NGSIM-I80 data, the actual merging points of the ramp vehicles are acquired by searching for the positions at which the vehicles' lane ID information changes from 7 (i.e. the acceleration lane) to 6 (i.e. the rightmost lane on the main road).With 207 recorded merging positions (a record for each merging vehicle) in the data, a generalized extreme value distribution with an expectation of 10.87 m and a 95 % confidence interval from 0.97 m to 32.01 m is fitted for the remaining distance of NVs.For AVs, we assume that the merging may occur at any points along the acceleration lane (except for the first and last 5 m for safety constraints) at equal chance.Thus, a uniform distribution with a range from 5 m to 95 m is assumed for the remaining distance of AVs.

Acceptable gap of the RMV.
The acceptable gap is defined as the minimum gap that a vehicle can accept for merging.For NVs, this parameter is related to the human driver's personality, experience, mental and physical conditions, and many other factors.Thus, it is not directly observable in the vehicle trajectory data like NGSIM data.In this case study, we approximate the size of acceptable gap using the size of the gap that the RMV actually merges into.The actually-merged gap is determined as the MFV's time headway at the last time step before the RMV merges.We assume that the acceptable gap is approximately 60 % of the actually-merged gap.A varying coefficient may better describe the relationship between the actually-merged gap and the acceptable gap, however, we use a constant coefficient for simplification.With a coefficient of 0.6, the distribution of the actually-merged gaps observed in the simulation is most similar to that derived from the data (p-value of two-sample Kolmogorov-Smirnov test = 0.95).In addition, we exclude all data with a gap value larger than the 95 th percentile of the actuallymerged gap (12.72 s), as it is reasonable to consider that an RMV decides to merge into such a large gap simply because of the existence of the large gap instead of the conservativeness of the driver.With a total of  193 data records (data with a gap value of 0 or 9999.99 are also removed), an inverse gaussian distribution with an expectation of 2.78 s and a 95 % confidence interval from 1.11 s to 5.88 s are determined for the RMV acceptable gap of NVs.
For AVs, the acceptable gap should be a parameter related to the driving mode of AVs.As a 30 %-40 % -30 % share across the aggressive, normal, and conservative AV driving modes is assumed, we correspondingly divide the acceptable gaps of human drivers into three groups according to the same ratio of 30 %-40 % -30 % to represent the acceptable gaps of the aggressive, normal, and conservative human driver groups, respectively.Then, we use the 85 th percentile of each group (i.e.1.90 s, 2.95 s, and 5.20 s) as the acceptable gap of AVs in the corresponding driving mode.This assumption ensures that most AV passengers (85 %) will not feel that the AV behaves too aggressively at merging.

Critical headway for checking alternates and number of alternative gaps checked.
In the merging maneuver process, it is assumed that the RMV will check alternative gaps when the risk to merge into the first available gap is too high, and only take the risk when no alternative gap is found after checking a certain number of gaps.We consider that the critical headway is equivalent to a headway that 95 % human drivers are unwilling to accept for car-following.Thus, 0.88 s, a value corresponding to the 5 th percentile of the MFV desired headway distribution (discussed later), is used as the threshold for checking alternative gaps.Furthermore, it is assumed that the human drivers will only check the next immediate gap, while the AVs can check three gaps in the following traffic stream thanks to the comprehensive information on traffic conditions provided by the vehicle communication technologies.

Initial speed of the MFV.
The distribution of the MFV initial speed for NVs is fitted to the vehicle speed data collected on the road section upstream of the merging area in the rightmost lane on the main road (yellow-shaded area in Fig. 8).Note that two peaks are observed in the histogram of mainline vehicle speed data (Fig. 10).This is because the data are collected in the build-up period of traffic congestion, and data reflecting both congested and non-congested traffic states co-exist in the dataset.As it is not possible to describe the congested and noncongested traffic flow with a single set of parameters, we remove data collected in the congested state, namely data with a speed value less than 22 km/h.The speed of 22 km/h is used as the threshold because it is the point of the lowest frequency between the two peaks.
With a total of 19,942 data records, a lognormal distribution with an expectation of 35.5 km/h and a 95 % confidence interval of 21.83 km/h to 54.62 km/h is fitted for NVs.Similar to the RMV initial speed for AVs, a deterministic value equals the expectation of NV speed is used as the MFV initial speed for AVs.

Desired headway of the MFV.
The MFV desired headway is defined as the minimum distance that an MFV tends to keep from the RMV merging in front of it.Similar to the RMV acceptable gap, this parameter reflects the MFV's aggressiveness and is not directly measurable from the trajectory data.To estimate the desired headway of NVs, we randomly selected 300 pairs of leading and following vehicles on the road section downstream of the merging area (the green-shaded area in Fig. 8) and record their average headway in the process of carfollowing.The selected leading-following vehicle pairs must satisfy two conditions: (1) the following relationship should last at least 10 s; (2) the following vehicle does not experience stop-and-go during the following process.By assuming that the desired headway is approximately 60 % of the observed car-following headway (the coefficient of 0.6 gives the best fit of actually-merged gaps with a two-sample Kolmogorov-Smirnov test p-value of 0.95), a generalized extreme value distribution with an expectation of 1.39 s and a 95 % confidence interval from 0.68 s to 2.35 s is fitted for the MFV desired headway for NVs.
For AVs, the 85 th percentiles of the desired headway for the aggressive drivers, the normal drivers, and the conservative drivers (i.e.1.10 s, 1.50 s, and 2.15 s) are used as the desired headway of AVs in the corresponding driving modes.This ensures that the AV behaviors are not too aggressive for 85 % of the AV passengers.The possibility of each value follows the share of AVs in the corresponding driving mode (30 %-40 %-30 %).3.3.1.9.Reaction time of the MFV.The reaction time of NVs reflects the experience and attention of the human drivers and is widely studied in the literature.Since it is impossible to obtain the case-specific reaction time from the trajectory data, we refer to the review of AASHTO ( 2018) and set up a lognormal distribution with an expectation of 1.65 s and an approximate range of 0.75 s to 3.18 s (95 % confidence level) for human drivers' reaction time.This distribution is in line with findings in the literature on brake reaction time (Johansson and Rumar, 1971;Taoka, 1989).
It is assumed that AVs need much less time to react compared to NVs when the vehicle control systems work properly.However, there could be a very minor probability that the AV braking system fails to react due to malfunctions or potential cyberattacks (Koopman and Wagner, 2017).The reaction time of AVs is infinite in this case.We assume a constant reaction time of 1 s for AVs with a 0.01 % possibility of failed reaction based on the published literature and AV safety reports (Bhavsar et al., 2017;Medford, 2018).

Other parameters.
As suggested by AASHTO (2018), the ramp speed limit is set to 80 km/h.The maximum acceleration of the RMV and the maximum deceleration of the MFV are 3.4 m/s 2 .These correspond to the maximum acceleration and deceleration rates observed in the merging area in the NGSIM-I80 dataset.

Comparison of simulation outputs and NSGIM-I80 observations
While the empirical data from the NGSIM traffic study served to calibrate the input distributions of the merging conflict model, the validity of the calibrated model should be explored.This validation could be achieved either by comparing the CMH results against the actual road crash data, or by simulating other ramp-merge segments as the proxies for validation.Due to the limited access to the actual crash data and the traffic records which can be used to extract the CMH values, the validation process in this study is focused on evaluating how the results obtained from the proposed merging conflict model compare with the actual CMH value observed in the available traffic dataset.
Fig. 11 compares the Monte-Carlo simulation results of the NV100 scenario to the NGSIM-I80 data observations in terms of two indicators: the size of the actually-merged gap and the CMH value.Fig. 11a shows that, with the input distributions in Table 2, the Monte-Carlo process successfully reproduces the distribution of the actually-merged gap observed in the NGSIM-I80 data (p-value of the two-sample Kolmogorov-Smirnov test = 0.95), suggesting that the proposed model can well reflect the actual merging process.The curves of the data and the simulation results highly coincident with each other, supporting the validity of the fitted probabilistic distributions.
As shown in Fig. 11b, the simulation results tend to overestimate the value of CMH in the area with relatively small CMH (CMH<2 s), resulting in a p-value of 0.01 of the two-sample Kolmogorov-Smirnov test.This is because we assume that the MFV evasive action is fully completed when estimating CMH with the merging conflict model, but in reality, the evasive action may still be in progress at the time when the RMV passes the merging point.Thus, the estimated CMH value might be larger than the observed values in the cases where the MFV evasive action occurs.The difference is more obvious in the low CMH area (CMH<2 s), because the evasive action usually occurs when the headway is small, thus it is more frequently present in the cases with lower CMH values.Although the simulation results are somewhat optimistic in predicting critical merging events, the cumulative distribution produced by the simulation has an overall shape and range very similar to the distribution derived from the data, especially in the area with larger CMH values (for CMH>2 s, the null assumption that the two distributions are not statistically different is accepted at the 5% significance level with a p-value of the two-sample Kolmogorov-Smirnov test of 0.15).This implies that the simulation results are capable of providing the reliable insights in the safety performance of the real traffic conditions.3a), and the results of the two-sample Kolmogorov-Smirnov tests show that the distributions under different AV penetration rates are statistically different from each other (Table 3b).The greater the difference in AV market penetration rate, the more significant the difference in the CMH distribution, implying that the AVs are expected to have more and more substantial influences as their share in the traffic flow increases.

Safety performance of AVs
Based on the probabilistic distributions of the CMH index given in Fig. 12, there are several result points that should be discussed which represent sudden changes in CMH values.As shown in Fig. 12, the scenario with no AV presence in the traffic flow presents a smoothly distributed CMH value.However, in the AV-present scenarios, ranging from 20 % to 100 % of AVs in the traffic flow, the cumulative probabilities increase suddenly at the CMH values of 1.1 s, 1.5 s, and 2.15 s.These values exactly correspond to the defined discrete values of the MFV desired headway for AVs (please see Table 2).This finding is reasonable, as in most cases where the autonomous MFV takes an evasive action, the final distance between the RMV and the MFV (i.e.CMH) will be expanded to a pre-defined and satisfactory level, namely to the size equal to the MFV desired headway.It reflects that the behaviors of AVs, with less variation in the driving mode, are expected to be more predictable than that of the human-driven NVs.However, this finding also reflects to some extent the limitation of this and other existing AV road safety studies, as the more reliable references to AV behaviors in traffic are still very limited.More testing studies on AV reactions in various conflicting situations are required to derive more precise values of parameters describing the AV driving behaviors.
By setting appropriate thresholds, CMH can be used to identify the occurrence of critical merging events, such as near-crashes and conflicts.In order to define these thresholds, we refer to the critical PET values reported in the literature (Tang and Kuwahara, 2011;Paul and Ghosh, 2019;Qi et al., 2020).The use of reference values from another surrogate safety measure is in this case permitted, as CMH and PET represent the same idea based on the occupancy of a conflict zone (for PET) or a cross-section (for CMH).Note that theoretically, the value of CMH should be slightly larger than the value of PET in any individual cases, because PET considers a conflict zone with a length, while CMH only considers a cross-section where conflicts start (without a length).Thus, the value of CMH should be about equal to the value of PET plus the travel time in the conflict zone.Therefore, we adopt the upper level of the PET thresholds reported in the literature and set the CMH thresholds for near-crashes and conflicts to 1 s and 2 s, respectively (black dashed lines in Fig. 12).
Table 4a reports the frequencies and probabilities of near-crashes and conflicts under various AV penetration rates.It is obvious that the application of AVs substantially reduces the probability of critical merging events.Approximately 31 % of near-crashes is avoided when the AV penetration rate is as low as 20 %.In the AV100 scenario, the *Due to the limited ability of Shapiro-Wilk test to process large sample size, we randomly draw 5000 variables from the 50,000 variables of a study scenario for the Shapiro-Wilk test (defined as a trial).For each study scenario, we test five such trials of 5000 variables and report the average p-values in Table 3a.*The average values in this table are estimated from a total of 5 rounds of simulation.One round of simulation refers to simulating the merging process for 50,000 times for each study scenario.Results reported in the other parts of this paper (e.g.Fig. 12 and Table 5) are based on the results from the first simulation round.
probability of near-crashes is reduced to zero, namely almost no accident is expected to happen with a full AV penetration.In addition, the proportion of conflicts also steadily decreases as the AV penetration rate increases.Overall, the probability of critical merging events (nearcrashes and conflicts) is reduced by 13.74 percentage points when replacing all NVs with AVs.
The evasive braking rate of the MFV can reflect the severity of the critical merging events.Even though a large CMH is achieved in the end, the situation should be considered as severe and undesired if the MFV has to brake hard in the evasive action.Table 4b shows the average values of the MFV evasive braking rate.The average braking rate goes down as the penetration rate of AVs increases, implying that AVs have positive effects on smoothing the evasive behaviors in the merge segments and reducing the severity of the critical events.

Cause analysis of near-crashes
In a total of 1549 near-crashes reported in the first simulation round, 1385 near-crashes (about 90 %) involve only NVs, 163 of them are between a NV and an AV, and only 1 near-crash involves only AVs.As at least one NV exists in most near-crashes, replacing NVs with AVs can substantially reduce the risk of crash.
Based on the case-by-case analysis of the simulated merging processes, all near-crashes involving NVs are caused by the aggressiveness of the human drivers, who accept a very small merging gap (as the driver of the RMV) or car-following headway (as the driver of the MFV).In the results, there is no conflict caused by the late reaction of the human driver in the MFV.This is because, given the current assumption on mainline awareness time (12.1 s -12.9 s), the drivers are able to complete the evasive action even if they react late.The only near-crash between two AVs is caused by the braking failure of the MFV, following the RMV's decision to merge with a risky initial headway.In other cases, the AVs are able to maintain a CMH at least equal to the desired headway in the aggressive mode (1.1 s), and thus very severe conflicts are avoided.

Sensitivity analysis on relevant parameters
Sensitivity analysis on six model parameters related to AV driving behaviors is conducted for the AV100 scenario to provide reference for the AV operational design.Other parameters are not included in the analysis, because they are either dependent on the traffic conditions (e. g. mainline gap size, initial speed, ramp cruising distance) or restricted by the vehicle dynamic capabilities and roadway design (e.g.speed limit, maximum acceleration and deceleration).Results of the sensitivity analysis are shown in Table 5.The table presents the average values of the CMH (avg.CMH) and the evasive braking rate (avg.brake) in each case.
The value of CMH is the most sensitive to the acceptable gap of the RMV (Pearson correlation = 0.9984).The average value of CMH reduces from 3.39 s to 3.01 s when the acceptable gap is reduced by 20 %, and it increases to 3.85 s with a 20 % increase in the acceptable gap.Other factors that notably influence the average CMH value include the MFV desired headway (Pearson correlation = 0.9738), the critical headway for checking alternative gaps (Pearson correlation = 0.9955), and the number of alternative gaps checked (Pearson correlation = 0.8610).
The mainline awareness distance and the MFV reaction time are not relevant to CMH.This is because, the current parameter values can already ensure that the MFV completes the evasive action and maintains a desired distance from the RMV in time.Thus, the increase and decrease in the parameter values will not notably change the average value of CMH.However, the average evasive braking rate is sensitive to the change in the mainline awareness distance (Pearson correlation = -0.8229)and the MFV reaction time (Pearson correlation = 0.9664), as the vehicle can brake more gently with a longer awareness distance and a faster reaction.
Table 5b shows the number of near-crashes under various assumptions on the AV brake failure rate.A near-crash can be stably observed in the simulation when the failure rate rises to 0.04 %, and there are two near-crashes with a failure rate higher than 0.09 %.All simulated nearcrashes between AVs are caused by the MFV's brake failure in the evasive action (i.e.infinite reaction time).This implies that it is very important to ensure that the AV brake failure rate is kept within an acceptable range.

Limitation and future work
This study has some limitations.As merging accidents are only occasionally observed in reality, it is difficult to collect comprehensive and accurate data of actual merging accidents without long-term observation or the help of local traffic authorities.Due to our limited access to the empirical accident data, the efficiency of the proposed CMH index is only discussed from a theoretical perspective in this paper, while a more comprehensive data-driven validation is a part of the future research plan.In the future, it is recommended to check the correlation between the number of merging conflicts estimated by the CMH index and the actual number of accidents observed in the field, when proper empirical data are available.A possible comparison procedure is suggested in Fig. 13.The CMH index can be derived from vehicle trajectories collected from field investigations or well-calibrated simulation studies, and the correlation shall be tested quantitatively under various circumstances (e.g., at different sites or times of day).Further, the performance of the CMH index shall be benchmarked against the prevailing safety surrogate measures, such as TTC and PET, to assess the superiority of CMH in reflecting ramp merging safety.This can be done by comparing the correlations between the number of field-observed merging accidents and the number of merging conflicts estimated by different safety indexes.
In addition, assumptions and policy recommendations are widely used for the description and modeling of AVs in this paper, due to the absence of real data on the AV behaviors.This may introduce certain bias into the results.This deficiency should be covered in the future as more and more results of AV road test become available.In this regard, the AV parameters used in the case study should only be considered as a baseline for the application of the methodology, and it is encouraged to calibrate the AV parameters in a similar way to the calibration of the NV parameters, when proper AV data are available.

Conclusion
This paper proposes a method to capture and assess the risk of critical events at freeway on-ramp merging with a consideration of AV presence in the traffic flow.A new conflict index that is primarily designed for the lateral merging conflicts, called Conflict Merging Headway (CMH), is proposed in theory, and a merging conflict model is developed to estimate the value of CMH by considering the interactions between an RMV and an MFV in various situations.Real-world uncertainties and variations are included in the safety investigation by using data-driven probabilistic distributions as model inputs, and Monte-Carlo simulations are conducted to estimate the probability of critical merging events under various AV penetration rates.The developed safety investigation approach, incorporating merging-specific traffic conflict techniques and probabilistic risk assessment, is the first contribution of this paper.This approach can be transferred to investigate traffic safety in other lanechanging cases, such as overtaking, merging into a platoon, and merging at lane reduction.
According to the case study results, the introduction of AVs will have a positive effect on the overall safety performance of the traffic flow.It is found that most near-crashes at on-ramp merging are caused by the high aggressiveness of the human drivers, which can be substantially eliminated by the introduction of AVs.With the presence of AVs, the probability of critical merging events is remarkably reduced, even at a relatively low penetration rate; and the reduction in the merging risk becomes more remarkable as the AV penetration rate increases.In addition, the average evasive braking rate of the MFV turns lower with a larger AV share in the traffic flow, indicating a reduction in conflict severity and an improvement in passenger comfort.The revelation of the potential safety impacts of AVs is the second contribution of this paper.
Sensitivity analysis on the essential parameters related to AV driving behaviors shows that the acceptable gap of the RMV is a major contributing factor in the crash/conflict outcome.Other factors, such as the MFV desired headway, the critical gap for checking alternative gaps, and the number of alternative gaps checked, can also affect the safety performance of AVs to varying degrees.Therefore, when designing the operational behaviors of AVs, it is important to determine appropriate values for these influential parameters by jointly considering operational efficiency and safety.Moreover, it is found in the sensitivity analysis that the number of near-crashes between AVs is closely related to the braking failure rate of the MFV, indicating that the proper functioning of the autonomous driving systems must be sufficiently ensured.The potential to provide implications on the future development of AVs is another contribution of this study.
The current study has some limitations.The superiority of the proposed CMH index stays at the theoretical level in this paper.In the future, the efficiency of CMH should be further investigated and benchmarked with the prevailing safety surrogate measures, preferably with empirical data on actual merging accidents observed in the field.Further, due to the absence of empirical data on AV driving behaviors, the setting of AV parameters primarily employs assumptions and policy recommendations.As a result, these parameter values should only act as a reference for the application of the methodology and be subject to adaptions when being applied in other study cases (e.g.different locations/ time periods), as the conditions of traffic operation and data availability may vary from case to case.

Fig. 3 .
Fig. 3. Gap selection process of the ramp merging vehicle.

Fig. 4 .
Fig. 4. The desired position and the earliest-achievable position of the ramp merging vehicle (RMV) within the target gap.

Fig. 12
Fig. 12 shows the cumulative probabilistic distribution of CMH under different AV penetration rates.The results of Shapiro-Wilk tests reject the normality of the CMH distributions (Table3a), and the results of the two-sample Kolmogorov-Smirnov tests show that the distributions under different AV penetration rates are statistically different from each other (Table3b).The greater the difference in AV market penetration rate, the more significant the difference in the CMH distribution, implying that the AVs are expected to have more and more substantial influences as their share in the traffic flow increases.Based on the probabilistic distributions of the CMH index given in Fig.12, there are several result points that should be discussed which represent sudden changes in CMH values.As shown in Fig.12, the scenario with no AV presence in the traffic flow presents a smoothly distributed CMH value.However, in the AV-present scenarios, ranging from 20 % to 100 % of AVs in the traffic flow, the cumulative probabilities increase suddenly at the CMH values of 1.1 s, 1.5 s, and 2.15 s.These values exactly correspond to the defined discrete values of the MFV desired headway for AVs (please see Table2).This finding is reasonable, as in most cases where the autonomous MFV takes an evasive action, the final distance between the RMV and the MFV (i.e.

Table 2
Input of the merging conflict model.

Table 4
Safety impact analysis.

Table 5
Sensitivity analysis results.