Random task scheduling and resource allocation method in MEC system for D2D collaborative computing

By constructing an average weighted heterogeneous model of energy consumption in the MEC system and applying the Lyapunov optimization method, it is decomposed into computing frequency and resource allocation problems, solving the efficiency problem of D2D dynamic scheduling under time-varying channels, and achieving a more efficient Task processing and resource management.

CN114980039BActive Publication Date: 2024-09-24SUN YAT SEN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210569951.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-24
Publication Date
2024-09-24
Estimated Expiration
2042-05-24

AI Technical Summary

Technical Problem

The existing technology ignores the coupling between task arrival times in multi-user MEC systems and fails to effectively adapt to the traffic volume of D2D heterogeneous and time-varying channels. As a result, the D2D dynamic scheduling problem in dynamic network environments has not been fully studied.

Method used

Using the stochastic task scheduling and resource allocation method in the MEC system of D2D collaborative computing, by constructing a heterogeneous MEC system model based on D2D collaborative computing, taking the average weighted sum of energy consumption of the terminal device and the MEC server as the optimization goal, using Lyapunov The optimization method converts the optimization problem into sub-problems within each time slot, and decomposes the sub-problems into computing frequency control and computing resource allocation problems, as well as offloading strategy and transmit power control problems, and performs closed-form solution and alternate optimization.

Benefits of technology

It improves the system's flexibility and task processing speed, improves long-term performance and stability, and enables real-time and effective task and resource decision-making without prior conditions of task arrival time and wireless channel fading.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114980039B
    Figure CN114980039B
Patent Text Reader

Abstract

In view of the limitations of the prior art, the present invention proposes a random task scheduling and resource allocation method in a MEC system of D2D collaborative computing. By introducing D2D collaborative computing, the edge device computing tasks can be offloaded not only to the server side, but also to adjacent devices, which improves the flexibility of the system and the processing speed of tasks; by taking the average weighted energy consumption as the optimization performance indicator, the long-term performance of the system is improved and the stability of the system is enhanced; in addition, the online task offloading and resource management algorithm design based on the Lyapunov optimization algorithm of the present invention does not require the task arrival time and wireless channel fading prior conditions, and can make task and resource decisions in real time and effectively.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of mobile communication systems, and in particular to applications in mobile edge computing; more particularly, to a random task scheduling and resource allocation method in a D2D collaborative computing MEC system. Background Art

[0002] Mobile edge computing (MEC) can effectively realize the vision of integrated communication, computing, control and caching in 5G by pushing resources to the edge of the network and processing the data collected or generated by edge devices on-site. At the same time, through computing offloading and other methods, it can significantly reduce the execution time of tasks and save energy consumption of edge devices.

[0003] In order to realize collaborative task execution in multi-user MEC systems, device-to-device (D2D) collaborative computing technology is introduced into the MEC system. In a dynamic network environment, collaborative computing can be achieved by making full use of the computing and communication resources of a large number of devices. The Chinese invention patent with the authorization announcement date of 2021.11.02: In a method for joint downlink and uplink edge computing migration in an ultra-dense heterogeneous network, the joint uplink and downlink computing migration problem is first modeled as an optimization model for minimizing system latency, while considering saving energy consumption of user devices. Since the joint downlink and uplink computing migration problem is a mixed integer programming problem, it is transformed into a resource allocation subproblem and a computing migration subproblem.

[0004] However, existing technologies ignore the coupling between task arrival times and only consider short-term performance under strict delay or energy constraints. This consideration is acceptable in deterministic problem optimization, but under the influence of time-varying channels and random arrival times, MEC networks have time-varying characteristics. In summary, in MEC networks that support D2D, in order to adapt to the heterogeneous and time-varying traffic of D2D, the D2D dynamic scheduling problem needs to be further studied. Summary of the invention

[0005] In view of the limitations of the prior art, the present invention proposes a random task scheduling and resource allocation method in a MEC system of D2D collaborative computing. The technical solution adopted by the present invention is:

[0006] A random task scheduling and resource allocation method in a D2D collaborative computing MEC system includes the following steps:

[0007] S1, taking the average weighted sum of energy consumption of terminal devices and MEC servers as the optimization target, a heterogeneous MEC system model based on D2D collaborative computing is constructed;

[0008] S2, using the Lyapunov optimization method, converting the optimization problem involved in the heterogeneous MEC system model into sub-problems within each time slot;

[0009] S3, further decomposing the sub-problems into computing frequency control and computing resource allocation problems and offloading strategy and transmission power control problems;

[0010] S4, in each time slot, performing closed-form solutions to the computing frequency control and computing resource allocation problems, and alternately optimizing the offloading strategy and the transmission power control problem.

