CN108647910B - Method, device and terminal for setting urban bus stop and computer storage medium - Google Patents

Method, device and terminal for setting urban bus stop and computer storage medium Download PDF

Info

Publication number
CN108647910B
CN108647910B CN201810627696.9A CN201810627696A CN108647910B CN 108647910 B CN108647910 B CN 108647910B CN 201810627696 A CN201810627696 A CN 201810627696A CN 108647910 B CN108647910 B CN 108647910B
Authority
CN
China
Prior art keywords
bus
stop
urban
processed
bus stop
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810627696.9A
Other languages
Chinese (zh)
Other versions
CN108647910A (en
Inventor
镇依婷
高婧
周康
刘江蓉
刘朔
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Wuhan Polytechnic University
Original Assignee
Wuhan Polytechnic University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Wuhan Polytechnic University filed Critical Wuhan Polytechnic University
Priority to CN201810627696.9A priority Critical patent/CN108647910B/en
Publication of CN108647910A publication Critical patent/CN108647910A/en
Application granted granted Critical
Publication of CN108647910B publication Critical patent/CN108647910B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/06Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling
    • G06Q10/063Operations research, analysis or management
    • G06Q10/0637Strategic management or analysis, e.g. setting a goal or target of an organisation; Planning actions based on goals; Analysis or evaluation of effectiveness of goals
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/23Clustering techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • G06Q10/047Optimisation of routes or paths, e.g. travelling salesman problem
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Systems or methods specially adapted for specific business sectors, e.g. utilities or tourism
    • G06Q50/10Services
    • G06Q50/26Government or public services
    • G06Q50/40

Abstract

The invention discloses a method, a device, a terminal and a computer storage medium for setting urban bus stops, which are characterized in that firstly, each bus stop is clustered to obtain n areas to be processed, any two bus stops in each area to be processed are respectively connected, so that each area to be processed has a plurality of stop line segments; connecting the clustering centers between the neighboring areas to generate an area communication line between the neighboring areas, so that a communicated route is randomly generated between the blocks, and the connectivity of the whole public transport network is ensured; and finally, setting the bus stop of the current city according to the selected bus stop of each bus and the city bus line. Therefore, when the number of urban bus stops is large, urban management personnel can plan the urban bus stops effectively.

Description

Method, device and terminal for setting urban bus stop and computer storage medium
Technical Field
The invention relates to the technical field of computers, in particular to a method, a device, a terminal and a computer storage medium for setting urban bus stops.
Background
In urban traffic planning, the status of public transportation is increasingly important. An excellent public transport network system not only can save traffic resources, but also can provide powerful guarantee for facilitating the travel of passengers. Therefore, when the urban public transportation network design is carried out today when advocating "public transportation is first", the public transportation network overall optimization carried out according to the traffic conditions has more practical significance.
In recent years, with the improvement of computer hardware performance, intelligent algorithms such as genetic algorithm, tabu algorithm, simulated annealing algorithm, neural network and the like are also proposed successively, and the application of the algorithms to bus planning is an important research direction for carrying out overall optimization of the bus network.
The urban public transport network optimization is the basis for implementing an intelligent public transport system, and the operation efficiency is more obvious only by implementing the intelligent public transport system on an optimized public transport network. Because the constrained overall optimization of the bus network is a difficult problem, when the number of bus stations increases, the operation scale increases exponentially. Therefore, the traditional mathematical planning method is difficult to be applied to the actual bus system optimization.
The above is only for the purpose of assisting understanding of the technical aspects of the present invention, and does not represent an admission that the above is prior art.
Disclosure of Invention
The invention mainly aims to provide a method for setting urban bus stops, a server and a computer readable storage medium, aiming at solving the problem that how to effectively plan the urban bus stops when urban managers face huge number of urban bus stops.
In order to achieve the purpose, the invention provides a method for setting urban bus stops, which comprises the following steps:
determining the number of buses in a current city, the maximum line number of urban bus lines and the maximum pre-distributed bus number of each bus stop;
clustering the bus stops according to a first preset distance to obtain n clustering centers, and taking each area with the clustering centers as the circle centers and the radius of a second preset distance as areas to be processed to determine n areas to be processed, wherein n is an integer not less than 1;
respectively connecting any two bus stops in each area to be processed so as to enable each area to be processed to have a plurality of stop line segments;
when the distance difference value between the clustering centers of two different to-be-processed areas is smaller than a third distance threshold value, judging that the two different to-be-processed areas are neighbor areas, and connecting the clustering centers between the neighbor areas to generate an area communication line between the neighbor areas;
generating a plurality of urban public transport lines according to station line segments in each area to be processed, area communication lines among each adjacent area and the maximum line number of the urban public transport lines;
sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm to obtain a selected bus stop of each bus;
and setting the bus stop of the current city according to the selected bus stop of each bus and the city bus route.
Preferably, the sending the maximum pre-distributed bus number, the bus number and the urban bus route of each bus stop into a preset selection operator algorithm to obtain the selected bus stop of each bus specifically includes:
sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm;
traversing each bus stop and each bus through the preset selection operator algorithm to obtain the selection probability of the traversed buses of the traversed bus stops;
when the selection probability is larger than a first preset probability threshold value, recording a selected bus stop corresponding to the selection probability;
accumulating the selection probabilities of the traversed buses to obtain the accumulation probability of the traversed buses, stopping traversing the rest bus stops until the accumulation probability of the traversed buses reaches a second preset probability threshold, and determining each selected bus stop.
Preferably, after connecting any two bus stops in each to-be-processed area respectively to make each to-be-processed area have a plurality of stop line segments, the method further includes:
and characterizing the communication relation among the stations in each area to be processed by an adjacency matrix, wherein the adjacency matrix is represented by a matrix A,
Figure GDA0001781836020000031
wherein, aijA line segment between two stops, namely a bus stop i and a bus stop j, is shown, when aijWhen the value of (1) is assigned, the bus stop i and the bus stop j have a direct line; when a isijWhen the value of (1) is 0, it indicates that there is no direct line between the bus stop i and the bus stop j.
Preferably, the step of accumulating the traversed selection probabilities of the buses to obtain the traversed accumulation probabilities of the buses, and the step of stopping traversing the remaining bus stops and determining each selected bus stop when the traversed accumulation probabilities of the buses reach a second preset probability threshold, further includes:
counting the selected bus stops of each bus, embedding the selected bus stops of each bus into the urban bus line, and displaying the urban bus line embedded into the bus stops.
Optionally, the determining the number of buses in the current city, the maximum number of lines of urban bus lines, and the maximum pre-distributed bus number of each bus stop specifically includes:
receiving the number of bus stops, the number of buses and the maximum line number of urban bus lines of a current city, which are input by a user;
and calculating the maximum pre-distributed bus number of each bus stop according to the bus stop number, the bus number and the maximum line number of the urban bus lines.
In addition, in order to achieve the above object, the present invention further provides a setting device for urban bus stops, the device comprising:
the determining module is used for determining the number of buses in the current city, the maximum line number of urban bus lines and the maximum pre-distributed bus number of each bus stop;
the system comprises a clustering module, a processing module and a processing module, wherein the clustering module is used for clustering bus stops according to a first preset distance to obtain n clustering centers, and each area with the clustering center as a circle center and the radius as a second preset distance is used as an area to be processed to determine n areas to be processed, wherein n is an integer not less than 1;
the line segment generation module is used for respectively connecting any two bus stops in each area to be processed so as to enable each area to be processed to have a plurality of stop line segments;
the region communication module is used for judging that the two different regions to be processed are neighbor regions when the distance difference value between the clustering centers of the two different regions to be processed is smaller than a third distance threshold value, and connecting the clustering centers between the neighbor regions to generate a region communication line between the neighbor regions;
the line generation module is used for generating a plurality of urban public transport lines according to the fact that each to-be-processed area is provided with a plurality of station line segments, area communication lines among neighbor areas and the maximum line number of the urban public transport lines;
the calculation module is used for sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm so as to obtain a selected bus stop of each bus;
and the setting module is used for setting the bus stop of the current city according to the selected bus stop of each bus and the city bus line.
In addition, in order to achieve the above object, the present invention further provides a terminal for setting a city bus stop, wherein the terminal comprises: the setting program of the urban bus stop is configured to realize the steps of the setting method of the urban bus stop.
In addition, in order to achieve the above object, the present invention further provides a computer storage medium, where a setting program of a city bus stop is stored, and the setting program of the city bus stop is configured to implement the steps of the setting method of the city bus stop.
Firstly, clustering each bus stop according to a first preset distance by adopting a matrix theory blocking idea to obtain n areas to be processed, and respectively connecting any two bus stops in each area to be processed so as to enable each area to be processed to have a plurality of stop line segments; connecting the clustering centers between the neighboring areas to generate an area communication line between the neighboring areas, so that a communicated route is randomly generated between blocks, and the connectivity of the whole public transport network is ensured; generating a plurality of urban public transport lines according to the station line segments in each area to be processed, the area communication lines between each adjacent area and the maximum line quantity of the urban public transport lines, generating and ensuring that all the public transport stations are included by adopting the wheel roulette thought and the traversal thought, and finally setting the public transport stations of the current city according to the selected public transport stations of each bus and the urban public transport lines. Therefore, at present, when the number of urban bus stops is large, urban management personnel can plan the urban bus stops effectively.
Drawings
Fig. 1 is a schematic structural diagram of a terminal for setting a city bus stop in a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart of an embodiment of a method for setting a city bus stop according to the present invention;
fig. 3 is a block diagram of the structure of an embodiment of the setting device of the urban bus stop of the invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Referring to fig. 1, fig. 1 is a schematic structural diagram of a terminal for setting a city bus stop in a hardware operating environment according to an embodiment of the present invention.
As shown in fig. 1, the terminal may include: a processor 1001, such as a CPU, a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Wherein a communication bus 1002 is used to enable connective communication between these components. The user interface 1003 may include a Display screen (Display), an input unit such as a Keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface). The memory 1005 may be a high-speed RAM memory or a non-volatile memory (e.g., a magnetic disk memory). The memory 1005 may alternatively be a storage device separate from the processor 1001.
Those skilled in the art will appreciate that the configuration shown in fig. 1 does not constitute a limitation of the terminal, and may include more or less components than those shown, or some components in combination, or a different arrangement of components.
As shown in fig. 1, a memory 1005, which is a kind of computer storage medium, may include therein an operating system, a user interface module, a network communication module, and a setting program of a city bus stop.
In the terminal shown in fig. 1, the processor 1001 and the memory 1005 in the terminal of the present invention may be provided in the terminal, and the terminal calls the setting program of the urban bus stop stored in the memory 1005 through the processor 1001 and performs the following operations:
determining the number of buses in a current city, the maximum line number of urban bus lines and the maximum pre-distributed bus number of each bus stop;
clustering the bus stops according to a first preset distance to obtain n clustering centers, and taking each area with the clustering centers as the circle centers and the radius of a second preset distance as areas to be processed to determine n areas to be processed, wherein n is an integer not less than 1;
respectively connecting any two bus stops in each area to be processed so as to enable each area to be processed to have a plurality of stop line segments;
when the distance difference value between the clustering centers of two different to-be-processed areas is smaller than a third distance threshold value, judging that the two different to-be-processed areas are neighbor areas, and connecting the clustering centers between the neighbor areas to generate an area communication line between the neighbor areas;
generating a plurality of urban public transport lines according to station line segments in each area to be processed, area communication lines among each adjacent area and the maximum line number of the urban public transport lines;
sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm to obtain a selected bus stop of each bus;
and setting the bus stop of the current city according to the selected bus stop of each bus and the city bus route.
Further, the processor 1001 may call the setting program of the city bus stop stored in the memory 1005, and also perform the following operations:
sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm;
traversing each bus stop and each bus through the preset selection operator algorithm to obtain the selection probability of the traversed buses of the traversed bus stops;
when the selection probability is larger than a first preset probability threshold value, recording a selected bus stop corresponding to the selection probability;
accumulating the selection probabilities of the traversed buses to obtain the accumulation probability of the traversed buses, stopping traversing the rest bus stops until the accumulation probability of the traversed buses reaches a second preset probability threshold, and determining each selected bus stop.
Further, the processor 1001 may call the setting program of the city bus stop stored in the memory 1005, and also perform the following operations:
and characterizing the communication relation among the stations in each area to be processed by an adjacency matrix, wherein the adjacency matrix is represented by a matrix A,
Figure GDA0001781836020000071
wherein, aijA line segment between two stops, namely a bus stop i and a bus stop j, is shown, when aijWhen the value of (1) is assigned, the bus stop i and the bus stop j have a direct line; when a isijWhen the value of (1) is 0, it indicates that there is no direct line between the bus stop i and the bus stop j.
Further, the processor 1001 may call the setting program of the city bus stop stored in the memory 1005, and also perform the following operations:
counting the selected bus stops of each bus, embedding the selected bus stops of each bus into the urban bus line, and displaying the urban bus line embedded into the bus stops.
Further, the processor 1001 may call the setting program of the city bus stop stored in the memory 1005, and also perform the following operations:
receiving the number of bus stops, the number of buses and the maximum line number of urban bus lines of a current city, which are input by a user;
and calculating the maximum pre-distributed bus number of each bus stop according to the bus stop number, the bus number and the maximum line number of the urban bus lines.
The method comprises the steps of firstly clustering bus stops according to a first preset distance by adopting a matrix theory blocking idea to obtain n areas to be processed, and respectively connecting any two bus stops in the areas to be processed so as to enable the areas to be processed to have a plurality of stop line segments; connecting the clustering centers between the neighboring areas to generate an area communication line between the neighboring areas, so that a communicated route is randomly generated between blocks, and the connectivity of the whole public transport network is ensured; generating a plurality of urban public transport lines according to the station line segments in each area to be processed, the area communication lines between each adjacent area and the maximum line quantity of the urban public transport lines, generating and ensuring that all the public transport stations are included by adopting the wheel roulette thought and the traversal thought, and finally setting the public transport stations of the current city according to the selected public transport stations of each bus and the urban public transport lines. Therefore, at present, when the number of urban bus stops is large, urban management personnel can plan the urban bus stops effectively.
Based on the hardware structure, the embodiment of the method for setting the urban bus stop is provided.
Referring to fig. 2, fig. 2 is a schematic flow chart of an embodiment of a method for setting a city bus stop according to the present invention.
In this embodiment, the method includes the steps of:
step S10: determining the number of buses in the current city, the maximum line number of urban bus lines and the maximum pre-distributed bus number of each bus stop.
It can be understood that the number of buses in the current city, the maximum number of lines of the urban bus lines and the number of bus stops in the current city can be parameters input by a city manager when the terminal is used; the maximum pre-distributed bus number of each bus stop can also be a parameter input by a city manager, and can be determined by other parameters; in this embodiment, a simple example is used for explanation, and if the number of bus stops in the current city is 100, and there are 20 routes, the maximum pre-distributed bus number of each bus stop is not more than 6.
Step S20: clustering each bus stop according to a first preset distance to obtain n clustering centers, and taking each area with the clustering centers as the circle centers and the radius of a second preset distance as areas to be processed to determine n areas to be processed, wherein n is an integer not less than 1.
It can be understood that, in step S20, all bus stops in the current city are clustered according to the distance, in this embodiment, the first preset distance is set to 1 km, two adjacent stops are clustered, and each area with the cluster center as the center of a circle and the radius of the cluster center as the second preset distance is used as the area to be processed, so as to obtain n cluster centers, that is, the city is divided into n areas, in this embodiment, the second preset distance may be set to 10 km, that is, the area of each area to be processed is 314 square km;
step S30: and respectively connecting any two bus stops in each area to be processed so as to enable each area to be processed to have a plurality of stop line segments.
In this embodiment, it can be understood that the foregoing step S20 adopts the blocking concept in the matrix theory, and in step S30, the adjacent matrix (a two-dimensional array is used to store the data of the relationship (edge or arc) between vertices, and this two-dimensional array is referred to as an adjacent matrix) of the bus stop spanning tree structure in each area to be processed is blocked, and two minor diagonals of each blocking submatrix are set to 1. That is, the connection relationship between the stations in each region to be processed is characterized by an adjacency matrix, which is represented by the following matrix a,
Figure GDA0001781836020000091
wherein, aijA line segment between two stops, namely a bus stop i and a bus stop j, is shown, when aijWhen the value of (1) is assigned, the bus stop i and the bus stop j have a direct line; when a isijWhen the value of (1) is 0, it indicates that there is no direct line between the bus stop i and the bus stop j.
Step S40: and when the distance difference value between the clustering centers of two different to-be-processed areas is smaller than a third distance threshold value, judging the two different to-be-processed areas as neighbor areas, and connecting the clustering centers between the neighbor areas to generate an area communication line between the neighbor areas.
Specifically, in this embodiment, the third distance threshold is set to be 22 kilometers, and if the distance between two clustering centers is less than 22 kilometers, that is, the shortest distance between two to-be-processed areas is less than 2 kilometers, it is determined that the two different to-be-processed areas are neighboring areas, and the clustering centers between the neighboring areas are connected to generate an area communication line between the neighboring areas, that is, a communication line is established in two adjacent sub-matrices, thereby ensuring the connectivity of a graph formed by the whole urban bus stop.
It will be appreciated that, for example, in a current city, two adjacent areas are separated by a river, and in order to allow a path for a vehicle to travel between the two adjacent areas, a bridge must be installed, which corresponds to the area communication line and is the necessary path for all buses.
Step S50: and generating a plurality of urban public transport lines according to the station line segments in the areas to be processed, the area communication lines among the adjacent areas and the maximum line number of the urban public transport lines.
Step S60: sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm to obtain a selected bus stop of each bus;
specifically, in a specific implementation of step S60, after sending the maximum pre-distributed bus number, the bus number, and the urban bus route of each bus stop into a preset selection operator algorithm, traversing each bus stop and each bus through the preset selection operator algorithm to obtain a selection probability of the traversed bus at the traversed bus stop; when the selection probability is larger than a first preset probability threshold value, recording a selected bus stop corresponding to the selection probability; accumulating the selection probabilities of the traversed buses to obtain the accumulation probability of the traversed buses, stopping traversing the rest bus stops until the accumulation probability of the traversed buses reaches a second preset probability threshold, and determining each selected bus stop. It should be noted that the first preset probability threshold and the second preset probability threshold may be set by current city managers or program developers of the setting program of the city bus stop
Firstly, a wheel roulette thought is utilized to search a bidirectional bus route covering 10 to 25 stops, and more bus routes passing through a city center are ensured; secondly, a traversing idea is adopted to search bidirectional bus routes meeting requirements, all the bus routes are guaranteed to contain all stops of the city, and the specified number of bus routes are generated at the same time. The traversal refers to making one-time and only one-time access to each node (which is equivalent to a bus stop) in sequence along a certain search route. The method is characterized in that the method is not heavy and leak-free, the bus route is searched by traversing, the idea of roulette in the previous step is processed to guide the missed stops in depth-first search, and the searched bidirectional bus route which meets the requirements is ensured to be free of missing and comprises all stops of the city. Controlling the number of routes to meet the number of effective routes generated in the first two stages of statistics, and prompting a user to reset a route numerical value if the number is larger than the number required by the user; if the two are exactly equal, no operation is performed; if the route value is greater than the return value of the active route, then it is necessary to randomly generate (number of routes-active route.) sites and reuse traversal to generate the deficient route.
Step S70: and setting the bus stop of the current city according to the selected bus stop of each bus and the city bus route.
In the specific implementation, a plurality of routes with larger length are selected for the generated bidirectional bus route, and a circular route is obtained by connecting front and rear stops or adding a new stop; selecting a route with the length of more than 20 from the generated annular route, and obtaining a corresponding one-way route by means of a halving idea; and storing the generated urban bus lines, counting the selected bus stops of each bus, embedding the selected bus stops of each bus into the urban bus lines, and displaying the urban bus lines embedded into the bus stops. Selecting a plurality of routes with larger length for the generated bidirectional bus route, and connecting front and rear stops or adding a new stop to obtain a ring route; and selecting a route with the length of more than 20 from the generated annular route, and obtaining a corresponding unidirectional route by virtue of a halving idea.
The method comprises the steps of firstly clustering bus stops according to a first preset distance by adopting a matrix theory blocking idea to obtain n areas to be processed, and respectively connecting any two bus stops in the areas to be processed so as to enable the areas to be processed to have a plurality of stop line segments; connecting the clustering centers between the neighboring areas to generate an area communication line between the neighboring areas, so that a communicated route is randomly generated between blocks, and the connectivity of the whole public transport network is ensured; generating a plurality of urban public transport lines according to the station line segments in each area to be processed, the area communication lines between each adjacent area and the maximum line quantity of the urban public transport lines, generating and ensuring that all the public transport stations are included by adopting the wheel roulette thought and the traversal thought, and finally setting the public transport stations of the current city according to the selected public transport stations of each bus and the urban public transport lines. Therefore, at present, when the number of urban bus stops is large, urban management personnel can plan the urban bus stops effectively.
In addition, referring to fig. 3, the present invention further provides a setting apparatus for a city bus stop, in this embodiment, the apparatus includes:
the determining module 10 is used for determining the number of buses in a current city, the maximum line number of urban bus lines and the maximum pre-distributed bus number of each bus stop;
the clustering module 20 is configured to cluster the bus stations according to a first preset distance to obtain n clustering centers, and determine n to-be-processed areas by taking each area with the clustering center as a circle center and a radius of a second preset distance as the to-be-processed area, where n is an integer not less than 1;
the line segment generation module 30 is configured to respectively connect any two bus stops in each to-be-processed area, so that each to-be-processed area has multiple stop line segments;
the region communication module 40 is configured to determine, when a distance difference between clustering centers of two different to-be-processed regions is smaller than a third distance threshold, that the two different to-be-processed regions are neighbor regions, and connect the clustering centers between the neighbor regions to generate a region communication line between the neighbor regions;
the route generation module 50 is configured to generate a plurality of urban public transportation routes according to the number of the urban public transportation routes, where each to-be-processed area has a plurality of station line segments, the area communication routes between neighboring areas, and the maximum route number of the urban public transportation routes;
the calculation module 60 is configured to send the maximum pre-distributed bus number, the bus number, and the urban bus route of each bus stop into a preset selection operator algorithm to obtain a selected bus stop of each bus;
and the setting module 70 is used for setting the bus stop of the current city according to the selected bus stop of each bus and the city bus route.
It can be understood that the setting device for the urban bus stop implemented in the present embodiment may be an APP application program, and the APP application program device is in the terminal of the above embodiment, and the specific implementation manner of the setting device for the urban bus stop of the present invention may refer to the above setting method embodiment for the urban bus stop, and is not described herein again.
In addition, an embodiment of the present invention further provides a readable storage medium, where a setting program of a city bus stop is stored on the readable storage medium, and when executed by a processor, the setting program of the city bus stop implements the following operations:
determining the number of buses in a current city, the maximum line number of urban bus lines and the maximum pre-distributed bus number of each bus stop;
clustering the bus stops according to a first preset distance to obtain n clustering centers, and taking each area with the clustering centers as the circle centers and the radius of a second preset distance as areas to be processed to determine n areas to be processed, wherein n is an integer not less than 1;
respectively connecting any two bus stops in each area to be processed so as to enable each area to be processed to have a plurality of stop line segments;
when the distance difference value between the clustering centers of two different to-be-processed areas is smaller than a third distance threshold value, judging that the two different to-be-processed areas are neighbor areas, and connecting the clustering centers between the neighbor areas to generate an area communication line between the neighbor areas;
generating a plurality of urban public transport lines according to station line segments in each area to be processed, area communication lines among each adjacent area and the maximum line number of the urban public transport lines;
sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm to obtain a selected bus stop of each bus;
and setting the bus stop of the current city according to the selected bus stop of each bus and the city bus route.
Further, when executed by the processor, the setting program for the urban bus stop further realizes the following operations:
sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm;
traversing each bus stop and each bus through the preset selection operator algorithm to obtain the selection probability of the traversed buses of the traversed bus stops;
when the selection probability is larger than a first preset probability threshold value, recording a selected bus stop corresponding to the selection probability;
accumulating the selection probabilities of the traversed buses to obtain the accumulation probability of the traversed buses, stopping traversing the rest bus stops until the accumulation probability of the traversed buses reaches a second preset probability threshold, and determining each selected bus stop.
Further, when executed by the processor, the setting program for the urban bus stop further realizes the following operations:
and characterizing the communication relation among the stations in each area to be processed by an adjacency matrix, wherein the adjacency matrix is represented by a matrix A,
Figure GDA0001781836020000131
wherein, aijA line segment between two stops, namely a bus stop i and a bus stop j, is shown, when aijWhen the value of (1) is assigned, the bus stop i and the bus stop j have a direct line; when a isijWhen the value of (1) is 0, it indicates that there is no direct line between the bus stop i and the bus stop j.
Further, when executed by the processor, the setting program for the urban bus stop further realizes the following operations:
counting the selected bus stops of each bus, embedding the selected bus stops of each bus into the urban bus line, and displaying the urban bus line embedded into the bus stops.
Further, when executed by the processor, the setting program for the urban bus stop further realizes the following operations:
receiving the number of bus stops, the number of buses and the maximum line number of urban bus lines of a current city, which are input by a user;
and calculating the maximum pre-distributed bus number of each bus stop according to the bus stop number, the bus number and the maximum line number of the urban bus lines.
The method comprises the steps of firstly clustering bus stops according to a first preset distance by adopting a matrix theory blocking idea to obtain n areas to be processed, and respectively connecting any two bus stops in the areas to be processed so as to enable the areas to be processed to have a plurality of stop line segments; connecting the clustering centers between the neighboring areas to generate an area communication line between the neighboring areas, so that a communicated route is randomly generated between blocks, and the connectivity of the whole public transport network is ensured; generating a plurality of urban public transport lines according to the station line segments in each area to be processed, the area communication lines between each adjacent area and the maximum line quantity of the urban public transport lines, generating and ensuring that all the public transport stations are included by adopting the wheel roulette thought and the traversal thought, and finally setting the public transport stations of the current city according to the selected public transport stations of each bus and the urban public transport lines. Therefore, at present, when the number of urban bus stops is large, urban management personnel can plan the urban bus stops effectively.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or system. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal device (such as a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the method according to the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (8)

1. A method for setting urban bus stops is characterized by comprising the following steps:
determining the number of buses in a current city, the maximum line number of urban bus lines and the maximum pre-distributed bus number of each bus stop;
clustering the bus stops according to a first preset distance to obtain n clustering centers, and taking each area with the clustering centers as the circle centers and the radius of a second preset distance as areas to be processed to determine n areas to be processed, wherein n is an integer not less than 1;
respectively connecting any two bus stops in each area to be processed so as to enable each area to be processed to have a plurality of stop line segments;
when the distance difference value between the clustering centers of two different to-be-processed areas is smaller than a third distance threshold value, judging that the two different to-be-processed areas are neighbor areas, and connecting the clustering centers between the neighbor areas to generate an area communication line between the neighbor areas;
generating a plurality of urban public transport lines according to station line segments in each area to be processed, area communication lines among each adjacent area and the maximum line number of the urban public transport lines;
sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm to obtain a selected bus stop of each bus;
setting the bus stop of the current city according to the selected bus stop of each bus and the city bus route;
the step of setting the bus stop of the current city according to the selected bus stop of each bus and the city bus route comprises the following steps:
selecting a target route according to the urban bus route;
preprocessing the target route to obtain a circular route;
selecting a target annular route of which the length is greater than a preset length threshold value from the annular routes;
and counting the selected bus stations of each bus, and embedding the selected bus stations of each bus into the target annular route so as to set the bus stations of the current city.
2. The method according to claim 1, wherein the step of sending the maximum pre-assigned bus number, the bus number and the urban bus route of each bus stop into a preset selection operator algorithm to obtain the selected bus stop of each bus comprises the following steps:
sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm;
traversing each bus stop and each bus through the preset selection operator algorithm to obtain the selection probability of the traversed buses of the traversed bus stops;
when the selection probability is larger than a first preset probability threshold value, recording a selected bus stop corresponding to the selection probability;
accumulating the selection probabilities of the traversed buses to obtain the accumulation probability of the traversed buses, stopping traversing the rest bus stops until the accumulation probability of the traversed buses reaches a second preset probability threshold, and determining each selected bus stop.
3. The method as claimed in claim 2, wherein said respectively connecting any two bus stops in each area to be processed so that each area to be processed has a plurality of stop line segments, further comprises:
and characterizing the communication relation among the stations in each area to be processed by an adjacency matrix, wherein the adjacency matrix is represented by a matrix A,
Figure FDA0003294639980000021
wherein, aijA line segment between two stops, namely a bus stop i and a bus stop j, is shown, when aijWhen the value of (1) is assigned, the bus stop i and the bus stop j have a direct line; when a isijWhen the value of (1) is 0, it indicates that there is no direct line between the bus stop i and the bus stop j.
4. The method according to any one of claims 2 to 3, wherein the step of accumulating the traversed selection probabilities of the buses to obtain the traversed accumulation probabilities of the buses, the step of stopping traversing the remaining bus stops when the traversed accumulation probabilities of the traversed buses reach a second preset probability threshold, and the step of determining each selected bus stop further comprises the step of:
counting the selected bus stops of each bus, embedding the selected bus stops of each bus into the urban bus line, and displaying the urban bus line embedded into the bus stops.
5. The method of claim 1, wherein the determining the number of buses in the current city, the maximum number of routes of the city bus routes, and the maximum pre-allocated number of buses per bus stop specifically comprises:
receiving the number of bus stops, the number of buses and the maximum line number of urban bus lines of a current city, which are input by a user;
and calculating the maximum pre-distributed bus number of each bus stop according to the bus stop number, the bus number and the maximum line number of the urban bus lines.
6. The utility model provides a setting device of city bus stop which characterized in that, the device includes:
the determining module is used for determining the number of buses in the current city, the maximum line number of urban bus lines and the maximum pre-distributed bus number of each bus stop;
the system comprises a clustering module, a processing module and a processing module, wherein the clustering module is used for clustering bus stops according to a first preset distance to obtain n clustering centers, and each area with the clustering center as a circle center and the radius as a second preset distance is used as an area to be processed to determine n areas to be processed, wherein n is an integer not less than 1;
the line segment generation module is used for respectively connecting any two bus stops in each area to be processed so as to enable each area to be processed to have a plurality of stop line segments;
the region communication module is used for judging that the two different regions to be processed are neighbor regions when the distance difference value between the clustering centers of the two different regions to be processed is smaller than a third distance threshold value, and connecting the clustering centers between the neighbor regions to generate a region communication line between the neighbor regions;
the line generation module is used for generating a plurality of urban public transport lines according to the fact that each to-be-processed area is provided with a plurality of station line segments, area communication lines among neighbor areas and the maximum line number of the urban public transport lines;
the calculation module is used for sending the maximum pre-distributed bus number, the bus number and the urban bus line of each bus stop into a preset selection operator algorithm so as to obtain a selected bus stop of each bus;
the setting module is used for setting the bus stop of the current city according to the selected bus stop of each bus and the city bus route;
the setting module is also used for selecting a target route according to the urban bus route; preprocessing the target route to obtain a circular route; selecting a target annular route of which the length is greater than a preset length threshold value from the annular routes; and counting the selected bus stations of each bus, and embedding the selected bus stations of each bus into the target annular route so as to set the bus stations of the current city.
7. The utility model provides a terminal for city bus stop sets up which characterized in that, the terminal includes: the setting program of the urban bus stop is configured to realize the steps of the setting method of the urban bus stop according to any one of claims 1 to 5.
8. A computer storage medium characterized in that the computer storage medium has stored thereon a setting program of a city bus stop configured to implement the steps of the setting method of a city bus stop according to any one of claims 1 to 5.
CN201810627696.9A 2018-06-15 2018-06-15 Method, device and terminal for setting urban bus stop and computer storage medium Active CN108647910B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810627696.9A CN108647910B (en) 2018-06-15 2018-06-15 Method, device and terminal for setting urban bus stop and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810627696.9A CN108647910B (en) 2018-06-15 2018-06-15 Method, device and terminal for setting urban bus stop and computer storage medium

Publications (2)

Publication Number Publication Date
CN108647910A CN108647910A (en) 2018-10-12
CN108647910B true CN108647910B (en) 2022-04-01

Family

ID=63752718

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810627696.9A Active CN108647910B (en) 2018-06-15 2018-06-15 Method, device and terminal for setting urban bus stop and computer storage medium

Country Status (1)

Country Link
CN (1) CN108647910B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111460598B (en) * 2020-04-13 2023-02-10 同济大学 Bus trunk line network generation method based on machine learning
CN113283754A (en) * 2021-05-27 2021-08-20 哈尔滨工业大学(深圳) Station site selection method and device, computing equipment and storage medium
CN113514071B (en) * 2021-06-29 2024-04-16 阿波罗智联(北京)科技有限公司 Public traffic route determining method and device
CN114613123A (en) * 2022-02-17 2022-06-10 华录智达科技股份有限公司 Public transportation intelligent scheduling method based on big data
CN114944056B (en) * 2022-04-20 2023-09-01 京东城市(北京)数字科技有限公司 Traffic reachability calculation method and device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101187996A (en) * 2007-10-08 2008-05-28 常飞 A quick bus line selection algorithm based on self-adapted backbone network
CN104282142A (en) * 2014-10-10 2015-01-14 江苏三棱科技发展有限公司 Bus station arrangement method based on taxi GPS data
CN105427001A (en) * 2015-12-03 2016-03-23 北京理工大学 Optimal route of school bus of regional middle and primary school
CN105427003A (en) * 2015-12-30 2016-03-23 北京航空航天大学 Travel demand analysis-based bus station point deployment method

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9336508B2 (en) * 2012-11-02 2016-05-10 Patrick Soon-Shiong Virtual planogram management, systems, and methods

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101187996A (en) * 2007-10-08 2008-05-28 常飞 A quick bus line selection algorithm based on self-adapted backbone network
CN104282142A (en) * 2014-10-10 2015-01-14 江苏三棱科技发展有限公司 Bus station arrangement method based on taxi GPS data
CN105427001A (en) * 2015-12-03 2016-03-23 北京理工大学 Optimal route of school bus of regional middle and primary school
CN105427003A (en) * 2015-12-30 2016-03-23 北京航空航天大学 Travel demand analysis-based bus station point deployment method

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
定制公交行车站点规划与时刻表编制研究;定制公交行车站点规划与时刻表编制研究;《中国优秀硕士学位论文全文数据库信息科技Ⅱ辑》;20160715;第17-43页 *

Also Published As

Publication number Publication date
CN108647910A (en) 2018-10-12

Similar Documents

Publication Publication Date Title
CN108647910B (en) Method, device and terminal for setting urban bus stop and computer storage medium
US11061984B2 (en) Grid-based geofence data indexing
US20210065226A1 (en) Geographic boundary determination service
Hegeman et al. Near-constant-time distributed algorithms on a congested clique
CN107547633A (en) Processing method, device and the storage medium of a kind of resident point of user
CN111126773B (en) Abnormal vehicle identification method and device and electronic equipment
Kumar et al. A novel heuristic simulation‐optimization method for critical infrastructure in smart transportation systems
CN111815946A (en) Method and device for determining abnormal road section, storage medium and electronic equipment
CN113763700A (en) Information processing method, information processing device, computer equipment and storage medium
CN110633843A (en) Park inspection method, device, equipment and storage medium
CN111159577B (en) Community dividing method and device, storage medium and electronic device
CN116934056A (en) Vehicle scheduling method, device, computer equipment and storage medium
Das et al. A review on coverage-hole boundary detection algorithms in wireless sensor networks
CN116346863A (en) Vehicle-mounted network data processing method, device, equipment and medium based on federal learning
CN113946159B (en) Unmanned aerial vehicle expressway patrol path optimization method and system
Yang et al. Real‐time detection of traffic congestion based on trajectory data
CN111429742B (en) Road side equipment distribution method and device
CN113486100A (en) Service management method, device, server and computer storage medium
CN105766015A (en) Method and apparatus for reducing cell identifier conflicts when deploying a new cell into a telecommunications network
CN111724002B (en) Method for predicting bus to be taken by user and reminding arrival information based on kNN
CN113593217B (en) Traffic police force commanding and dispatching method, equipment and readable storage medium
CN112949887B (en) Method, device and equipment for planning dispatch path and computer readable storage medium
Wang et al. A distributed convergent solution to the ambulance positioning problem on a streetmap graph
CN116385878B (en) Road center line extraction method, distributed system, server, and storage medium
Shanmukhappa et al. Bus transport network in Hong Kong: Scale-free or not

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant