Bus operation scheduling method, scheduling system and storage medium
By optimizing bus operation scheduling using greedy and genetic algorithms, initial and target timetables for multiple routes are generated, solving the problem of low bus utilization and improving the operational efficiency of electric buses.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHENZHEN RES INST OF BIG DATA
- Filing Date
- 2022-08-29
- Publication Date
- 2026-04-17
AI Technical Summary
In the current technology, the utilization rate of buses is low, especially for electric buses, which are often idle and neither in operation nor being charged, resulting in unreasonable timetable arrangements.
The operation and scheduling of buses are optimized by using greedy algorithms and genetic algorithms. Initial operation maps and target timetables for multiple routes are generated, and the difference between the standard number of buses and the configured number of buses is taken into account to optimize the operation arrangement of buses.
It has improved the utilization rate of buses, especially the operating efficiency of electric buses, reduced idle time, and improved the overall operational efficiency.
Smart Images

Figure CN115423285B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of public transportation dispatch data processing, and in particular to a method, system and storage medium for dispatching public transportation. Background Technology
[0002] With the continuous development of urban public transportation, buses are a type of ground transportation equipment in urban public transportation. Bus timetables have different routes, and different routes often have different operating hours. Moreover, the demand for buses on the same route varies at different times, so the corresponding demand for buses varies. In related technologies, when arranging the operation of buses, the same bus is only assigned to operate one route. In the operation of urban public transportation, the utilization rate of buses is low, especially for electric buses. In the timetables arranged in the above way, there will be idle buses that are neither operating nor charging, resulting in low utilization of buses in the timetable arrangement. Summary of the Invention
[0003] This invention aims to at least solve one of the technical problems existing in the prior art. To this end, this invention provides a bus operation scheduling method, scheduling system, and storage medium, which can effectively improve bus utilization by planning bus operation schedules that execute multiple routes.
[0004] A first aspect of the present invention provides a method for scheduling the operation of buses, comprising:
[0005] Obtain the running data for each original route;
[0006] Based on operational data, determine the standard number of buses between two terminal stations within multiple preset standard time periods;
[0007] The greedy algorithm is used to schedule and plan the number of buses in each standard time period to obtain multiple initial operation maps. An initial timetable is generated based on the initial operation maps. In each initial operation map, there is one overlapping terminal station between two adjacent original routes.
[0008] The number of buses in each initial timetable is initialized, and the target timetable is obtained by performing genetic iteration on the initial timetable using a genetic algorithm, with the convergence of the difference between the number of buses in the initial timetable and the standard number of buses as the condition.
[0009] According to the above embodiments of the present invention, at least the following beneficial effects are achieved: by dividing the running time into multiple standard time periods, the demand for buses in a single standard time period can be calculated based on the original route's running data, which is the standard number of buses. An initial timetable is generated by a greedy algorithm guided by the standard number of buses, and then a target timetable is obtained by a genetic algorithm guided by the difference between the number of buses and the standard number of buses. By first generating the initial timetable with a greedy algorithm and then converging the target timetable through the genetic algorithm during the iteration process, the convergence effect of the final target timetable can be effectively improved, thereby effectively improving the utilization rate of buses.
[0010] According to some embodiments of the first aspect of the present invention, the operational data includes one-way time, originating station, and destination station;
[0011] A greedy algorithm is used to schedule and plan the standard number of buses in each standard time period, resulting in multiple initial operation diagrams, including:
[0012] The starting and ending stations of an unplanned original route are used as the first and second stations of the initial operating plan, respectively.
[0013] Using the second station as the base station, within the standard time period corresponding to the arrival time of the base station, the terminal station of the original route with the largest number of bus standards that has not been planned is selected as the third station of the initial operation map.
[0014] Using the third station as the base station, the initial operating schedule is planned again until the last station of the initial operating schedule does not match the starting station of the original route that was not planned or the planning time of the initial operating schedule exceeds the operating time, thus obtaining the planned initial operating schedule.
[0015] Plan all unplanned original routes to obtain multiple planned initial operation maps.
[0016] According to some embodiments of the first aspect of the present invention, before obtaining the planned initial running chart, the method further includes:
[0017] Determine whether the initial running graph meets the preset constraints;
[0018] If the constraints are not met, the initial running graph is replanned.
[0019] According to some embodiments of the first aspect of the present invention, the constraints include:
[0020]
[0021]
[0022]
[0023]
[0024] in, τ(j,i,t) represents the time it takes for a bus to travel from terminal station j to terminal station i within a standard time period t. A value of 1 indicates that bus k uses terminal station j as its final destination and uses terminal station i as its starting point within the standard time period t. A value of 0 indicates other cases. A value of 1 indicates that bus k stopped at the terminal station i within the time period t. A value of 0 indicates other cases, s ijt This represents the number of buses missing from terminal station i to terminal station j within a standard time period t. ijt f represents the excess number of buses traveling from terminal station i to terminal station j within a standard time period t. ijt Let T represent the standard number of buses, T represent the standard time period set, and K represent the set of buses.
[0025] According to some embodiments of the first aspect of the present invention, the operational data also includes the maximum and minimum demand values for the number of buses in different time periods, and the standard number of buses is obtained by taking the average of the sum of the maximum and minimum demand values in the corresponding standard time period.
[0026] According to some embodiments of the first aspect of the present invention, a target timetable is obtained by performing genetic iteration on an initial timetable using a genetic algorithm, assuming the convergence of the difference between the number of buses allocated and the standard number of buses, including:
[0027] Using the objective function as the convergence criterion, a genetic algorithm iterates through the initial running graph in the initial timetable to obtain the target timetable, where the objective function is... This represents the penalty coefficient for the absence of a bus from terminal station i to terminal station j within a standard time period t. s represents the penalty coefficient for excess buses traveling from terminal station i to terminal station j within a standard time period t. ijt This represents the number of buses missing from terminal station i to terminal station j within a standard time period t. ijt This represents the excess number of buses traveling from terminal station i to terminal station j within a standard time period t, where T represents the set of standard time periods.
[0028] According to some embodiments of the first aspect of the present invention, a target timetable is obtained by performing genetic iteration based on an initial running graph in an initial timetable using a genetic algorithm, including:
[0029] Use the initial timetable as the input timetable;
[0030] Divide the multiple initial run charts in the input timetable into multiple pairs of run chart groups;
[0031] Transform each running graph group to obtain multiple corresponding transformed graph groups;
[0032] The number of bus configurations is configured for the running map group and the transformed map group using a local search algorithm, and the output timetable is obtained by matching the objective function.
[0033] Using the genetic iteration of the output timetable as the input timetable, the output timetable corresponding to the convergence of the objective function to the minimum value is obtained as the target timetable.
[0034] According to some embodiments of the first aspect of the present invention, transforming each running graph group to obtain a corresponding plurality of transformed graph groups includes:
[0035] By using insertion operators, elimination operators, exchange operators, or movement operators to transform each running graph group, multiple corresponding transformed graph groups are obtained.
[0036] A second aspect of the present invention provides a bus operation scheduling system, comprising:
[0037] The data acquisition module acquires the operational data for each original route;
[0038] The preprocessing module determines the standard number of buses between two terminal stations within multiple preset standard time periods based on the operating data.
[0039] The initial timetable generation module uses a greedy algorithm to schedule and plan the corresponding number of buses in each standard time period, resulting in multiple initial operation maps. Based on the initial operation maps, an initial timetable is generated. In each initial operation map, there is one overlapping terminal station between two adjacent original routes.
[0040] The output module is optimized to initialize the number of buses in each initial timetable of the initial timetable. The target timetable is obtained by performing genetic iteration on the initial timetable using a genetic algorithm, with the convergence of the difference between the number of buses in the initial timetable and the standard number of buses as the condition.
[0041] According to the above embodiments of the present invention, at least the following beneficial effects are achieved: by dividing the running time into multiple standard time periods, the demand for buses in a single standard time period can be calculated based on the original route's running data, which is the standard number of buses. An initial timetable is generated by a greedy algorithm guided by the standard number of buses, and then a target timetable is obtained by a genetic algorithm guided by the difference between the number of buses and the standard number of buses. By first generating the initial timetable with a greedy algorithm and then converging the target timetable through the genetic algorithm during the iteration process, the convergence effect of the final target timetable can be effectively improved, thereby effectively improving the utilization rate of buses.
[0042] According to a third aspect of the present invention, a computer storage medium is provided, which stores computer-executable instructions for executing the bus operation scheduling method of any one of the first aspects.
[0043] Since the computer storage medium of the third aspect embodiment can execute the bus operation scheduling method of any one of the first aspects, it has all the beneficial effects of the first aspect of the present invention.
[0044] Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description
[0045] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which:
[0046] Figure 1 This is a schematic diagram of the main steps of the bus operation scheduling method according to an embodiment of the present invention;
[0047] Figure 2 yes Figure 1 A schematic diagram illustrating the specific steps of step S300;
[0048] Figure 3 yes Figure 1 A schematic diagram illustrating the specific steps of step S400;
[0049] Figure 4 yes Figure 3 A schematic diagram illustrating the specific steps of step S410;
[0050] Figure 5 yes Figure 3 A schematic diagram illustrating the specific steps of step S420;
[0051] Figure 6 This is a schematic diagram of the operation diagram in this invention;
[0052] Figure 7 This is a schematic diagram of the planning process of the bus operation scheduling method according to an embodiment of the present invention;
[0053] Figure 8 This is a schematic diagram of the genetic algorithm processing in the bus operation scheduling method of this invention.
[0054] Figure 9 This is a schematic diagram of the transformation process of the operation map group in the bus operation scheduling method of this invention. Detailed Implementation
[0055] In the description of this invention, unless otherwise explicitly defined, terms such as "setting," "installing," and "connecting" should be interpreted broadly. Those skilled in the art can reasonably determine the specific meaning of these terms in this invention based on the specific content of the technical solution. In the description of this invention, "several" means one or more, "multiple" means two or more, "greater than," "less than," and "exceeding" are understood to exclude the stated number, while "above," "below," and "within" are understood to include the stated number. Furthermore, features specified as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this invention, unless otherwise stated, "multiple" means two or more.
[0056] With the continuous development of urban public transportation, buses are a type of ground transportation equipment in urban public transportation. Bus timetables have different routes, and different routes often have different operating hours. Moreover, the demand for buses on the same route varies at different times, resulting in different demand for the corresponding number of buses. To improve the efficiency of bus operation, many cities have built hub stations capable of refueling. In these hub stations, fuel-powered buses can be refueled, and electric buses can be recharged. Furthermore, these hub stations often serve as the starting point for multiple original routes.
[0057] In order to adapt to the sustainable development concept of energy conservation and emission reduction, electric vehicles have gradually become a means of transportation for people. However, due to the limitations of battery technology, electric vehicles often require more charging time than fuel vehicles, and their range is also limited. In the planning of urban public transportation, the charging time of electric buses needs to be taken into account as a factor in the scheduling of bus timetables.
[0058] In related technologies, when scheduling bus operations, the same bus is only assigned to one route. This results in low bus utilization in urban public transportation, especially for electric buses. In the timetables obtained through this method, there will be buses that are neither in operation nor being charged, leading to low bus utilization due to the timetable arrangement.
[0059] Therefore, in order to improve the utilization rate of buses and reduce the duplication rate of buses on the original routes and the number of out-of-cover departure times, the operational efficiency of buses can be improved by implementing different original routes for the same bus.
[0060] The following reference Figures 1 to 9 This invention describes a bus operation scheduling method, scheduling system, and storage medium. By planning a bus operation schedule that executes multiple routes, the utilization rate of buses can be effectively improved.
[0061] refer to Figure 1As shown, a first aspect of the present invention provides a method for scheduling the operation of a bus, including but not limited to the following steps:
[0062] S100: Obtain the running data for each original route;
[0063] S200: Based on the operation data, determine the standard number of buses between two terminal stations within multiple preset standard time periods. The standard time is obtained by dividing the operation time of the original timetable equally. The standard time periods are continuous in natural time. The standard number of buses represents the number of buses required within the standard time period.
[0064] S300: The greedy algorithm is used to schedule and plan the number of buses in each standard time period to obtain multiple initial operation maps. An initial timetable is generated based on the initial operation map. In each initial operation map, there is an overlapping terminal station between two adjacent original routes.
[0065] S400: Initialize the number of buses in each initial timetable of the initial timetable, and obtain the target timetable by performing genetic iteration on the initial timetable through a genetic algorithm, based on the convergence of the difference between the number of buses in the initial timetable and the standard number of buses. The target timetable includes multiple target timetables.
[0066] By dividing the original timetable's running time into multiple standard time periods, the demand for buses in a single standard time period can be calculated based on the original route's running data. This is known as the standard number of buses. An initial timetable is generated using a greedy algorithm guided by the standard number of buses. Then, a target timetable is obtained by using a genetic algorithm guided by the difference between the number of buses allocated and the standard number of buses. By first generating the initial timetable using a greedy algorithm and then using a genetic algorithm to converge the target timetable during the iteration process, the convergence effect of the final target timetable can be effectively improved, thereby effectively improving the utilization rate of buses.
[0067] Especially when applied to electric buses, without considering the battery life of the electric bus and the location of charging stations, the target operation map obtained by this application, combined with the charging time, can effectively improve the operating efficiency of electric buses. Since this invention plans based on the original route, it improves efficiency by optimizing the number of buses running on each route at each time.
[0068] Understandably, the operational data includes one-way time, originating station, and destination station;
[0069] In step S300, refer to Figure 2As shown, a greedy algorithm is used to schedule and plan the standard number of buses in each standard time period, resulting in multiple initial operation diagrams, including but not limited to the following steps:
[0070] S310: The starting and ending stations of an unplanned original route are used as the first and second stations of the initial operating schedule, respectively.
[0071] S320: Using the second station as the base station, within the standard time period corresponding to the arrival time of the base station, the terminal station of the original route with the largest number of bus standards that has not been planned is matched as the third station of the initial operation map.
[0072] S330: Using the third station as the base station, continue to plan the initial timetable until the last station of the initial timetable does not match the starting station of the unplanned original route or the planned time of the initial timetable exceeds the running time, and obtain the planned initial timetable. Here, the running time refers to the total time span of the bus trips arranged in the original timetable.
[0073] S340: Repeat steps S310 to S330 to plan all unplanned original routes and obtain multiple planned initial running maps.
[0074] It should be noted that steps S310 to S340 above can also be understood as follows: taking the unplanned original routes in the preset standard time period where the starting point of the one-way trip time is located as the base route segment, and taking the terminal station of the base route segment as the base station, in the standard time period where the end point of the one-way trip time of the base route segment is located, the original route with the most bus standards and which is not planned is calculated by a greedy algorithm as the planned route segment; using the planned route segment as the base route segment, until the end point of the one-way trip time of the base route segment is greater than the end point of the running time, or the base station does not match the starting station of other original routes, an initial operation map is generated based on all the base route segments and planned route segments; repeating the above two steps to generate multiple initial operation maps for the corresponding original routes in each standard time period.
[0075] Understandably, considering the planning efficiency of the operation diagrams, the number of initial operation diagrams generated in step S330 is related to the total number of buses |K|, and the number of initial operation diagrams is... Based on the unassigned original routes and unassigned standard time periods, repeat steps S310 and S320 to generate multiple initial running maps corresponding to the original routes in each standard time period, and generate an initial timetable based on all the initial running maps.
[0076] It can be understood that in step S330, before obtaining the planned initial running diagram, the following steps are included but not limited to:
[0077] Determine whether the initial running graph meets the preset constraints;
[0078] If the constraints are not met, the initial running graph is replanned.
[0079] If the constraints are met, continue generating the initial running graph.
[0080] It should be noted that the constraints include:
[0081]
[0082]
[0083]
[0084]
[0085] S ijt o ijt ≥0
[0086] Among the five relationships above, τ(i,j,tt) represents the time it takes for a bus to travel from terminal station i to terminal station j within a standard time period t. A value of 1 indicates that bus k uses terminal station j as its final destination and uses terminal station i as its starting point within the standard time period t. A value of 0 indicates other cases. A value of 1 indicates that bus k stopped at the terminal station i within the time period t. A value of 0 indicates other cases, s ijt This represents the number of buses missing from terminal station i to terminal station j within a standard time period t. ijt f represents the excess number of buses traveling from terminal station i to terminal station j within a standard time period t. ijt The standard number of buses is represented by T, the standard time period set is represented by K, and the terminal station refers to the station on the original route of the bus. Both the starting station and the ending station are terminal stations.
[0087] The number of buses is insufficient. ijt The excess number of buses (o) can be obtained by subtracting the standard number of buses from terminal station i to terminal station j within a standard time period t from the actual number of buses deployed. ijt It can be obtained by subtracting the actual number of buses allocated from terminal station i to terminal station j within the standard time period t from the standard number of buses allocated.
[0088] The following explains the greedy algorithm, which is an algorithm that makes the best choice at each step in the current state, hoping to achieve the optimal result. It aims to obtain the globally optimal result from locally optimal results. Greedy algorithms have the advantage of high computational efficiency and producing results close to the optimal one. Using a greedy algorithm as an auxiliary algorithm to generate the initial timetable can effectively save subsequent computation time.
[0089] Understandably, the operational data also includes the maximum and minimum demand values for the number of buses in different time periods. The standard number of buses is obtained by taking the average of the sum of the maximum and minimum demand values in the corresponding standard time period.
[0090] It is understandable that the standard number i of buses in each original route within each standard time period is defined as follows: ijm :
[0091]
[0092] In the above relation, l ijm u represents the lower bound of the demand for buses from terminal station i to terminal station j within the m-th standard time period. ijm This represents the lower bound of the demand for buses from terminal station i to terminal station j within the m-th standard time period.
[0093] Among them, l ijm and u ijm Represented as:
[0094]
[0095]
[0096] In the two relations above, t ijm Let Δt represent the m-th standard time interval from terminal station i to terminal station j, Δt represent the t-th standard time interval, and |·| represent the time span. This represents the maximum demand for buses within one hour in the m-th standard time period corresponding to the original route from terminal station i to terminal station j. This represents the minimum demand for buses within one hour for the m-th standard time period corresponding to the original route from terminal station i to terminal station j.
[0097] It is understandable that in step S400, reference Figure 3 As shown, the initial timetable configuration includes the number of buses allocated to each initial operating schedule, including but not limited to the following steps:
[0098] S410: Configure the number of buses for each initial timetable in the initial timetable using a local search algorithm.
[0099] It should be noted that the reference Figure 4 As shown, the specific operation process of the local search algorithm is as follows:
[0100] S411: First, randomly configure each initial operation map to obtain the number of buses configured for each initial operation map;
[0101] S412: Randomly select two initial running maps as the first running map and the second running map. Move a bus in the first running map to the second running map. If the result of the objective function decreases, keep the move and re-execute step S412. Otherwise, cancel the move and execute step S413.
[0102] S413: Move a bus from the second running map to the first running map. If the result of the objective function decreases, keep the move and execute step S414. Otherwise, cancel the move and return to step S412.
[0103] S414: Repeat step S412 until the objective function value no longer decreases, and obtain the optimal solution for the number of bus configurations for each initial running map.
[0104] It should be noted that the objective function is This represents the penalty coefficient for the absence of a bus from terminal station i to terminal station j within a standard time period t. s represents the penalty coefficient for excess buses traveling from terminal station i to terminal station j within a standard time period t. ijt This represents the number of buses missing from terminal station i to terminal station j within a standard time period t. ijt This represents the excess number of buses traveling from terminal station i to terminal station j within a standard time period t, where T represents the set of standard time periods.
[0105] It is understandable that in step S400, reference Figure 3 As shown, based on the convergence of the difference between the number of buses allocated and the standard number of buses, the target timetable is obtained by performing genetic iteration on the initial timetable using a genetic algorithm, including but not limited to the following steps:
[0106] S420: Using the objective function as the convergence condition, the target timetable is obtained by performing genetic iteration based on the initial running graph in the initial timetable using a genetic algorithm.
[0107] It is understandable that step S420, refer to Figure 5 As shown, the target timetable is obtained by performing genetic iterations based on the initial running graph in the initial timetable using a genetic algorithm, including but not limited to the following steps:
[0108] S421: Use the initial timetable as the input timetable;
[0109] S422: Divide multiple initial run charts in the input timetable into multiple pairs of run chart groups;
[0110] S423: Transform each running chart group to obtain multiple corresponding transformed chart groups;
[0111] S424: Configure the number of bus configurations for the running map group and the transformed map group using a local search algorithm, and obtain the output timetable based on the objective function matching;
[0112] S425: Using the output timetable as the genetic iteration as the input timetable, the output timetable corresponding to the convergence of the objective function to the minimum value is obtained as the target timetable.
[0113] Specifically, the working process of steps S421 to S424 is as follows: using the initial timetable as the input timetable; dividing the input timetable into several pairs of running chart groups in sequence; generating two sub-running charts based on the selected pair of running chart groups, and transforming these two sub-running charts to obtain a pair of transformed chart groups; calculating the number of bus configurations using the local search algorithm in step S410 for the running chart groups and transformed chart groups, and obtaining the optimal output timetable based on the objective function matching; using the genetic iteration of the output timetable as the input timetable, repeating steps S422 to S424 until the objective function converges to no longer decrease, that is, the objective function converges to the minimum value, and the corresponding output timetable is the target timetable.
[0114] The following explains the genetic algorithm, which can be interpreted as follows: for an optimization problem, a certain number of candidate solutions can be abstractly represented as chromosomes, allowing the population to evolve towards better solutions. The solutions of a genetic algorithm are usually represented in binary, but other methods are also possible. Evolution begins with a population of completely random individuals, and then occurs generation after generation. In each generation, the fitness of the entire population is evaluated, and multiple individuals are selected from the current population. Through natural selection and mutation, a new population of life is generated, which becomes the current population in the next iteration of the genetic algorithm.
[0115] refer to Figure 6 As shown, Figure 6 As an example of a route diagram, t represents time, and R represents the original route. When a bus operates according to the route diagram, it can operate on multiple original routes. A simplified diagram of the processing procedure for a bus operation scheduling method is provided in the first aspect of this invention. Figure 7 As shown. The genetic algorithm performs a genetic iteration process on the running graph as follows: Figure 8 As shown.
[0116] It is understandable that transforming each running chart group yields multiple corresponding transformed chart groups, including:
[0117] By using insertion operators, elimination operators, exchange operators, or movement operators to transform each running graph group, multiple corresponding transformed graph groups are obtained.
[0118] The four transformation types mentioned above are as follows:
[0119] Insert operator: Insert one or more original routes within the running graph group. (Refer to...) Figure 9 Figure 'a' shows a schematic diagram of the transformation process of inserting the original route R2 into one of the running graphs;
[0120] Elimination operators eliminate one or more original routes within the running graph group. (Refer to...) Figure 9 Figure b in the diagram illustrates the transformation process of eliminating the original route R4 in one of the running graphs;
[0121] The swap operator selects one or more original routes within each running graph group to swap their positions. (Refer to...) Figure 9 Figure c in the figure shows a schematic diagram of the transformation process in which the original routes R4 and R1 are selected and exchanged in two running graphs in the running graph group.
[0122] The move operator selects one or more original routes within each of the running graph groups and inserts one or more original routes from one running graph before or after one or more selected original routes from another running graph. (Refer to...) Figure 9 The diagram shown in d illustrates the transformation process after selecting the original routes R4 and R1 in the two running graphs of the running graph group and inserting the original route R4 into R1.
[0123] The first aspect of this invention provides a bus operation scheduling method. When generating the target timetable, it breaks the limitation that buses can only travel back and forth on one original route per day, thereby improving their operational efficiency. When planning the route map, it considers the issue of bus allocation, minimizing the objective function result under the constraints of two route maps to prevent only obtaining locally optimal results from considering only one. Furthermore, when setting the objective function, it considers both insufficient and excessive bus numbers, avoiding both situations and effectively improving the efficiency of bus scheduling. Before generating the target timetable, it uses a greedy algorithm to generate an initial timetable, improving computational efficiency while providing better initial values to increase the probability of reaching the optimal point during the genetic algorithm iteration process.
[0124] A second aspect of the present invention provides a bus operation scheduling system, comprising:
[0125] The data acquisition module is used to acquire the running data for each original route;
[0126] The preprocessing module determines the standard number of buses between two terminal stations within multiple preset standard time periods based on the running data. The standard time is obtained by dividing the running time of the original timetable equally. The standard time periods are continuous in natural time. The standard number of buses represents the number of buses required within the standard time period.
[0127] The initial timetable generation module uses a greedy algorithm to schedule and plan the corresponding number of buses in each standard time period, resulting in multiple initial operation maps. Based on the initial operation maps, an initial timetable is generated. In each initial operation map, there is one overlapping terminal station between two adjacent original routes.
[0128] The output module is optimized to initialize the number of bus configurations for each initial timetable in the initial timetable. The target timetable is obtained by performing genetic iteration on the initial timetable using a genetic algorithm, based on the convergence of the difference between the number of bus configurations and the standard number of buses. The target timetable includes multiple target timetables.
[0129] By dividing the original timetable's running time into multiple standard time periods, the demand for buses in a single standard time period can be calculated based on the original route's running data. This is known as the standard number of buses. An initial timetable is generated using a greedy algorithm guided by the standard number of buses. Then, a target timetable is obtained by using a genetic algorithm guided by the difference between the number of buses allocated and the standard number of buses. By first generating the initial timetable using a greedy algorithm and then using a genetic algorithm to converge the target timetable during the iteration process, the convergence effect of the final target timetable can be effectively improved, thereby effectively improving the utilization rate of buses.
[0130] Furthermore, a third aspect of the present invention provides a computer-readable storage medium storing computer-executable instructions that are executed by a processor or controller, for example, by a processor in the above-described device embodiment, causing the processor to execute the bus operation scheduling method in the above-described embodiment, for example, executing the method steps S100 to S400, S310 to S340, S410 to S420, S411 to S414, and S421 to S425 described above.
[0131] It will be understood by those skilled in the art that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware, and suitable combinations thereof. Some or all of the physical components can be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software can be distributed on a computer-readable medium, which can include computer storage media (or non-transitory media) and communication media (or transient media). As is known to those skilled in the art, the term computer storage media includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital versatile disc (DVD) or other optical disc storage, magnetic cartridges, magnetic tape, disk storage or other magnetic storage devices, or any other medium that can be used to store desired information and is accessible to a computer. Furthermore, as is known to those skilled in the art, communication media typically contain computer-readable instructions, data structures, program modules, or other data in modulated data signals such as carrier waves or other transmission mechanisms, and may include any information delivery medium.
[0132] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "illustrative embodiment," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.
[0133] Although embodiments of the invention have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.
Claims
1. A method for scheduling the operation of buses, characterized in that, include: Obtain the running data for each original route; Based on the operational data, determine the standard number of buses between two terminal stations within multiple preset standard time periods; The scheduling plan is carried out by using a greedy algorithm to plan the number of buses corresponding to each standard time period, resulting in multiple initial operation maps. An initial timetable is generated based on the initial operation maps. In each initial operation map, there is an overlapping terminal station between two adjacent original routes. The number of buses in each initial timetable is initialized, and the target timetable is obtained by performing genetic iteration on the initial timetable using a genetic algorithm, with the convergence of the difference between the number of buses in the initial timetable and the standard number of buses as the condition. The operational data includes arrival time, originating station, and destination station; The method involves using a greedy algorithm to schedule and plan the number of buses corresponding to each standard time period, resulting in multiple initial operation maps, including: The starting and ending stations of the original, unplanned route are respectively used as the first and second stations of the initial operating plan; Using the second station as the base station, in the standard time period corresponding to the arrival time of the base station, the terminal station of the original route with the largest number of bus standards and which has not been planned is matched as the third station of the initial operation map; Using the third station as the base station, the initial operation map is planned again until the last station of the initial operation map does not match the starting station of the unplanned original route or the planning time of the initial operation map exceeds the running time, thus obtaining the planned initial operation map. All the original routes that were not planned are planned to obtain multiple planned initial running maps; The operational data also includes the maximum and minimum demand values for the number of buses in different time periods. The standard number of buses is obtained by taking the average of the sum of the maximum and minimum demand values in the corresponding standard time period. The step of obtaining the target timetable by performing genetic iteration on the initial timetable using a genetic algorithm, based on the convergence of the difference between the configured bus quantity and the standard bus quantity, includes: Using the objective function as the convergence condition, a genetic algorithm is used to perform genetic iteration based on the initial running graph in the initial timetable to obtain the target timetable, wherein the objective function is: , Indicates standard time period From the terminal station To the final stop The lack of a penalty factor for buses Indicates standard time period From the terminal station To the final stop The penalty coefficient for extra buses, Indicates within the standard time period From the terminal station To the final stop The shortage of buses Indicates within the standard time period From the terminal station To the final stop The excess number of buses. This represents a set of standard time periods.
2. The bus operation scheduling method according to claim 1, characterized in that, Before obtaining the planned initial running diagram, the process also includes: Determine whether the initial running graph meets the preset constraints; If the constraints are not met, the initial running graph is replanned.
3. The bus operation scheduling method according to claim 2, characterized in that, The constraints include: in, , , , Indicates the bus departs from the terminal station. Departure within the standard time period Arrive at the final station , A value of 1 indicates a bus. By the terminal station As the final destination and within the standard time period Inner terminal station As the originating station, A value of 0 indicates other cases. A value of 1 indicates a bus. In time period The car stopped at the terminal station. , A value of 0 indicates other cases. Indicates within the standard time period From the terminal station To the final stop The shortage of buses Indicates within the standard time period From the terminal station To the final stop The excess number of buses. Indicates the standard number of buses. Represents a standard time period set. This indicates that the buses are assembled.
4. The bus operation scheduling method according to claim 1, characterized in that, The step of obtaining the target timetable through genetic iteration using a genetic algorithm based on the initial running graph in the initial timetable includes: Use the initial timetable as the input timetable; The multiple initial running charts in the input timetable are divided into multiple pairs of running chart groups; Each of the aforementioned running graph groups is transformed to obtain multiple corresponding transformed graph groups; The number of bus configurations is configured in the running map group and the transformed map group using a local search algorithm, and the output timetable is obtained by matching according to the objective function. Using the genetic iteration of the output timetable as the input timetable, the output timetable corresponding to when the objective function converges to the minimum value is obtained as the target timetable.
5. The bus operation scheduling method according to claim 4, characterized in that, The step of transforming each of the running graph groups to obtain corresponding multiple transformed graph groups includes: By using insertion operators, elimination operators, exchange operators, or movement operators to transform each of the running graph groups, multiple corresponding transformed graph groups are obtained.
6. A bus operation dispatching system, characterized in that, include: The data acquisition module acquires the operational data for each original route; The preprocessing module determines the standard number of buses between two terminal stations within multiple preset standard time periods based on the operational data. The initial table generation module uses a greedy algorithm to schedule and plan the corresponding number of buses in each standard time period to obtain multiple initial operation maps. An initial timetable is generated based on the initial operation maps. In each initial operation map, there is an overlapping terminal station between two adjacent original routes. The output module is optimized to initialize the number of bus configurations for each initial timetable in the initial timetable. The target timetable is obtained by performing genetic iteration on the initial timetable using a genetic algorithm, with the convergence of the difference between the number of bus configurations and the standard number of buses as the condition. The operational data includes arrival time, originating station, and destination station; The method involves using a greedy algorithm to schedule and plan the number of buses corresponding to each standard time period, resulting in multiple initial operation maps, including: The starting and ending stations of the original, unplanned route are respectively used as the first and second stations of the initial operating plan; Using the second station as the base station, in the standard time period corresponding to the arrival time of the base station, the terminal station of the original route with the largest number of bus standards and which has not been planned is matched as the third station of the initial operation map; Using the third station as the base station, the initial operation map is planned again until the last station of the initial operation map does not match the starting station of the unplanned original route or the planning time of the initial operation map exceeds the running time, thus obtaining the planned initial operation map. All the original routes that were not planned are planned to obtain multiple planned initial running maps; The operational data also includes the maximum and minimum demand values for the number of buses in different time periods. The standard number of buses is obtained by taking the average of the sum of the maximum and minimum demand values in the corresponding standard time period. The step of obtaining the target timetable by performing genetic iteration on the initial timetable using a genetic algorithm, based on the convergence of the difference between the configured bus quantity and the standard bus quantity, includes: Using the objective function as the convergence condition, a genetic algorithm is used to perform genetic iteration based on the initial running graph in the initial timetable to obtain the target timetable, wherein the objective function is: , Indicates standard time period From the terminal station To the final stop The lack of a penalty factor for buses Indicates standard time period From the terminal station To the final stop The penalty coefficient for extra buses, Indicates within the standard time period From the terminal station To the final stop The shortage of buses Indicates within the standard time period From the terminal station To the final stop The excess number of buses. This represents a set of standard time periods.
7. A computer storage medium, characterized in that, The device stores computer-executable instructions for executing the bus operation scheduling method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Multi-form bus dynamic scheduling method based on bus station informatization
CN106504516A
Calculation method and device for train operation adjustment under multiple constraint conditions
CN112116207A