Optimal Joint Power and Rate Adaptation for Awareness and Congestion Control in Vehicular Networks

To support inter-vehicular applications, vehicles broadcast beacons with information about their state. Congestion may occur when the load on the channel due to beaconing can prevent the transmission of other types of messages. In this paper, we propose a distributed algorithm for optimal joint adaptation of transmit power and beaconing rate for congestion and awareness control. Our approach is based on a network utility formulation of the congestion control problem, which allows us to induce a desired fairness notion and set different priorities for vehicles. We formulate the general problem but, since it is not convex, we assume Rayleigh fading and derive an algorithm, called PRAIOS, that solves the optimization problem in a decentralized way with convergence guarantees. Our results, validated with realistic simulations in both static and dynamic scenarios and compared with other proposals, show that PRAIOS quickly converges to close to optimal allocations, while keeping the maximum beaconing load at the desired level. They also show that it can control the load when the fading is not Rayleigh. Applications can dynamically set their requirements as constraints, that are enforced by the algorithm while complying with the maximum load, which allows seamless integration of operational requirements into the control framework.


I. INTRODUCTION
I NTELLIGENT Transportation Systems (ITS) are being built upon the capabilities of connected vehicles, which support the use of innovative applications in traffic safety, traffic control, cooperative driving and other advanced services. Communications among vehicles are subject to severe or moderate fading effects [1], which results in a dynamic environment with short-life connections and adverse propagation conditions. American and European standards have allocated several channels at 5.9 GHz for vehicular communications and have adopted IEEE 802.11p as physical and medium access control layers [2], [3]. To support inter-vehicular applications, vehicles use a control channel to broadcast information about their state, including their position, speed, heading, or acceleration, among other data [4]. This information is encapsulated in beacon messages, which are transmitted periodically at a fixed or variable beaconing rate, what is called Cooperative Awareness Service (CAS) in the ETSI standards [4].
In addition, the control channel is mainly used to broadcast event-driven messages, such as emergency messages when a dangerous situation is detected. Since these are high priority messages, it is therefore necessary to ensure the availability of the control channel for them. However, the aggregated load on the control channel due to beaconing may degrade the performance of CAS in general and even prevent the transmission of emergency messages, what is called channel congestion due to beaconing activity. To prevent this situation, ETSI has specified a framework for decentralized congestion control (DCC) in the control channel [5], which supports dynamic adaptation of several transmission parameters such as transmit power, beaconing rate or message datarate [6]. Therefore, the goal of DCC is to limit the channel bandwidth used by beacons to ensure that the remaining capacity is available to event-based messages. However, beaconing must also provide the "level of awareness" required by the applications working on top of the service. That is, awareness control should be used to adjust the aforementioned communication parameters in order to fulfill the requirements of a particular application [7]. Both goals may conflict, since in general application reliability increases with high power and beaconing rates. Moreover, quality of service requirements are dynamical, context-dependent and particular of each vehicle. For example, the minimum beaconing rate and communication range for vehicles approaching an intersection may be quite different from those of vehicles under free-flow conditions in a highway. Since there are multiple parameters to control and potentially conflicting goals, it is clear that an integrated, flexible and dynamically configurable approach to congestion and awareness control is necessary. In this paper we propose such a mechanism based on a decentralized joint control of beaconing rate and transmit power.
Our proposal also allows to select a particular fairness notion and control it dynamically. In the vehicular context, fairness is specially important since it is related to the user safety. Since beacons are used to build and accurate estimate This work is licensed under a Creative Commons Attribution 4.0 License. For more information, see https://creativecommons.org/licenses/by/4.0/ of the surrounding road traffic state [7], it is necessary that all vehicles can effectively communicate its state, that is, they should be allocated similar resources, under the constraints imposed by the available capacity. But different formal notions of fairness can be used, which result in a trade-off between fairness and efficiency [8]: a more restrictive fairness notion usually implies a less efficient use of the shared resource.
To derive an algorithm with such features, we model the congestion control as a Network Utility Maximization (NUM), the formal approach that we used in previous papers, but adapting it to the current goal of controlling both rate and power and extending the scope in several ways as we discuss next. The underlying approach of NUM is just to derive an algorithm that solves a constrained convex optimization problem, where each vehicle is associated a utility function [9], and the optimization goal is to maximize or minimize the sum of the utilities. But NUM additionally uses the shape of the utility function to induce globally a certain notion of fairness. That is, by using a class of utility functions known as (α,w)fairness functions, the allocations will exhibit a particular type of fairness [10]. With those functions, the fairness parameter, α is used to select from range of fairness notions that go from proportional fairness (α = 1) to max-min fairness (α → ∞) [10], and the priority parameter, w, to assign different priorities. We have used this formal method in [11] to derive a beaconing rate control, but assumed a single common power for all the vehicles. Conversely, in [12] we derived a transmit power control assuming a fixed beaconing rate. In [13] we extended both models by considering the possibility of transmitting beacons with multiple powers simultaneously, but the transmit power was not actually controlled explicitly, that is, the only control variable managed by the algorithm was the beaconing rate, although the different available powers entered the constraints.
In this paper, we do propose a distributed algorithm for optimal joint control of transmit power and beaconing rate. That is, both transmit power and beaconing rate are actually controlled and their values are assigned by the algorithm. This proposal, hence, extends our previous work in several ways. First, let us note that it is not immediate to derive a joint power-rate control from the previous separate rate and power controls, because the controlled variables multiply each other and make the problem non-convex in general. Second, we here seek to maximize an awareness metric, discussed and defined later, which depends on both power and beaconing rate. To model the dependence on transmit power, we assume a single-slope path loss for attenuation and Nakagami-m for fading. Therefore, unlike our previous works, in which the utility functions only depended on the beaconing rate, in this paper the utility is the level of awareness a vehicle produces, considering a more realistic channel model as well as power and rate as decision variables. However, introducing such a general fading model also makes the problem non-convex in general. To overcome it, we then restrict ourselves here to the case of Rayleigh fading but show in our results that it is also able to control the load even with other fading conditions.
Our algorithm stands out from previous proposals in several features. First, joint control, in the sense that the output of the algorithm is the value to set for transmit power and beaconing rate, is not actually carried out in various previous works [14], [15], [16]. Instead, they adjust the value of only one of the variables in order to control the excess of channel capacity available after some particular application has set some minimum values. Second, in the capability of inducing a fairness notion and weighted priority, as well as the convergence guarantees shown here. Hence, in the paper we compare our algorithm with BFPC [17], a proposal that actually controls power and rate jointly; and the SAE J2945/1 standard [18], which controls separately rate and power in a heuristic way, and show how it outperforms them.
In the remainder of this paper we first review related works in section II. In section III, the problem is formulated as a NUM joint power and rate allocation problem. First we discuss the awareness metric we are interested in and the propagation model, then we provide a formal description of the problem and propose a particular algorithm to solve it. In section IV, it is validated and compared with other proposals in static scenarios and we show its behavior when the fading conditions are different from Rayleigh fading. We extend afterwards the comparison and evaluation to different dynamic scenarios and show how it can be configured by applications and assign different priorities. Finally, conclusions and future work are discussed in section V.

