A vehicle networking fairness transmission method based on convex optimization and reinforcement learning

By improving the ACK and DATA frame structures to detect hidden nodes and combining convex optimization and reinforcement learning to optimize transmission strategies, the problem of unfair transmission between hidden nodes and fast and slow vehicles in the Internet of Vehicles is solved, thereby improving throughput and transmission reliability.

CN122120731APending Publication Date: 2026-05-29IANGSU COLLEGE OF ENG & TECH

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
IANGSU COLLEGE OF ENG & TECH
Filing Date
2026-04-29
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

In the Internet of Vehicles (IoV), there are issues such as data frame conflicts caused by hidden nodes and fairness of transmission between vehicles of different speeds, which are difficult to solve effectively with existing technologies.

Method used

By improving the structure of ACK frames and DATA frames, hidden nodes are detected and transmission power is increased. By combining convex optimization and reinforcement learning to optimize the transmission strategy, hidden node conflicts are resolved. Furthermore, the fairness of data transmission between fast and slow vehicles is optimized through mathematical modeling and convex optimization methods.

Benefits of technology

It improves the throughput of vehicle-to-everything (V2X) networks, alleviates transmission conflicts caused by hidden nodes, achieves fairness in data transmission between fast and slow vehicles, and enhances the balanced allocation of network resources and transmission reliability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122120731A_ABST
    Figure CN122120731A_ABST
Patent Text Reader

Abstract

The application provides a vehicle networking fairness transmission method based on convex optimization and reinforcement learning, and belongs to the technical field of vehicle networking and data transmission. The technical scheme is as follows: S1: an improved confirmation ACK frame and a data DATA frame are designed to realize hidden node detection; S2: mathematical modeling of the transmission fairness problem; S3: fairness transmission based on convex optimization and reinforcement learning. The application effectively discovers hidden nodes, alleviates transmission conflicts caused by hidden nodes by improving the transmission power and the 'continuation' field of the data frame DATA, and finally improves the throughput; the reinforcement learning and convex optimization method are used to jointly optimize the transmission strategy, solve the minimization problem of the difference between the transmission data amounts of fast and slow vehicles, and improve the data fairness of vehicle networking transmission.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of vehicle networking and data transmission technology, and in particular to a fair transmission method for vehicle networking based on convex optimization and reinforcement learning. Background Technology

[0002] The application of autonomous driving and intelligent navigation has driven the development of vehicle-to-everything (V2X) communication technology. The terminals in V2X are characterized by changes in location and significant differences in movement speed, posing new challenges to V2X data transmission technology. First, due to distance, there are hidden nodes in V2X that are unaware of each other's presence. When two vehicles transmit data to the same destination node, it leads to numerous data frame collisions, resulting in decreased throughput. Second, when vehicles pass the same base station at different speeds, the varying communication durations cause differences in data transmission volume, raising the issue of fair transmission for vehicles of different speeds.

[0003] The IEEE Access journal paper "Fairness-Aware Computation Offloading for MobileEdge Computing With Energy Harvesting" (Vol. 13, 2025) studies the task offloading problem for multiple devices. Based on Lyapunov optimization and sequential least squares quadratic programming, the paper proposes a Fairness-Aware Computation Offloading Optimization (FACOO) algorithm. However, the study does not consider the mobility characteristics of nodes, making it difficult to guarantee data transmission fairness in vehicular networks. Summary of the Invention

[0004] The purpose of this invention is to provide a fair transmission method for vehicular networks based on convex optimization and reinforcement learning, which solves the technical problem of transmission fairness between hidden terminals and vehicles of different speeds in vehicular networks. This invention effectively discovers hidden nodes and alleviates transmission conflicts caused by hidden nodes by increasing transmission power, ultimately improving throughput. It utilizes reinforcement learning and convex optimization methods to jointly optimize the transmission strategy, solving the problem of minimizing the difference in data transmission volume between fast and slow vehicles, thus improving data fairness in vehicular network transmission.

[0005] To achieve the aforementioned objectives, the present invention employs the following technical solution: a fair transmission method for vehicle-to-everything (V2X) networks based on convex optimization and reinforcement learning, characterized by comprising the following steps:

[0006] S1: Add source MAC address field, destination MAC address field, and "limited transmission" field to the improved ACK frame, and add "resume transmission" field to the data frame; implement hidden node detection; source node A listens to and parses the improved ACK frame and data frame, and determines the existence of a hidden node when a specific MAC address matching condition is met and no corresponding data frame is listened to; for hidden nodes, increase transmission power by enabling power enhancement mode, or guide competing nodes to back off through the interaction of the "resume transmission" field and the "limited transmission" field; S2: Mathematical modeling of the transmission fairness problem, including: S21, Mathematical Model of the Problem Define W as the competition window. For a fixed time slot, the MAC layer backoff time is: (1); Define the data frame transmission rate of the source node as The frame length of the data frame is The time for sending the data frame is: (2); Among them, T P The time required to transmit the physical layer preamble, T PHY The time required to transmit the header of the Physical layer bitstream, T H Time is spent transmitting the MAC frame header; Define the ACK frame transmission rate as The length of the confirmed ACK frame is The time for sending the ACK frame is: (3); Among them, the length of the ACK frame is fixed, and the transmission rate is... If fixed, then It is a constant; By definition, the throughput of a node is: (4); in and These are the distributed frame interval and the shortest frame interval, respectively, both of which are fixed time coefficients; Based on the general formula for throughput above, the throughput of the express train is: (5); in, and These represent the data frame length and contention window value for the express train, respectively. The throughput of the slow train is: (6); in, and These represent the data frame length of the slow train and the contention window value, respectively. Considering the data frame transmission rate of express and slow trains The coefficients are equal and constant, the range of the wireless signal is defined as D, and the average speed of the express train is... Then the amount of data sent by the express train is The slow train's speed is constant. Then the amount of data sent by the slow train is ; The issue of data transmission fairness between express and slow trains is described as follows: (7); in, and These represent the minimum and maximum thresholds of the competition window, respectively. This is the maximum threshold for the data frame length. S22, Proof of Convex Approximation S221, Convexification of the Objective Function The objective function in formula (7) is non-convex, so an auxiliary variable is introduced. and The original objective function is transformed into the following equivalent optimization problem: (8); S222, Throughput Convexity Approximation Assume W and Variations within a finite numerical range, the throughput th is approximately a concave function of W, and... A convex function has For convex constraints, For concave constraints, the inequality Equivalent to That is, it is transformed into a convex constraint, and the problem in formula (7) is approximately a convex optimization problem; S23. Proof of the validity of convex approximation S231, Monotonicity of throughput Throughput th varies with frame length The constraint increases as the competition window W increases, and decreases as the competition window W increases, ensuring the monotonicity of the constraint. S232, Verification of Local Convexity Taking the second-order partial derivative of th with respect to W with respect to the throughput of formula (4), we get: (9); The above results demonstrate throughput It is a strictly concave function, and its negative function is a convex function; S233, Constraint Equivalence Introducing auxiliary variables and After that, new goals Compared with the original target Equivalent, and all constraints are convex, satisfying the Karush-Kuhn-Tucker (KKT) conditions for convex optimization, and solved using a convex optimization algorithm; S3: Fair transfer based on convex optimization and reinforcement learning. It convexizes the objective function by introducing auxiliary variables and utilizes the convexity approximation of parameters by throughput and the KKT conditions.