[0011] Compared with the prior art, the present invention introduces D2D collaborative computing, so that the computing tasks of edge devices can be offloaded not only to the server side, but also to nearby devices, thereby improving the flexibility of the system and the processing speed of tasks; by taking the average weighted energy consumption as the optimization performance indicator, the long-term performance of the system is improved and the stability of the system is enhanced; in addition, the online task offloading and resource management algorithm design based on the Lyapunov optimization algorithm of the present invention does not require the task arrival time and wireless channel fading prior conditions, and can make task and resource decisions in real time and effectively.

[0012] As a preferred solution, in the heterogeneous MEC system model, N terminal devices and a MEC server located at a base station are included, and the terminal device is represented as The MEC server contains a Z-core CPU, represented as Each terminal device includes a CPU and communicates with other terminal devices through a cellular network interface. Tasks that have arrived at the terminal device but have not been processed will be queued for processing. The queued tasks can be delivered to the MEC server or a nearby terminal device for processing in the form of task offloading via a D2D link.

[0013] The network represented by the heterogeneous MEC system model operates in a time slot manner, the length of the time slot is denoted as τ, the time slot index t∈1, 2, ..., T; all computing nodes in the network are denoted as It includes an MEC server and N terminal devices, with the index number recorded as 0; the network controller in the network has system global information, which includes the location of each terminal device and the backlog length of the queue of each terminal device; the network controller is used to connect, allocate resources and schedule tasks for each computing node. Each computing node can maintain cellular and D2D connections at the same time with the assistance of the network controller, and each time slot only allows data transmission on one link; the connection between each terminal device is represented by a node connection diagram It indicates that, d max Indicates the maximum distance over which D2D can communicate;

[0014] In the heterogeneous MEC system model, the tasks of the terminal device are allowed to be split in the form of computing bits, and are executed on the local computing nodes of the terminal device and the computing nodes near the terminal device according to the split results;

[0015] In the heterogeneous MEC system model, the variable x nm ∈{0, 1} indicates whether the terminal device n offloads the computing task to the terminal device m. When m=0, it means offloading to the MEC server. Each terminal can only serve as the transmitter or receiver of the offloading decision in a time slot. In time slot t, the offloading strategy is calculated. satisfy:

[0016]

[0017] Furthermore, the average weighted sum of energy consumption of the terminal device and the MEC server is expressed by the following formula:

[0018]

[0019] Among them, ω n and ω s Respectively represent the weights of the terminal device and MEC server in power consumption calculation; P n (t) represents the power consumed by terminal device n in time slot t, P s (t) represents the power consumption of MEC server.

[0020] Furthermore, the optimization problem It is expressed as follows:

[0021]

[0022]

[0023]

[0024]

[0025]

[0026]

[0027]

[0028]

[0029] in, Indicates the uninstallation strategy; Indicates computing frequency control and computing resource allocation strategy; Indicates the transmit power control strategy definition; Indicates the calculation frequency of the terminal device; Indicates the calculation frequency of the MEC server; Indicates the result of computing resource allocation; Indicates the transmit power decision of the terminal device on each communication link.

[0030] Furthermore, the sub-problem It is expressed as follows:

[0031]

[0032] Among them, Φ(t)={X(t), P(t), f d (t), f s (t), D s (t)};

[0033]

[0034] V≥0 is the control variable, and its unit is (bits 2 / W), which is used to control the tradeoff between power consumption and queue backlog.

[0035] Furthermore, the computing frequency control and computing resource allocation issues of terminal devices It is expressed as follows:

[0036]

[0037] Computing frequency control and computing resource allocation issues of MEC servers It is expressed as follows:

[0038]

[0039] Furthermore, for a specific computing frequency control and computing resource allocation strategy {f(t), f s (t), D s (t)}, in step S3, the question Decomposed into the following offloading strategy and transmit power control problem

[0040]

[0041] The present invention also provides the following contents:

[0042] A random task scheduling and resource allocation platform in a D2D collaborative computing MEC system includes a model building module, a Lyapunov optimization module, an optimization problem decomposition module, and an optimization problem solving module connected in sequence; wherein:

[0043] The model building module is used to build a heterogeneous MEC system model based on D2D collaborative computing by taking the average weighted sum of energy consumption of terminal devices and MEC servers as the optimization target;

[0044] The Lyapunov optimization module is used to convert the optimization problem involved in the heterogeneous MEC system model into a sub-problem within each time slot using the Lyapunov optimization method;

[0045] The optimization problem decomposition module is used to further decompose the sub-problems into computing frequency control and computing resource allocation problems and offloading strategy and transmission power control problems;

