CN109299813B - Method for calculating shortest path length of public transport network under minimum transfer - Google Patents
Method for calculating shortest path length of public transport network under minimum transfer Download PDFInfo
- Publication number
- CN109299813B CN109299813B CN201810998771.2A CN201810998771A CN109299813B CN 109299813 B CN109299813 B CN 109299813B CN 201810998771 A CN201810998771 A CN 201810998771A CN 109299813 B CN109299813 B CN 109299813B
- Authority
- CN
- China
- Prior art keywords
- matrix
- stations
- adjacency matrix
- minimum
- transfer
- 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.)
- Expired - Fee Related
Links
- 238000012546 transfer Methods 0.000 title claims abstract description 54
- 238000000034 method Methods 0.000 title claims abstract description 13
- 239000011159 matrix material Substances 0.000 claims abstract description 60
- 230000008859 change Effects 0.000 claims abstract description 4
- 230000007704 transition Effects 0.000 claims description 2
- 230000006872 improvement Effects 0.000 description 2
- 230000008569 process Effects 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 239000000463 material Substances 0.000 description 1
- 238000005259 measurement Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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/00—Administration; Management
- G06Q10/04—Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
- G06Q10/047—Optimisation of routes or paths, e.g. travelling salesman problem
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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/00—Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
- G06Q50/40—Business processes related to the transportation industry
Landscapes
- Business, Economics & Management (AREA)
- Human Resources & Organizations (AREA)
- Engineering & Computer Science (AREA)
- Economics (AREA)
- Strategic Management (AREA)
- Tourism & Hospitality (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Marketing (AREA)
- General Business, Economics & Management (AREA)
- Physics & Mathematics (AREA)
- Game Theory and Decision Science (AREA)
- Quality & Reliability (AREA)
- Operations Research (AREA)
- Entrepreneurship & Innovation (AREA)
- Development Economics (AREA)
- Health & Medical Sciences (AREA)
- General Health & Medical Sciences (AREA)
- Primary Health Care (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The invention discloses a method for calculating the shortest path length of a public transport network under the condition of least transfer, which comprises the following steps: using a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kRespectively recording the minimum reachable lap number and the corresponding shortest path length between the sites, and initializing a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kTo do so byAndrepresenting a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kIn the initial state of the mobile terminal,andmatrix element in (1)Andsetting to be + ∞; by usingAndmatrix element in (1)Andupdating a matrixAndtoAnditeration matrixAndtoAndm is more than or equal to 2; further increasing the number of transfers does not change the second adjacency matrix H any morek×kLet us orderAt this time, the second adjacency matrix Hk×kThe shortest path length of any two stations in the public transport network under the minimum transfer times is included. The invention iterates the adjacency matrix under the consideration of the minimum transfer times, thereby obtaining the shortest path length under the minimum transfer times.
Description
Technical Field
The invention belongs to the field of public transportation, and particularly relates to a method for calculating the shortest path length of a public transportation network under the condition of minimum transfer.
Background
The public transportation system is an engineering facility for providing transportation service for resident trip and social material transportation, and plays a vital role in the economic development of the country or region and the life of people. In the planning and scheduling process of the public transportation system, the shortest path between stations is one of the factors to be considered. In the public transportation network, transfer has an important influence on the measurement of the path length, different transfer modes are usually corresponding to different path lengths, people generally prefer to reach a destination under a small number of transfer times, but the influence of the transfer on the path length is mostly ignored in the current calculation of the shortest path length of the public transportation network.
Disclosure of Invention
In view of the above drawbacks or needs for improvement in the prior art, the present invention provides a method for calculating a shortest path length of a public transportation network with minimal transfer, thereby solving the technical problem in the prior art that the influence of transfer on the path length is not considered.
In order to achieve the above object, the present invention provides a method for calculating a shortest path length of a public transportation network under minimum transfer, comprising:
(1) using a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kRespectively recording the minimum reachable lap number and the corresponding shortest path length between sites, and a first adjacent matrix Tk×kFirst element t of (1)i,jRepresenting a site niAnd njThe minimum number of reachable laps in between, (t)i,j-1) represents a site niAnd njMinimum transfer betweenDegree of second adjacency matrix Hk×kThe second element h in (1)i,jRepresenting a site niAnd njThe shortest path length under the minimum transfer between the stations, k represents the number of public transportation stations, i belongs to [1, k ]],j∈[1,k];
(2) Initializing a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kTo do so byAndrepresenting a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kIn the initial state of the mobile terminal,andmatrix element in (1)Andsetting to be + ∞;
(5) repeating the step (4) untilI.e. further increasing the number of transfers does not change the second adjacency matrix H any morek×kLet us orderAt this time, the second adjacency matrix Hk×kThe shortest path length of any two stations in the public transport network under the minimum transfer times is included.
Further, the step (3) comprises:
if n isiAnd njTwo stations on a public transport line, i ≠ j, thenElement (1) ofFor matrixIf the shortest travel distance between the stations is obtained, thenElement (1) ofIf the shortest travel time between the stations is obtained, thenWhere v and Δ represent the average traveling speed and average waiting time of the public transportation means, Dis (n), respectivelyi,nj) Representing a site niTo njIf n is a running distance ofiAnd njNot two stations on a public transport line, thenElement (1) of Element (1) of
Further, the step (4) comprises:
(4-2) ifSelecting a site nxAs niAnd njTransfer station between, where x ≠ i ≠ j, calculationA value of (d);
(4-3) removing niAnd njRepeating the step (4-2) for all public transportation stations except the public transportation station, and performing the step for all transfer stations nxIs selected to makeN of minimum valuexAs a transfer station, the transfer station is, if it is notThenIf there is only one site nxMake itThe value is minimum, then the station nxAs transfer stations, and if there are multiple sites nxMake itThe smallest value, thenAnd selectCorresponding site n when value of (d) is minimumxAs transfer stations.
In general, compared with the prior art, the above technical solution contemplated by the present invention can achieve the following beneficial effects:
(1) the invention introduces the adjacency matrix, iterates the adjacency matrix under the consideration of the minimum transfer times, considers the influence of transfer on the shortest path, and further obtains the shortest path length under the minimum transfer times. The shortest path obtained by the method is more accurate in length and stronger in reliability.
(2) The invention can finally obtain the shortest path length between any two stations in the public transport network under the minimum transfer times, including the shortest travel distance and the shortest travel time.
Drawings
Fig. 1 is a flowchart of a method for calculating a shortest path length of a public transportation network under minimal transfer according to an embodiment of the present invention;
fig. 2 is a schematic diagram of a public transportation network provided by an embodiment of the invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention. In addition, the technical features involved in the embodiments of the present invention described below may be combined with each other as long as they do not conflict with each other.
As shown in fig. 1, a method for calculating shortest path length of public transportation network under minimum transfer includes:
(1) using a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kRespectively recording the minimum reachable lap number and the corresponding shortest path length between sites, and a first adjacent matrix Tk×kFirst element t of (1)i,jRepresenting a site niAnd njThe minimum number of reachable laps in between, (t)i,j-1) represents a site niAnd njThe minimum number of transitions between, the second adjacency matrix Hk×kThe second element h in (1)i,jRepresenting a site niAnd njThe shortest path length under the minimum transfer between the stations, k represents the number of public transportation stations, i belongs to [1, k ]],j∈[1,k];
(2) Initializing a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kTo do so byAndrepresenting a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kIn the initial state of the mobile terminal,andmatrix element in (1)Andsetting to be + ∞;
(5) repeating the step (4) untilI.e. further increasing the number of transfers does not change the second adjacency matrix H any morek×kLet us orderAt this time, the second adjacency matrix Hk×kThe shortest path length of any two stations in the public transport network under the minimum transfer times is included.
Further, the step (3) comprises:
if n isiAnd njTwo stations on a public transport line, i ≠ j, thenElement (1) ofFor matrixIf the shortest travel distance between the stations is obtained, thenElement (1) ofIf the shortest travel time between the stations is obtained, thenWhere v and Δ represent the average traveling speed and average waiting time of the public transportation means, Dis (n), respectivelyi,nj) Representing a site niTo njIf n is a running distance ofiAnd njNot two stations on a public transport line, thenElement (1) of Element (1) of
Further, the step (4) comprises:
(4-2) ifSelecting a site nxAs niAnd njTransfer station between, where x ≠ i ≠ j, calculationA value of (d);
(4-3) removing niAnd njPlaces other than the aboveWith the step (4-2) repeated for all transfer stations nxIs selected to makeN of minimum valuexAs a transfer station, the transfer station is, if it is notThenIf there is only one site nxMake itThe value is minimum, then the station nxAs transfer stations, and if there are multiple sites nxMake itThe smallest value, thenAnd selectCorresponding site n when value of (d) is minimumxAs transfer stations.
As shown in fig. 2, assuming that the public transportation network has 7 public transportation stations, there are three public transportation lines: lines 1(1-2-3-4), lines 2(1-2-5-3) and lines 3(6-4-7), the distances between adjacent stations being as shown in fig. 2. Based on the iteration process of the matrixes T and H, the shortest path length of any two stations of the public transportation network under the minimum transfer times can be obtained through three iterations, and the shortest travel distance under the minimum transfer times is taken as an example, and the specific calculation result is as follows:
the method for calculating the shortest path length of the public transport network under the minimum transfer times can calculate the shortest path length between any two stations in the public transport network under the condition of considering the minimum transfer, wherein the shortest path length comprises the shortest travel distance and the shortest travel time.
It will be understood by those skilled in the art that the foregoing is only a preferred embodiment of the present invention, and is not intended to limit the invention, and that any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the scope of the present invention.
Claims (1)
1. A method for calculating the shortest path length of a public transport network under the condition of minimum transfer is characterized by comprising the following steps:
(1) using a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kRespectively recording the minimum reachable lap number and the corresponding shortest path length between sites, and a first adjacent matrix Tk×kFirst element t of (1)i,jRepresenting a site niAnd njThe minimum number of reachable laps in between, (t)i,j-1) represents a site niAnd njThe minimum number of transitions between, the second adjacency matrix Hk×kThe second element h in (1)i,jRepresenting a site niAnd njThe shortest path length under the minimum transfer between the stations, k represents the number of public transportation stations, i belongs to [1, k ]],j∈[1,k];
(2) Initializing a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kTo do so byAndrepresenting a first adjacency matrix Tk×kAnd a second adjacency matrix Hk×kIn the initial state of the mobile terminal,andmatrix element in (1)Andsetting to be + ∞;
(5) repeating the step (4) untilI.e. further increasing the number of transfers does not change the second adjacency matrix H any morek×kLet us orderAt this time, the second adjacency matrix Hk×kThe shortest path length of any two stations in the public transport network under the minimum transfer times is included;
the step (3) comprises the following steps:
if n isiAnd njTwo stations on a public transport line, i ≠ j, thenElement (1) ofFor matrixIf the shortest travel distance between the stations is obtained, thenElement (1) ofIf the shortest travel time between the stations is obtained, thenWhere v and Δ represent the average traveling speed and average waiting time of the public transportation means, Dis (n), respectivelyi,nj) Representing a site niTo njIf n is a running distance ofiAnd njNot two stations on a public transport line, thenElement (1) of Element (1) of
The step (4) comprises the following steps:
(4-2) ifSelecting a site nxAs niAnd njTransfer station between, where x ≠ i ≠ j, calculationA value of (d);
(4-3) removing niAnd njRepeating the step (4-2) for all public transportation stations except the public transportation station, and performing the step for all transfer stations nxIs selected to makeN of minimum valuexAs a transfer station, the transfer station is, if it is notThenIf there is only one site nxMake itThe value is minimum, then the station nxAs transfer stations, and if there are multiple sites nxMake itThe smallest value, thenAnd selectCorresponding site n when value of (d) is minimumxAs transfer stations.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810998771.2A CN109299813B (en) | 2018-08-27 | 2018-08-27 | Method for calculating shortest path length of public transport network under minimum transfer |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810998771.2A CN109299813B (en) | 2018-08-27 | 2018-08-27 | Method for calculating shortest path length of public transport network under minimum transfer |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109299813A CN109299813A (en) | 2019-02-01 |
CN109299813B true CN109299813B (en) | 2021-11-02 |
Family
ID=65165785
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810998771.2A Expired - Fee Related CN109299813B (en) | 2018-08-27 | 2018-08-27 | Method for calculating shortest path length of public transport network under minimum transfer |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109299813B (en) |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102880642A (en) * | 2012-08-20 | 2013-01-16 | 浙江工业大学 | Bus transfer method based on weighted directed network model |
CN105206037A (en) * | 2014-05-30 | 2015-12-30 | 中国电信股份有限公司 | Bus route analysis method and system |
CN106779225A (en) * | 2016-12-22 | 2017-05-31 | 福州大学 | A kind of optimal path method for solving comprising Dominator collection |
CN107808217A (en) * | 2017-10-24 | 2018-03-16 | 山东大学 | A kind of Public Transport Transfer optimization method based on Big Dipper positioning with the volume of the flow of passengers |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20080071849A1 (en) * | 2006-09-15 | 2008-03-20 | Krieger Cynthia A H | Polynomial method for detecting a Hamiltonian circuit |
-
2018
- 2018-08-27 CN CN201810998771.2A patent/CN109299813B/en not_active Expired - Fee Related
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102880642A (en) * | 2012-08-20 | 2013-01-16 | 浙江工业大学 | Bus transfer method based on weighted directed network model |
CN105206037A (en) * | 2014-05-30 | 2015-12-30 | 中国电信股份有限公司 | Bus route analysis method and system |
CN106779225A (en) * | 2016-12-22 | 2017-05-31 | 福州大学 | A kind of optimal path method for solving comprising Dominator collection |
CN107808217A (en) * | 2017-10-24 | 2018-03-16 | 山东大学 | A kind of Public Transport Transfer optimization method based on Big Dipper positioning with the volume of the flow of passengers |
Non-Patent Citations (1)
Title |
---|
Vulnerability effects of passengers" intermodal transfer distance preference and subway expansion on complementary urban public transportation systems;Liu Hong等;《Reliability Engineering and System Safety》;20161015;全文 * |
Also Published As
Publication number | Publication date |
---|---|
CN109299813A (en) | 2019-02-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR20170021233A (en) | System and method for managing supply of service | |
CN104125538B (en) | The secondary localization method and device of RSSI signal intensities based on WIFI network | |
CN105074495B (en) | For the hierarchical service in indoor positioning and the adaptive assistance data of efficiency | |
CN104715286B (en) | The method and apparatus for determining order starting point | |
CN110972073B (en) | Living circle defining method based on mobile phone big data and walking accessibility | |
CN106125043B (en) | A kind of localization method based on position location residual weighted | |
CN115586557B (en) | Vehicle driving track deviation correcting method and device based on road network data | |
CN114111830B (en) | Path planning method and device based on AI model | |
CN103530694A (en) | Urban subway dynamic passenger flow distribution method constructed on the basis of time-space network | |
CN111191817B (en) | Bus network topology division method based on transfer passenger flow | |
CN110019569B (en) | Method for acquiring urban rail transit operation state information | |
Kannan et al. | Predictive indoor navigation using commercial smart-phones | |
CN107978169A (en) | A kind of method of bus station positional deviation correction under the source to multi-source data | |
CN105824818A (en) | Informationized management method, platform and system | |
CN111476389A (en) | Method and device for pre-estimating order receiving waiting time | |
CN113222205B (en) | Path planning method and device | |
CN109299813B (en) | Method for calculating shortest path length of public transport network under minimum transfer | |
Sokolov et al. | Rational solutions for development of telecommunications networks | |
CN110493853B (en) | Sequencing method for high-speed rail private network base stations | |
CN112836991A (en) | Site planning method and device, terminal equipment and readable storage medium | |
EP4394669A1 (en) | Logistics routing network determination method and apparatus, and electronic device | |
CN117114525A (en) | Internet of things-based cross-border logistics big data intelligent management system and method | |
CN113761397B (en) | Recommendation method, system, equipment and storage medium for customizing passenger transport route | |
CN107437208A (en) | Order processing method and server | |
CN115130263A (en) | Multi-traffic-facility equal-time-circle calculation method oriented to territorial space planning |
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 | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20211102 |