[0007] Furthermore, the improved ACK and DATA frames in S1 design enable hidden node detection; specifically, they include the following:

[0008] S11. Design Improvement: Acknowledgment (ACK) Frame and Data (DATA) Frame

[0009] In the improved ACK frame of the 802.11 protocol, a source MAC (Media Access Control) address field is added. The improved ACK frame then contains a source MAC address field and a destination MAC address field, along with a "limited transmission" field. The frame type field of the improved ACK frame is filled with 2 bits, and the frame subtype field is filled with 4 bits, with data values ​​of "01" and "1111" respectively. The default ACK frame is filled with 2 bits for the frame type field and 4 bits for the frame subtype field, with data values ​​of "01" and "1101" respectively. The destination node uses these two fields to determine whether a frame is an improved ACK frame or a default ACK frame. After receiving a data frame F from source node A, destination node B fills in its own MAC address in the source MAC address field of the improved ACK frame. B For the address field, enter A, i.e., MAC address. A The address is then used to send the improved ACK frame described above;

[0010] S12. Improved listening to ACK and DATA frames.

[0011] Before source node A plans to send a data frame to node B, the current transmit power of node A is [value missing]. All nodes listen for and confirm ACK frames and parse all the content inside the frame; all nodes listen for and confirm DATA frames and parse the content of the frame header.

[0012] S13. Determination and removal of hidden nodes

[0013] Condition 1: If source node A receives an improved acknowledgment (ACK) frame, where the source MAC address field contains the MAC address... B The content in the destination MAC address field is not its own MAC address. A The address indicates that the destination node B is receiving the data DATA frame from the host C and has sent an improved ACK frame to node C.

[0014] Condition 2: If source node A cannot listen to data frames from node C, i.e., the source address is MAC address C Data DATA frames.

[0015] When both conditions 1 and 2 are met, node A determines that it and node C are each other's hidden nodes, and nodes A and C activate the power enhancement mode, that is, increase the transmission power. Let the maximum transmit power of the node be... , must meet Then, it sends a data frame, allowing node C to listen to node A's transmission process. Node C then avoids transmission collisions with node A according to the Carrier Sense Multiple Access with Collision Avoidance (CSMA / CA) rule.

[0016] In the data DATA frame (hereinafter referred to as data frame or DATA frame), a "resume" field is added. If node A and node C cannot detect the data frame signal sent by the other after increasing their transmission power, the transmission adopts the following strategy: Before sending a data frame frame1, if there are other data frames waiting to be sent in node A's transmission buffer, then 1 is filled in the "resume" field of data frame frame1. If there are no other data frames in node A's transmission buffer, then 0 is filled in the "resume" field of data frame frame1. After receiving data frame frame1 from node A, destination node B checks the content of the "resume" field in the data frame. If the content is 1, then 1 is filled in the "limited transmission" field of the improved ACK frame, which means that only node A is allowed to resume the subsequent data frame 2. After receiving the improved ACK frame, node C implements backoff. If the content of the "resume" field in the data frame is 0, then 0 is filled in the "limited transmission" field of the improved ACK frame, which means that any node is allowed to send freely, and node C prepares to transmit its own data frame.

[0017] If source node A does not detect any improved ACK frames sent by node B to other nodes within the period duration, then A will restore its transmit power to normal. The interval between the last two improved ACK frames sent by node B to the same host is defined as a delay time unit g, and the duration of the period is calculated according to the formula. calculate.

[0018] The S3 method, based on convex optimization and reinforcement learning for fair transmission, includes the following steps:

[0019] S31. Convex Optimization Solution

[0020] The problem represented by formula (8) is transformed into a linearly constrained convex optimization problem, which is solved using the interior point method. The k-th iteration value of variable u is defined as follows: Where u is the contention window W and the length of the data frame. All variables, k is a non-negative integer;

[0021] Let the decision variable vector be... The superscript symbol T represents transpose. Let i be a positive integer less than or equal to m, and write constraints C1 to C6 in the general form of inequalities. Where m=6, all inequality constraints are incorporated into the objective function to construct a logarithmic barrier function. Introducing obstacle parameters The original problem is transformed into an unconstrained obstacle problem:

[0022]

[0023] S311: Initialization parameters

[0024] Set the initial values ​​as follows: , , , ,in Take 100 bytes;

[0025] initial point Choose strict interior points, meaning all constraints are strictly less than 0, and set the initial values ​​of the obstacle parameters to 0. ω is the update coefficient used to increase z, with a typical value of Regarding convergence accuracy, the inner Newton method has higher accuracy. Outer layer total accuracy The number of inequality constraints is m;

[0026] S312: Outer Loop

[0027] S3121: Using the current z value, apply Newton's method to solve the obstacle problem. To obtain the solution ;

[0028] S3122: Update obstacle parameters ;

[0029] Repeat steps S3121 and S3122 until the stopping condition is met. ;

[0030] S313: Inner loop

[0031] Solve for a fixed z. ;

[0032] S3131: Calculate the gradient ,in , These are the gradient vectors of each constraint;

[0033] S3132: Calculate the Hessian matrix

[0034] Since all constraints are linear, ,have

[0035] ;

[0036] And because The Hessian matrix simplifies to:

[0037] ;

[0038] S3133: Solve for the x-increment in the Newton direction.

[0039] Solve the system of linear equations ;

[0040] S3134: Backtracking search determines step size b

[0041] Define learning rate ,from Start by halving the amount repeatedly until the following expression is satisfied:

[0042] ;

[0043] S3135: Update Iteration Point

[0044] ;

[0045] S3136: Convergence Judgment