[0046] The optimization problem solving module is used to perform closed-form solutions to the computing frequency control and computing resource allocation problems in each time slot, and to alternately optimize the offloading strategy and the transmission power control problem.

[0047] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of the random task scheduling and resource allocation method in the MEC system of D2D collaborative computing as described above.

[0048] A computer device comprises a storage medium, a processor and a computer program stored in the storage medium and executable by the processor, wherein when the computer program is executed by the processor, the steps of the random task scheduling and resource allocation method in the MEC system of D2D collaborative computing are implemented as described above. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 A schematic diagram of the steps of a random task scheduling and resource allocation method in a MEC system for D2D collaborative computing provided by an embodiment of the present invention;

[0050] Figure 2 A heterogeneous MEC system model based on D2D collaborative computing provided by an embodiment of the present invention;

[0051] Figure 3 A general example of D2D-MEC with four terminal devices;

[0052] Figure 4 Based on solving the problem provided by the embodiment of the present invention Pseudo-code diagram of the uninstallation strategy and resource management algorithm;

[0053] Figure 5 The results of the comparison of cohort stability of different schemes are presented;

[0054] Figure 6 The average power consumption performance comparison results of different solutions are shown;

[0055] Figure 7 The average delay comparison results of different solutions are shown in Figure 2.

[0056] Figure 8 Performance comparison results for different numbers of devices;

[0057] Fig. 9 is parameter A max and ω s The impact of the value on system performance;

[0058] Fig.10 For different s Comparison of MEC power consumption and device power consumption when taking values;

[0059] Fig.11 A schematic diagram of a random task scheduling and resource allocation platform in a MEC system for D2D collaborative computing provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0060] The drawings are for illustrative purposes only and should not be construed as limiting the present patent;

[0061] It should be clear that the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the embodiments of the present application.

[0062] The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to limit the embodiments of the present application. The singular forms of "a", "said" and "the" used in the embodiments of the present application and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.

[0063] When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. On the contrary, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the attached claims. In the description of the present application, it should be understood that the terms "first", "second", "third", etc. are only used to distinguish similar objects, and do not have to be used to describe a specific order or sequence, nor can they be understood as indicating or implying relative importance. For those of ordinary skill in the art, the specific meanings of the above terms in the present application can be understood according to the specific circumstances.

[0064] In addition, in the description of this application, unless otherwise specified, "multiple" means two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. The present invention is further described below in conjunction with the accompanying drawings and embodiments.

[0065] In order to solve the limitations of the prior art, this embodiment provides a technical solution, and the technical solution of the present invention is further described below in conjunction with the drawings and embodiments.

[0066] Example 1

[0067] This embodiment aims at the task offloading and resource management problem of MEC system for D2D collaborative computing, and constructs a system model by taking the average weighted sum of energy consumption of terminal devices and MEC servers as the optimization target. For the random optimization problem to be solved in the system model, the problem is optimized into sub-problems within each time slot by citing the Lyapunov optimization method. Subsequently, in each time slot, the CPU frequency and computing resource allocation problem are solved in closed form, and at the same time, the transmission power and task scheduling decision are calculated by alternating optimization.

[0068] Please refer to Figure 1 , a random task scheduling and resource allocation method in a D2D collaborative computing MEC system, comprising the following steps:

[0069] S1, taking the average weighted sum of energy consumption of terminal devices and MEC servers as the optimization target, a heterogeneous MEC system model based on D2D collaborative computing is constructed;

[0070] S2, using the Lyapunov optimization method, converting the optimization problem involved in the heterogeneous MEC system model into sub-problems within each time slot;

[0071] S3, further decomposing the sub-problems into computing frequency control and computing resource allocation problems and offloading strategy and transmission power control problems;

[0072] S4, in each time slot, performing closed-form solutions to the computing frequency control and computing resource allocation problems, and alternately optimizing the offloading strategy and the transmission power control problem.

[0073] Compared with the prior art, the present invention introduces D2D collaborative computing, so that the computing tasks of edge devices can be offloaded not only to the server side, but also to nearby devices, thereby improving the flexibility of the system and the processing speed of tasks; by taking the average weighted energy consumption as the optimization performance indicator, the long-term performance of the system is improved and the stability of the system is enhanced; in addition, the online task offloading and resource management algorithm design based on the Lyapunov optimization algorithm of the present invention does not require the task arrival time and wireless channel fading prior conditions, and can make task and resource decisions in real time and effectively.

[0074] As a preferred embodiment, in the heterogeneous MEC system model, please refer to Figure 2 , including N terminal devices and a MEC server located at the base station, the terminal device is represented as The MEC server contains a Z-core CPU, represented as Each terminal device includes a CPU and communicates with other terminal devices through a cellular network interface. Tasks that have arrived at the terminal device but have not been processed will be queued for processing. The queued tasks can be delivered to the MEC server or a nearby terminal device for processing in the form of task offloading via a D2D link.

