Modelling of User Behaviour for Static Rebalancing of Bike Sharing System: Transfer of Demand from Bike-Shortage Stations to Neighbouring Stations
Algorithm 2
Optimization algorithm by metaheuristic (Random Search) using Algorithm 1 for lost demand evaluation.
Input: Station capacity (), the initial station status (), the interstation acceptance rate matrix (), the interstation distance matrix (), the maximum number of movable bicycles , the list of supplier stations (i.e.), and the number of maximum iterations.
Output: The rebalancing plan (i.e., the number of bicycles picked up or dropped off, ), the total lost demand evaluated by using Algorithm 1, and the total number of displaced bicycles
Begin
//iteration counter
//total loss of the current solution
//total number of bicycles displaced
For alldo
//initialization of the solution variables (or by a constructive heuristic)
End for
Whiledo
//Neighbourhood operator
Randomly select a picking station ( for compliance with constraint C1) which still has bicycles to be picked up ()
Randomly select a station , different from , such that there is still available dockings for bicycles ( for compliance with constraint C4)
Choose a random number of bicycles to be displaced from the station to the station within the interval
//Checking the constraint of the total number of bicycles displaced
Calculate the number of bicycles displaced by solution
Ifthen //compliance with constraint C2
//Evaluation of the loss of the neighbouring solution