Urban rail transit intersection optimization method and device and electronic equipment

By classifying the built environment of rail transit stations using K-means clustering and random forest algorithms, and combining this with a multi-objective genetic algorithm to optimize the large and small route schemes, the problem of poor route optimization in urban rail transit has been solved, and precise operation has been achieved.

CN121562883APending Publication Date: 2026-02-24GUANGDONG URBAN TECHNICIAN COLLEGE
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511622739.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-07
Publication Date
2026-02-24

AI Technical Summary

Technical Problem

In existing technologies, the route optimization effect of urban rail transit is not good. There is a lack of optimization design that systematically incorporates the built environment factors into the operation plan of both large and small routes, resulting in insufficient coordinated optimization of capacity matching, operating costs and passenger waiting time.

Method used

The K-means clustering algorithm is used to spatially classify the built environment factors of the rail transit stations, and a passenger flow prediction model is constructed by combining it with the random forest algorithm. The large and small route schemes are optimized by the multi-objective genetic algorithm to generate differentiated operation strategies.

Benefits of technology

It has achieved in-depth integrated analysis between the built environment and passenger flow, provided a transformation mechanism from spatial cognition to operational decision-making, and improved the operational efficiency and service quality of urban rail transit.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121562883A_ABST
    Figure CN121562883A_ABST
Patent Text Reader

Abstract

The invention provides an urban rail transit intersection optimization method and device and electronic equipment, and the method comprises the steps: employing a K-means clustering algorithm to carry out the spatial classification of construction environment factors of rail transit line stations, and recognizing the types of stations with different functional features; based on the space classification result of the built environment, a random forest algorithm is adopted to construct a passenger flow prediction model fusing multi-dimensional built environment elements, and the passenger flow volume of the rail transit stations along the line is predicted to obtain a passenger flow prediction result; based on the space classification result and the passenger flow prediction result, constructing a large and small intersection multi-target optimization model fusing the built-up environment factors; and solving the large and small intersection multi-target optimization model by combining a multi-target genetic algorithm to obtain a target optimization scheme of the rail transit. According to the invention, a conversion mechanism from space cognition to operation decision is established, and the problem of poor route optimization effect of urban rail transit in the prior art is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of urban rail transit technology, and in particular to a method, apparatus and electronic equipment for optimizing urban rail transit routes. Background Technology

[0002] With the continuous advancement of global urbanization, urban rail transit, as a crucial means of alleviating traffic congestion in large cities, directly impacts urban sustainable development through its operational efficiency. However, as urban spatial structures become increasingly complex, passenger flow exhibits significant asymmetry in its spatiotemporal distribution, rendering traditional single-route operation models inadequate for adapting to diverse travel demands. The built environment, as the concrete carrier and direct manifestation of urban spatial structure, becomes a key mediating variable connecting the macro-spatial pattern of the city with the micro-passenger flow distribution of rail transit through spatial combinations of factors such as land use patterns, building density distribution, transportation facility configuration, and population concentration. Regions with different built environment characteristics exhibit significant differences in travel generation, travel attractiveness, and spatiotemporal distribution, directly determining the passenger flow intensity and distribution patterns at various rail transit stations and sections. Clarifying the intrinsic correlation mechanism between built environment factors and urban rail transit passenger flow distribution, and systematically applying it to the operational optimization decisions of long-short turning routes, is of significant practical importance for achieving precise matching of transportation supply and demand, improving rail transit service quality, and enhancing operational efficiency.

[0003] Currently, research on the impact mechanism of built environment factors on rail transit passenger flow mainly focuses on spatial heterogeneity and passenger flow forecasting methods, but rarely applies these forecasting results systematically to the optimization design of long and short route operation schemes. Methodologically, many models have studied how built environment factors affect passenger flow at rail transit stations. Geographically weighted regression and machine learning methods are widely used in rail transit passenger flow forecasting. Regarding long and short route optimization, existing research mostly adopts traditional passenger flow allocation methods, establishing bi-objective or multi-objective optimization models and using intelligent optimization algorithms such as genetic algorithms for solving them. However, existing research rarely considers the coordinated optimization of capacity matching degree, operation cost, and passenger waiting time simultaneously, and lacks an integrated decision-making framework that systematically incorporates built environment factors into the long and short route optimization decision-making process, resulting in poor optimization effects for urban rail transit routes.

[0004] There is currently no effective solution to the problem of poor route optimization performance in existing related technologies for urban rail transit. Summary of the Invention

[0005] This invention provides a method, apparatus, and electronic device for optimizing urban rail transit routes, in order to address the shortcomings of existing related technologies in terms of poor route optimization effects for urban rail transit.

[0006] In a first aspect, the present invention provides a method for optimizing urban rail transit routes, comprising: The K-means clustering algorithm was used to spatially classify the built environment factors of rail transit stations and identify station types with different functional characteristics. Based on the spatial classification results of the built environment, a passenger flow prediction model integrating multi-dimensional built environment elements is constructed using the random forest algorithm, and the passenger flow of the stations along the rail transit line is predicted to obtain the passenger flow prediction results. Based on the spatial classification results and the passenger flow prediction results, a multi-objective optimization model for large and small routes that integrates built environment factors is constructed. The multi-objective optimization model of the large and small routes is solved by combining a multi-objective genetic algorithm to obtain the target optimization scheme of the rail transit.

[0007] According to the urban rail transit route optimization method provided by the present invention, the K-means clustering algorithm is used to spatially classify the built environment factors of rail transit stations, and identify station types with different functional characteristics, including: The elbow rule is used to determine the optimal clustering parameters of the K-means clustering algorithm and to generate a systematic hierarchical system of built environment factors. Classification rules are formulated based on the combination characteristics of elements, and a multi-factor combination pattern recognition method is used to classify the stations along the rail transit line. Based on the different types of built environment factors, corresponding operational strategy guidelines are generated.

