Dynamic Demand-Responsive Feeder Bus Network Design for a Short Headway Trunk Line

: Recent advancements in technology have increased the potential for demand-responsive feeder transit services to enhance mobility in areas with limited public transit access. For long rail headways, feeder bus network algorithms are straightforward, as the maximum feeder service cycle time is determined by rail headway, and bus–train matching is unnecessary. However, for short rail headways, the algorithm must address both passenger–feeder-bus and feeder-bus–train matching. This study presents a simulated annealing (SA) algorithm for ﬂexible feeder bus routing, accommodating short headway trunk lines and multiple bus relocations for various stations and trains. A 5 min headway rail trunk line example was utilized to test the algorithm. The algorithm effectively managed bus relocations when optimal routes were infeasible at speciﬁc stations. Additionally, the algorithm minimized total costs, accounting for vehicle operating expenses and passenger in-vehicle travel time costs, while considering multiple vehicle relocations.


Introduction
The modal share for ridesharing has been in decline over the past few decades; however, it still has played an important role in mobility as one of the influencing travel modes in the United States [1].There has been significant consideration given to on-demand ride services in recent years from federal and state governments and private sectors for improving on-demand transit services, especially in areas with limited accessibility to public transit services.Fewer mobility options are available in suburban areas because of weaker production/attraction centers of trips in a relatively large area and unpredictable travel demand based on low population density [2].The flexible demand-responsive transit system (DRT), as an on-demand ride service, has been considered as an efficient mobility option in urban and suburban areas in many studies; however, the efficiency of these systems is open to discussion because of the different approaches and perspectives toward considering passengers and operator costs [3,4].Generally, DRT systems have been proved in past studies as transit systems capable of satisfying even large transit demands and as a complementary transit mode that supports conventional transit systems [5].Considering the advancement of new communication and computational technologies in transportation and transit systems such as automation and connectivity of vehicles, the demand-responsive transit systems with time windows (DRTTW) can take advantage of these technologies to improve the quality of service and maximize serving demands.
The proposed DRT feeder system in the current study performs as a complementary transit system with a rail system.A feeder system should follow routes and timetables to match demand requests to maximize demand coverage while improving the quality of service by maximizing fleet efficiency [6].However, the perspectives of passengers and operators using a DRT system are different.From users' perspective, their in-vehicle travel time should be minimized; therefore, direct routes are preferable for them because this will decrease their travel time and consequently the total passengers' travel cost.On the other hand, the operator seeks to minimize vehicles' traveled distances because that will decrease vehicle travel time and consequently the total transit operational costs.This problem should consider both user and operator costs at the same time as total costs, and therefore, it has a complex structure.In past studies, it has been introduced as an NP-Hard problem that should be solved by heuristics and metaheuristic methods [7].
Previously, an algorithm for a feeder bus routing problem was developed which accommodated multiple stations and feeder buses while allowing relocations of feeder buses [8].For that research, it was assumed that the headway of the rail service is long enough for the feeder buses to come back by the next train.Because the maximum feeder service cycle time is determined by the rail headway, matching between feeder buses and the trains is not necessary.However, if the headway of the rail service is not long enough for the feeder buses to return before the next train, then the algorithm should find not only matching between passengers and feeder buses but also matching between feeder buses and trains, which makes the problem much more complicated and distinguishes this research from the previous research.In this research, using the previously developed algorithm and the model network, the headway of trains is decreased from 20 min to 5 min, making the problem more realistic and usable not only for suburban areas but also for the higher-frequency rail lines serving urban areas.Transportation network companies (TNCs) such as Uber and Lyft have actively expanded their services in the U.S. in recent years; more realistic and optimized routing algorithms for these companies can remarkably decrease their operating costs and resources while increasing the satisfaction of time-sensitive originto-destination passengers in urban areas.The results of this study could be utilized by transportation authorities, transport investment agencies, and collaborators in urban and suburban transportation systems.The remainder of this contribution is structured as follows: the literature review is presented in Section 2, the methodology of the research is proposed in Section 3, the hypothetical network is explained in Section 4, the results and analysis are provided in Section 5, and the discussion and conclusion are stated in Section 6.The references are presented in the last section of this manuscript.