[0046] definition To subtract Newton's weight, the expression is: ;

[0047] like Then the inner layer converges;

[0048] S314: Termination and Output

[0049] When the outer loop stops, the current solution is the approximate optimal solution;

[0050] S32, Solving using reinforcement learning

[0051] While reinforcement learning, as an artificial intelligence algorithm, has advantages such as adaptability, it also suffers from problems like unstable training and poor generalization ability. Therefore, this invention adds a convex optimization algorithm to the reinforcement learning algorithm. When the learning result of reinforcement learning exceeds the constraints of the objective optimization problem, the convex optimization algorithm is used to correct the action output by reinforcement learning. Through joint optimization of reinforcement learning and convex optimization, the fairness of data transmission in the vehicle-to-everything (V2X) network is improved.

[0052] S321. System State and Action Space Definition

[0053] By interacting with the outside world, Deep Reinforcement Learning (DRL) inputs environmental parameters (referred to as the state) for vehicle-to-everything (V2X) data transmission and outputs intelligent decisions (referred to as actions). Based on the V2X transmission situation, a statespace is defined, including vehicle speeds, real-time throughput, contention window size, and data frame length. The statespace is... ;

[0054] At each time step, the DRL determines the adjustment values ​​for the contention window and data frame length for the fast and slow trains, and the constraints of both are consistent with the constraints in formula (7). , , and These are the contention window for express and slow trains and the change in data frame length, respectively. The defined action space is:

[0055] ;

[0056] S322, Reward Function Design

[0057] The reward function guides the policy learning of the DRL algorithm, reflecting the fairness objective. The designed reward function is as follows:

[0058] ;

[0059] When the amount of data transmitted by the fast and slow trains becomes similar, the absolute value approaches 0, maximizing the reward.

[0060] S323, DRL network architecture

[0061] The algorithm employs a deep deterministic policy gradient (DDPG) with an actor-critic dual-network architecture. The actor network, based on the input to the state space, outputs actions, namely adjustments to the competition window and data frame length, with the system state as its input. The output is the optimal action. The function of a Critic network is to evaluate the value of a state, with the state as its input. With action The output is an action value assessment. The Replay Buffer stores experiences within the interactive environment, including states, actions, rewards, and the next state, denoted as... ;

[0062] S324, Algorithm Steps and Flow

[0063] S3241, Initialization Phase

[0064] Set the initial values ​​for the contention window and data frame length. ;

[0065] Initialize the DDPG network and its hyperparameters, initialize the Actor network μ, and the input state. Output action The actions satisfy the four constraints of formula (7), initialize the Critic network Q, and input the state. With action Output the value of the state-action pair. Initialize the target networks corresponding to the Actor network and Critic network. , Parameters of the Critic network With the parameters of the Actor network The parameters of the target network corresponding to the Critic network Parameters of the target network corresponding to the Actor network Initialize the experience replay pool RB with a capacity of N;

[0066] S3242, Environmental Interaction and Experience Collection

[0067] Real-time acquisition of status information in the environment, including parameters such as contention window, data frame length, and throughput. ;

[0068] S32421, The Actor network, based on the current state... Output action Based on this, the current competition window and data frame length of fast and slow vehicles can be obtained. ;

[0069] S32422. After executing the action, update the throughput of the fast and slow trains in the environment. and Calculate the reward function and transition to the new state. ;

[0070] S32423, Experience storage, will Stored in the Experience Replay Pool RB;

[0071] S3243, Convex Optimization Auxiliary Solution When the action output by DRL violates one of the four constraints of constraint formula (7), the convex optimization solver is called to correct the action. The solution steps are shown in step S31. Based on the output of the convex optimization solver... , , and Then update the contention window and frame length settings for fast and slow trains. , , Otherwise, continue with step S3244;

[0072] S3244, Network Training

[0073] S32441. Sample batch experience: Randomly sample B pieces of experience from RB, including the current state, action, reward, and next state. , where i is a non-negative integer;

[0074] S32442, Critic network update: Calculate the next state using the target Actor network.

[0075] Target action The target Q-value is calculated using the target Critic network. ,in Using the discount factor, the optimization objective of the Critic network is to minimize the following loss function:

[0076] ;

[0077] S32443. Actor network update: Using deterministic policy gradients, the Actor network is updated. The Actor network optimizes the policy by maximizing the Q-value of the Critic network. Its objective function is:

[0078] ;

[0079] Update the Actor network using the gradient method:

[0080] ;

[0081] S32444, Target network soft update: After each training iteration, the target network parameters are softly updated.

[0082] ,

[0083] ,

[0084] hyperparameters ;

[0085] S32445. If the previous round of the DRL algorithm called the convex optimization solver to calculate the contention window size and frame length, then the number of samples in the next round... To appropriately expand the sampling range, otherwise the number of samples in the next round will be insufficient. To slightly reduce the sampling range, but ,in and These are the minimum and maximum thresholds for sampling, respectively;

[0086] S3245, Iterative Convergence

[0087] Repeat steps S3242 to S3244 until the reward function is reached. The stabilization indicates the completion of the fairness objective, and the final Actor network is the optimization strategy for solving this fairness problem.

[0088] Meanwhile, this invention proposes a vehicle-to-everything (V2X) fair transmission system based on convex optimization and reinforcement learning. The system, applying the method described in this invention, includes the following steps:

[0089] The detection module is configured to perform the following process: designing improved ACK and DATA frames to achieve hidden node detection;

[0090] Mathematical modeling module: configured to perform the following process: mathematical modeling of the fairness problem;

[0091] The transmission module is configured to perform the following process: fair transmission based on convex optimization and reinforcement learning.

[0092] Meanwhile, the present invention proposes an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the computer program is executed, it implements the steps of the method described in the present invention.

[0093] Furthermore, the present invention proposes a computer-readable storage medium having a computer program stored thereon, the computer program being configured to implement the steps of the method described in the present invention when invoked by a processor.

[0094] Finally, the present invention provides a computer program product comprising a computer program / instructions that, when executed by a processor, implement the steps of the method described in the present invention.

[0095] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0096] (1) Hidden nodes in the vehicle-to-everything (V2X) network prevent two nodes from detecting each other's existence, causing transmission conflicts when they simultaneously send data frames to a certain node. To address this hidden node problem, this invention improves the ACK frame and DATA frame structures. The ACK frame adds a source MAC address and a limited transmission field, while the DATA frame adds a continuation field to assist hidden nodes in detecting each other's presence. After detecting a hidden node, the transmission power of the source node is increased (within legal transmission power constraints) to allow other hidden nodes to detect the transmission, thereby utilizing Carrier Sense Multiple Access / Collision Avoidance (CSMA / CA) rules to avoid collisions. If increasing the transmission power still fails to detect hidden nodes, this invention uses the improved ACK frame and DATA frame structures to alleviate frame transmission conflicts caused by hidden nodes, ultimately improving throughput.