II. RELATED WORK
Previous approaches to DCC use separately beaconing rate [11], [19], [20] or transmit power [7], [21] and some consider combined power and rate control [14], [15], [16], [17], [18]. A recent survey [6] discusses in detail the most relevant proposals and most of the potential control variables, so we briefly discuss here some of them directly related to our work. We do not consider proposals related to vehicular communications based on cellular networks (C-V2X), since its MAC differs significantly from 802.11, although some of the mechanisms evaluated in this paper have been used for congestion control in C-V2X [22].
One of the algorithms suggested by the ETSI standards is LIMERIC [19], which adapts only beaconing rate with a linear control based on the measured channel busy rate (CBR) from the local neighbors. LIMERIC is shown to converge to a single fixed point, which assigns equally the bandwidth among all the vehicles that share the same congestion state, but only if assumed that all the vehicles are in range. For multihop scenarios it is combined with PULSAR [20] which requires CBR measurements from two-hop neighbors. Several pure transmit power controls are discussed in [7]. In [18] and [21] is used to adjust the communication range to keep the desired number of neighbors in range. In general, controlling only the power tends to result in oscillatory behavior, as discussed later in our results, but it has been shown to improve the performance of cooperative driving application when combined with synchronized communication slots [23].
Combined transmit power and rate adaptation has been used in [14], [15], and [16] mainly for awareness control, that is, to fulfill the quality of service requirements of particular applications, None of them control both transmission variables in a joint optimal way, but set them separately according to some heuristic. In [14] the beaconing rate is adjusted to keep the maximum position error under a certain value and then the transmit power adjusts the transmission range to keep the channel occupancy within some range. Both [16] and [15] have as main goal to control the inter-beacon reception time at some target distance and in both cases they use LIMERIC and PULSAR as an additional beaconing rate control to comply with the maximum channel load. In [16] the transmit power is first set to maximize the inter-beacon reception time and then the beaconing rate is adapted using PULSAR. And in [15] the desired inter-beacon reception time determines the transmit power and rate and if there is some channel capacity available the beaconing rate is increased via LIMERIC and PULSAR until the maximum channel load is reached. In comparison, in this paper we derive an algorithm for optimal joint control of both transmit power and beaconing rate. We compare our proposal to the SAE J2945 standard [18], which is used in the United States, and BFPC [17]. The former is an adaptation of the work in [14], discussed previously, which adapts the transmit power to keep the channel load within a certain range and sets the beaconing rate according to the measured density of surrounding vehicles. BFPC uses non-cooperative game theory to derive a distributed algorithm for joint power and rate control, which does no need to exchange any additional information with neighbors to work. Its main drawback is that it does not allow to configure a precise maximum range for the desired channel load but uses three parameters which have to be tuned to particular scenarios by trial.
An approach similar to ours here can be found in [24] where authors use a NUM joint rate and power control framework. There are still significant differences: first, the propagation model is abstracted by an indicator function, but the mapping of the channel model to the indicator function is not discussed. In addition, it turns the optimization problem into an integer programming one. In our case we explicitly include a propagation model in our maximization problem. Second, since their formulation is non-convex in general, they decompose the problem in rate and power subproblems and propose an iterative algorithm where rate or power are considered constant inputs to the other subproblem alternatively. The obtained solution is suboptimal. On the contrary, we provide an algorithm which results in an optimal solution to the joint problem, although focused on the particular convex case of Rayleigh fading. Third, transmit power is not included in the utility function unlike our formulation.
Since the goal of awareness control is to fulfill the requirements of a particular application [7], it is necessary to relate those needs to communication parameters. In [16] several possible awareness metrics which capture the application requirements are discussed in detail. In Section III we define such a metric, adapted from [16]. A number of proposals are designed around particular application requirements [14], [25]. In particular, keeping a certain tracking error [14], [25] is one of the metrics used by POSSAC [25] to set the beaconing rate, in addition to a target warning distance dependent on the vehicle movement status together with a control of the contention window to minimize the probability of packet collisions. Our proposal can be used to achieve the same goals in a flexible way. As discussed in Section IV, applications can dynamically set several parameters and use the priority parameter to assign more resources to particular vehicles. In fact, the state of the environment and road can be incorporated seamlessly into the framework control while meeting the channel load constraints, as we showed in [26], where we used the time-to-collision of vehicles to prioritize the beaconing rate in a NUM control. Since our algorithm here involves power and beaconing rate, more sophisticated environmental aware controls can be implemented seamlessly.
Finally, machine-learning methods have been applied to congestion control recently [6], [28]. Such methods are heuristic in nature but have the advantage that can be applied to problems in which traditional optimization methods are difficult to apply due to the non-convexity of the problem, such as those that involve control of data rate [27]. In particular, reinforcement learning (RL) has been applied to resource allocation in centralized networks [28], but fewer proposals apply RL in distributed environments, as we did in [29], where we used Q-learning to train agents to adapt power and rate for congestion control. Although such procedures work well, they do not provide flexibility for configuration, there are no guarantees about its optimality and they raise concerns about their applicability in scenarios different from the ones used to train. The model derived in this paper allows to compare the optimal allocation to the solutions provided by such methods.