Literature Review
The subject of feeder bus transit systems has been considered in past studies from various perspectives.Most of these studies have considered developing vehicle routing and scheduling algorithms by considering relevant time windows.This study categorizes the subject into four areas: last-mile transportation (LMT) problems, demand-response transit, dial-a-ride problems, and coordinated feeder bus transit systems.The following literature review concentrates on past studies related to proposing or developing routing and scheduling algorithms.

Last-Mile Transportation Problem
LMT issues generally relate to delivering passengers from mass transit systems to their destinations when those destinations are not within walking distance.In recent years, some studies focused on both shared and private LMT transit systems.LMT services have been widely used in industry, especially for goods transportation services.
Some studies addressed LMT transit systems as personal rapid transit (PRT) systems [9,10]; however, a few studies focused on the operating issues of LMTs.Wang [11] focused on lastmile transportation system (LMTS) constraints in proposing an algorithm for a DRT system.The proposed model considered a DRT system coordinated with a rail system and also minimization of passengers' total travel time including waiting and in-vehicle travel times.Raghunathan, Bergman [12] improved the model of Wang [11] by using a constructive heuristic and local search procedure to find better-quality solutions.Ma, Rasulkhani [13] proposed an integrated dynamic dispatch and idle vehicle relocation algorithm to improve multimodal aspects of LMTSs by considering a range of door-to-door service options including ridesharing, rideshare-transit-rideshare, and rideshare-transit-walking.They believed the proposed algorithm could save costs for both passengers and the operator.

Demand-Responsive Transit
The flexible demand-responsive transport services have been considered both theoretically and practically [14][15][16][17][18]. Shuttle vans, dial-and-ride services, and dial-up buses are examples of shared demand-response transport services in urban and suburban areas.Past studies proved that these systems potentially could improve mobility efficiency in urban and suburban areas not only for general travelers but also for those with special issues, e.g., the elderly or disabled [3,19].
LMT could be considered as one branch of DRT problems; however, DRT studies have concentrated mainly on developing and proposing routing and scheduling of vehicles, while LMT studies focused on optimizing passenger allocation to designated destinations.Balancing travel demand and service supply to find the desired level of flexibility in mode choice was the main goal of the earliest studies, the majority of which focused on the single-vehicle pickup and delivery problem [20,21].Recently, most studies tried to propose more realistic and complicated algorithms by considering multiple passengers and multiple vehicles [22,23].A range of attempts to find optimal solution methods have been implemented in past studies: metaheuristics methods [24,25], fuzzy logic approaches [26], integer programming (exact solution) [27], and classification methods [28].
The main weakness of reviewed studies regarding DRT problems was the relocation of vehicles between designated origins/destinations. Recent studies mainly have focused on the dynamic nature of demand-responsive services considering the use of emerging technologies that provide real-time spatial-temporal information about passengers and vehicles.Okulewicz and Ma ńdziuk [29] applied a continuous search space approach to solve a dynamic VRP.They proved that this approach provides optimal solutions with better qualities and stabilities compared with the use of a discrete space.Also, the dynamic approaches are mainly applied in the re-optimization of routing and disruption management after perturbations [30,31].Vansteenwegen, Melis [32] conducted an extensive literature review on the demand-responsive public bus systems.