[0097] (2) To address the fairness issue in the transmission between fast and slow vehicles, this invention first establishes a fairness mathematical model and proves the feasibility of convex approximation modeling. Secondly, it utilizes Deep Reinforcement Learning (DRL) and convex optimization to solve the transmission fairness problem. On one hand, when the action output by the DRL violates the constraints, the convex optimization solver is invoked to correct the action. On the other hand, depending on whether the convex optimization solver is invoked, the deep reinforcement learning algorithm adaptively adjusts the number of sampling experiences during the reinforcement learning process, balancing the diversity of experience sampling with learning efficiency, ultimately achieving dynamic adaptive joint optimization. This scheme does not rely on an accurate channel model, can solve the problem of unstable reinforcement learning training, and improve the data transmission fairness in vehicle-to-everything (V2X) transmission. Attached Figure Description

[0098] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used together with the embodiments of the invention to explain the invention and do not constitute a limitation thereof.

[0099] Figure 1 This is a diagram illustrating the improved ACK frame structure designed for this invention.

[0100] Figure 2 This is a diagram of the data frame structure designed for this invention.

[0101] Figure 3 This is a comparison chart of packet loss rates between the present invention and the default solution.

[0102] Figure 4This is a comparison chart of the normalized fast and slow train throughput ratios of the fair scheme, FACOO algorithm, and default scheme in this invention.

[0103] Figure 5 This is a flowchart of the hidden node detection and response algorithm in this invention.

[0104] Figure 6 This is a schematic diagram illustrating the model construction principle in this invention.

[0105] Figure 7 This is a flowchart illustrating the joint solution of convex optimization and reinforcement learning in this invention. Detailed Implementation

[0106] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. Of course, the specific embodiments described herein are merely illustrative and not intended to limit the invention.

[0107] Example 1: See Figure 1 and Figure 4 This embodiment provides a technical solution: a fair transmission method for vehicle-to-everything (V2X) networks based on convex optimization and reinforcement learning, comprising the following steps:

[0108] S1: Design improvements to acknowledgement (ACK) frames and data frames to achieve hidden node detection;

[0109] S2: Mathematical modeling of the transmission fairness problem;

[0110] S3: Fair transfer based on convex optimization and reinforcement learning.

[0111] Specifically, step S1 involves designing and improving the ACK and DATA frames to achieve hidden node detection; this includes the following:

[0112] S11. Design Improvement: Acknowledgment (ACK) Frame and Data (DATA) Frame

[0113] In the improved ACK frame of the 802.11 protocol, a source MAC (Media Access Control) address field is added. The improved ACK frame then contains a source MAC address field and a destination MAC address field, along with a "limited transmission" field. The frame type field of the improved ACK frame is filled with 2 bits, and the frame subtype field is filled with 4 bits, with data values ​​of "01" and "1111" respectively. The default ACK frame is filled with 2 bits for the frame type field and 4 bits for the frame subtype field, with data values ​​of "01" and "1101" respectively. The destination node uses these two fields to determine whether a frame is an improved ACK frame or a default ACK frame. After receiving a data frame F from source node A, destination node B fills in its own MAC address in the source MAC address field of the improved ACK frame. B For the address field, enter A, i.e., MAC address. A The address is then used to send the improved ACK frame described above;

[0114] S12. Improved listening to ACK and DATA frames.

[0115] Before source node A plans to send a data frame to node B, the current transmit power of node A is [value missing]. All nodes listen for and confirm ACK frames and parse all the content inside the frame; all nodes listen for and confirm DATA frames and parse the content of the frame header.

[0116] S13. Determination and removal of hidden nodes

[0117] Condition 1: If source node A receives an improved acknowledgment (ACK) frame, where the source MAC address field contains the MAC address... B The content in the destination MAC address field is not its own MAC address. A The address indicates that the destination node B is receiving the data DATA frame from the host C and has sent an improved ACK frame to node C.

[0118] Condition 2: If source node A cannot listen to data frames from node C, i.e., the source address is MAC address C Data DATA frames.

[0119] When both conditions 1 and 2 are met, node A determines that it and node C are each other's hidden nodes, and nodes A and C activate the power enhancement mode, that is, increase the transmission power. Let the maximum transmit power of the node be... , must meet Then, it sends a data frame, allowing node C to listen to node A's transmission process. Node C then avoids transmission collisions with node A according to the Carrier Sense Multiple Access with Collision Avoidance (CSMA / CA) rule.

[0120] In the data DATA frame (hereinafter referred to as data frame or DATA frame), a "resume" field is added. If node A and node C cannot detect the data frame signal sent by the other after increasing their transmission power, the transmission adopts the following strategy: Before sending a data frame frame1, if there are other data frames waiting to be sent in node A's transmission buffer, then 1 is filled in the "resume" field of data frame frame1. If there are no other data frames in node A's transmission buffer, then 0 is filled in the "resume" field of data frame frame1. After receiving data frame frame1 from node A, destination node B checks the content of the "resume" field in the data frame. If the content is 1, then 1 is filled in the "limited transmission" field of the improved ACK frame, which means that only node A is allowed to resume the subsequent data frame 2. After receiving the improved ACK frame, node C implements backoff. If the content of the "resume" field in the data frame is 0, then 0 is filled in the "limited transmission" field of the improved ACK frame, which means that any node is allowed to send freely, and node C prepares to transmit its own data frame.

[0121] If source node A does not detect any improved ACK frames sent by node B to other nodes within the period duration, then A will restore its transmit power to normal. The interval between the last two improved ACK frames sent by node B to the same host is defined as a delay time unit g, and the duration of the period is calculated according to the formula. calculate.

[0122] Specifically, the mathematical modeling of the fairness problem in step S2 includes the following:

[0123] Mathematical Model of Problem S21

[0124] Define W as the competition window. For a fixed time slot, the MAC layer backoff time is...

[0125] (1)

[0126] Define the data frame transmission rate of the source node as The frame length of the data frame is The time to send data frames is

[0127] (2)

[0128] Among them, T P The time required to transmit the physical layer preamble, T PHY The time required to transmit the header of the Physical layer bitstream, T H Time is consumed in transmitting the MAC frame header.

