Disclosure of Invention
In view of the above, the present invention provides a mutual exclusion method in advertisement ranking, which uses programmed automatic ranking to replace manual ranking, and solves the direct mutual exclusion of different orders and the average problem of the same order in a playing cycle, so as to solve the deficiencies in the prior art.
In order to achieve the purpose, the invention is realized by the following technical scheme:
the method for mutual exclusion in advertisement ranking is applied to a plurality of orders, and comprises the following steps:
s1, defining the value range of the duration and the frequency in each order;
s2, solving the loop playing times:
solving the value of how many times each order is to be played in a cycle by using the greatest common divisor according to the frequency information;
s3, solving an optimal playing sequence;
s4, defining judgment criteria of uniform distribution of orders in the cycle:
the smaller the sum of standard deviations of the order sorting intervals in the cycle is, the more uniform the sorting frequency distribution is;
and S5, solving the optimal piece arrangement mode for the order uniform distribution in the loop based on the S4.
In the mutual exclusion method in the advertisement ranking, in S3, weights of different mutual exclusion information between orders are defined, and the orders to be played in a loop are combined into a two-dimensional weight matrix; and solving the optimal playing sequence by adopting a TSP mode.
In the mutual exclusion method in the advertisement ranking, in S5, an optimal solution of a two-dimensional weight matrix is obtained, and a sum of order interval standard deviations of each solution is given; and circulating N times to find an optimal solution with the minimum path and standard deviation.
The technical scheme of the invention has the beneficial effects that:
replacing manual and manual sheet arrangement with programmed automatic sheet arrangement, labor cost can be saved, and efficiency is higher;
manually defining mutually exclusive weights between different advertisements, making the way of ordering advertisements more flexible.
Detailed Description
The invention is further described with reference to the following drawings and specific examples, which are not intended to be limiting.
Referring to fig. 1, the mutual exclusion method in advertisement ranking according to the present invention is applied to a plurality of orders, and comprises the following steps:
and S1, defining the value range of the duration and the frequency in each order.
Assuming n orders in total, the first order is a1 b1(a1 is duration in seconds, b1 is how many times per day to play), and so on, the nth order is an bn. b1, b2, …, bn, all must be multiples of 50; a1 b1+ a2 b2+ … + an bn is less than or equal to 18h 60min 60s (the working time of the general screen is 6:00am-12: pm, and the working time is 18 hours).
S2, solving the loop playing times: and solving the value of how many times each order is to be played in a cycle by using the greatest common divisor according to the frequency information.
And (5) calculating the greatest common divisor x of the frequencies b1, b2, … and bn. And c1, c2, and cn is obtained by dividing b1, b2, … and bn by the greatest common divisor x. The total number of orders in a cycle is c1+ c2+ … + cn, the duration of a cycle is a1 × c1+ a2 × c2+ … + an × cn, and the unit is seconds, that is, the first order plays c1 times in a cycle, and the nth order plays cn times in the nth cycle.
And S3, solving the optimal playing sequence.
In the preferred embodiment, in S3, defining weights of different mutual exclusion information between orders, and forming a two-dimensional weight matrix for orders to be played in a loop; and solving the optimal playing sequence by adopting a TSP mode.
For example, there are four orders, and in a loop, the first order (d1) should be played 1 time, the second (d2)2 times, the third (d3)3 times, and the fourth (d4)2 times, that is, the total number of times of playing the advertisement in the loop is 8 times, so as to arrange the order of the four orders, the following conditions should be satisfied at the same time:
-the first order and the second order are mutually exclusive;
-the second order and the third mutually exclusive;
within a cycle, orders that do not need to be taken together are preferably not put together;
the frequency-averaged distribution of each order is preferably done in a loop.
The problem is the typical TSP problem (traveler problem), which means that a traveler is to travel n cities, requiring each city to go through and only go once and then back to the departure city, and requiring the shortest distance to be traveled. It is obvious that the mutual exclusion information between orders can be regarded as distance information between cities. We can use the TSP solution as long as we define the weights of different mutual exclusion information. However, this method has a disadvantage of not solving the problem of frequent even distribution of the same order in one cycle.
S4, defining judgment criteria of uniform distribution of orders in the cycle: the smaller the sum of the standard deviations of the order sorting intervals within the cycle, the more uniform such sorting frequency distribution.
For example, there is now a group of orders, with two sorts d1d2d1d2 and d1d2d2d1, with a total order number of 4. In the first sort the d1 orders have an interval of 2,2 with a standard deviation of 0, an interval of 2,2 with a d2 with a standard deviation of 0 and a sum of the total standard deviations of 0; in the second ordering, the spacing of d1 is 3,1, the standard deviation is 1, the spacing of d2 is 1,3, the standard deviation is 1, and the total standard deviation is 2.
The total standard deviation of the first sort is smaller, so the frequency distribution of the first sort is more uniform.
And S5, solving the optimal piece arrangement mode for the order uniform distribution in the loop based on the S4.
In S5, obtaining an optimal solution of the two-dimensional weight matrix, and giving the sum of the order interval standard deviations of each solution; and circulating N times to find an optimal solution with the minimum path and standard deviation.
According to the invention, manual and manual film arrangement is replaced by programmed automatic film arrangement, so that the labor cost can be saved, and the efficiency is higher; manually defining mutually exclusive weights among different advertisements, so that the advertisement sequencing mode is more flexible.
While the invention has been described with reference to a preferred embodiment, it will be understood by those skilled in the art that various changes in form and detail may be made therein without departing from the spirit and scope of the invention.