[0075] The network represented by the heterogeneous MEC system model operates in a time slot manner, the length of the time slot is denoted as τ, the time slot index t∈1, 2, ..., T; all computing nodes in the network are denoted as It includes an MEC server and N terminal devices, with the index number recorded as 0; the network controller in the network has system global information, which includes the location of each terminal device and the backlog length of the queue of each terminal device; the network controller is used to connect, allocate resources and schedule tasks for each computing node. Each computing node can maintain cellular and D2D connections at the same time with the assistance of the network controller, and each time slot only allows data transmission on one link; the connection between each terminal device is represented by a node connection diagram It indicates that, dmax represents the maximum distance over which D2D can communicate;

[0076] In the heterogeneous MEC system model, the tasks of the terminal device are allowed to be divided in the form of computing bits, and are executed on the local computing nodes of the terminal device and the computing nodes near the terminal device according to the segmentation results; the amount of computation initially arriving at the terminal n at time slot t is recorded as A n (t), which satisfies A n (t)≤A n,max The tasks in different time slots are independent and identically distributed, and their mean The amount of computation performed by local execution and offloading at the terminal n of time slot t is denoted as D n (t), the newly arrived task volume is denoted as K n (t), which includes the newly generated tasks locally and the tasks received from other devices, i.e., K n (t) = C n (t)+A n (t). Where, C n (t) represents the amount of tasks received by node n from other devices. The queue backlog length at the initial terminal n in time slot t is recorded as Q n (t), vector Q T (t)=[Q1(t),…,Q N (t)] represents the queue length of all terminals, and its value is updated over time as follows:

[0077] Q n (t+1)=max{Q n (t)-D n (t), 0}+K n (t). (1)

[0078] Similarly, the length of the backlog queue at the initial MEC server at time slot t is recorded as G T (t)=[G1(t),…,G N (t)], and its value is updated as follows:

[0079] G n (t+1)=max{G n (t)-D s,n (t), 0}+K s,n (t), (2)

[0080] Among them, D s,n (t) represents the amount of data from terminal n processed by the server in time slot t, and the amount of tasks unloaded from terminal n and stored in the task cache of the MEC server is denoted as K s,n (t).

[0081] At time slot t, the number of bits processed by the local CPU at terminal n is denoted as

[0082]

[0083] It is related to the CPU frequency f n This value is determined by the network controller at the base station side. n represents the number of CPU cycles required to execute one bit of computation. Correspondingly, the energy consumed by terminal n in time slot t is P n (t) = κ n (f n (t)) 3, (4)

[0084] Among them, κ n Represents the effective switching capacitance coefficient of the transistor, and its value is related to the CPU hardware architecture.

[0085] In the heterogeneous MEC system model, the variable x nm ∈{0, 1} indicates whether the terminal device n offloads the computing task to the terminal device m. When m=0, it means offloading to the MEC server. Each terminal can only serve as the transmitter or receiver of the offloading decision in a time slot. In time slot t, the offloading strategy is calculated. satisfy:

[0086]

[0087] Then the amount of computation that terminal n offloads to the MEC server through the cellular network at time slot t can be expressed as:

[0088]

[0089] Among them, B C represents the bandwidth used by frequency division multiple access; N0 is the noise power spectrum density at the base station side; p n0 (t) is the transmission power of terminal n; then K s,n (t) = x n0 (t)R n0 (t).

[0090] At the same time, the power consumption of the server is

[0091]

[0092] where f s,z (t) represents the computing frequency adopted by the zth processor of the MEC server in time slot t.

[0093] Similarly, the terminal can offload computing tasks to other terminal devices through the D2D link. Then the amount of tasks that terminal n can offload to terminal m in time slot t is

[0094]

[0095] Among them, B D represents the D2D link transmission bandwidth; p nm (t) represents the transmission power of terminal n; |h nm (t)| 2 is the D2D link channel gain. In addition, the amount of tasks it receives from other devices is

[0096]

[0097] In summary, the amount of computing tasks completed by terminal n in time slot t is

[0098]

[0099] It consists of three parts: local computing, D2D offloading based on D2D links, and task offloading based on MEC servers. Accordingly, the total power consumed is

[0100]

[0101] This technology uses the long-term average power consumption of the system as the performance indicator of the system, which is defined as the weighted sum of the power consumption of all devices and the power consumption of the MEC server in each time slot within T system time slots, which can be expressed as:

[0102]