The Dial-a-Ride Problem
Dial-a-ride problems (DARPs) have been considered as a variant of DRT problems; however, in a DARP problem, the focus is on pickup and delivering passengers from the exact points to defined points in an allowed time window [33,34].The pickup and delivery problem with time windows (PDPTW) and dial-a-ride problems with time windows (DARPTWs), which are both a generalization of the vehicle routing problem (VRP), are similar to DRT and DARP problems.All these problems involve providing point-to-point transportation services while considering spatial-temporal information about passengers.
The main goal of these problems is creating the best routes for vehicles where both vehicles' and passengers' traveling costs are minimized.PDPTWs and DARPTWs are essentially linear models; however, in recent years, by considering new variable and more realistic circumstance factors these models turned out to be dynamic and nonlinear [35].Ayadi, Chabchoub [36] proposed a metaheuristic method to solve a single-depot DRT problem by minimizing the operator's cost.They considered a static DRT problem which considered fixed demands and routes.However, this model could only be implemented in small networks.Osaba, Diaz [37] solved a DRT algorithm that was modeled as a rich traveling salesman problem (RTSP).Although the proposed model aimed to minimize the sum of the costs from all routes and a Golden Ball metaheuristics was implemented as a solution, the model did not coordinate with another transit system.van Engelen, Cats [38] developed an online dynamic insertion algorithm with demand forecasts, aiming to minimize passengers' travel costs.The results of their model showed that the proposed model could reduce passenger travel and waiting times at the same time.The issue they needed to address in future studies was the possibility of relocating shared vehicles when there is a high volume at a certain station.Recently, Paradiso, Roberti [39] formulated an exact solution framework to address the capacitated multi-trip vehicle routing problem with time windows.In this approach, they established two computationally efficient lower bounds.These bounds were utilized within the framework to produce a condensed set of columns encompassing any optimal multi-trip vehicle routing solution.Subsequently, a branch-and-cut method was employed to identify the optimal solution.