[0008] According to the present invention, an urban rail transit route optimization method is provided, which uses the elbow rule to determine the optimal clustering parameters of the K-means clustering algorithm and generates a systematic hierarchical system of built environment factors, including: Calculate the within-cluster sum of squares corresponding to different clustering parameters, identify the inflection point in the decreasing trend of the within-cluster sum of squares, and determine the optimal clustering parameters; The threshold of each built environment factor is determined by the midpoint value of adjacent cluster centers, and each built environment factor is divided into different levels according to the threshold, forming a systematic building environment factor classification system.

[0009] According to a method for optimizing urban rail transit routes provided by the present invention, a passenger flow prediction model integrating multi-dimensional built environment elements is constructed using a random forest algorithm, and the passenger flow at stations along the rail transit line is predicted to obtain the passenger flow prediction results, including: Obtain the original dataset of passenger flow at stations along the rail transit line, and randomly extract data with replacement from the original dataset to generate a subset dataset; For each decision tree, a regression tree is generated by splitting the feature set of a randomly selected subset of the dataset. The passenger flow at each station along the rail transit line is predicted using each decision tree, and the passenger flow prediction result is determined based on the average of all prediction results.

[0010] According to the present invention, an urban rail transit route optimization method is provided, wherein the objective function of the multi-objective optimization model for large and small routes includes a capacity matching degree function, an operating cost function, and a total waiting time function; The penalty constraints followed by the multi-objective optimization model for large and small routes include waiting time constraints, running interval constraints, load factor constraints, and vehicle number constraints.

[0011] According to the present invention, an urban rail transit route optimization method is provided, which combines a multi-objective genetic algorithm to solve the multi-objective optimization model of the large and small routes to obtain the target optimization scheme of the rail transit, including: The start and end points and departure frequencies of the rail transit routes are encoded; Based on the classification results of the built environment factors and the passenger flow prediction results, a knowledge-guided initialization strategy is adopted to obtain a population containing multiple individuals; each individual in the population corresponds to a route optimization scheme. The population is iteratively evaluated and updated until the number of iterations reaches a preset value or the convergence condition is met, thereby determining the target optimization scheme for the rail transit.

[0012] According to a method for optimizing urban rail transit routes provided by the present invention, the start and end positions and departure frequencies of the rail transit long and short routes are encoded, including: The start and end positions of short routes are encoded in tuple form; The departure frequency of long-haul routes is encoded using integers; The departure frequency of short-route services is encoded using an integer list.

[0013] According to the urban rail transit route optimization method provided by the present invention, the population is iteratively evaluated and updated, including iteratively executing the following steps: For each individual in the population, the objective function value is calculated, and the frontier level is determined based on the dominance relationship of each chromosome using a fast non-dominated sorting strategy, and the crowding distance is calculated. Randomly select individuals from the population, perform crossover and mutation processing, and generate offspring populations; The parent and offspring populations are merged, and new populations are filled according to the frontier level based on the results of the fast non-dominated sorting. When truncation is required, individuals with better diversity are retained as the next generation population based on the crowding distance.

[0014] Secondly, the present invention also provides an urban rail transit route optimization device, comprising: The classification module is used to spatially classify the built environment factors of rail transit stations using the K-means clustering algorithm, and identify station types with different functional characteristics. The prediction module is used to construct a passenger flow prediction model that integrates multi-dimensional built environment elements based on the spatial classification results of the built environment and the random forest algorithm, and to predict the passenger flow of the stations along the rail transit line to obtain the passenger flow prediction results. The construction module is used to construct a multi-objective optimization model for large and small routes that integrates built environment factors, based on the spatial classification results and the passenger flow prediction results. The solution module is used to solve the multi-objective optimization model of the large and small intersections by combining a multi-objective genetic algorithm to obtain the target optimization scheme of the rail transit.

[0015] Thirdly, the present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the urban rail transit route optimization method as described in the first aspect above.

[0016] Compared with the prior art, the present invention has the following beneficial effects: This invention provides a method for optimizing urban rail transit routes. Unlike traditional methods that continuously process built-up environment factors in passenger flow forecasting, this method uses K-means clustering to classify built-up environment variables, categorizing stations along the rail transit line and constructing a technical path from element classification to spatial identification and then to accurate passenger flow forecasting. Compared to traditional continuous variable methods, this method effectively captures the threshold effect and nonlinear correlation mechanism between the built environment and passenger flow, providing a new modeling perspective for rail transit passenger flow forecasting. It achieves a deep integration and analysis of built-up environment spatial classification and route optimization. Distinguishing itself from the current situation where built-up environment analysis and operation optimization are separated, this method directly transforms spatial classification results into actionable differentiated operation strategies for the first time. For passenger flow characteristics of stations with different built-up environment types, an improved multi-objective genetic algorithm is used to achieve multi-objective collaborative optimization, establishing a conversion mechanism from spatial cognition to operational decision-making. This provides a systematic solution for precise operation of urban rail transit and solves the problem of poor route optimization effects in existing related technologies. Attached Figure Description

[0017] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0018] Figure 1 This invention provides a method for optimizing urban rail transit routes. Figure 2 This is a schematic diagram illustrating the degree to which the built environment affects the station's passenger flow in an embodiment of the present invention; Figure 3 This is a schematic diagram of the K-means clustering elbow rule curve in an embodiment of the present invention; Figure 4 This is a schematic diagram of the threshold distribution of different built environment factors in an embodiment of the present invention; Figure 5 This is a schematic diagram showing the classification results of the built environment of stations along Shenzhen Metro Line 1 in this embodiment of the invention; Figure 6 This is a flowchart illustrating the NSGA-II algorithm in an embodiment of the present invention; Figure 7 This is a schematic diagram illustrating the spatial heterogeneity of built environment factors; Figure 8 This is a map showing the distribution of environmental factors affecting the construction of stations on Shenzhen Metro Line 1. Figure 9This is a schematic diagram showing the convergence of the three objective functions during 400 iterations of this invention; Figure 10 This is a schematic diagram of the Pareto front results for 0-3 small loops in an embodiment of the present invention; Figure 11 This is a schematic diagram of the structure of the electronic device provided by the present invention. Detailed Implementation