III. JOINT POWER-RATE AWARENESS AND CONGESTION CONTROL IN VEHICULAR NETWORKS
Notation: In the remaining of the paper we use boldface letters (x) for random variables, lowercase letters with bars (x) for vectors, uppercase letters with bar (H ) for matrices and subscripts for the elements of a vector or matrix.
In this section we model the joint transmit power and beaconing congestion control problem as a convex optimization problem. We first discuss the propagation model and awareness metric we use. Afterwards we formally formulate the general problem which is not convex, so we transform it into convex form for Rayleigh fading and propose a distributed algorithm for its solution. ] beacon/sec. The goal of our algorithm is to find the p v and r v that maximize some utility function.

A. Propagation and Fading Model
We use the model described in [13] and [12]. We assume a single-slope path loss attenuation model and a Nakagami-m fading model. With this assumptions, the power received at a distance d from a transmitter is For a vehicle transmitting with power p, the scale parameter is set to μ = m p to get an average power of p. The fading intensity is given by the parameter m, a lower value implies more severe fading conditions.
With this model, the probability that the received power at a point at distance d from a transmitter is above the sensitivity of the receiver S, P r , is: where (m, x) is the upper incomplete gamma function. From now on, to simplify notation, we define where d i j is the distance between vehicle i and j . Note that K i j = K j i . Note also that when m = 1 we get Rayleigh fading and P r (

B. Awareness
Periodic broadcast of beacons with vehicle status information is the basic service upon which cooperative inter-vehicular applications are built. Even though the service is called "Cooperative Awareness Basic Service", the standard does not define precisely what is meant by awareness, apart from stating that "On reception of a CAM the receiving ITS-S becomes aware of the presence, type, and status of the originating ITS-S" [4].
Due to this lack of a clear specification of awareness, different definitions can be found in the literature [6], see for instance [16] for a discussion. Most of them define awareness in terms of either a certain Packet Delivery Ratio (PDR) or Inter-Beacon Reception Time (IRT), at a target distance, required by an application to ensure a given quality of service. But these metrics are not equivalent and do not generally imply each other, that is, a low IRT does not necessarily imply a high PDR. We consider the IRT a more suitable metric for the reliability of an application and so derive an expression for it. In the following discussion we assume that eq. (1) gives also the probability of successful reception of a package. This is the case when the noise and interference power is low enough so that the sensitivity can be used instead of the Signal-to-Noiseand-Interference Ratio, SNIR. In our context, the background noise is usually negligible and, when congestion control is working properly, the MAC is not saturated and so collisions are rare and interfering vehicles are relatively far away [21].
To provide reliability guarantees, an application usually requires that, at a certain target distance (d o ), a maximum IRT (T max ) is achieved with a given target probability P o , that is, Prob(IRT ≤ T max ) ≥ P o . Now, given a beaconing rate r and assuming that the probability of successful beacon reception is independent at each transmission, the number of lost beacons, l b , is geometrically distributed and the IRT is a r.v. IRT = (l b +1)/r . From this, the reliability in terms of IRT for a given transmit power p and beaconing rate r is given by Hence, eq. (2) relates power and beaconing rate with IRT and fixes the minimum power and beaconing rate required to guarantee a certain reliability. It may be a candidate as utility function to be maximized by each vehicle. However, no reliability is actually guaranteed unless it is used in the problem constraints. Furthermore, it is not convex for a general Nakagami model.
Our alternative then is, first, to let the application set the minimum acceptable values as constraints if necessary. That is, an application can use eq. (2) to transform its requirements into some p min v and r min v , and pass them to the algorithm when necessary. Otherwise the minima specified by the standard are used. With our algorithm, such particular requirements can be set dynamically and independently by each vehicle, and the allocation will be optimal as long as it is feasible, that is, the sum of the minimum rates sets by the vehicle does not exceed the channel capacity. And, second, we set as goal to minimize the average IRT, or equivalently, to maximize its inverse. Let us note that in that case, we are actually maximizing the beaconing rate weighted by the reception probability at the target distance, r P r (d o , p), what we call effective beaconing rate, which is also a reasonable measure of the level of awareness a vehicle generates.
As we said, although the PDR is often used as a metric of awareness, under the assumption of independence of errors, the obtained results are different as we will discuss in Sect. IV-A.

C. Problem Formulation
We have already discussed the propagation model and the awareness control goal. It remains to define the remaining goals: For congestion control we are interested in limiting the total rate of beacons received by each vehicle to a Maximum Beaconing Load (MBL), that is a maximum of C beacons/s. The MBL is often expressed in equivalent ways, in particular as a limit to the Channel Busy Time (CBT), which is the fraction of time that the channel is not idle. When expressed this way we will refer to the MBL as C C BT . The utility function to be maximized by each vehicle is the inverse of the average IRT, 1 E[IRT] = r P r (d o , p), as discussed in the previous section. But to control the fairness of the optimal allocation, we use α-fair utility functions U v as so that any optimal solutions of the problem are also (α, w)fair [10]. This way, any required fairness notion can be enforced by setting the α parameter, while the w v values can be used to achieve weighted fairness and assign priority to vehicles.
With all the previous definitions we can formulate the general joint power-rate optimization problem: The objective function (4a) maximizes the sum of the utilities as functions of the effective beaconing rate at the target distance.
Constraints (4b), ensure that the average beaconing load measured by a vehicle is below the MBL. To see this, consider that a Nakagami-m fading model a vehicle v receives a beacon from a neighbor i with a probability P r (d vi , p i ), and there is a probability of receiving beacons from distant neighbors and not receiving beacons from close ones. In that case, the channel is effectively not occupied since the received power is below the sensitivity due to fading. Assuming a binomial distribution with parameter p = P r (d, p) for the number of successfully received beacons and neglecting the changes of distance in vehicles during the measurement period (T m ), which is reasonable, since T m is usually in the order of hundreds of milliseconds, the average beaconing load on the channel locally measured by a vehicle v is given by i r i P r (d vi , p i ), which already includes its own generated beaconing load. For simplicity we assumed a common beacon size, but the following algorithm can accommodate any beacon size, even if different vehicles use different sizes. In that case, constraints (4b) have to be modified appropriately by multiplying the beaconing rates by the beacon size used by vehicles and changing the units of C. In practice it requires that the vehicles keep track of the size of beacons received from other vehicles.
Finally, constraints (4c) and (4d) keep the variables within the allowed ranges. As discussed before, the lower limits can be set by applications in order to enforce some quality of service requirements, via eq. (2). They can be dynamically set by each vehicle independently if necessary. Or they may be set to the lower limit determined by the standards.
However, problem G − PR (4a) is not convex in general, only in certain cases, as for instance, Rayleigh fading. In the remaining of the paper we therefore focus only on the Rayleigh case, since it describes well a wide range of scenarios [30]. In addition, in Section IV-B we evaluate and discuss the results when this assumption is not valid. We will see that the algorithm is still very effective in controlling the load in these cases.

D. Rayleigh Fading
In this section we formulate the optimization problem when Rayleigh fading is assumed. In that case problem G − PR (4a) can be transformed to convex problem by a change of variables as follows. First, we make the change of variable, h v = p −1 v and set m = 1 in (1) for Rayleigh fading, so that the probability of successful reception becomes, P r = ex p(−K i j h). The set of constraints (4b) are not convex yet, but if we additionally make the change of variable y v = ln(r v ), we obtain convex constraints. To induce the desired fairness notion we will use as utility functions the ones in (3) so that any rate allocation to the vehicles is α-fair if and only if, it is the optimum solution of (5). But taking into account that the objective function is concave as long as α > 1, as discussed in the Appendix.
With the above transformations the convex form of the problem of joint power-rate optimization for Rayleigh fading is: Notice that, only for K o but not for the constraints (5b), we may substitute the sensitivity S by a decoding threshold D to reflect the more realistic case of requiring a higher power to successfully decode a packet.

E. Dual Decomposition
In order to find a decentralized algorithm to solve problem R − PR (5) we use a dual decomposition, see [31] for a general overview of dual methods.
To use the standard formulation in optimization, we first convert problem (5) to a minimization problem by changing the sign of sum in (5a). Then we form the Lagrangian function L of (5a) relaxing the constraints (5b): where λ v ≥ 0 are the Lagrange multipliers associated with the relaxed constraints. The Lagrange dual is the minimum value of the Lagrangian function over the domain of the variables. That is, given a set of non-negative multipliersλ, And the dual problem is: Since the objective function in (5a) is concave, for α > 1, and the Slater condition holds, it has the strong duality property and the Karush-Kuhn-Tucker (KKT) conditions characterize its optimum solution [32]. Then, when the optimal multipliersλ * have been found, at least one of the associated ratesȳ * (λ * ) and powersh * (λ * ) are the optimal solution of the original problem (5).
Solving the power-rate allocation problem with the dual method then requires using a gradient descent algorithm to iteratively find the dual optimal multipliersλ * , and obtain the corresponding optimum powerp * (λ * ) and rater * (λ * ) allocations from eq. (7). In the following subsection we develop this procedure: At each iteration, vehicles broadcast their multiplier λ v , receive multipliers from neighbors and use them as input to the optimization problem (7). The latter has no analytical solution, but can be solved independently by each vehicle with a gradient algorithm using local information.
Let us clarify that, to solve problem (7), one should actually use global information, since the sum in the relaxed constraints in eq. (6) extends to all the vehicles. This issue can be formally corrected just by limiting the sum in the constraints (5b) to only the neighbors of a vehicle. All the subsequent derivations remain equal just by limiting the corresponding sum to the set of neighbors and the proofs in the Appendix require the introduction of a neighbor matrix. But, since from a practical point of view this fact is not relevant, as we discuss in the following section and show in the Results, we prefer to keep the problem in its current simpler formulation.

F. Distributed Algorithm
In this section, we propose PRAIOS (Power-Rate awareness and congestion control for inter-vehicular communications), an algorithm that solves problem (8) in a decentralized way, without the need of any central coordinated infrastructure.
At each iteration, the algorithm first compute a distributed gradient descent: vehicles receive the multipliers from neighbors and compute the gradient of (7) to update their own multiplier; Afterwards, they pass all the received multipliers to a function that solves the local problem of minimizing the Lagrangian function eq. (6) and update their rate an power. Since there is no analytical solution to the latter problem we propose to use a gradient projection algorithm that provides a quick convergence to the optimal solution and discuss later other practical alternatives.

Algorithm 1 -Power-Rate Awareness and Congestion Control for Inter-Vehicular Communications (PRAIOS)
At k = 0, set initial vehicle multiplier λ 0 v , inverse of power h 0 v and logarithmic rate y 0 v , ∀v Then, at each time k: Step 1. Each vehicle v receives the multipliers from neighbor vehicles λ i , ∀i .
Step 2. Each vehicle updates its own multiplier λ k+1 v as: Step 3. Each vehicle updates y k+1 v and h k+1 v with the output of Algorithm (2): The main procedure is described in Algorithm 1. The algorithm to minimize the Lagrangian function is described in Algorithm 2. In both cases the gradient descent is projected on the constrain set, that is, [x] + X = arg min z∈X ||z − x|| 2 denotes the orthogonal projection with respect to the Euclidean norm of a vector onto the convex set X. But notice that, since in both algorithms the set X is made of box-constraints, that projection is inmediate.
until ||∇ L(y, h)|| = 0 8: return y j +1 , h j +1 9: end procedure Next we clarify the algorithm steps and discuss other practical aspects: • To update the multiplier in Step 2 of Algorithm 1, we use the fact [33, pp. 423] that, given a set of multipliersλ, a subgradient G ∈ ∂g, of the dual function g evaluated atλ is given by The subgradient is just the difference between the measured load by a vehicle and the MBL constraint. Hence, as a practical alternative, we use in our implementation the CBT measured by a vehicle, that is, where T b is the beacon duration. • The Lagrange multiplier of a vehicle, λ v , represents the congestion measured by that vehicle. • The LagrangianMinimization function executes a gradient-descent algorithm to minimize the Lagrangian function in eq. (7). At each step, and given the collected set of multipliersλ, the gradient ∇ L(y, h) is • The probabilities of reception from distant enough vehicles are essentially zero, P r = e −K iv h v ≈ 0. Therefore, their beacons are not received in practice and their multipliers are not known. But, even if they were known, due to the extremely low value of the probability of reception, they would not contribute appreciably to the sums in eqs. (11) and (12). So, as mentioned in the previous section, we have formally kept the global formulation but the sums in the LGP function only involves the vehicles for which a beacon has been received during a measurement period. In any case, in Section IV our results confirm that this is the case and the algorithm is robust. • An alternative to solve problem (7), is to only compute the line 5 of Algorithm 2 and then set y j +1 to the value given by eq. (19) in Appendix B, at each iteration. This is slightly faster and is what we do in our implementation.
• Our proposal requires that vehicles broadcast their current beaconing rate and transmit power and the multiplier: three real numbers. They would be piggybacked in a beacon, which would add 12 bytes to its size, a small overhead. • The parameters γ and are used to tune the speed of convergence of the gradient descent. They should be as high as possible to increase speed, but below the bound derived in Appendix B. The bound is not tight, so in practice they can be higher and selected by by experimentation, as done in the next section. Since the algorithm converges, any initial λ 0 v is valid. PRAIOS converges in general to the proximity of the optimal value, and, in some cases, to the optimal value, depending on the strict concavity of the objective function, which in turn depends on the value of the parameters. The convergence of the algorithm is shown and discussed in the Appendix.

IV. RESULTS
In this section we discuss the results of our proposal and provide a comparison with two other joint rate-power control algorithms, BFPC [17] and the SAE J2945/1 standard [18]. The simulations have been implemented with the OMNET++ 6.0 simulator [34], and the INET 4.3.7 library [35] which implements the IEEE 802.11p standard. This library also implements a realistic propagation and interference model for computing the Signal to Interference-plus-Noise Ratio (SINR) and determining the packet reception probabilities, considering also capture effect. We set a data rate of 6 Mbps and assume an equal beacon size of 500 bytes. This results in a total message size of 537 bytes, including MAC and physical headers. Because the physical-layer trailer duration depends on the payload size via the padding, the resulting packet duration is 752 μs, according to [2], and thus, the total channel capacity is 1329.8 beacons per second. Finally, we are going to focus on the α = 2 case. Although PRAIOS allows to use different fairness parameters, the bound for the gradient step, γ , derived in Appendix B depends exponentially on the fairness parameter, which means that using a high value is detrimental to the convergence speed. In the following results we show that PRAIOS converges quickly with α = 2 but that might no be the case for higher values. In addition, we prefer not clutter the results with additional figures. So, we leave as future work a more detailed study on the influence of the fairness parameter and the difference in the outcomes it produces.
The simulation parameters that are common to the simulations studies in this and the following sections are summarized in Table I. To encourage reproducibility, the implementation of the algorithms and the rest of the code used for the paper are freely available in our public repository 1 and any other parameter value can be checked there.

A. Validation
In this section we test the validity of our algorithm and assumptions, in a static scenario where vehicles do not move 1 https://gitlab.com/esteban.egea/praios  For CBFP we have tried several combinations of its parameters and we have finally set the parameters to w = 650, u = 20, c = 1. Simulations are run for 100 s. CBT measurements and algorithm steps are executed every T m = 100 ms, so 1000 steps of the algorithms are computed. In addition to the algorithms, the exact optimal values have been computed with the CVX numerical solver in Python, CVXPY [36]. All simulations have been replicated 5 times and 95% confidence intervals are computed and shown as shaded bands in the plots.
In Fig. 1(a) we show the per vehicle allocated rate and power respectively. In Fig. 1(a) we also plot the effective beaconing rate at d o per vehicle, that is r v P r (d o , p v ), which is the desired awareness, that is, our utility. As can be seen, the shapes of the rate and power allocations from PRAIOS differ from the optimal ones computed by CVX, but the effective beaconing rate of PRAIOS is very close to the optimal one from CVX. It means that the particular combination of allocated power and rate from PRAIOS is able to achieve a very similar total utility. In fact, if we compute the value of the utility function of the PRAIOS .89, the ratio of this value to the exact optimal one computed by CVX is just 1.0065. As an additional check, the bound M 2 G γ /2 for the utility value computed in Appendix B for this case is 2.037 and the difference of the utility values is 0.32, which is well within the bound. BFPC allocates very high rates but reduces considerably the power, whereas SAE allocates lower powers and rates than PRAIOS. The effective rate for BFPC is higher than PRAIOS but the MBL constraint is not met by BFPC as seen in Fig. 1(b), whereas SAE results in a CBT 20% lower than the target MBL, so channel is underutilized, and the effective rate is also lower than PRAIOS. In fact, if we examine the average CBT in Fig. 1(b) we can see one of the problems of both BFCP and SAE: that the MBL and other constraints cannot be precisely set. SAE allows to set a range of values for the MBL and it actually keeps the CBT around 0.32, that is, inside the allowed range. With BFPC the problem is more acute, since different parameter combinations result in different average CBT and there is no clear indication of how to select them [17]. For instance, if we set c = 3 keeping the rest of parameters equal we obtain an average CBT of 0.3, similar to SAE. We show here a combination that only exceeds 10% the MBL. In comparison, PRAIOS allows to set a precise MBL constraint, which is met, as shown in Fig. 1(b). Actually these results show that PRAIOS provide the best effective beaconing rate that is able to meet the MBL constraint, as designed.
If we look at the average PDR at 250 m shown in Fig. 1(b), PRAIOS clearly outperforms the other proposals. The allocated rates by all the algorithms are quite stable as indicated by the indistinguishable confidence interval bands in Fig. 1, while there is more variability in the allocated power per replication in general. This explains in part the variability in the PDR figure. But BFPC shows a very high variability of PDR, not corresponding to the moderate variability of its allocated power. In fact, it may seem contradictory that the effective rate of BFPC is higher while its PDR may be low. But it is not, because the effective rate (or the inverse of the average IRT) and the PDR give different results. To see this, notice that the average PDR at a target distance can be computed as follows: given an ego vehicle e, a set of N(d) neighbor vehicles whose distances to e are less or equal than d, and assuming that the probability of successful beacon reception is independent for each neighbor, the expected PDR for a transmission for e at distance d is given by where each s i is an independent Bernouilli r.v. with probability of success given by the corresponding P r (d ei , p) from eq. (1), and the sum in (13) goes over all vehicles in N(d). The expected value of the sum is just the sum of the expected values of the Bernouilli r.v. Then the expected value of the PDR when r beacons are transmitted in a second is given by 1 r r j =1P j ≈P, if we assume that the relative distances do not change much in a second and so theP j are approximately equal. We see that the PDR does not depend on the beaconing rate but only on the power via P r . This is of course a very simplified analysis valid only in absence on interference. A more accurate model is P r = P r (d ei , p t )(1 − P c (e, j )) + (1 − P i (i, j ))Pc(e, j ), where P i is the interference probability given, for instance, by eq. (17) in [21] and P c is a probability of collision that has to be computed and depends in general on the MAC and load, that is, on the beaconing rate. Therefore, the main reason for the poor PDR of BFPC is the low power allocated, which results in a low P r , combined with a high beaconing rate that increases the collisions and interference. The effective beaconing rate, r P r may be high because of a high beaconing rate, while the PDR is low because of a low power, as illustrated in the following example. Consider a vehicle with a single neighbor at a target distance for which the effective beaconing rate is r P r = 5 beacon/s. This effective rate may be achieved in two different ways: (1) with r = 5.5 beacons/s and P r = 0.9 and (2) with r = 10 beacons/s and P r = 0.5. After two seconds, for case (1) the vehicle has transmitted 10 beacons and the neighbor has received on average 9 beacons, so the PDR = 9/10 = 0.9. For case (2) the vehicle has transmitted 20 beacons but the neighbor has received only 10 on average, so PDR = 10/20 = 0.5. Note that in both cases, the average IRT is actually the same.
The conclusions of the previous discussion are general: when using joint rate and power control, a combination of low power and high rate is detrimental to PDR, and does not necessarily decrease the average IRT. This is why we said in Sect. III-B that selecting PDR or IRT as goal metrics gives different results. It also suggests that setting a high minimum power may be desirable for this kind of control. Unlike the other proposals, PRAIOS provides the flexibility to set this kind of precise limits to the constraints and goals.

B. Different Fading Types and Convergence Speed
We have derived our algorithm under the assumption that the fading is of Rayleigh type, m = 1. In this subsection we discuss the behaviour of PRAIOS when that assumption is not met. We also discuss the speed of convergence of the algorithm.
We simulate the scenario described in the previous section but changing the shape parameter to m = 3 and m = 0.5, that is, more moderate and stronger fading respectively. In Fig. 2 we plot the results. Regarding the allocations, the powers are similar and we see in Fig. 2(a) that for moderate fading the effective rate is higher with lower rates because the probability of reception is higher at the same power. We cannot say whether the allocations are optimal or how close to an optimal allocation they are, but as we can see in Fig. 2(b) top, the average CBT constraint is tightly met in both cases. The key to obtain that behaviour is that we use the measured CBT as subgradient, that is, eq. (10) instead of eq. (9), so we do not have to use the assumptions about the m parameter that are in the K iv . Thus, PRAIOS can effectively control the load when the fading is not Rayleigh, even if the allocation is not actually optimal.
Finally, we look at the speed of convergence. In the previous Section we plotted the results after 100 s of simulation, which may raise concerns about the speed of convergence. But the convergence is much faster. In Fig. 2(b) bottom we plot the ratio of the total utility achieved by PRAIOS to the exact optimal utility computed by CVXPY. As can be seen, after around 4 s the ratio has reached 0.97, which means that the algorithm has practically converged. Note that the utility can be higher than the optimal one at the beginning, because the MBL constraints are not met. The power and rate allocations at that time are also shown in Fig. 2(a). PRAIOS converges quickly to a close to optimal allocation and then it moves slowly to the exact optimal allocation with some small oscillations due to packet losses.

C. Dynamic Scenario
In this section we examine the behavior of the algorithms in a dynamic situation. We simulate a typical scenario, where a road has a traffic jam in one direction with a high density of vehicles, which generates high congestion levels, while on the other direction there are moving vehicles in free flow at high speeds. In our scenario we place 3 lanes of static vehicles in one direction. At each lane, 85 vehicles are placed separated by 2 m plus a random value uniformly distributed between 2 and 4 m, starting at the origin, so that each row of vehicles spans around 450 m. In the other direction a set of 50 vehicles separated with the same distribution is moving at 30 m/s heading to the static cluster. The moving cluster starts at 930 m at t = 0. We use the parameters of Section IV-A for all the algorithms, except that we set C C BT = 0.6 and, for SAE J2945 we set vMaxChanUtil = 0.6 and vMinChanUtil = 0.3. The simulation runs for 100 s, and the moving cluster passes the static cluster at time between 15 to 50 s.
In Fig. 3 we plot the different metrics averaged over all the simulation time, showing the static and moving vehicles in two different plots for each metric. The abscissa shows the vehicle positions at the start of the simulation, but it is understood that the coordinates in the moving cluster change as vehicles move. The results show, in general, that PRAIOS works properly in a dynamic scenario. The conclusions of the comparison are very similar to those of the previous section. In particular, we can see how PRAIOS keeps the CBT at the maximum allowed, while the other proposals result in just around 50% of the MBL. Again, the effective beaconing rate of BFPC is above that of PRAIOS, but it reduces considerably the power, which results in a worse PDR for the static cluster. For the moving cluster the PDR for BFPC is slightly better than PRAIOS, because it benefits from the lower power used by the vehicles in the static cluster, which results in lower interference. The higher power of PRAIOS is also the reason for the slightly worse PDR of vehicles in the center of the static cluster, as a consequence of the interference created by hidden node collisions.
To achieve a better understanding of the algorithms behavior, we show in Fig. 4 the time evolution of power and rates for the static and moving clusters. We have plotted the results for all the vehicles, but keeping the same color for each algorithm. We can now clearly see that both SAE and BFPC have oscillations. For BFPC the power converges to a stable value but the rate keeps oscillating in the static cluster. The reason is not clear, it is probably due to the configuration parameters used. As said above, the lack of a guide to configure the parameters to achieve some goal is one of the main drawbacks of this proposal. For the moving cluster the rate oscillation appears only when they are passing the static cluster and then stabilizes. For SAE J2945, there are longer-period oscillations of both rate and power, which is the expected behavior of this algorithm: it increases linearly the power when it is in the allowed CBT range, but when it is out of range, it directly sets the maximum or minimum power respectively. Those power oscillations are transferred to the beaconing rate because it is driven by the estimated density of vehicles, derived from the number of neighbors measured. PRAIOS, on the contrary, does not exhibit oscillating behavior. The powers in the static cluster are kept at the maximum value, except for the periods of adaptation when the moving cluster is passing or leaving the static one. Rates have a slight variation over the mean value (recall that all the vehicle rates are plotted with the same color) depending on the position in the static cluster. The figure also shows the quick convergence of PRAIOS to the final value. In the moving cluster, it is interesting to note that PRAIOS vehicles first reduce the power when approaching the high congestion zone, then drop the rate at the level of the static vehicles. When they are out of the influence of the high congestion cluster, both power and rate are kept at the maximum level, as one would expect, because the load is below the MBL, unlike the other proposals. In conclusion, PRAIOS is able to adapt the allocations to variable situations and quickly recover the maximum rate and power when the measured load is below the MBL.

D. Flexibility for Applications
A usual criticism to congestion control algorithms is that they ignore the needs of the applications and just use the state of the channel for congestion control [25]. We, on the contrary, think that our approach provides more flexibility for the applications to adapt the control to their needs and the vehicular environment than other approaches, which design the algorithm around some particular requirements, such as to minimize some tracking error metric. With PRAIOS, applications on vehicles can set independently the maximum and minimum rate and power and the MBL to enforce some behavior, but they can also use the priority parameter, w v , to induce a more subtle adaptation. Even the MBL and the fairness parameter, α, can be used to drive the behavior. In fact, in a previous work we discussed how to use the priority parameter to adapt the rate control to the surrounding traffic situation [26]. With power and rate, more possibilities are open for such a control, but we leave it as future work and conclude this section with an example that illustrates the flexibility of PRAIOS.
In this scenario, we use again the configuration of the dynamic scenario in the previous section. The static vehicles are again placed in 3 parallel lanes with the same intervehicle distance. For the moving vehicles we set two different configurations: Cluster A comprises the first 25 moving vehicles and cluster B the remaining 25 moving vehicles. Let us assume that cluster A vehicles run some particular application, such as the Longitudinal Collision Risk Warning, LCRW, defined by ETSI [38], which requires a latency below 300 ms and a communication range between 200 and 300 m. To derive a set of constraints from this requirements we apply eq. (2) with target distance d o = 250 m, target probability P o = 0.95 and maximum IRT T max = 0.3 s, or in words, that the IRT at 250 m has to be below 300 ms for 95% of the packets, and get a number of combinations of minimum rate and power that are able to achieve that level of awareness. In our case, at least we have to set r min v = 6 beacon/s and p min v = 0.5 W, but to account for interference for vehicles in cluster A we set a slightly higher minimum rate of 7 beacon/s and power of 0.6 W. For the rest of vehicles, we set minimum rates of 1 beacon/s and minimum power 0.1 W. For the static cluster we set C C BT = 0.4, and for vehicles in A and B, C C BT = 0.6. Finally, we use the priority parameter to remark how weighted fairness can be achieved with PRAIOS. So we consider a number of special vehicles, think of ambulances, for instance, that have priority over the rest of vehicles. We set w v = 4 for 3 vehicles in different positions along the static cluster, for the first and last vehicle in cluster A and for 2 vehicles in cluster B. For the rest of vehicles the priority parameter is 1. Our algorithm will assign more resources to these vehicles, according to the situation, without enforcing a minimum value. As an approximation to the expected results, from eq. (19) in Appendix B, it follows that the ratio of rates of vehicles i and j, measuring the same congested channel state, would be w In Fig. 5 top we show the rate and effective rate when moving vehicles are in the middle of passing the static cluster. It clearly shows the higher rates for special vehicles in both static and B clusters, due to the higher priority parameter, whereas for cluster A only a slight increase in the effective rate for the last vehicle. As previously mentioned, the assignment actually depends on the congestion state or available resources, and vehicles in less congested areas (borders) are assigned higher relatives rates. For vehicles in cluster A, there is no margin for it, and all of them set the minimum rate. Finally, in Fig. 5 bottom we show the empirical cumulative density function, CDF, for the IRT of the beacons received only from vehicles in cluster A, in total more than 2 million samples for the simulation time. As can be seen 95% of the samples are below 300 ms, and in fact, 82% of the samples are below 146 ms. And again the measured CBT, not shown, is very close to the MBL. In this case, since there are many more vehicles in the static cluster, the CBT is 0.4. In conclusion, PRAIOS parameters can be dynamically and independently set by applications to achieve particular requirements. If multiple applications running on a vehicle demand different requirements, some manager module needs to decide the more stringent to set the parameters.

V. CONCLUSION
In this paper we propose a distributed algorithm for optimal joint adaptation of rate and power for congestion and awareness control in vehicular networks. Our approach is based on a NUM formulation of the congestion control problem, which allows us to induce a desired fairness notion and set different priorities for vehicles. Our goal is to minimize the average IRT as an awareness metric. We formulate the general problem but, since it is not convex, we assume Rayleigh fading and derive an algorithm, called PRAIOS, that solve the optimization problem in a distributed way, with convergence guarantees.
We have validated our proposal with realistic simulations in both static and dynamic scenarios and compared its performance with other similar proposals. Our results show that PRAIOS quickly converges to close to optimal allocations, while keeping the MBL at the desired level. Unlike the other proposals, PRAIOS provides the flexibility to set precise limits to the constraints and goals, which are enforced by the algorithm in dynamic scenarios, without oscillations. We have also shown that PRAIOS can effectively control the load and keep it under the MBL when the fading is not Rayleigh, although in that case the allocation might not be optimal. Finally, we have exemplified how PRAIOS provide a flexible framework for applications which allows them to adapt the control to their particular needs. Applications can independently translate their requirements to particular constraints, that can be dynamically set and enforced by the algorithm, and different priorities can be assigned according to the state of the environment or the characteristics of the vehicle, while meeting the channel load constraints.
As future work, we plan to take advantage of that flexibility to integrate more precisely context-dependent constraints into the framework control, as we did in a previous paper, where we used the computed TTC to set the priority parameter of the vehicles. The combination of available parameters and the possibility to seamlessly use even different utility functions independently by each vehicle open the way to richer designs. In that work we also plan to study the influence of the fairness parameter in the outcomes of the algorithm and the convergence speed. An alternative to explore is the use of a linear utility function. That is, we have shown that the proposed utility functions are concave when α > 1, but if we set α = 1 in the utility we obtain an affine function of the log-rates and the probability of reception, that can be regularized to obtain a strictly concave utility. Such a control would be easy to implement, should converge quickly and would provide proportional fairness. We leave it as future work.

A. Concavity of the Objective Function
The concavity of the objective function of problem R − PR (5), determines whether it is possible to converge to the optimal value or just to the proximity of it. It depends on the value of the parameters, and as we discuss next, only convergence to the proximity is guaranteed in general. To establish the concavity we compute the Hessian of the objective function and its eigenvalues. It can be shown that it is a set made of (0, −(K 2 o +1)e (y v −K o h v )(1−α) (α−1)), ∀v, that is, for every pair of rate and power variables, there are two eigenvalues: one is zero and the other one is negative as long as α > 1. Therefore, the objective function is concave, provided α > 1, but not strictly concave. As discussed in the next section, in this case the algorithm converges to the proximity of the optimal value. This is usually enough for practical purposes, since in a realistic environment the collection of neighbor multipliers is subjected to noisy measurements. The objective function is strictly concave for certain combinations of the parameters and variable ranges, as can be shown by computing second-order conditions, and so it is possible in theory to converge to the optimal value. But such combinations do not have a trivial form and it is not practical to use them.

B. Proof of Convergence of Algorithm 1
As we said previously, the objective function can be concave or strictly concave depending on the domain of the variables and the value of the parameters. We consider first the case of strict concavity.
We first compute the Hessian by direct differentiation of the gradient of the dual function (9), obtaining the Hessian matrix H , which is a V × V matrix, whose elements are Now, to bound it we need the following relations. For each vehicle and at each algorithm iteration, given a vector of multipliersλ, the unique minimizers in (7), y * v and h * v , are computed from the stationarity condition of the Lagrange dual (7), that is, ∇ L = 0 for the Lagrangian function (6). So, from (11) and (12) we get for vehicle i Grouping the above expression (16) for all the vehicles, i = 1 . . . V , we form a linear system of equations for theλ, written in matrix form asBλ =ā (18) where (B) i j = e y i −K ji h i and a i = (e y i −K o h i ) (1−α) . We look for an additional system involving the Hessian. For this, we solve for y * v in (11) and, since, both y * i and h * i are functions of the vector of multiplersλ, then take the partial derivative with respect to one of the multipliers using implicit differentiation to get where we have used the fact that obtained from dividing (17) by (16). Next we group the partial derivatives on the left side of (20): and multiply both sides of (21) by e y * i and the sum in denominator of the right side to get v λ v e y * again using the previous expression for K o . Finally, we add together (22) for all the vehicles, i = 1 . . . V , and get Since the above expression is the inner product of the j column of the Hessian and the vector of multipliers,H j