[0103] Among them, ω n and ω s They respectively represent the weights of edge devices and servers in power consumption calculation, which can be used to adjust the power consumption ratio between the two.

[0104] In addition, the total delay of system calculation is proportional to the average task queue length in the system. While studying how devices can reduce power consumption through collaborative calculation, this technology also focuses on the trade-off between power consumption and delay in the system. The average calculation delay of the system is defined as the ratio of the time average of the backlog length of all cache queues in the system to the sum of the mean of random arrival of tasks, that is,

[0105]

[0106] Setting up and simplifying the power consumption minimization problem:

[0107] According to the above model, the uninstallation strategy is defined as The computation control and resource allocation strategy is defined as The transmit power control strategy is defined as in, The computing frequency of the edge device; is the calculation frequency of the MEC server; Indicates the result of computing resource allocation; Makes decisions on the device's transmit power on each communication link.

[0108] The optimization problem with the goal of minimizing the long-term average power consumption of the system can be defined as

[0109]

[0110]

[0111]

[0112]

[0113]

[0114]

[0115]

[0116]

[0117] Among them, formula (14a) constrains the feasible domain of the offloading strategy; formulas (14b) and (14c) represent the maximum transmission power limit and maximum computing frequency limit of the device respectively; is the upper limit of the transmission power of device n, f n,max The upper limit of the calculation frequency of device n; is the maximum computing frequency of the zth processor of the MEC server; Formula (14d) ensures that the sum of the allocated computing resources cannot exceed the total resources; Formulas (14e) and (14f) require that the queues of all computing nodes reach a stable average rate, thereby ensuring that all computing tasks can be completed within a limited time.

[0118] Since the offloading strategy in the above problem is an integer variable, and the randomness of the arrival of computing tasks and channel status in each time slot is taken into account, it is a random mixed integer nonlinear programming problem, which requires making decisions based on system status information in each time slot. At the same time, since the solution to the above problem consists of system decisions in consecutive time slots, there is a time correlation. This makes it difficult to solve the problem directly. In order to further optimize the solution to the above problem, this technology considers decomposing the random optimization problem with long-term constraints and time-averaged objective function into a deterministic problem in each time slice based on Lyapunov optimization theory, thereby decoupling the problem in the time domain and formulating online offloading decisions and resource management algorithms.

[0119] First, construct the corresponding Lyapunov function as

[0120]

[0121] Among them, Θ T (t) = [Q T (t), G T (t)]. Then the Lyapunov function shift is the time difference value of the above Lyapunov function, which can be written as

[0122]

[0123] The Lyapunov function offset reflects the change of the queue between adjacent time slots. Accordingly, according to the optimization goal, the mean of the weighted sum of system power consumption is used as the "penalty value", so that the Lyapunov function offset in each time slot plus the "penalty value" is defined as

[0124]

[0125] Among them, V≥0 is the control variable, and its unit is (bits 2 / W), which is used to control the tradeoff between power consumption and latency (queue backlog).

[0126] It can be proved that based on Lyapunov optimization theory, the random optimization problem can be It is transformed into minimizing the upper bound of the Lyapunov function offset superposition "penalty value" function in each time slot. Then the optimization problem is Convertible to

[0127]

[0128] Among them, Φ(t)={X(t), P(t), f d (t), f s (t), D s (t)}. Based on the observed channel state information and queue length, the network controller can solve the problem Determine task scheduling and resource allocation strategies.

[0129] The above objective function is defined as

[0130]

[0131] Unloading strategy and resource management algorithm design:

[0132] In the above formula, F1(f d (t), f s (t), D s (t)) is only related to the calculation frequency control and resource allocation, while F2(X(t), P(t)) is only related to the offloading strategy and transmit power control. Therefore, the problem It can be further decomposed into computing frequency control and resource allocation problems As well as offloading strategies and transmit power control issues Among them, the calculation frequency control and resource allocation problems Defined as

[0133]

[0134] Since the device's calculation frequency is only related to the local cache queue backlog length, the problem Can be further decomposed into

[0135]

[0136] Obviously, is a convex problem, and its corresponding optimal solution is the equation Or the boundary value in constraint (e), that is

[0137]

[0138] It can be seen from the above formula that the optimal calculation frequency of terminal n in time slot t is With Q n (t) increases, because the device needs to increase the computing frequency to speed up the processing of tasks in order to shorten the local task cache queue. With V and ω n Increase and decrease: The increase of V corresponds to the problem The "penalty term" in the objective function increases, that is, the focus is on reducing the power consumption of the device, so the calculation frequency should be reduced; ω n The increase of indicates that the weight of device n in the average power consumption increases, so its calculation frequency should be reduced to reduce the weighted sum of the power consumption of all devices.