[0019] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0020] This invention provides a method for optimizing urban rail transit routes. Figure 1 This invention provides a method for optimizing urban rail transit routes, such as... Figure 1 As shown, the method includes the following steps: Step S101: Use the K-means clustering algorithm to spatially classify the built environment factors of the rail transit stations and identify the station types with different functional characteristics. Step S102: Based on the spatial classification results of the built environment, a passenger flow prediction model integrating multi-dimensional built environment elements is constructed using the random forest algorithm, and the passenger flow of stations along the rail transit line is predicted to obtain the passenger flow prediction results. Step S103: Based on the spatial classification results and passenger flow prediction results, construct a multi-objective optimization model for large and small routes that integrates built environment factors; Step S104: Solve the multi-objective optimization model of large and small routes using a multi-objective genetic algorithm to obtain the target optimization scheme for rail transit.

[0021] For example, firstly, the K-means clustering algorithm is used to spatially classify the built environment factors of stations along the rail transit line, identifying station types with different functional characteristics, providing a spatial basis for subsequent passenger flow forecasting and operational strategy formulation. Then, based on the classification results of the built environment factors, the Random Forest algorithm is used to construct a passenger flow forecasting model integrating multi-dimensional built environment elements, exploring the intrinsic correlation mechanism between built environment factors such as land use, population density, and transportation facilities and passenger flow distribution, obtaining passenger flow forecast results. Thirdly, based on the spatial classification results and passenger flow forecast results, a multi-objective optimization model integrating built environment factors is constructed. Finally, the NSGA-II Algorithm is used to solve the large and small loop operation schemes, obtaining the objective optimization scheme for rail transit. Based on this, sensitivity analysis is used to verify the stability and practicality of the model, and targeted policy recommendations are proposed for the precise operation and management of urban rail transit based on the analysis results.

[0022] This paper proposes a novel passenger flow forecasting method driven by built environment element classification. Unlike the continuous processing of built environment factors in traditional passenger flow forecasting, this method uses K-means clustering to classify built environment variables, categorizing stations along the rail transit line and constructing a technical path from element classification to spatial identification and then to accurate passenger flow forecasting. Compared with traditional continuous variable methods, this method effectively captures the threshold effect and nonlinear correlation mechanism between the built environment and passenger flow, providing a new modeling perspective for rail transit passenger flow forecasting. It achieves in-depth integration and analysis of built environment spatial classification and route optimization. Distinguishing itself from the current situation where built environment analysis and operation optimization are separated, this method directly transforms spatial classification results into actionable differentiated operation strategies for the first time. For the passenger flow characteristics of stations with different built environment types, an improved multi-objective genetic algorithm is used to achieve multi-objective collaborative optimization, establishing a conversion mechanism from spatial cognition to operational decision-making. This provides a systematic solution for the precise operation of urban rail transit and solves the problem of poor route optimization effects in existing related technologies.

[0023] Next, we will take Shenzhen Metro Line 1 as an example to describe this method in detail. The research objects mainly include 30 operational rail transit stations along Shenzhen Metro Line 1 as of June 2019, with a total length of approximately 40.876 kilometers and 29 operating sections.

[0024] In some embodiments, step S101 involves using the K-means clustering algorithm to spatially classify the built environment factors of rail transit stations and identify station types with different functional characteristics. This includes: using the elbow rule to determine the optimal clustering parameters of the K-means clustering algorithm and generating a systematic hierarchical system for built environment factors; formulating classification rules based on the combination characteristics of elements and using a multi-factor combination pattern recognition method to classify the rail transit stations; and generating corresponding operation strategy guidelines based on the different types of built environment factors.

[0025] Specifically, the elbow rule is used to determine the optimal clustering parameters of the K-means clustering algorithm and generate a systematic classification system for built environment factors. This includes: calculating the intra-cluster sum of squares corresponding to different clustering parameters, identifying the inflection point in the downward trend of the intra-cluster sum of squares, and determining the optimal clustering parameters; determining the threshold of each built environment factor by the midpoint value of adjacent cluster centers, and classifying each built environment factor into different levels according to the threshold, thus forming a systematic classification system for built environment factors.

[0026] For example, such as Figure 2 As shown, Figure 2 This is a schematic diagram illustrating the importance of the built environment in influencing station passenger flow in this embodiment of the invention. It can be seen that the top five built environment factors affecting passenger flow primarily include: accessibility, average house price, road network density, scenic spots, and land mix. To systematically analyze the intrinsic relationship between the built environment characteristics of each station and passenger flow distribution, and to provide a scientific basis for subsequent passenger flow prediction and optimization of long-distance and short-distance routes, this embodiment uses the K-means clustering algorithm to classify the built environment factors.

[0027] To determine the optimal number of clusters K, this embodiment uses built environment data (including accessibility, average housing price, road network density, scenic spots, and land mix) from 30 stations on Shenzhen Metro Line 1 and employs the elbow rule for K value selection analysis. By calculating the Within-Cluster Sum of Squares (WCSS) corresponding to different K values, the inflection point in the WCSS decreasing trend is identified, thereby determining the optimal clustering parameters. Specific results are as follows: Figure 3 As shown, Figure 3 This is a schematic diagram of the K-means clustering elbow rule curve in an embodiment of the present invention. According to... Figure 3 In this embodiment, the number of clusters K is set to 6.

