A Bus Reservation System On Smartphone

– The use of bus in traveling is a large growing business in the world. Hence, bus reservation system deals with maintenance records of each passenger who had reserved a seat for a journey. Moreover, the ticketing system includes maintenance of schedule, fare and details of each bus traveling. This paper is a web-based application that will manage the scheduling of buses in all bus terminals of a transport company and also analyses the basic needs of passengers and design requirements of the transfer algorithm, and influence factors for effective running. This software developed can be used by any transport company as it wasn’t designed for a particular bus station/company. The scheduling of buses which was the major addition to the bus booking application was implemented using round robin for proper bus assignment in a way that improves operational efficiency. The system thus designed will provide a scenario for the customer/passengers and the bus company to attain a win-win situation. It is an adaption of the speed-up technique. This aim is achieved through the use of object-oriented methodology.


I. INTRODUCTION
Transportation assumes an urgent part in urban areas as it altogether impacts the nature of individuals' lives and is frequently the vital methods for getting to schooling, work and fundamental administrations. All the more along these lines, throughout the long term, a great many people like to go by transports since it's more advantageous and generally reasonable than different methods for street transport. The essential commitment of a vehicle association is to give customers satisfaction to the extent organization transport by decreasing the proportion of holding on schedule for each customer. On this note, the use of reservation has used a subject of phenomenal interest. The usage of booking targets organizing a way to deal with improve the utilization of a fleet of vehicles [1]. This is characterizing the highway a vehicle should be allotted by contemplating the exercises of those vehicles. Transport working organizations depend on some huge factors, for example, populace, culture, atmosphere, and economy. As referenced already, transports are by a wide margin the most utilized procedure of street transport inferable from their adaptability, high accessibility, and availability, which normally prompted this paper. [2]. Transport reservation done physically is a method of making a schedule for each transport in the diverse warehouse by drafting the plan to contain their everyday course and arrangement of outings. At the point when a given course has less sum or no travelers, transports doled out to this course, will be reassigned to more bustling courses regardless of whether it's in another takeoff station of the vehicle organization.
Transport booking otherwise called transport booking is one of the trademark exercises of the arranging cycle in a Transport Company in that it deals with the most ideal undertaking of transport task to serve the normal voyager demand [3]. A Bus reservation System will assist the traveler with knowing when he is booked to travel which thus will assist with staying away from considerable delays and objections at the transport terminal. For example, if a traveler shows up at the bus stop and there is no transport or there are no travelers for his objective, this traveler may need to stand by the entire day and still will be unable to travel. All the more in this way, Bus reservation System will fill in as an organization chief to control and screen the development of transports and the everyday reservation of transports to various courses. Transport reservation System will fill in as a warning framework to help organizations use sound judgment and augment benefit.
Throughout the long term, people/travelers have thought that it was hard to grasp a Bus reservation System for their movements, reasons may be that they either don't design appropriately for their excursion or they are not mechanically slanted. These entanglements have been considered in this work, hence it is made to be easy to use and organizations/firms utilizing Bus reservation System might have staff(s) prepared for this reason to encourage the utilization of Bus reservation System.

II. THEORETICAL BACKGROUND
The theoretical background gives a synopsis of the technologies used in developing the system "Bus Reservation System" and the general concept of the research topic as seen by the other researchers. The technology is chosen in other to present a more userfriendly system.
The site developed comprises various web contents written in HTML, PHP, JAVASCRIPT and MYSQL server used in the development of the database of the system.

Scheduling Algorithm
Scheduling is the act of following a schedule, while a schedule is an outline of things to be done and the time when they will be done. However, the concept of scheduling is mostly used in operating systems where processes are scheduled to run within a particular time after which the CPU may be preempted from it, and this brings us to types of scheduling Scheduling may be 1. Preemptive Scheduling: the CPU can be preempted from a process even while it has not exhausted its CPU burst. 2. Non-preemptive Scheduling: Once a process is assigned the CPU, it cannot be taken away until the process completes its CPU burst. And this brings us to the types of scheduling algorithms.

High
Leads to starvation especially when long jobs arrive first on the queue

Shortest Job First
Associate with each process the length of its next CPU burst and Uses these lengths to schedule the process with the shortest time and uses e.g., FCFS to break ties

Low
Leads to the starvation of long jobs

Round Robin
A preemptive scheduling scheme for time-sharing systems Low Solves the problem of starvation as each job is allocated a time slice.