[0139] Similarly, the computing frequency control and resource allocation problem of MEC servers can be expressed as

[0140]

[0141] This problem is a convex optimization problem and can be solved using a convex optimization algorithm. However, in order to reduce the complexity of the algorithm, the closed-form solution of the computational frequency and resource allocation can be obtained by using the characteristics of the solution:

[0142]

[0143] Substitute the above formula into the optimization problem In the above equation, the computation frequency control problem of MEC server can be decomposed into Z sub-problems, where The value of The stationary point or boundary point of constraint f, that is,

[0144]

[0145] From the above formula, we can see that: when ω s = 0, the MEC server maintains the maximum computing frequency to speed up the processing of offloaded tasks; and when ω s >0, the calculation frequency increases with G n′ (t) increases, and as ω s decreases with the increase of .

[0146] For a specific computing frequency control and resource allocation strategy {f(t), f s (t), D s (t)}, optimization problem It can be transformed into an optimization problem of unloading strategy and power control Right now

[0147]

[0148] Since X(t) is an integer variable, It is a mixed integer nonlinear programming problem. We further consider separating integer variables from continuous variables, and alternately optimizing the calculation of the offloading strategy X(t) and the transmit power allocation strategy P(t). Among them, the optimal transmit power is solved by closed form, and the optimal task scheduling strategy is solved by the graph matching algorithm. First, fix the offloading strategy X(t), then the optimal transmit power P(t) of the terminal device can be obtained by solving the following sub-problems:

[0149]

[0150] This problem is a convex problem, and the optimal solution for the transmission power is The closed-form solution of the optimal transmit power of the device on the D2D and cellular links is

[0151]

[0152] Secondly, when the power control strategy P(t) is fixed, consider optimizing the unloading strategy X(t). At this time, the optimization problem Can be simplified to

[0153]

[0154] in,

[0155]

[0156] For fixed When Θ(t) is known, we can nm (t) is calculated and solved, therefore, It is a joint optimization problem. Let y (n,m) (t) = x nm (t)+x mn (t), where n, And n≠m, then y (n,m) (t)≤1, Rewriting

[0157]

[0158] The above problem can be regarded as a minimum weight matching problem of a general graph, where computing nodes are understood as nodes of the "graph"; and the offloading relationship between nodes is regarded as the edge in the "graph"; in addition, the virtual machine of the MEC server can be regarded as a virtual node, represented as a set The set of edges in the graph can be represented as Construction diagram in The weight of each edge can be determined as

[0159]

[0160] For example, when the system contains four edge devices, the general graph constructed and the connection relationship between nodes are as shown in the attached figure. Figure 3 shown.

[0161] After completing the construction of the general graph according to the above method, the optimization problem It is converted into the minimum edge weight matching problem of the graph. By solving the optimal matching edge, the computational offloading strategy X can be obtained. * (t). The present invention uses Edmond's blossom algorithm

[21] Solve and get the minimum weight matching, recorded as Afterwards, the optimal task scheduling decision can be obtained by And solve the following equation.

[0162]

[0163] Find X * (t), fix its value and update the device transmit power P(t). According to the updated transmit power, adjust the weight of the graph and match it again. Continue to optimize alternately until convergence is achieved to obtain the final calculation offloading strategy and transmit power allocation strategy.

[0164] Specifically, based on solving the problem The uninstallation strategy and resource management algorithm can be summarized as Algorithm 1. The pseudo code can be found in Figure 4 The specific implementation process of the algorithm in each time slot is as follows:

[0165] (1) Observe the queue length Θ(t) and channel status H(t) of the terminal and server.

[0166] (2) According to formulas (22), (24) and (25), f is calculated * (t),

[0167] (3) Initialize the transmit power P and task scheduling decision X;

[0168] (4) Alternately optimize P and X until convergence conditions are reached, where the task scheduling decision X is recovered by Edmond's blossom and formula (33); the transmit power is calculated by formula (28) and a fixed X.

[0169] (5) Output the final f * (t), P * (t);

[0170] More specifically, Figure 5 The paper describes the comparison of the average length of the cache queue backlog in the system using the D2D-MEC method proposed in the present invention and three unloading strategies: local computing, random unloading, and centralized MEC unloading, within 3000 simulation time slots. It can be seen that the method proposed in the present invention converges faster, the final queue length is shorter, and the cached computing tasks can be processed more timely.

[0171] Figure 6 The average power consumption of the D2D-MEC offloading strategy proposed in the present invention and the other three offloading strategies in the simulation is compared. It can be seen that as the control parameter V increases, the power consumption of this method is reduced faster, and the average power consumption is lower than that of other methods, which can effectively reduce the power consumption of the system.