[0028] In cluster analysis of the various built environment variables, this embodiment uses the K-means algorithm to identify six development levels for each variable. To ensure the reproducibility of the experiment, the random seed is fixed at 42, and the K-means clustering algorithm parameters are set as follows: clustering parameter K=6, maximum number of iterations is 300, and convergence tolerance is 1×10⁻⁶. -4 The initialization iterations are 10 times to ensure that the model can iterate sufficiently and converge stably.

[0029] Each variable is divided into six levels using five thresholds: Level 1 (very low), Level 2 (low), Level 3 (low to medium), Level 4 (high to medium), Level 5 (high), and Level 6 (very high). The thresholds are calculated using the midpoint values ​​of adjacent cluster centers, as shown in the following formula:

[0030] in, Thredshold ij Indicates the distinction of the first i Class and the j Class-level threshold, C i and C j These represent the numbers after being sorted in ascending order by their center values. i The and the first j There are cluster centers, and i < j .

[0031] Based on this, the specific classification thresholds for each variable were obtained, forming a systematic hierarchical system for built environment elements, providing a unified basis for subsequent site horizontal classification, as shown in Table 1.

[0032] Table 1. Thresholds for Classification of Built Environment Factors Based on K-means Clustering

[0033] Table 1 categorizes built environment factors into six levels based on threshold values: Level 1 (Very Low) < Threshold 1; Threshold 1 ≤ Level 2 (Low) < Threshold 2; Threshold 2 ≤ Level 3 (Medium-Low) < Threshold 3; Threshold 3 ≤ Level 4 (Medium-High) < Threshold 4; Threshold 4 ≤ Level 5 (High) < Threshold 5; Level 6 (Very High) ≥ Threshold 5. The threshold distribution for each built environment factor is as follows: Figure 4 As shown, Figure 4 This is a schematic diagram of the threshold distribution of different built environment factors in an embodiment of the present invention.

[0034] The aforementioned analysis determined that K=6 is the optimal number of levels for a single built environment factor, and each factor is divided into 6 levels (levels 1-6). Based on the clustering threshold results in Table 1, this embodiment uses a multi-factor combination pattern recognition method to classify 30 sites, as shown in Table 2. High-level factors are defined as ≥ level 5, medium-high-level factors as ≥ level 4, and low-level factors as ≤ level 3. The number of sites reaching each level across five dimensions—housing price, number of attractions, land mix, road network density, and accessibility—is counted. Classification rules are established based on the combination characteristics of the factors: ≥3 high-level factors are classified as CBD core area; ≥2 high-level factors and ≥2 medium-high-level factors are classified as urban sub-center; ≥3 medium-high-level factors are classified as general urban area; both ≥1 high-level factor and ≥1 low-level factor are classified as transitional area; and ≥3 low-level factors are classified as peripheral area. Furthermore, different operational strategy orientations are given based on different built environment types.

[0035] Table 2. Classification of Environmental Factors Along Rail Transit Stations

[0036] Based on the above criteria, the classification results of the built environment of stations along Shenzhen Metro Line 1 are as follows: Figure 5 As shown, Figure 5 This is a schematic diagram illustrating the classification results of the built environment of stations along Shenzhen Metro Line 1 in this embodiment of the invention. This classification system not only realizes the transformation from qualitative description to quantitative judgment, but also provides theoretical support for the subsequent formulation of differentiated operation strategies. Based on the quantitative identification of the above five categories of built environment characteristics, a basis for discussion can be provided for the formulation of spatial strategies and capacity allocation decisions in the optimization of long and short routes.

[0037] In some embodiments, step S102 involves using a random forest algorithm to construct a passenger flow prediction model that integrates multi-dimensional built environment elements, and predicting passenger flow at stations along the rail transit line to obtain passenger flow prediction results. This includes: acquiring the original dataset of passenger flow at stations along the rail transit line, and randomly sampling from the original dataset with replacement to generate a subset dataset; for each decision tree, splitting it using the feature set of the randomly sampled subset dataset to generate a regression tree; predicting passenger flow at stations along the rail transit line using each decision tree, and determining the passenger flow prediction result based on the average of all prediction results.

[0038] Random forest was chosen as an ensemble learning method based on the following considerations: 1. Nonlinear modeling capability: It can effectively capture the complex nonlinear relationship and threshold effect between built environment factors and passenger flow distribution. 2. Advantages in handling categorical variables: It has good adaptability to categorical variables processed by K-means clustering, avoiding the limitations of traditional linear models. 3. Feature Importance Assessment: The built-in variable importance mechanism helps identify key built environment influencing factors. 4. Robustness: It is not sensitive to noise and outliers, and is suitable for multi-source heterogeneous built environment data.

[0039] The core process of the random forest algorithm is as follows: 1. Sample Extraction: Randomly extract samples with replacement from the original dataset to generate a subset of the dataset. The specific formula is as follows:

[0040] in, For the first Subdatasets, For the first A set of sample indexes for each subset of datasets. For the first The feature vector of each sample For the first The target value for each sample.

[0041] 2. Decision Tree Training: For each decision tree, a randomly selected feature set is used to split it, generating a regression tree. Feature Selection: At each split node j, p features are randomly selected from d features: Fj {1,2,...,d}, |Fj|= p, the specific formula for the splitting criterion is as follows:

[0042] in, j It is a feature index. m It is the number of samples in the current node. It is the first j A random feature set of nodes, It is the first i The true value of each sample These are the predicted values ​​after splitting based on features. MSE ( j ) is the use of features j Mean square error during splitting.

[0043] 3. Final Prediction: The prediction result for the new data point is the average of all decision tree prediction results. The specific formula is as follows:

[0044] in, Input sample x The final predicted value, B It is the number of decision trees. It is the first b The predicted values ​​of each decision tree.

[0045] Based on the above embodiments, the objective functions of the multi-objective optimization model for long and short routes include a capacity matching degree function, an operating cost function, and a total waiting time function.