Bus Reservation Techniques
Round robin scheduling (RRS) is quite possibly the most prepared, leased buildings, most attractive and most extensively used booking calculations ever utilized [4]. It is a preemptive type of planning and furthermore a work booking calculation that is accepted to be reasonable, as it utilizes time cuts that are allotted to each cycle in the line or line. Each cycle is then permitted to utilize the CPU for a given time measure, and on the off chance that it isn't finished inside the assigned time, it is appropriated and afterward moved at the rear of the line with the objective that the accompanying system in line can use the CPU for a comparative proportion of time.
Cooperative planning is a calculation predominantly utilized by working frameworks, working structures, and frameworks that serve different customers or clients that expect assets to be utilized. It handles all solicitations in a round first-in-first-out (FIFO) request and evades need so that all cycles/applications can utilize similar assets in a similar measure of time and have a similar measure of holding up time each cycle; henceforth it is additionally considered as a cyclic chief.

How Round Robin Is Applied
However, this project makes use of round robin in assigning buses for a particular route. Here, buses for the same route are assigned different departure time but if a bus departure time has elapsed and the bus is yet to leave the bus station within the time slice allocated to it as a result of insufficient passengers, then the passengers will be reassigned to the next bus plying that route whose departure time has not elapsed. Then the bus returned to the back of the queue where it waits for its turn again to be loaded. This process will continue as long as the bus has not yet reached its maximum sitting capacity. More so, the last bus will depart once the time slice assigned to it has elapsed (i.e. run to completion), this will ensue regardless of the number of passengers on the bus.

Advantages Of Round Robin Over Other Scheduling Algorithms
1. It is very simple to achieve because there are no complex timings or priorities to consider, Simply put it is a FIFO with time allocated to each job or process to ensure equal distribution of the CPU across all jobs.
2. It helps to solve the problem of starvation (a situation in which a job is not able to use the CPU because it is always preempted by other jobs that are usually considered being more important). In this case of the bus station, it helps to avoid the overstressing of some buses while others are left less busy.
3. It helps in a win-win situation. In which resources will be properly harnessed by the bus station while ensuring customer satisfaction.

