Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2 1.

26
Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2 http://dcm.uhcl.edu/caps10g4/home.ht ml 1
  • date post

    21-Dec-2015
  • Category

    Documents

  • view

    223
  • download

    0

Transcript of Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2 1.

Page 1: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

1

Android Mobile Application for Traveling Salesman Problem

(TSP)

Presented By: Capstone Team #2http://dcm.uhcl.edu/caps10g4/home.html

Page 2: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

2

Team Information….

Team Members Instructor & Mentor

Shravani Reddy Tappati Dr. Perez Davilae-mail: [email protected] e-mail: [email protected]

Tejasri Yelamanchilie-mail: [email protected]

Nikunj Tibdewale-mail: [email protected]

Divya Karukondae-mail: [email protected]

Page 3: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

3

Outline….

Presenter 1:Divya Karukonda

•Overview •Software requirement•System architecture•Use case

Presenter 2Nikunj Tibdewal

•Application content•GUI•Algorithm

Presenter 3Tejasri Yelamanchili

•Class diagram•Sequence diagram •Project timeline

Presenter 4Shravani Reddy Tappati

•Google Android•Sample code•Project schedule•References

Page 4: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

4

Project Overview….

•To develop a mobile application using the Google android platform for finding the optimal route

•This application allows the user to input the multiple locations that the user is interested to visit and find the optimal route among them

•The user can give his/her own priority in visiting the locations, so the optimal route can be found in the listed priority

Page 5: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

5

Software Requirement….

•Windows XP (32-bit) or Vista (32- or 62-bit)

•Eclipse IDE 3.5 (Galileo)

•Android SDK 2.1

•XML

Page 6: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

6

Basic System Architecture….

Figure 1. Basic Architecture Diagram

Page 7: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

7

Use Case….

Android mobile application for TSP

Figure 2. Application overview use case diagram

Page 8: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

8

What does the application contain?....

•Graphical User Interface (GUI )

•Algorithm

•Google Maps

Page 9: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

9

Graphic User Interface….

Android mobile application for TSP

Figure 3. GUI for the android mobile application

Page 10: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

10

Algorithm….

•Euclidean Distance Formula

•Nearest Neighbor Algorithm

Page 11: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

11

Euclidean Distance Formula….

•Calculate distance between locations

Where,p: Current locationq: Desire locationd: distance between p & q

Page 12: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

12

Nearest Neighbor Algorithm….

1. Stand on an arbitrary vertex as current vertex

2. Find out lightest edge connecting current

vertex and unvisited vertex V

3. Set current vertex to V

4. Mark V as visited

5. If all the vertices in domain are visited, then

terminate

6. Go to step 2

Page 13: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

13

Class Diagram

Figure 4. UML class diagram for application

Page 14: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

14

Sequence Diagram….

Figure 5. Sequence diagram

User GUI HTTP connection

Android application

Google Map

1. GetConnect()

2..SetConnect ()

3. SetApplication()

4. Getapplication()

5. GetAddress()6.SaveAddress()

Application server

8. showroute ()

9. GetAddress()

10. CalDistance()

11. Getdistance()

7.Searc()

12. FindNN()

13. GetNN()

14. MapNN()

15. ShowOptimizedRoute()

Page 15: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

15

Project Timeline….

Page 16: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

16

Android….

•Android is mobile phone operating system developed by Google

•Is first complete, open and free mobile platform

•100% java support

•We can create application for the android platform using the Android SDK

Page 17: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

17

Android….

•Java and XML based GUI

•Application written using java programming language run on Dalvik, a custom virtual machine designed for embedded use, which runs on top of a Linux Kernel

Page 18: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

18

Android Architecture….

Figure 6. Android Architecture

Page 19: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

19

Download and Install the SDK….

Download and install the SDK starter package

Select a starter package for your operating system and download it

Install the ADT Plug-in for Eclipse If you are developing in Eclipse, set up a remote update

site and install the Android Development Tools (ADT) plug-in

Add Android platforms to your SDK Use the Android SDK and AVD Manager, included in the

SDK starter package, to add one or more Android platforms

Page 20: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

20

Sample Android Code….

<TextView android:id="@+id/label" android:layout_width="fill_parent"

android:layout_height="wrap_content"

android:text="Zip Code:"/><EditText android:id="@+id/entry" android:layout_width="fill_parent" android:layout_height="wrap_content“ android:background="@android:drawable/editbox_background” android:layout_below="@id/label"/> <Button android:id="@+id/ok" android:layout_width="wrap_content" android:layout_height="wrap_content"

android:layout_below="@id/entry" android:layout_alignParentRight="true" android:layout_marginLeft="10px" android:text="OK" /> <Button android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_toLeftOf="@id/ok" android:layout_alignTop="@id/ok" android:text="Cancel" />

</RelativeLayout>

File.java

package com.android.helloactivity;import android.app.Activity;import android.os.Bundle;/** * A minimal "Hello, World!" application. */public class HelloActivity extends Activity { public HelloActivity() { } /** * Called with the activity is first created. */ @Override public void onCreate(Bundle savedValues) { super.onCreate(savedValues); // Set the layout for this activity. You can find it // in res/layout/hello_activity.xml setContentView(R.layout.hello_activity); restoreValues(savedValues); } private void restoreValues(Bundle savedValues) { // TODO Auto-generated method stub }}

File.xml

<?xml version="1.0" encoding="utf-8"?>

<!-- Demonstrates using a relative layout to create a form -->

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android” android:layout_width="fill_parent" android:layout_height="wrap_content" android:padding="10px">

Page 21: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

21

Work Accomplished….

•Class diagram

•Sequence diagram

•Installed Android SDK 2.1

•Installed Eclipse Galileo 3.5

•Tested sample codes

Page 22: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

22

Work To Do….

•GUI implementation

•Algorithm implementation

•GUI and Algorithm integration

•Testing

•Deployment

Page 23: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

23

Project Schedule….

Project phase Starting Ending Team Member Status

Project Initial Specification 1.22.2010 1.28.2010 Divya, Tejasri, Shravani Done

Project Web Site 1.29.2010 2.5.2010 Shravani Done

Software Requirement Specification 2.5.2010 2.24.2010 Team Done

Project Design Document 2.19.2010 3.5.2010 Tejasri, Nikunj Done

Mid Term Presentation 3.5.2010 3.5.2010 Team Done

Basic Implementation [ API’s, Map,Location] 2.19.2010 3.12.2010 Team Partially

Implementation of Required GUI 3.12.2010 3.26.2010 Tejasri, Shravani Pending

Implementation of Algorithm 3.16.2010 3.31.2010 Nikunj, Divya Pending

Integration of GUI & Algorithm 4.01.2010 4.09.2010 Team Pending

Testing 4.10.2010 4.20.2010 Team Pending

Deployment 4.20.2010 4.29.2010 Team Pending

Final Presentation 4.30.2010 4.30.2010 Team Pending

Figure 7. Project Schedule

Page 24: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

24

References….

•Android logo http://www.devicedaily.com/wp-content/uploads/2008/10/android-logo.png

• Nearest Neighbor algorithm http://en.wikipedia.org/wiki/Nearest_neighbour_algorithm

• http://www.wikipedia.org/

•http://code.google.com/android/

•http://developer.android.com/resources/tutorials/hello-world.html

Page 25: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

25

Thank You !!

Page 26: Android Mobile Application for Traveling Salesman Problem (TSP) Presented By: Capstone Team #2  1.

26

Any Queries???