Application of The Haversine Method in the Android-Based Donation Search Application

Used goods that we no longer use will only fill the room which if we leave it will be damaged and have no use value because it consumes time. If given to someone else, the goods may still be useful and can help their lives the problem is how we find people who need our goods and vice versa. For this reason, a system is needed that can help facilitate and bring the two parties together. The effort made to make it easier for the recipient to contribute in taking the donated goods is to use the haversine method so that the recipient can consider the distance between them and the donated item. The haversine formula is an equation that uses latitude and longitude to find the distance between the two different points. By using the haversine formula, the output is the distance from the location of the party receiving the donation (current location) to the donor. Therefore, the author wants to create and design an android-based application so that it can reach many people and can make it easier for donors to donate their goods or for the recipient of donations in looking for items that have been donated.


I. INTRODUCTION
Donations have a variety of mentions or other names such as for example charity, donations or in Buddhism are more often referred to as dana that can be interpreted as sincere and sincere gifts or which means also releasing what we already have, be it in the form of goods or materials, money, a sense of security, forgiveness, not making others suffer and good teachings or advice. In general, donations can be interpreted as a gift that is generally physical by an individual or a legal entity, this gift is also voluntary without any beneficial reward. In some cases, we definitely have used items that we no longer use and only fill the corners of the room that if we leave it will be damaged and have no use value because it takes time. Wouldn't it be better if we donate the item so that it can be useful to others who need it, from here the challenge arises which is how our goods can be found by those who need the item. Conventionally we certainly offer items that we want to donate to others and if the person does need them then he will take them and use them for their purposes this process is definitely quite tiring. To solve this, a system is needed that can bring together the donor and the recipient of the donation and can display the estimated distance between them so that the recipient gets additional information to consider whether the donation can be reached by them or not. The solution to realize this is to use the haversine formula, the haversine formula is an equation that utilizes latitude and longitude to find the distance between the two points using the haversine formula will get an output in the form of distance from the location of the party who will receive the donation (current location) with the donor [1].

II. RELATED WORKS/LITERATURE REVIEW (OPTIONAL)
A donation is a gift that is generally material or physical in nature by an individual or group organization such as a legal entity or other, this gift is voluntary without expecting reciprocity in the form of benefits to the recipient. Donations are not only in the form of materials such as goods, money, food, clothing or others. When an emergency event such as a disaster occurs, donations can be in the form of humanitarian assistance. Donations themselves have various different mentions such as charity, donations, fitrah, infak or zakat. Zakat itself is a part of the property that must be set aside by adherents of the Islamic religion or a body owned by Muslims in accordance with the recommendations of their religion to be given to those in need [2].
An application is an applied tool or software created to process a specific task [3]. Application comes from the word Application which means deployment, application, use. In terms of application, it is a ready-made program that is created to carry out a function for application users and can be used for the intended goal [4] Location Based Service (LBS) is a service to provide information that has been created, compiled, selected or filtered taking into account the location of the user or other person or current mobile device [5]. Location based service (LBS) is a technology that reacts actively to positional motion and is commonly used to find the location of the devices we use [6].
Android is an operating system for Linux-based mobile devices that includes an operating system, middleware andapplication [7]. This operating system is based on the modified Linux kernel and was developed primarily for devices with touch screen interfaces [8], Android also provides an open platform for developers to create their own applications to be used for various mobile devices [9].
Flutter framework is a hybrid SDK (Software Development Kit) developed by Google to create an application. Similarly, it is defined by [10] other authors that flutter is an open source framework owned by Google that is used to create applications that are capable of running on the iOS or Android operating system. Flutter has several advantages over others such as easier and faster application development because flutter provides widgets that can be customized easily without the need for coding from scratch, besides that flutter also has an attractive custom user interface and has performance like a native application [11].
Global Positioning System is a satellite system that functions as positioning in satellite-based navigation functions run by the United States as the owner, The system is designed to know position, three-dimensional speed and time information, constantly around the world without being disturbed by time and weather [14] III. METHODS The inventor of the Haversine formula was Jamez Andrew discovered for the first time in 1805 [15] . Using latitude and longitude haversine formula is an important equation in navigation with a function to calculate the distance between the two points on the earth's surface, namely the latitude and longitude points in the form of inputs [16] that can be described by the following formula: (3) Information: x = Longitude y= Lattitude d= Distance R= Earth radius = 6371 km 1 degree= 0.0174532925 radians.
So that with the formula above we can calculate the distance from the donation to the user's location, the results of the distance that can be displayed in the application to determine whether the item can be reached or not by the user. To be able to apply the formula from the haversine method above to the application that is being built, the formula must be converted into a programming language that can be understood by computers. In this case the haversine method is written in the dart programming language. In developing a software there is a term known as SDLC, which is a cycle used in the manufacture or development of information systems that aim to solve problems effectively. [17]. In developing this software using the SDLC approach which is referred to as the waterfall method. The waterfall method is a method that has 5 stages, namely analysis, design, implementation, integration testing and maintenance [18]. The following is the framework used in developing this software.