[0172] Figure 7 The average calculation delay of the D2D-MEC offloading strategy proposed in this invention and the other three offloading strategies in simulation is compared. It can be seen that the average delay of each scheme increases with the increase of the control parameter V, but the average calculation delay of the algorithm proposed in this invention is lower than that of other benchmark methods, and the larger the V, the more obvious the difference, which can effectively reduce the average delay of the system and improve the system efficiency.

[0173] Figure 8-10 The relationships between the performance of the algorithm proposed in the present invention and parameters such as the number of devices and control variables are studied respectively, and the flexibility and scalability of the algorithm proposed in the present invention are explained from different angles.

[0174] Example 2

[0175] See also Fig.11 , a random task scheduling and resource allocation platform in a D2D collaborative computing MEC system, comprising a model building module 1, a Lyapunov optimization module 2, an optimization problem decomposition module 3 and an optimization problem solving module 4 connected in sequence; wherein:

[0176] The model building module 1 is used to build a heterogeneous MEC system model based on D2D collaborative computing by taking the average weighted sum of energy consumption of terminal devices and MEC servers as the optimization target;

[0177] The Lyapunov optimization module 2 is used to convert the optimization problem involved in the heterogeneous MEC system model into a sub-problem within each time slot using the Lyapunov optimization method;

[0178] The optimization problem decomposition module 3 is used to further decompose the sub-problems into computing frequency control and computing resource allocation problems and offloading strategy and transmission power control problems;

[0179] The optimization problem solving module 4 is used to perform closed-form solutions to the computing frequency control and computing resource allocation problems in each time slot, and to alternately optimize the offloading strategy and the transmission power control problem.

[0180] Example 3

[0181] A computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the steps of the random task scheduling and resource allocation method in the MEC system of D2D collaborative computing as described in Example 1 are implemented.

[0182] Example 4

[0183] A computer device comprises a storage medium, a processor, and a computer program stored in the storage medium and executable by the processor, wherein when the computer program is executed by the processor, the steps of the random task scheduling and resource allocation method in the MEC system of D2D collaborative computing as described in Example 1 are implemented.

[0184] Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not intended to limit the embodiments of the present invention. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the embodiments here. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the claims of the present invention.

Claims

1. A random task scheduling and resource allocation method in a MEC system for D2D collaborative computing, characterized in that: The following steps are involved: S1, taking the average weighted sum of energy consumption of terminal devices and MEC servers as the optimization target, a heterogeneous MEC system model based on D2D collaborative computing is constructed; wherein, in the heterogeneous MEC system model, there are N terminal devices and a MEC server located at a base station, and the terminal device is represented as The MEC server contains a Z-core CPU, represented as Each terminal device includes a CPU and communicates with other terminal devices through a cellular network interface; tasks that have arrived at the terminal device but have not been processed will be queued for processing; tasks in the queue can be delivered to the MEC server or a nearby terminal device for processing in the form of task offloading via a D2D link; and, The network represented by the heterogeneous MEC system model operates in a time slot manner, the length of the time slot is denoted as τ, and the time slot index t∈1,2,…,T; all computing nodes in the network are denoted as It includes an MEC server and N terminal devices, with the index number recorded as 0; the network controller in the network has system global information, which includes the location of each terminal device and the backlog length of the queue of each terminal device; the network controller is used to connect, allocate resources and schedule tasks for each computing node. Each computing node can maintain cellular and D2D connections at the same time with the assistance of the network controller, and each time slot only allows data transmission on one link; the connection between each terminal device is represented by a node connection diagram It indicates that, d max Indicates the maximum distance over which D2D can communicate; S2, using the Lyapunov optimization method, converting the optimization problem involved in the heterogeneous MEC system model into sub-problems within each time slot; wherein the optimization problem It is expressed as follows: in, Indicates the uninstallation strategy; Indicates computing frequency control and computing resource allocation strategy; Indicates the transmit power control strategy definition; Indicates the calculation frequency of the terminal device; Indicates the calculation frequency of the MEC server; Indicates the result of computing resource allocation; represents the transmit power decision of the terminal device on each communication link; and, The sub-problem It is expressed as follows: where, Φ(t) = {X(t), P(t), f d (t), f s (t), D s (t)}; V≥0 is the control variable, and its unit is (bits 2 / W), used to control the tradeoff between power consumption and queue backlog; S3, further decomposing the sub-problems into computing frequency control and computing resource allocation problems and offloading strategy and transmission power control problems; S4, in each time slot, performing closed-form solutions to the computing frequency control and computing resource allocation problems, and alternately optimizing the offloading strategy and the transmission power control problem.