III. REVIEW OF RELATED LITERATURE
A bus reservation system is not a new concept in use as it has been implemented for different bus stations around the globe. However, in Nigeria and most developing countries, bus reservation is basically done manually i.e. the manager picks which bus to include on the traveling queue and the bus is then assigned to passengers. In turn, a passenger goes to a bus station and books for a ticket and is manually issued a ticket which is a slip containing his name, seat number, destination and amount paid. This may be done online or offline.
Different publications have also been published on this subject as a consequence of comprehensive studies over the past decades. Several model approaches, as well as specific solving strategies have been provided for the issue and its extensions. These are discussed below based on the benefits of public bus transport, the need for customer satisfaction, bus reservation and other online bus systems.
[5] Recognized issues with the present type of the Russian urban transport scheme, since the existing modes and strategies of transport growth may not always be relevant in certain conditions. Afterward, a solution or feasible way to improve their transport system was found. The analysis was done by using the successful nominated six cities as demonstrator cities to develop a roadmap for sustainable mobility together with the city government and related stakeholders.
[6] Proposed an intelligent transport system composed of three parts: a sensor system, a surveillance system, and a display system. A sensor system gets information from a global positioning system (GPS) and near-field communication (NFC), temperature and moisture sensors. The surveillance scheme extracts significant information from the raw data collected from the sensor scheme and gives it to the bus driver. The presentation framework shows transportation and travel-related information at the bus stop to commuters. A paper by [7] acknowledged that the increase in the public transport traveler stacks in the USA is decreasing fuel utilization by around 11 million gallons yearly -the proportionate advantage of expelling 23,813 vehicles from the street. The benefits of public bus transport include but are not limited to: It is more economical for commuters, It helps to de congest the roads as it reduces the number of vehicles that would have filled the road if commuters had travelled with private vehicles, It helps to reduce noise pollution.
[8] Conducted a survey to determine the reasons for traffic congestion in Lebanon and discovered that the reasons are simply as a result of a high number of private cars and the absent of a good transportation code. While the later can be solved only by the government the former can be reduced by providing a good public transport system. The study tried to investigate the problems associated with the transport system in Lebanon. The problems were highlighted as: Accidents, Traffic congestion, Noise and Air pollution [4] Noted that there was only one functional public bus service enterprise that provides transport services in and around the city. The enterprise uses a fixed bus schedule system to serve passengers in 110 routes. However, this type of bus assignment system created a problem in the company's operational and financial performances. Hence the researchers studied the operation pattern of the enterprise and developed a model to best schedule buses for the day to day activities of the bus company. The number of passengers at each period of the day was noted and these time periods were referred to as shifts. Since the enterprise uses a fixed number of buses scheduled per route in its day to day operations, optimal bus/resource utilization was not ensured.
[9] Addresses schedule design for a bus route with one intermediate bus stop also known as time point. The authors tried to minimize passenger waiting time, the delay time for through passengers, delay/early penalty and total operation cost. Unlike. Used a schedule based holding control strategy to achieve this. Schedule-based holding control strategy involves withholding a bus ready to depart from a bus station at a time earlier than the scheduled departure time until the scheduled departure time but if it is delayed beyond the scheduled departure time, it will depart once it has completed all necessary requirements for departure.
[10] Designed a schedule to minimize waiting time at bus stops. Used the time control point strategy, which is bus arrival time at each of its time control point (i.e. bus stop) on the bus route. The strategy was chosen by because it is the type used by most bus companies in China and Singapore. This type of control involves using the expected bus arrival time at bus stops to determine when a bus will arrive at its final destination.
[11] Stressed the need for a bus information system that offers a range of helpful data for customers in towns and particularly distant regions where bus transport is the only type of transportation accessible. Again, because these remote areas contain fewer amounts of commuters, the time spent in waiting for buses at bus stops is high.
[12] Proposed implementation of a crowd-participation bus arrival time forecast scheme using cellular signals. The scheme bridges the gap between customers questioning about the arrival time of the bus and customers ready to share data, providing them real-time bus data, regardless of any bus company. A querying user sends the server the bus stop and path of concern. A sharing customer sends the server a series of a cell tower. The server then matches the sequence of cell towers to the bus route and predicts the arrival time of the bus.
[13] Suggested a wireless sensor network with which the bus information system can provide customers with the current bus position and estimated bus arrival times. Bus nodes, router nodes, bus stop nodes, and concentrators are part of the network.
[14] Studied GPS, Remote Sensing (RS) and Geographic Information System (GIS) methods and suggested using them all to depict the real-time status of each bus and bus arrival time on maps. [15] Introduced an intelligent public transport system composed of bus modules fitted with a GPS receiver, digital speedometer, telecommunications modem, and other server modules, bus stop modules and client applications. The system supplied customers with data about the present place of buses approaching the bus stop.
While [16] suggested using the genetic algorithm to discover the shortest driving time with various situations of actual traffic environments and variable car speeds.
[17] Proposed a web-based system. It allows a customer to check the ticket availability and search for the most possible prices. The system is always available online, but the basic benefits of the system is in its ability to allow the customers to search and choose his/her seat position and ticket payment procedure. They collected data to define the new application's demands.

IV. ANALYSIS OF PROPOSED SYSTEM
The main aim of this software is to help bus transport companies to schedule their buses to ensure maximum resource utilization in their day to day operation. This software developed can be used by any transport company as it wasn't designed for a particular bus station/company. The scheduling of buses which was the major addition to the bus booking application was implemented using round robin for proper bus assignment in a way that improves operational efficiency. The system thus designed will provide a scenario for the customer/passengers and the bus company to attain a win-win situation. Hence timers were assigned to each bus and before the designated time is exhausted the bus is checked if not at least half-filled, then the passengers in the bus are moved to the next bus in line of the same route. This is continued till the last bus to ply the route cannot accommodate the spillover passengers. Nevertheless, if there is only one bus assigned for to a particular route, it will leave the bus station once its allotted time has elapsed. The framework to be planned is an upgraded bus reservation application. Booking in accordance with travelers and reservation in accordance with the administration of the everyday exercises and assets of the bus stop to guarantee consumer loyalty and decrease operational expense.
Examination has indicated that a great many people like to go by transport because of its vicinity and moderateness, yet the helpless administrations given by these transport organizations will in general disperse travelers who wish to go by transport. Consequently, the framework has been planned utilizing Round robin Algorithm.
The cooperative calculation includes allotting time cuts to each transport that has been doled out a course. The framework naturally checks the transports at stretches and tunes in to know whether the transport is half plowed to its ability before an hour to the takeoff time. In the event that it is up to a large portion of its ability, the transport is dispatched from the line once its time cut (takeoff time) pass, Otherwise, the travelers are moved to the following transport in the prepared line and a message is sent across to all travelers in the transport revealing to them that their transport has been deferred. The framework consequently sends the message across educating them regarding what to do in the event of any crisis.
The product configuration measure model utilized in this work is the cascade model. This is on the grounds that it takes into consideration appropriate arranging and assists with including all the plan elicitations of the clients. The plan stage began with correspondence for example visiting the transport organization to get an outline of how the current framework runs and to determine what different functionalities they wished the framework had. The undertaking will utilize a social data set and a web engineering since it will run on the web. The social information base was picked because of its adaptability and ability to meet all kinds of information requires. The plan apparatus utilized in this work is Unified Modeling Language (UML). The UML is a standard graphical documentation for portraying programming examination and plans. It has images to help with portraying and reporting all aspects of the application improvement measure.
The class diagram contains 8 classes in which the user is a superclass to admin, customer, and agents. The aforementioned are subclasses which inherit the attributes and functions of the superclass, user. The relationships between them are specified through the multiplicity.  System implementation has to do with the transformation of the framework's calculated and intelligent plans into an actual execution. Usage exercises incorporate choice and establishment of the picked language, coding, investigating, testing, documentation, preparing and client manual. In this venture work, a XAMP worker was introduced on a framework and the product was coded on its IDE and conveyed on localhost. The coding includes a methodical portrayal of the framework's model in a robotized structure under a decision advancement climate. Investigating and testing the product incorporate eliminating the mistakes of the framework at the various phases of its turn of events and running the framework severally as every blunder is repaired. The product runs well on a nearby worker following the building structure specified in the plan.