IV. RESULTS
The Haversine method is used to calculate the distance between two different points, namely the coordinate point of the initial location and the location of the destination [19]. In this case, it is latitude and longitude which will later be calculated using the Haversine formula. The following is a calculation of the distance between two points using the formula [20] a. Define the starting point and goal The process of initializing the starting point and destination point that you want to calculate the distance or in this application can be referred to as the coordinate point of the user's location and the coordinate point of the location of the donated item. Here are the two points, the following two coordinate points are the coordinate points taken based on the road on the street bentengbetawi. Initial: -6.170381, 106.679478 Destination: -6.175889, 106.644944 b. Change values from degrees to radians Before the calculation process is carried out, the next step is for us to convert the values of the existing coordinate points into radian form. Because 1 degree = 0.0174532925 radians so to convert the coordinate value that was previously in the form of degrees into radian form we only need to multiply it by 0.0174532925. After the coordinate points are converted into radian form, we can then enter the results of the calculation into a formula to find the values of x and y or the value of calculating the longitude and latitude which will later be used to calculate d or the distance of two points. c. Look up the value of X = ( 2 − 1) × cos ( The next step to find out the distance between two points is to find the value of D by rooting the value 2 + 2 and multiplying it by the value of R. R value is the value of the radius of the earth which is the distance between the center of the earth to a point on or near its surface. Therefore the value of R is equal to 6371km = (√ 2 + 2 ) * (6) = (√(−9.608e −5 ) 2 + (−0.0006) 2 ) × 6371 = 6.103421967313538e −4 × 6371 = 3.8884 From the calculation above we know the distance between the two coordinate points from jl. BentengBetawi is about 3.8884 km which the results shown are not much different from those shown by the following google maps, which is 3.9 km The results of this study are an Android-based application that coordinates donated items so that they can be found by those in need by utilizing the haversine formula. From the results of tests that have been carried out on the software it can be said that the system can run well as shown in table 1 below. If the user presses the goods taken button, it will display the goods that have been given by other users to the user if the item with the status of the item pending is clicked, an alert will appear in the confirmation dialog of the item received

Valid
In making this application, of course, this application still has many shortcomings that cannot be resolved. As for suggestions that can be given to carry out development so that this application can be better, namely by adding features and updating the display in the application for searching for donated items to add value to the functionality of the application, and of course Making applications that can run on multiplatforms is a good thing to reach a wider community and updates to the logic code in applications are needed so that applications can run more optimally and lightly.

VI. CONCLUSIONS
The application of the haversine method in the application can add functionality and help users to estimate whether goods can be received by users or not so that with the application it is hoped that it can help and ease the burden on our less fortunate brothers and sisters and can make it easier and open up more opportunities to do good to others by donating items that we no longer use and can also bring donors together with those who need donated goods. the use of a multiplatform framework, namely Flutter, can also open up opportunities for developing this application to reach a wider group of people