[0046] This embodiment addresses the uneven passenger flow distribution on urban rail transit lines by adopting a combined long and short route operation mode. Based on passenger flow forecasts using built-up environment factors, it optimizes train departure frequencies and short-route configurations. The research objective is to collaboratively optimize capacity matching degree, operation cost, and total passenger waiting time while meeting operational safety and service quality constraints, thereby determining the optimal long and short route scheme and its departure frequency configuration.

[0047] Specifically, the capacity matching degree of an urban rail transit system refers to the degree of proximity between transport capacity supply and passenger demand. It uses the passenger flow at each section during peak hours as the passenger demand and the transport capacity provided by each section as the supply. The sum of the absolute values ​​of the differences between the two is denoted as . Its geometric meaning is the deviation between the two, and the specific formula is as follows:

[0048] in, For capacity matching degree function, For range index, ; For high-frequency departures on long routes, For the first The frequency of departures on this short route A value of 1 indicates the intersection Coverage area If the value is 0, then the route Uncovered range ; For the number of train formations, The number of passengers in the vehicle is set. For the upward direction, the interval Peak passenger flow at cross-sections.

[0049] Regarding the optimization of train route plans, the enterprise's operating cost mainly includes three core components: train purchase cost, train operating costs, and station service fees. The specific formula is as follows:

[0050] in, For enterprise operating cost function, For the cost of purchasing the train, For train operating costs, Fees for stopping services.

[0051] Train purchase cost The calculation formula is as follows:

[0052] in, The unit price for purchasing the train. For the service life of the undercarriage, For the research period, This represents the total number of vehicles in use.

[0053] Train running fees The calculation formula is as follows:

[0054] in, Cost per unit kilometer traveled by the train. This is the total distance. For high-frequency departures on long routes, For the first The frequency of departures on this short route For the first The distance of a short route.

[0055] Stop service fee The calculation formula is as follows:

[0056] in, Fees for train stop services. The total number of stations, For high-frequency departures on long routes, For the first The frequency of departures on this short route For the first The terminus of this short bus route, For the first The starting station of this short-distance bus route.

[0057] Existing research indicates that urban rail transit has relatively short train intervals, and passenger arrivals during peak hours follow a Poisson distribution, with the specific formula for the probability function as follows:

[0058] in, Let be a function of total waiting time. The total number of stations, For the station Passenger arrival rate For the station's departure frequency, The average waiting time is based on the Poisson distribution.

[0059] The penalty constraints followed by the multi-objective optimization model for long and short routes include waiting time constraints, running interval constraints, load factor constraints, and vehicle number constraints.

[0060] Specifically, to ensure a good passenger experience and service quality, urban rail transit systems must keep passenger waiting times within a reasonable range. Excessive waiting times not only reduce passenger satisfaction but may also lead to passenger loss, impacting the competitiveness of the rail transit system. The specific formula for the waiting time constraint is as follows:

[0061] in, For range index, ; For high-frequency departures on long routes, For the first The frequency of departures on this short route A value of 1 indicates the intersection Coverage area If the value is 0, then the route Uncovered range ; This represents the maximum acceptable waiting time for passengers.

[0062] The operational safety of a rail transit system is paramount, and train intervals must meet the basic requirements of the signaling system and safety regulations. Excessively short intervals increase the risk of rear-end collisions, impacting system safety, and are also limited by the technological capabilities of the signaling equipment. The specific formula for the interval constraint is as follows:

[0063] in, For site range index, ; For high-frequency departures on long routes; For the first The frequency of departures on this short route A value of 1 indicates the intersection Coverage area If the value is 0, then the route Uncovered range , This is the minimum operating time interval.

[0064] Train occupancy rate is an important indicator for measuring the quality of transportation services. Excessively high occupancy rates lead to overcrowding in carriages, severely impacting passenger comfort and safety. Furthermore, overcrowding can also cause passenger safety accidents and reduce the overall service level of the system. The specific formula for constraining train occupancy rate is as follows:

[0065] in, For site range index, ; For high-frequency departures on long routes; For the first The frequency of departures on this short route A value of 1 indicates the intersection Coverage area If the value is 0, then the route Uncovered range ; This refers to the number of train formations. The number of passengers in the vehicle is set. For the upward direction, the interval Peak hour cross-sectional passenger flow This represents the maximum occupancy rate of the train.

[0066] The vehicle count constraint ensures that the total number of vehicles required for the operational plan does not exceed the company's actual vehicle resources, thus ensuring the feasibility of the plan. The specific formula is as follows:

[0067] in, For high-frequency departures on long routes; For the first Frequent departures on short-distance routes; For long-distance turnaround time; For the first Short-haul turnaround time; To maximize the number of vehicles used.

[0068] In some embodiments, step S104, combining a multi-objective genetic algorithm to solve the multi-objective optimization model of large and small routes to obtain the target optimization scheme of rail transit, includes: encoding the start and end positions and departure frequencies of large and small rail transit routes; based on the classification results of built environment factors and passenger flow prediction results, adopting a knowledge-guided initialization strategy to obtain a population containing multiple individuals; each individual in the population corresponds to a route optimization scheme; iteratively evaluating and updating the population until the number of iterations reaches a preset value or the convergence condition is met, to determine the target optimization scheme of rail transit.

[0069] Specifically, the start and end points and departure frequencies of rail transit routes are encoded, including: the start and end points of short routes are encoded in tuple form; the departure frequencies of long routes are encoded in integer form; and the departure frequencies of short routes are encoded in integer list form.

[0070] The population is iteratively evaluated and updated, including the following steps: For each individual in the population, the objective function value is calculated, and the frontier level is determined based on the dominance relationship of each chromosome using a fast non-dominated sorting strategy, and the crowding distance is calculated; individuals in the population are randomly selected, and crossover and mutation are performed to generate offspring populations; the parent and offspring populations are merged, and new populations are filled according to the frontier level based on the fast non-dominated sorting results; when truncation is required, individuals with better diversity are retained as the next generation population based on the crowding distance.