[0129] Define the ACK frame (improved ACK or default ACK) transmission rate as follows: The frame length for confirming the ACK is The time to send the ACK frame is

[0130] (3)

[0131] Among them, the length of the ACK frame is fixed, and its transmission rate is... It is also fixed, so It is a constant.

[0132] By definition, the throughput of a node is

[0133] (4)

[0134] in and These are the distributed frame interval and the shortest frame interval, respectively, both of which are fixed time coefficients.

[0135] Based on the general formula for throughput above, the throughput of the express train is:

[0136] (5)

[0137] in and These represent the data frame length and contention window value for the express train, respectively.

[0138] The throughput of the slow train is

[0139] (6)

[0140] in and These represent the data frame length of the slow train and the contention window value, respectively.

[0141] Considering the data frame transmission rate of express and slow trains The coefficients are equal and constant, the range of the wireless signal is defined as D, and the average speed of the express train is... Then the amount of data sent by the express train is The slow train's speed is constant. Then the amount of data sent by the slow train is .

[0142] Therefore, the data transmission fairness problem between express and slow trains can be expressed as follows:

[0143] (7)

[0144] in, and These represent the minimum and maximum thresholds of the competition window, respectively. This is the maximum threshold for the data frame length.

[0145] S22, Proof of Convex Approximation

[0146] S221, Convexification of the Objective Function

[0147] The objective function in formula (7) is non-convex, so an auxiliary variable is introduced. and The original objective function is transformed into the following equivalent optimization problem:

[0148] (8);

[0149] S222, Throughput Convexity Approximation

[0150] Assume W and Variations within a finite numerical range, the throughput th is approximately a concave function of W, and... A convex function has For convex constraints, Concave constraint, but inequality It can be equivalent to That is, it is transformed into a convex constraint, and the problem in formula (7) is approximately a convex optimization problem;

[0151] S23. Proof of the validity of convex approximation

[0152] S231, Monotonicity of throughput

[0153] Throughput th varies with frame length The constraint increases as the competition window W increases, and decreases as the competition window W increases, ensuring the monotonicity of the constraint.

[0154] S232, Verification of Local Convexity

[0155] Taking the second-order partial derivative of th with respect to W with respect to the throughput of formula (4), we get:

[0156] (9);

[0157] The above results demonstrate throughput It is a strictly concave function, and its negative function is a convex function;

[0158] S233, Constraint Equivalence

[0159] Introducing auxiliary variables and After that, new goals Compared with the original target The conditions are equivalent, and all constraints are convex, satisfying the Karush-Kuhn-Tucker (KKT) conditions for convex optimization. The solution is obtained using a convex optimization algorithm.

[0160] Specifically, S3, based on fair transmission using convex optimization and reinforcement learning, includes the following steps:

[0161] S31. Convex Optimization Solution

[0162] The problem represented by formula (8) is transformed into a linearly constrained convex optimization problem, which is solved using the interior point method. The k-th iteration value of variable u is defined as follows: Where u is the contention window W and the length of the data frame. All variables, k is a non-negative integer;

[0163] Let the decision variable vector be... The superscript symbol T represents transpose. Let i be a positive integer less than or equal to m, and write constraints C1 to C6 in the general form of inequalities. Where m=6, all inequality constraints are incorporated into the objective function to construct a logarithmic barrier function. Introducing obstacle parameters The original problem is transformed into an unconstrained obstacle problem:

[0164]

[0165] S311: Initialization parameters

[0166] Set the initial values ​​as follows: , , , ,in Take 100 bytes;

[0167] initial point Choose strict interior points, meaning all constraints are strictly less than 0, and set the initial values ​​of the obstacle parameters to 0. ω is the update coefficient used to increase z, with a typical value of Regarding convergence accuracy, the inner Newton method has higher accuracy. Outer layer total accuracy The number of inequality constraints is m;

[0168] S312: Outer Loop

[0169] S3121: Using the current z value, apply Newton's method to solve the obstacle problem. To obtain the solution ;

[0170] S3122: Update obstacle parameters ;

[0171] Repeat steps S3121 and S3122 until the stopping condition is met. ;

[0172] S313: Inner loop

[0173] Solve for a fixed z. ;

[0174] S3131: Calculate the gradient ,in , These are the gradient vectors of each constraint;

[0175] S3132: Calculate the Hessian matrix

[0176] Since all constraints are linear, ,have

[0177] ;

[0178] And because The Hessian matrix simplifies to:

[0179] ;

[0180] S3133: Solve for the x-increment in the Newton direction.

[0181] Solve the system of linear equations ;

[0182] S3134: Backtracking search determines step size b

[0183] Define learning rate ,from Start by halving the amount repeatedly until the following expression is satisfied:

[0184] ;

[0185] S3135: Update Iteration Point

[0186] ;

[0187] S3136: Convergence Judgment

[0188] definition To subtract Newton's weight, the expression is: ;

[0189] like Then the inner layer converges;

[0190] S314: Termination and Output

[0191] When the outer loop stops, the current solution is the approximate optimal solution;

[0192] S32, Solving using reinforcement learning

[0193] S321. System State and Action Space Definition

[0194] By interacting with the outside world, Deep Reinforcement Learning (DRL) inputs environmental parameters (referred to as the state) for vehicle-to-everything (V2X) data transmission and outputs intelligent decisions (referred to as actions). Based on the V2X transmission situation, a statespace is defined, including vehicle speeds, real-time throughput, contention window size, and data frame length. The statespace is... ;

[0195] At each time step, the DRL determines the adjustment values ​​for the contention window and data frame length for the fast and slow trains, and the constraints of both are consistent with the constraints in formula (7). , , and These are the contention window for express and slow trains and the change in data frame length, respectively. The defined action space is:

[0196] ;

[0197] S322, Reward Function Design

[0198] The reward function guides the policy learning of the DRL algorithm, reflecting the fairness objective. The designed reward function is as follows:

[0199] ;

[0200] When the amount of data transmitted by the fast and slow trains becomes similar, the absolute value approaches 0, maximizing the reward.

[0201] S323, DRL network architecture

[0202] The DDPG algorithm employs an actor-critic dual-network architecture. The actor network, based on the input to the state space, outputs actions, namely adjustments to the contention window and data frame length. Its input is the system state. The output is the optimal action. The function of a Critic network is to evaluate the value of a state, with the state as its input. With action The output is an action value assessment. The Replay Buffer stores experiences within the interactive environment, including states, actions, rewards, and the next state, denoted as... ;