2. The random task scheduling and resource allocation method in the MEC system of D2D collaborative computing according to claim 1 is characterized in that: In the heterogeneous MEC system model, the tasks of the terminal device are allowed to be split in the form of computing bits, and are executed on the local computing nodes of the terminal device and the computing nodes near the terminal device according to the split results; In the heterogeneous MEC system model, the variable x nm ∈{0,1} indicates whether the terminal device n offloads the computing task to the terminal device m. When m=0, it means offloading to the MEC server. Each terminal can only serve as the transmitter or receiver of the offloading decision in a time slot. In time slot t, the offloading strategy is calculated. satisfy:

3. The random task scheduling and resource allocation method in the MEC system of D2D collaborative computing according to claim 2 is characterized in that: The average weighted sum of energy consumption of the terminal device and the MEC server is expressed as follows: Among them, ω n and ω s Respectively represent the weights of the terminal device and MEC server in power consumption calculation; P n (t) represents the power consumed by terminal device n in time slot t, P s (t) represents the power consumption of MEC server.

4. The random task scheduling and resource allocation method in the MEC system of D2D collaborative computing according to claim 3 is characterized in that: Computing frequency control and computing resource allocation issues of terminal equipment It is expressed as follows: Computing frequency control and computing resource allocation issues of MEC servers It is expressed as follows:

5. The random task scheduling and resource allocation method in the MEC system of D2D collaborative computing according to claim 3 is characterized in that: For the computing frequency control and computing resource allocation strategy {f(t),f s (t),D s (t)}, in step S3, the question Decomposed into the following offloading strategy and transmit power control problem 6. A random task scheduling and resource allocation platform in a D2D collaborative computing MEC system, characterized in that: The method comprises a model building module (1), a Lyapunov optimization module (2), an optimization problem decomposition module (3) and an optimization problem solving module (4) which are connected in sequence; wherein: The model building module (1) is used to build a heterogeneous MEC system model based on D2D collaborative computing by taking the average weighted sum of energy consumption of terminal devices and MEC servers as an optimization target; wherein, in the heterogeneous MEC system model, N terminal devices and a MEC server located at a base station are included, and the terminal devices are represented as The MEC server contains a Z-core CPU, represented as Each terminal device includes a CPU and communicates with other terminal devices through a cellular network interface; tasks that have arrived at the terminal device but have not been processed will be queued for processing; tasks in the queue can be delivered to the MEC server or a nearby terminal device for processing in the form of task offloading via a D2D link; and, The network represented by the heterogeneous MEC system model operates in a time slot manner, the length of the time slot is denoted as τ, and the time slot index t∈1,2,…,T; all computing nodes in the network are denoted as It includes an MEC server and N terminal devices, with the index number recorded as 0; the network controller in the network has system global information, which includes the location of each terminal device and the backlog length of the queue of each terminal device; the network controller is used to connect, allocate resources and schedule tasks for each computing node. Each computing node can maintain cellular and D2D connections at the same time with the assistance of the network controller, and each time slot only allows data transmission on one link; the connection between each terminal device is represented by a node connection diagram It indicates that, d max Indicates the maximum distance over which D2D can communicate; The Lyapunov optimization module (2) is used to convert the optimization problem involved in the heterogeneous MEC system model into a sub-problem within each time slot by using the Lyapunov optimization method; wherein the optimization problem It is expressed as follows: in, Indicates the uninstallation strategy; Indicates computing frequency control and computing resource allocation strategy; Indicates the transmit power control strategy definition; Indicates the calculation frequency of the terminal device; Indicates the calculation frequency of the MEC server; Indicates the result of computing resource allocation; represents the transmit power decision of the terminal device on each communication link; and, The sub-problem It is expressed as follows: where, Φ(t) = {X(t), P(t), f d (t), f s (t), D s (t)}; V≥0 is the control variable, and its unit is (bits 2 / W), used to control the tradeoff between power consumption and queue backlog; The optimization problem decomposition module (3) is used to further decompose the sub-problems into computing frequency control and computing resource allocation problems and offloading strategy and transmission power control problems; The optimization problem solving module (4) is used to perform closed-form solutions to the computing frequency control and computing resource allocation problems in each time slot, and to alternately optimize the unloading strategy and the transmission power control problem.

7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the random task scheduling and resource allocation method in the MEC system of D2D collaborative computing are implemented as described in any one of claims 1 to 5.

8. A computer device, characterized in that: The invention comprises a storage medium, a processor and a computer program stored in the storage medium and executable by the processor, wherein when the computer program is executed by the processor, the steps of the random task scheduling and resource allocation method in the MEC system of D2D collaborative computing are implemented as described in any one of claims 1 to 5.