[0071] For example, this embodiment designs the NSGA-II algorithm, which considers built environment factors, to solve the constructed multi-objective optimization model. Based on the built environment classification results, the algorithm prioritizes "transitional area" stations as candidates for short-route turnaround stations, improving the algorithm's convergence efficiency. The solution algorithm flow is as follows: Figure 6 As shown, Figure 6 This is a flowchart illustrating the NSGA-II algorithm in an embodiment of the present invention. The steps are as follows: Step 1: Encoding. The start and end points of short routes are encoded using tuples, the departure frequencies of long routes are encoded using integers, and the departure frequencies of short routes are encoded using lists of integers. A feasible solution is encoded as a dictionary structure, containing the routing scheme and frequency parameters. Built environment factors, based on passenger flow data predicted by a random forest model, provide a reference for the encoding design.

[0072] Step 2: Intelligent Initialization. Based on the built environment classification results, a knowledge-guided initialization strategy is adopted. Stations with a built environment type of "transitional area" and high passenger flow are given priority as candidates for short-route turnaround stations; continuous sections containing multiple high-passenger-flow stations are set as the short-route coverage area; the initial departure frequency is set according to the actual passenger flow distribution of each section. This dual initialization strategy based on built environment characteristics and passenger flow data allows the algorithm to start searching from solutions that are closer to actual needs, improving convergence efficiency.

[0073] Step 3: Fitness Evaluation and Non-Dominated Sort. For each individual in the population, three objective function values ​​are calculated: capacity matching degree, operating cost, and total waiting time. A fast non-dominated sorting strategy is used to determine the frontier hierarchy based on the dominance relationship of each chromosome and to calculate the crowding distance, providing a basis for subsequent selection operations.

[0074] Step 4: Crossover and Mutation. During the crossover process, two individuals are randomly selected from the population, their routing schemes are exchanged, and the average frequency value is calculated. During the mutation process, one individual is randomly selected from the population, and the mutation location is randomly chosen. The origin and destination stations of the routing location are reset, or the frequency value is randomly reset.

[0075] Step 5: Environmental Selection and Population Renewal. The parent and offspring populations are merged, and a new population is filled according to the frontier hierarchy based on the fast non-dominated ordination results. When truncation is necessary, individuals with better diversity are retained as the next generation population based on crowding distance.

[0076] Step 6: Termination condition check. Repeat Steps 3-5 until the number of iterations reaches the maximum value G or the convergence condition is met. Output the first non-dominated frontier as the final Pareto solution set.

[0077] To fully leverage the guiding role of built environment classification results in the optimization process, this embodiment makes targeted improvements to the traditional NSGA-II algorithm. Specifically, it utilizes built environment classification results to prioritize key nodes such as "transition areas" as candidate stations for short-route routes. It uses predicted and accurate passenger flow data to calculate the objective function and sets constraint parameters based on the service standard differences for different built environment types.

[0078] The algorithm parameters were set as follows: 400 iterations, 200 population size, 0.2 mutation rate, and 10 elite individuals. Due to the stochastic nature of the NSGA-II algorithm, a standardized process of multiple independent runs and recording the Pareto front solution set was adopted to ensure the statistical reliability and practical applicability of the results.

[0079] To comprehensively evaluate the contribution of built environment factor classification to the accuracy of passenger flow prediction, three sets of comparative experiments were designed. All models used the average daily passenger flow data of Shenzhen Metro Line 1 during the morning peak hours as the dependent variable, but employed different combinations of independent variables: the RF Without BE model used spatiotemporal features, including date and station interval indices; the RF With BE-Raw model added the raw continuous values ​​of 15 built environment factors to the spatiotemporal features; and the RF With BE-Classified model used built environment factors classified by K-means clustering. Furthermore, to more comprehensively evaluate model performance, this study also compared the models with traditional Geographically Weighted Regression (GWR) and Multiscale Geographically Weighted Regression (MGWR), and the comparison results are shown in Table 3.

[0080] Table 3. Comparison of the accuracy of passenger flow prediction models with different treatment methods for built environment factors.

[0081] Table 3 shows the comparison of prediction accuracy of each model under different built environment factor treatment methods. As can be seen from the table, the built environment factor treated with K-means classification (RF With BE-Classified) performed best on all evaluation indicators. Compared with the model using the original continuous built environment variables, the R² of the classified model improved from 0.911 to 0.952; the Adjusted R² improved from 0.892 to 0.936. Therefore, the classified treatment of built environment factors demonstrates a significant advantage in passenger flow prediction accuracy.

[0082] Taking Shenzhen Metro Line 1 as an example, based on K-means clustering analysis, the built environment of the 30 stations along Shenzhen Metro Line 1 exhibits significant spatial differentiation characteristics, with each type showing significant differences in the combination and spatial distribution of built environment elements. To visually demonstrate the built environment characteristics of the stations along the line, a map was drawn. Figure 7 , Figure 7 This is a schematic diagram of the spatial heterogeneity of built environment factors.

[0083] Figure 7 This study presents the spatial distribution pattern of built environment factors at each station of Shenzhen Metro Line 1, clearly reflecting the clustering characteristics and differentiation patterns of different types of stations along the line. To further quantify the spatial distribution of various built environment elements, this study mapped... Figure 8 The map shows the distribution of environmental factors at each station of Shenzhen Metro Line 1.

[0084] Combination Figure 8 Analysis of the station distribution map reveals that the built environment of the 30 stations on Shenzhen Metro Line 1 exhibits clear functional zoning and differentiation patterns in its spatial distribution. The following analysis will examine the spatial distribution characteristics of five built environment types and their corresponding operational strategy orientations, providing a spatial decision-making basis for optimizing long and short loop routes.