[0203] S324, Algorithm Steps and Flow

[0204] S3241, Initialization Phase

[0205] Set the initial values ​​for the contention window and data frame length. ;

[0206] Initialize the DDPG network and its hyperparameters, initialize the Actor network μ, and the input state. Output action The actions satisfy the four constraints of formula (7), initialize the Critic network Q, and input the state. With action Output the value of the state-action pair. Initialize the target networks corresponding to the Actor network and Critic network. , Parameters of the Critic network With the parameters of the Actor network The parameters of the target network corresponding to the Critic network Parameters of the target network corresponding to the Actor network Initialize the experience replay pool RB with a capacity of N;

[0207] S3242, Environmental Interaction and Experience Collection

[0208] Real-time acquisition of status information in the environment, including parameters such as contention window, data frame length, and throughput. ;

[0209] S32421, The Actor network, based on the current state... Output action Based on this, the current competition window and data frame length of fast and slow vehicles can be obtained. ;

[0210] S32422. After executing the action, update the throughput of the fast and slow trains in the environment. and Calculate the reward function and transition to the new state. ;

[0211] S32423, Experience storage, will Stored in the Experience Replay Pool RB;

[0212] S3243, Convex Optimization Auxiliary Solution When the action output by DRL violates one of the four constraints of constraint formula (7), the convex optimization solver is called to correct the action. The solution steps are shown in step S31. Based on the output of the convex optimization solver... , , and Then update the contention window and frame length settings for fast and slow trains. , , Otherwise, continue with step S3244;

[0213] S3244, Network Training

[0214] S32441. Sample batch experience: Randomly sample B pieces of experience from RB, including the current state, action, reward, and next state. , where i is a non-negative integer;

[0215] S32442, Critic network update: Calculate the next state using the target Actor network.

[0216] Target action The target Q-value is calculated using the target Critic network. ,in Using the discount factor, the optimization objective of the Critic network is to minimize the following loss function:

[0217] ;

[0218] S32443. Actor network update: Using deterministic policy gradients, the Actor network is updated. The Actor network optimizes the policy by maximizing the Q-value of the Critic network. Its objective function is:

[0219] ;

[0220] Update the Actor network using the gradient method:

[0221] ;

[0222] S32444, Target network soft update: After each training iteration, the target network parameters are softly updated.

[0223] ,

[0224] ,

[0225] hyperparameters ;

[0226] S32445. If the previous round of the DRL algorithm called the convex optimization solver to calculate the contention window size and frame length, then the number of samples in the next round... To appropriately expand the sampling range, otherwise the number of samples in the next round will be insufficient. To slightly reduce the sampling range, but ,in and These are the minimum and maximum thresholds for sampling, respectively;

[0227] S3245, Iterative Convergence

[0228] Repeat steps S3242 to S3244 until the reward function is reached. The stabilization indicates the completion of the fairness objective, and the final Actor network is the optimization strategy for solving this fairness problem.

[0229] Example 2: Experimental parameters are as follows: the speeds of the express train and the slow train are 120 km / h and 60 km / h respectively, and the minimum competition window for both is... 16. Largest competitive window The maximum length L of the data frame sent by the vehicle is 1024. max =2000 bytes. The initial data frame length for both is 100 bytes.

[0230] Figure 3 This section compares the packet loss rates of the fair scheme and the default scheme. The fair scheme exhibits a lower packet loss rate than the default algorithm. In practical applications, a lower packet loss rate translates to fewer retransmission requests and shorter end-to-end latency, which can effectively improve the service quality of services such as real-time streaming media and online games. Experimental results show that the fair scheme, by detecting potential hidden nodes, optimizing power, and combining a "resume" confirmation mechanism, effectively mitigates data frame conflicts caused by hidden nodes, significantly improving the reliability of data transmission.

[0231] Figure 4This paper compares the normalized throughput ratios of fast and slow vehicles using the fair scheme, the FACOO algorithm, and the default scheme. Compared to the default and FACOO algorithms, the fair scheme significantly improves the ratio. In practical applications, a higher normalized throughput ratio indicates that network resources are more evenly allocated to vehicles of different speeds, avoiding excessive concentration of bandwidth resources on slow vehicles, thus ensuring the overall fairness of the network. Experimental results show that the fair scheme effectively improves the uneven traffic distribution between fast and slow vehicles by optimizing resource allocation strategies, significantly improving the fairness of network resource allocation. Compared to the FACOO algorithm, the convex optimization correction reinforcement learning mechanism designed in this invention can alleviate the instability problem of reinforcement learning training, thereby achieving better transmission fairness. Figure 3 and Figure 4 The fair scheme alleviates data frame conflicts in hidden nodes and also achieves fairness in data transmission.

[0232] Example 3: This example proposes a vehicle-to-everything (V2X) fair transmission system based on convex optimization and reinforcement learning. The system, applying the method described in this invention, includes the following steps:

[0233] The detection module is configured to perform the following process: designing improved ACK and DATA frames to achieve hidden node detection;

[0234] Mathematical modeling module: configured to perform the following process: mathematical modeling of the fairness problem;

[0235] The transmission module is configured to perform the following process: fair transmission based on convex optimization and reinforcement learning.

[0236] Example 4: This example proposes an electronic system, including: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the method steps of the present invention.

[0237] Example 5: This example proposes a computer-readable storage medium storing a computer program thereon. When the computer program is executed by a processor, it implements the steps of the method described in this invention, which will not be repeated here.

[0238] Example 6: This example proposes a computer program product, including a computer program / instructions. When the computer program / instructions are executed by a processor, they implement the steps of the method described in this invention, which will not be repeated here.

[0239] It should be noted that the processing flow of embodiments 3-6 corresponds to the specific steps of the method provided in embodiment 1 of the present invention, and has the corresponding functional modules and beneficial effects of the method. Technical details not described in detail in this embodiment can be found in the method provided in embodiment 1 of the present invention.