Development Environment
The development environment (IDE) utilized in this undertaking is Netbeans 8.1 IDE and Notepad++. In spite of the fact that, Netbeans is generally utilized as a Java IDE however it can likewise be utilized for so numerous other programming dialects including PHP. The significant favorable circumstances of NetBeans over other IDEs like scratch pad which was utilized in this work, include: 1. Ability to make test classes, run and see the code inclusion straightforwardly from IDE interface. 2. There's an implicit neighborhood history that allows you to contrast code changes and return with a particular amendment.
Supportive when source code record is unintentionally overwritten. 3. The capacity to effectively leap to work usage from work call by squeezing (Ctrl + click), this element makes it simpler to investigate and adjust capacities; 4. The way it oversees source code as bundles stacking all documents identified with the venture in its record director segment instead of going forward and backward the windows record voyager.

Choice Of The Programming Language Used
The choice of the programming language used depends on the suitability of the language attributes to the scope and usage of the system developed. They are PHP, HTML, CSS. PHP is a scripting language. It facilitates the development of a web-based program and creation of web-pages. The WAMP server has some sets of scripts, logs, SQL manager and PHP code that enable communication between the MYSQL database and HTML. The system developed is an online system that allows multi usage. The wamp server enables data to be shared among users online and secures the data from the various users. The cascading style sheet formats the presentation of a web page to the end-user. It creates a suitable and user-friendly outlook for the user interface. Hence, these attributes informed the choice of the language used.

VI. RESULT AND DISCUSSION
Bus reservation system is another stage for travelers to book tickets by utilizing the application through their cell phones anyplace and whenever. The framework was intended to help alleviation course arranging and oversee abundance transports and transport lack at terminals. The BRS has been created to encourage travelers and give them an essential choice to book ticket as well as check their tickets anywhere and whenever utilizing their cell phone through Internet. What's more BRS will help the Admin and driver too in them day by day work to make their work more coordinated and effectively to Handle, and furthermore makes it quicker and simpler for the traveler to easily no the accessible transport and season of takeoff in the solace of their homes. The method for the framework's utilization is given in the client's manual. In an offer to diminish holding up time in transport stations while simplifying authoritative utilities, this examination was done. It is an improvement to the current reservation framework and electronic data stockpiling framework for transport stations. BRS was grown explicitly to fill in as a device for compelling transport stations the board. Below are screenshots of BRS. This is a test page created with paypal sandbox to test run the booking app. Once he clicks on "pay now" and a successful payment has been made.

VII. CONCLUSION
Bus Reservation System was developed to help passenger to book their ticket various like mobile devices or laptop and so on, also to help Admin and drivers for their daily work. In a bid to reduce waiting time in bus stations while maximizing organizational utilities, this project was carried out. It is an improvement to the existing booking system and electronic information storage system for bus stations. This project work was named BRS and was developed specifically to serve as a tool for effective reservation of bus management. The software was tested using Mozilla Firefox alongside google chrome. Notepad++ was the IDE (integrated development environment) that was used due to its ability to specify line numbers.