[0085] This differentiated strategy, based on in-depth analysis of built environment elements, not only provides a scientific basis for the spatial layout of major and minor traffic routes, but also achieves a precise match between transport capacity allocation and urban spatial development patterns.

[0086] To verify the convergence performance and optimization effect of the NSGA-II algorithm, Figure 9 The convergence of the three objective functions of the algorithm is shown during 400 iterations. Figure 9This diagram illustrates the convergence of the three objective functions across 400 iterations of this invention. As can be seen from the diagram, the three objective functions—capacity matching degree, enterprise operating cost, and waiting time—all exhibit good convergence trends, verifying the effectiveness and stability of the NSGA-II algorithm in solving multi-objective optimization problems involving both long and short routes in urban rail transit.

[0087] like Figure 10 As shown, Figure 10 This is a schematic diagram of the Pareto front results for 0-3 minor paths in an embodiment of the present invention. First, the number of minor paths was set to 0 (representing only major paths), 1, 2, and 3, respectively, yielding Pareto front results for four minor paths. Given the large number of Pareto solutions, only some solutions that performed well in various evaluation metrics are listed. The number of minor paths is set, corresponding to... Figure 10 The coordinate axes are a, b, c, and d. The three axes represent three objective functions: capacity matching degree, operating cost, and total waiting time. The optimal solution among the four options is found by comparing each route with a single route.

[0088] To verify the true contribution of built environment factors to the optimization effect, the optimization results based on different passenger flow prediction models were compared, as shown in Table 4. Each algorithm still used 400 iterations. The results show the progressive improvement effect of the three models. RF Without BE, as the baseline model, has a capacity matching degree of 267,850 passenger-hours, an operating cost of RMB 242,394,900, and a waiting time of 1,601 passenger-minutes. After introducing the original built environment variables, RF With BE-Raw reduced the capacity matching degree to 237,860 passenger-hours and the operating cost to RMB 233,979,800, but the waiting time increased to 1,700 passenger-minutes. After applying built environment classification, RF With BE-Classified further reduced the capacity matching degree to 200,964 passenger-hours, the operating cost to RMB 224,563,200, and the waiting time to 1,756 passenger-minutes.

[0089] Table 4 Comparison of the optimization effects of different prediction models for large and small intersections

[0090] A comparison of the three models reveals that the RF With BE-Classified model performs best in both core indicators: capacity matching and operating cost. Compared to the RF Without BE model, it improves capacity matching by 66,886 passenger-hours, saves RMB 17.8317 million in operating costs, and reduces the number of trains in use by two. Compared to the RF With BE-Raw model, it further improves capacity matching by 36,896 passenger-hours and saves RMB 9.4166 million in costs. Although waiting time has increased, the significant advantages of the built-up environment classification method in key operational indicators validate its effectiveness.

[0091] This invention also provides an urban rail transit route optimization device. The urban rail transit route optimization device provided by this invention is described below. The urban rail transit route optimization device described below can be referred to in correspondence with the urban rail transit route optimization method described above. The device includes: The classification module is used to spatially classify the built environment factors of rail transit stations using the K-means clustering algorithm, and identify station types with different functional characteristics. The prediction module is used to construct a passenger flow prediction model that integrates multi-dimensional built environment elements based on the spatial classification results of the built environment and the random forest algorithm, and to predict the passenger flow of stations along the rail transit line to obtain the passenger flow prediction results. The module is used to build a multi-objective optimization model for major and minor routes that integrates built environment factors, based on spatial classification results and passenger flow prediction results. The solution module is used to solve the multi-objective optimization model of large and small intersections by combining a multi-objective genetic algorithm, so as to obtain the target optimization scheme of rail transit.

[0092] For example, firstly, the classification module uses the K-means clustering algorithm to spatially classify the built environment factors of stations along the rail transit line, identifying station types with different functional characteristics, providing a spatial basis for subsequent passenger flow forecasting and operation strategy formulation. Then, based on the classification results of the built environment factors, the prediction module uses the random forest algorithm to construct a passenger flow forecasting model that integrates multi-dimensional built environment elements, exploring the inherent correlation mechanism between built environment factors such as land use, population density, and transportation facilities and passenger flow distribution, obtaining passenger flow forecast results. Next, based on the spatial classification results and passenger flow forecast results, the construction module constructs a multi-objective optimization model that integrates built environment factors. Finally, the solution module uses a multi-objective genetic algorithm to solve for the large and small route operation schemes, obtaining the objective optimization scheme for rail transit. Based on this, sensitivity analysis verifies the stability and practicality of the model, and based on the analysis results, targeted policy recommendations are proposed for the precise operation and management of urban rail transit.

[0093] Unlike traditional continuous processing of built-up environment factors in passenger flow forecasting, this device employs K-means clustering to classify built-up environment variables, categorizing stations along the rail transit line and constructing a technical path from element classification to spatial identification and then to accurate passenger flow forecasting. Compared to traditional continuous variable methods, this device effectively captures the threshold effect and nonlinear correlation mechanism between the built-up environment and passenger flow, providing a new modeling perspective for rail transit passenger flow forecasting. It achieves in-depth integration and analysis of built-up environment spatial classification and route optimization. Distinguishing itself from the current research that separates built-up environment analysis from operational optimization, it is the first to directly transform spatial classification results into actionable differentiated operational strategies. For passenger flow characteristics of stations with different built-up environment types, an improved multi-objective genetic algorithm achieves multi-objective collaborative optimization, establishing a conversion mechanism from spatial cognition to operational decision-making. This provides a systematic solution for precise operation of urban rail transit and solves the problem of poor route optimization effects in existing related technologies.