[0240] The program code used to implement the methods of this application may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing device, such that when executed by the processor or controller, the functions / operations specified in the flowcharts and / or block diagrams are implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0241] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A fair transmission method for vehicle-to-everything (V2X) networks based on convex optimization and reinforcement learning, characterized in that, Includes the following steps: S1: Add source MAC address field, destination MAC address field and "limited transmission" field to the improved ACK frame, and add "resume transmission" field to the data frame; Implement hidden node detection; Source node A listens to and parses the improved ACK frame and DATA frame. When a specific MAC address matching condition is met and the corresponding data frame is not listened to, it is determined that a hidden node exists. For hidden nodes, the power enhancement mode can be enabled to increase the transmission power, or the interaction between the "continue transmission" field and the "limited transmission" field can be used to guide competing nodes to back off; S2: Mathematical modeling of the transmission fairness problem, including: S21, Mathematical Model of the Problem Define W as the competition window. For a fixed time slot, the MAC layer backoff time is: (1); Define the data frame transmission rate of the source node as The frame length of the data frame is The time for sending the data frame is: (2); Among them, T P The time required to transmit the physical layer preamble, T PHY The time required to transmit the header of the Physical layer bitstream, T H Time is spent transmitting the MAC frame header; Define the ACK frame transmission rate as The length of the confirmed ACK frame is The time for sending the ACK frame is: (3); Among them, the length of the ACK frame is fixed, and the transmission rate is... If fixed, then It is a constant; By definition, the throughput of a node is: (4); in and These are the distributed frame interval and the shortest frame interval, respectively, both of which are fixed time coefficients; Based on the general formula for throughput above, the throughput of the express train is: (5); in, and These represent the data frame length and contention window value for the express train, respectively. The throughput of the slow train is: (6); in, and These represent the data frame length of the slow train and the contention window value, respectively. Considering the data frame transmission rate of express and slow trains The coefficients are equal and constant, the wireless signal range is defined as D, and the average speed of the express train is... Then the amount of data sent by the express train is The slow train's speed is constant. Then the amount of data sent by the slow train is ; The issue of data transmission fairness between express and slow trains can be described as follows: (7); in, and These represent the minimum and maximum thresholds of the competition window, respectively. This is the maximum threshold for the data frame length; S22, Proof of Convex Approximation S221, Convexification of the Objective Function The objective function in formula (7) is non-convex, so an auxiliary variable is introduced. and The original objective function is transformed into the following equivalent optimization problem: (8); S222, Throughput Convexity Approximation Assume W and Variations within a finite numerical range, the throughput th is approximately a concave function of W, and... A convex function has For convex constraints, For concave constraints, the inequality Equivalent to That is, it is transformed into a convex constraint, and the problem in formula (7) is approximately a convex optimization problem; S23. Proof of the validity of convex approximation S231, Monotonicity of throughput Throughput th varies with frame length The constraint increases as the competition window W increases, and decreases as the competition window W increases, ensuring the monotonicity of the constraint. S232, Verification of Local Convexity Taking the second-order partial derivative of th with respect to W with respect to the throughput of formula (4), we get: (9); The above results demonstrate throughput It is a strictly concave function, and its negative function is a convex function; S233, Constraint Equivalence Introducing auxiliary variables and After that, new goals Compared with the original target Equivalent, and all constraints are convex, satisfying the Karush-Kuhn-Tucker (KKT) conditions for convex optimization, and solved using a convex optimization algorithm; S3: Fair transfer based on convex optimization and reinforcement learning.

2. The vehicle-to-everything (V2X) fair transmission method based on convex optimization and reinforcement learning according to claim 1, characterized in that, S1 includes the following steps: S11. Design Improvement: Acknowledgment (ACK) Frame and Data (DATA) Frame In the improved ACK frame of the 802.11 protocol, a source MAC address field is added. The improved ACK frame contains a source MAC address field and a destination MAC address field. In addition, a "limited transmission" field is added. The frame type field of the improved ACK frame is filled with 2 bits, and the frame subtype field is filled with 4 bits. The data filled in are "01" and "1111" respectively. The default ACK frame is filled with 2 bits for the frame type field and 4 bits for the frame subtype field. The data filled in are "01" and "1101" respectively. The destination node determines whether a frame is an improved ACK frame or a default ACK frame based on the above two fields. After receiving the data frame F from the source node A, the destination node B fills in its own MAC address in the source MAC address field of the improved ACK frame. B For the address field, enter A, i.e., MAC address. A The address is then used to send the improved ACK frame described above; S12. Improved listening to ACK and DATA frames. Before source node A plans to send a data frame to node B, the current transmit power of node A is [value missing]. All nodes listen for the improved ACK frame and parse the entire content inside the frame; all nodes listen for the DATA frame and parse the content of its frame header. S13. Determination and removal of hidden nodes Condition 1: If source node A receives an improved acknowledgment (ACK) frame, where the source MAC address field contains the MAC address... B The content in the destination MAC address field is not its own MAC address. A The address indicates that the destination node B is receiving the data DATA frame from the host C and has sent an improved ACK frame to node C. Condition 2: If source node A cannot listen to data frames from node C, i.e., the source address is MAC address C The data frame; when conditions 1 and 2 above are met simultaneously, node A determines that it and node C are each other's hidden nodes, and node A and node C activate the power enhancement mode, that is, increase the transmission power. Let the maximum transmit power of the node be... , must meet Then, a data frame is sent so that node C can listen to node A's transmission process. Node C then avoids transmission conflicts with node A according to the Carrier Sense Multiple Access / Collision Avoidance (CSMA / CA) rules. In the data frame, a "resume" field is added. If node A and node C cannot detect the data frame signal sent by the other after increasing their transmission power, the transmission adopts the following strategy: Before sending a data frame 1, if there are other data frames waiting to be sent in node A's transmission buffer, then 1 is filled in the "resume" field of data frame 1. If there are no other data frames in node A's transmission buffer, then 0 is filled in the "resume" field of data frame 1. After receiving data frame 1 from node A, destination node B checks the content of the "resume" field in the data frame. If the content is 1, then 1 is filled in the "limited transmission" field of the improved acknowledgment ACK frame, indicating that only node A is allowed to resume the subsequent data frame 2. After receiving the improved acknowledgment ACK frame, node C implements backoff. If the content of the "resume" field in the data frame is 0, then 0 is filled in the "limited transmission" field of the improved acknowledgment ACK frame, indicating that any node is allowed to send freely, and node C prepares to transmit its own data frame. If source node A does not detect any improved ACK frames sent by node B to other nodes within the period duration, then A will restore its transmit power to normal. The interval between the last two improved ACK frames sent by node B to the same host is defined as a delay time unit g, and the duration of the period is calculated according to the formula. calculate.