Coordinated Feeder Bus Transit Systems (CFBT)
The issue of integrating trunk service and its feeder bus service has been considered in many studies [38,[40][41][42].Kuah and Perl [43] conducted the first study in this regard by considering metro rail as a trunk service; however, they did not consider the coordination of feeder bus and mass transit systems.More studies tried to develop this model, but most of them assumed that there are always enough vehicles to respond to the passengers' demand.Therefore, the two issues of relocating vehicles and waiting times of passengers due to possible queues have been neglected in most of the past studies.Also, considering a specific case when the headway of coordinated mass transit is too short was one of the main weaknesses of the past studies.
Although these reviewed studies have provided useful results that can minimize passenger or operator costs, there are still limitations in implementing these approaches in urban and suburban areas.The current study has two main innovations that distinguish it from previous studies.The first is considering the benefits of the user and the operator of a short headway transit service simultaneously in a model.Most of the reviewed studies considered increased operator revenues by scheduling vehicles on optimal routes even though individual passengers' travel time and traveler preferences are important variables that can change travel behavior, specifically when it comes to the use of a mass transit system with short headway.The second is considering the relocation of feeder buses between train stations while the headway of trains is short.There is little knowledge about considering the relocation of fleet service despite the fact that in short-headway and high-demand conditions, fleet relocation might be required.Table 1 shows a summary of selected studies related to designing routing algorithms for demand-responsive feeder transit services.

Methodology
The authors previously developed an algorithm for demand-responsive feeder transit services for a long headway trunk line [8].The previous research aimed to find an optimal routing solution for feeder buses assigned to train stations, where they were supposed to pick up and drop off passengers from and to train stations.The objective function of the algorithm was minimizing total costs, including vehicle operating costs and passenger travel time, while limiting individual passengers' maximum travel times.This differentiated the algorithm from typical delivery-pickup algorithms, which do not consider individual passengers' travel times.Furthermore, the study's other innovations included accommodating the relocation of buses and the dynamic nature of the operation involving multiple stations and trains.
While the previous algorithm was developed based on a long headway for a trunk line (20 min), this study reduces the headway of trains from 20 min to 5 min.Like the algorithm for the previous research, this algorithm minimizes the total cost, including vehicle operating costs and passenger travel time, while individual passengers' maximum travel times are limited within given maximum travel times.The main challenge of the model lies in the short headway of trains while considering passengers' time windows.When the rail service's headway is long enough for feeder buses to return before the next train arrives, the feeder network algorithm is relatively simple because the maximum feeder service cycle time is determined by the rail headway, and matching between feeder buses and trains is unnecessary.However, if the rail service's headway is not long enough for the feeder buses to return before the next train, the algorithm must find matches not only between passengers and feeder buses but also between feeder buses and trains.
This algorithm applies the simulated annealing (SA) algorithm to solve the proposed model.Figure 1 represents a conceptual operating framework of the proposed demandresponsive feeder transit in our study.

Mathematical Formulation
The problem consists of three main parameters: S as the number of train stations, K as the number of available feeder buses at the station s, and   as the number of passengers in station s.In this model, (, ) represents passengers around the train stations who can be alighted/boarded to/from stations where  ≠  = {1,2, . .,   }.Each station of s has the total number of   available at the beginning.The generated routes by the al-

Mathematical Formulation
The problem consists of three main parameters: S as the number of train stations, K as the number of available feeder buses at the station s, and I s as the number of passengers in station s.In this model, (i, j) represents passengers around the train stations who can be alighted/boarded to/from stations where i = j = {1, 2, . . . ,I s }.Each station of s has the total number of TV s available at the beginning.The generated routes by the algorithm can be defined as d s ij which is the direct distance between passengers i and j of station s and also d s i0 that represents the direct distance between passenger i and station s.RT s i is defined as the requested time of passenger i at station s.The speed of vehicles is defined by the speed parameter and capacity by the parameter of C. The following is the mathematical formulation.The parameter C T represents the time value of passengers per hour, and C O represents the unit operating cost of vehicles per kilometer.Objective Function: Variables: ∑ K k=1 (α s ijk +α s jik ≤ 1 i, j = 1, 2, . . ., I s ; i = j; ∀s v s k = (0, 1), α s ijk = (0, 1), y s ik = (0, 1) Formula ( 1) is the objective function of the problem.Constraint (2) specifies that each passenger is served by exactly one vehicle in that M is a big enough number used for modeling the expression.Constraint (3) ensures that if a passenger is assigned to a vehicle, it is considered as a used vehicle.Constraint (4) ensures that each vehicle starts and ends its trip from/to a station.Equation ( 5) makes sure that the total number of used vehicles does not exceed the total number of available vehicles.Equations ( 6) and ( 7) define each vehicle's path.Equations ( 8) and ( 9) make sure that each passenger is assigned to a path.(Also, zero is the index used for depot.)Equations ( 10)-( 12) calculate the total traveled distance up to passenger i.When having relocated vehicles, Equation (12) calculates the distance to the first passenger based on the relocated vehicle's station.Equation ( 13) defines the arrival time of vehicles to passengers where speed defines the vehicle's speed.Equation ( 14) calculates waiting time for passengers, and Equation ( 15) is an additional time ratio constraint that ensures passengers will be delivered within the required time window.Equation ( 16) specifies in which trip of each vehicle the passenger is picked up.Equations ( 17) and (18) ensure that passenger arrival time at the station is scheduled before their requested time.Constraint (18) is the cycle time constraint.Equations ( 19) and ( 20) are capacity constraints.Equation (19) ensures that if passenger j is served after passenger i in station s, the used capacity of the vehicle after picking up passenger j of station s is higher unless the vehicle comes back to the station.The total traveled distance is defined by Equation (21).

Algorithm
The DRTTW problems are combinatorial, and encountering multiple local optima is expected.This study employs the SA algorithm due to its capability to escape local optima by accepting sub-optimal solutions.Moreover, given the problem's nature, the SA algorithm can efficiently navigate a vast solution space, offering flexibility to explore and, through iterative refinements, achieve a near-optimal solution within a reasonable timeframe.The SA algorithm starts with a random solution and an initial high temperature.As iterations progress, the temperature decreases according to a cooling schedule.Convergence is determined by a set number of iterations and when temperature drops below a threshold.A cooling rate of 0.99 was chosen to ensure a gradual reduction in temperature, allowing the algorithm an extended exploration period before becoming more exploitative.Furthermore, the initial temperature was set at a sufficiently high value, enabling the algorithm to explore a broad spectrum of solutions from the outset.This strategy allows the SA algorithm to start with a more explorative approach, accepting even some suboptimal solutions to ensure it does not become trapped in local minima.
When there are many passengers with different arrival time requests, meeting the exact train may not be so necessary, which means feeder buses can deliver the passengers any time as long as it is no later than their requested time.Although feeder buses can deliver passengers any time before the requested time, waiting time due to the early arrival should be included in the total travel time, and the maximum travel time ratio constraint should be met.Also, passengers cannot be picked up before their available departure time.To generate the initial solution, a random permutation with the length of "number of passengers at the related station plus number of feeder buses minus one" is produced.Then, depending on the location of greater numbers, the assignment of passengers to feeder buses is determined.For instance, in the presence of two feeder buses and 10 passengers, a permutation with length 11 is produced.Suppose that the generated permutation is as follows: Path = [10,1,3,4,8,11,2,9,5,7,6].The path creator section was included in the model as a sub-algorithm.
The next step is to define the routes of feeder buses.The feeder bus first picks up the first assigned passenger and continues picking up the others in turn.However, it would return to the station if its capacity is full.Also, it makes a comparison and returns to the station if the cost of the trip when returning to the station is less than the cost of continuing the route and picking up the next passenger.The feeder bus can also wait for the passenger to reach the passenger's allowed time to pick up based on the maximum acceptable time ratio.Furthermore, the feeder bus tries to return to the station before the requested times of its passengers.In each iteration, the algorithm tries to improve the solution by searching its neighborhoods.For this purpose, common swap, insertion, and reversion methods were used.
The algorithm calculates the earliest and latest possible alighting/boarding time for each passenger.The latest alighting/boarding time is simply equal to the difference between arrival/departure time request and direct travel time (arrival/departure time request-direct travel time).In this stage, the algorithm assumes the feeder bus goes directly to the station right after alighting/boarding the passenger.In the next step, a series of passengers would be assigned to each vehicle, and new variables named "updated latest alighting/boarding time" would be introduced which are the latest possible alighting/boarding time for each passenger according to the defined series of passengers.This variable helps determine what series of passengers after serving a certain series should be served.Obviously, the updated latest alighting/boarding time will be equal to the latest alighting/boarding time for the last passenger.If we indicate a series of passengers with i, then the updated latest alighting/boarding time can be expressed as Updated latest pick up time (i) = min (Updated latest pick up time (i + 1) − direct travel time from i to (i + 1), latest pick up time (i)) In the previous algorithm, after assigning a series of passengers to each vehicle, the algorithm tries to make a route for each vehicle.However, in the developed algorithm, the introduced variable of updated latest alighting/boarding time decides whether vehicles return to the station or continue the trip.In this case, when the cost (both vehicle and passenger traveling costs) of going back to the station is less than continuing the trip, the vehicles return to the station only if there is a feasible solution for that.In other words, the updated latest alighting/boarding time must be bigger than the arrival/departure time.Therefore, the variable of the updated latest alighting/boarding time ensures reaching a feasible solution.
The cost of each new solution (Z') is calculated based on the passengers' travel time and the cost of consumed fuel.The travel time of passengers picked up at stations and getting off at destinations is equal to the destination arrival time minus feeder bus departure time.The travel time of passengers getting off at train stations is equal to the arrival time at the train station minus the arrival time of the feeder bus to passengers.To model constraints, penalties were used in the objective function.The value of the objective function (Z') for each generated solution was calculated.Then, based on the feasibility of the solution, the hypothesized objective function (Z) was defined, in which the penalties were also added to the value of the original objective function value.The algorithm attempts to reduce the value of the hypothesized objective function.The original and hypothetical objective functions are calculated as follows: The maximum capacity of the feeder bus was assumed to be 12, and the related constraint was considered as a penalty in the objective function.The penalty was equal to half of the maximum number of passengers in excess of feeder bus capacity.The algorithm saves the best solution and the best feasible solution (considering time ratios), and ultimately presents the best feasible solution as the final solution.The best infeasible solutions, which are unacceptable in terms of the maximum time ratio, are accepted, since the algorithm may produce a feasible solution for their neighborhoods.For this reason, the best infeasible solutions were accepted to expand the search space and reach the optimal global solution.If more buses are needed in a certain station and none of the stations have a surplus, serving all the passengers would become impossible with this number of buses.In order to validate the obtained results, the authors ran the algorithm 10 times, and the best solution was selected.The framework of the developed algorithm is shown in Figures 2  and 3.This framework comprises two algorithms: Algorithm 1, which is designed to solve the model, and Algorithm 2, the developed SA path creator.         1 Boarding/alighting passengers (prs). 2 Average direct travel distance in kilometers (km).

Results and Analysis
The proposed SA started with the initializing of inputs and clustering of the passengers.It is important in this algorithm that the cost calculation process includes three parameters: without relocation to other stations, considering relocated bus(es) from the previous station, and considering relocated bus(es) from the following station.Table 3 shows the results of the computations for the model.Figure 5 shows the results of the feeder bus movements including relocation of the buses for stations.In this figure, the travel path is indicated by arrows, with the arrow's beginning signifying the starting point and its end denoting the end of the trip.Each color corresponds to a distinct bus.As shown, the blue and red buses are relocated to another station.

Discussion and Conclusions
This study aimed to create a routing algorithm for a demand-responsive feeder transit system aligned with short headway mass transit.Building on a previous model [8] designed for long headway trunk lines in less dense areas, the new routing accommodates more frequent train services.
Developing a similar algorithm for use in more congested urban areas motivated the authors to develop a new specialized algorithm where the headway of metro trains is much shorter.Therefore, a 5 min headway was considered in the hypothetical network of this study.When the headway of the rail service is long enough for the feeder buses to come back by the next train, then the feeder network algorithm is rather easy because the maximum feeder service cycle time is determined by the rail headway, and matching between feeder buses and the trains is not necessary.However, if the headway of the rail service is not long enough for the feeder buses to return before the next train, then the algorithm should find not only matching between passengers and feeder buses but also matching between feeder buses and trains because the bus can deliver passengers any time as long as it is no later than their requested time.This makes fundamental changes in the algorithm.
In this study, a simulated annealing (SA) algorithm was developed for flexible feeder bus routing on short trunk lines, taking into account the relocation of buses across multiple stations.The objective function of the model incorporated both operating costs and passenger travel expenses.The proposed algorithm effectively managed bus relocations when optimal routing was infeasible due to bus availability constraints at specific stations.
For future research, it is recommended to develop a feeder bus routing algorithm for trains with equivalent short headways, including temporary stops for feeder buses.Furthermore, incorporating composite heuristics for the larger and real networks and exploring the use of more advanced metaheuristics within the algorithm are suggested.

22 Figure 1 .
Figure 1.Conceptual operation of the proposed demand-responsive feeder transit service.

Figure 1 .
Figure 1.Conceptual operation of the proposed demand-responsive feeder transit service.

Figure 2 .
Figure 2. The developed SA algorithm to solve the model.

Figure 3 .Algorithm 2 : 1 : 2 : 3 :
Figure 3.The path creator algorithm.Algorithm 2: Pseudocode for the developed SA path creator algorithm Step 0: Initialization: Set used_capacity=0, maximum_used_capacity =0, c Step 1: Calculate updated latest pickup time of passengers based on the sequence of passengers Step 2: Add the first passenger to the path Step 3: Update total traveled distance Total traveled distance= Distance to current passenger Step 4: IFarrival time to current > Earliest pick up time of the passenger Arrival time to the passenger= traveled distance/speed, else The vehicle should wait for the passenger Arrival time to the passenger = Earliest pick up time of the passenger END IF Step 5: Update time Time = Arrival time to the current passenger Step 6: Update used_capacity used_capacity = used_capacity + 1 Step 7: Update maximum_used_capacity IF used_capacity > maximum_used_capacity maximum_used_capacity= used_capacity END IF

Figure 4 .
Figure 4. Geographical distributions of the passengers.

Figure 4 .
Figure 4. Geographical distributions of the passengers.

Figure 5 .
Figure 5. Illustration for the feeder bus schedules and movements.

Figure 5 .
Figure 5. Illustration for the feeder bus schedules and movements.

Table 1 .
A summary of selected reviewed related studies.
WT s i = in vehicle travel time of passenger i of station s UC s i = used capacity of vehicle after picking up passenger i of station sRV ss = number of relocated vehicles from station s to s n s ik = passenger i of station s is served with vehicle k in the n s ik trip f rom station TV s = the total number of vehicles available at station s at the begininng 1 passenger j is served right after passenger i with vehicle k (station s) 0 otherwise D s ik = distance traveled up to passenger i at station s by vehicle k TotalD k = total distance traveled by vehicle k AT s i = pick up time of passenger i in station s CT s i = arrival time of passenger i to station s

Table 2 .
Passenger information for each station and each train.

Table 3 .
The results of computations for the model.