[0094] Figure 11 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 3 As shown, the electronic device may include: a processor 1101, a communication interface 1102, a memory 1103, and a communication bus 1104, wherein the processor 1101, the communication interface 1102, and the memory 1103 communicate with each other via the communication bus 1104. The processor 1101 can call logical instructions in the memory 1103 to execute an urban rail transit route optimization method, which includes: The K-means clustering algorithm was used to spatially classify the built environment factors of rail transit stations and identify station types with different functional characteristics. Based on the spatial classification results of the built environment, a passenger flow prediction model integrating multi-dimensional built environment elements is constructed using the random forest algorithm, and the passenger flow of stations along the rail transit line is predicted to obtain the passenger flow prediction results. Based on spatial classification results and passenger flow prediction results, a multi-objective optimization model for large and small routes that integrates built environment factors is constructed. By combining a multi-objective genetic algorithm to solve the multi-objective optimization model of large and small routes, the target optimization scheme of rail transit is obtained.

[0095] Furthermore, the logical instructions in the aforementioned memory 1103 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0096] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.

[0097] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for optimizing urban rail transit routes, characterized in that, include: The K-means clustering algorithm was used to spatially classify the built environment factors of rail transit stations and identify station types with different functional characteristics. Based on the spatial classification results of the built environment, a passenger flow prediction model integrating multi-dimensional built environment elements is constructed using the random forest algorithm, and the passenger flow of the stations along the rail transit line is predicted to obtain the passenger flow prediction results. Based on the spatial classification results and the passenger flow prediction results, a multi-objective optimization model for large and small routes that integrates built environment factors is constructed. The multi-objective optimization model of the large and small routes is solved by combining a multi-objective genetic algorithm to obtain the target optimization scheme of the rail transit.

2. The urban rail transit route optimization method according to claim 1, characterized in that, The K-means clustering algorithm was used to spatially classify the built environment factors of rail transit stations, identifying station types with different functional characteristics, including: The elbow rule is used to determine the optimal clustering parameters of the K-means clustering algorithm and to generate a systematic hierarchical system of built environment factors. Classification rules are formulated based on the combination characteristics of elements, and a multi-factor combination pattern recognition method is used to classify the stations along the rail transit line. Based on the different types of built environment factors, corresponding operational strategy guidelines are generated.

3. The urban rail transit route optimization method according to claim 2, characterized in that, The elbow rule is used to determine the optimal clustering parameters of the K-means clustering algorithm, and a systematic hierarchical system of built environment factors is generated, including: Calculate the within-cluster sum of squares corresponding to different clustering parameters, identify the inflection point in the decreasing trend of the within-cluster sum of squares, and determine the optimal clustering parameters; The threshold of each built environment factor is determined by the midpoint value of adjacent cluster centers, and each built environment factor is divided into different levels according to the threshold, forming a systematic building environment factor classification system.

4. The urban rail transit route optimization method according to claim 1, characterized in that, A random forest algorithm was used to construct a passenger flow prediction model that integrates multi-dimensional built environment factors, and the passenger flow at stations along the rail transit line was predicted to obtain the passenger flow prediction results, including: Obtain the original dataset of passenger flow at stations along the rail transit line, and randomly extract data with replacement from the original dataset to generate a subset dataset; For each decision tree, a regression tree is generated by splitting the feature set of a randomly selected subset of the dataset. The passenger flow at each station along the rail transit line is predicted using each decision tree, and the passenger flow prediction result is determined based on the average of all prediction results.

5. The urban rail transit route optimization method according to claim 1, characterized in that, The objective functions of the multi-objective optimization model for large and small routes include the capacity matching degree function, the operating cost function, and the total waiting time function. The penalty constraints followed by the multi-objective optimization model for large and small routes include waiting time constraints, running interval constraints, load factor constraints, and vehicle number constraints.

6. The urban rail transit route optimization method according to claim 1, characterized in that, The multi-objective optimization model of the large and small loop routes is solved by combining a multi-objective genetic algorithm to obtain the objective optimization scheme of the rail transit, including: The start and end points and departure frequencies of the rail transit routes are encoded; Based on the classification results of the built environment factors and the passenger flow prediction results, a knowledge-guided initialization strategy is adopted to obtain a population containing multiple individuals; each individual in the population corresponds to a route optimization scheme. The population is iteratively evaluated and updated until the number of iterations reaches a preset value or the convergence condition is met, thereby determining the target optimization scheme for the rail transit.

7. The urban rail transit route optimization method according to claim 6, characterized in that, The starting and ending points and departure frequencies of the aforementioned rail transit routes are encoded, including: The start and end positions of short routes are encoded in tuple form; The departure frequency of long-haul routes is encoded using integers; The departure frequency of short-route services is encoded using an integer list.

8. The urban rail transit route optimization method according to claim 6, characterized in that, The population is iteratively evaluated and updated, including iteratively performing the following steps: For each individual in the population, the objective function value is calculated, and the frontier level is determined based on the dominance relationship of each chromosome using a fast non-dominated sorting strategy, and the crowding distance is calculated. Randomly select individuals from the population, perform crossover and mutation processing, and generate offspring populations; The parent and offspring populations are merged, and new populations are filled according to the frontier level based on the results of the fast non-dominated sorting. When truncation is required, individuals with better diversity are retained as the next generation population based on the crowding distance.

9. A route optimization device for urban rail transit, characterized in that, include: The classification module is used to spatially classify the built environment factors of rail transit stations using the K-means clustering algorithm, and identify station types with different functional characteristics. The prediction module is used to construct a passenger flow prediction model that integrates multi-dimensional built environment elements based on the spatial classification results of the built environment and the random forest algorithm, and to predict the passenger flow of the stations along the rail transit line to obtain the passenger flow prediction results. The construction module is used to construct a multi-objective optimization model for large and small routes that integrates built environment factors, based on the spatial classification results and the passenger flow prediction results. The solution module is used to solve the multi-objective optimization model of the large and small intersections by combining a multi-objective genetic algorithm to obtain the target optimization scheme of the rail transit.

10. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the urban rail transit route optimization method as described in any one of claims 1 to 8.