3. The vehicle-to-everything (V2X) fair transmission method based on convex optimization and reinforcement learning according to claim 1, characterized in that, S3 includes the following steps: S31. Convex Optimization Solution The problem represented by formula (8) is transformed into a linearly constrained convex optimization problem, which is solved using the interior point method. The k-th iteration value of variable u is defined as follows: Where u is the contention window W and the length of the data frame. For each variable, k is a non-negative integer; Let the decision variable vector be... Where T represents the transpose, and let j be a positive integer less than or equal to m, then constraints C1 to C6 can be written in the general form of inequalities. Where m=6, all inequality constraints are incorporated into the objective function to construct a logarithmic barrier function. Introducing obstacle parameters The original problem is transformed into an unconstrained obstacle problem: ; S311: Initialization parameters Set the initial values ​​as follows: , , , ,in Take 100 bytes; initial point Choose strict interior points, meaning all constraints are strictly less than 0, and set the initial values ​​of the obstacle parameters to 0. ω is the update coefficient used to increase z, with a typical value of Regarding convergence accuracy, the inner Newton method has higher accuracy. Outer layer total accuracy The number of inequality constraints is m; S312: Outer Loop S3121: Using the current z value, apply Newton's method to solve the obstacle problem. To obtain the solution ; S3122: Update obstacle parameters ; Repeat steps S3121 to S3122 until the stopping condition is met. ; S313: Inner loop Solve for a fixed z. ; S3131: Calculate the gradient ,in , These are the gradient vectors of each constraint; S3132: Calculate the Hessian matrix ; Since all constraints are linear, ,have ; And because The Hessian matrix simplifies to: ; S3133: Solve for the x-increment in the Newton direction. ; Solve the system of linear equations ; S3134: Backtracking search determines step size b Define learning rate ,from Start by halving the amount repeatedly until the following expression is satisfied: ; S3135: Update Iteration Point ; S3136: Convergence Judgment definition To subtract Newton's weight, the expression is: ; like Then the inner layer converges; S314: Termination and Output When the outer loop stops, the current solution is the approximate optimal solution; S32, Solving using reinforcement learning S321. System State and Action Space Definition By interacting with the outside world, Deep Reinforcement Learning (DRL) inputs environmental parameters (state) for vehicle-to-everything (V2X) data transmission and outputs intelligent decisions (actions). Based on the V2X transmission situation, a state space is defined, including vehicle speeds, real-time throughput, contention window size, and data frame length. ; At each time step, the DRL determines the adjustment values ​​for the contention window and data frame length for the fast and slow trains, and the constraints of both are consistent with the constraints in formula (7). , , and These are the contention window for express and slow trains and the change in data frame length, respectively. The defined action space is: ; S322, Reward Function Design The reward function guides the policy learning of the DRL algorithm, reflecting the fairness objective. The designed reward function is as follows: ; When the amount of data transmitted by the fast and slow trains becomes similar, the absolute value approaches 0, maximizing the reward. S323, DRL network architecture The DDPG algorithm employs a dual-network architecture of Actor-Critic. The Actor network, based on the input to the state space, outputs actions, namely adjustments to the contention window and data frame length. Its input is the system state. The output is the optimal action. The function of a Critic network is to evaluate the value of a state, with the state as its input. With action The output is an action value assessment. The Replay Buffer stores experiences within the interactive environment, including states, actions, rewards, and the next state, denoted as... ; S324, Algorithm Steps and Flow S3241, Initialization Phase Set the initial values ​​for the contention window and data frame length. ; Initialize the DDPG network and its hyperparameters, initialize the Actor network μ, and the input state. Output action The actions satisfy the four constraints of formula (7), initialize the Critic network Q, and input the state. With action Output the value of the "state-action" pair. Initialize the target networks corresponding to the Actor network and Critic network. , Parameters of the Critic network With the parameters of the Actor network The parameters of the target network corresponding to the Critic network Parameters of the target network corresponding to the Actor network Initialize the experience replay pool RB with a capacity of N; S3242, Environmental Interaction and Experience Collection Real-time acquisition of status information in the environment, including parameters such as contention window, data frame length, and throughput. ; S32421, The Actor network, based on the current state... Output action To obtain the current contention window and data frame length of the fast and slow vehicles: ; S32422. After executing the action, update the throughput of the fast and slow trains in the environment. and Calculate the reward function and transition to the new state. ; S32423, Experience storage, will Stored in the Experience Replay Pool RB; S3243, Convex Optimization Auxiliary Solution When the action output by DRL violates one of the four constraints of constraint formula (7), the convex optimization solver is called to correct the action. The solution steps are shown in step S31. Based on the output of the convex optimization solver... , , and Then update the contention window and frame length settings for fast and slow trains. , , Otherwise, continue with step S3244; S3244, Network Training S32441. Sample batch experience: Randomly sample B pieces of experience from RB, including the current state, action, reward, and next state. , where i is a non-negative integer; S32442, Critic network update: Calculate the next state using the target Actor network. Target action The target Q-value is calculated using the target Critic network. ,in Using the discount factor, the optimization objective of the Critic network is to minimize the following loss function: ; S32443. Actor network update: Using deterministic policy gradients, the Actor network is updated. The Actor network optimizes the policy by maximizing the Q-value of the Critic network. Its objective function is: ; Update the Actor network using the gradient method: ; S32444, Target network soft update: After each training iteration, the target network parameters are softly updated. , , Among them, hyperparameters ; S32445. If the previous round of the DRL algorithm called the convex optimization solver to calculate the contention window size and frame length, then the number of samples in the next round... Otherwise, the next round of sampling numbers , ,in and These are the minimum and maximum thresholds for sampling, respectively; S3245, Iterative Convergence Repeat steps S3242 to S3244 until the reward function is reached. The stabilization indicates the completion of the fairness objective, and the final Actor network is the optimization strategy for solving this fairness problem.

4. A vehicle-to-everything (V2X) fair transmission system based on convex optimization and reinforcement learning, characterized in that, The system comprising the steps of applying the method according to any one of claims 1 to 3, wherein the system includes: The detection module is configured to perform the following process: designing improved ACK frames and DATA frames to achieve hidden node detection; Mathematical modeling module: configured to perform the following process: mathematical modeling of the fairness problem; The transmission module is configured to perform the following process: fair transmission based on convex optimization and reinforcement learning.

5. An electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the computer program is executed, it implements the steps of the method as described in any one of claims 1 to 3.

6. A computer-readable storage medium having a computer program stored thereon, characterized in that, The computer program is configured to implement the steps of the method according to any one of claims 1 to 3 when invoked by a processor.

7. A computer program product comprising a computer program / instructions, characterized in that, When the computer program / instructions are executed by the processor, they implement the steps of the method according to any one of claims 1 to 3.