Socket Programming in java Mrs Mlimaji Mashamba is a UWC graduate who runs a successful tricycle delivery business in the city of Cape Town. She has realized that a big portion of her business costs comes from her tricyle drivers using road segments with potholes and segments where traffic cops usually stop tricycles for documents’ verification. Building around socket programming, your knowledge of Python programming, and the shortest path algorithms learnt in your second-year courses, you are tasked to propose a client/server solution to Mrs Mashamba to help her drivers “find the least cost path” when starting a trip from a collection point to delivery point in the city. The goal is to develop a system that provide Mrs Mashamba’s drivers services which are similar to Google Map but with the possibility of integrating the cost of potholes and the costs incurred by the presence of traffic cops on each segment along the path from a collection point to a delivery point as provided by Google Waze. Note that the presence of potholes has been included in the least cost path computation because, on a long term, they will destroy the shock absorbers of the tricycle, while the presence of traffic cops results in reduced income in terms of number of daily trips made by a tricyle as a result of the time wasted during traffic cops’ verifications. The requirements are as follow The server process maintains a graph of different locations/stations in the city, some of them being shopping centers while others are only transit/dropping stations between two shopping centers. The server is also equipped with algorithms (Dijkstra and Bellman Ford algorithms covered in your second year) to compute/find the least cost path between a collection station and a delivery station. The client process maintains a file of routes that records the paths travelled by the tricycle during the day. For each trip, the client process (used by the driver) will provide to the server process through its socket a source location (a collection station) and a destination location (a delivery station). The client process will then wait for a response from the server which consists of an explicit path proposed by the server with all the points/stations traversed by the tricycle from the source to the destination. Such least cost path will be saved in the file of routes travelled for accountability and further insights (e.g. statistics on routes’ usage, classification and prediction using machine learning).

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

Socket Programming

in java

Mrs Mlimaji Mashamba is a UWC graduate who runs a successful tricycle delivery business in the city of Cape Town. She has realized that a big portion of her business costs comes from her tricyle drivers using road segments with potholes and segments where traffic cops usually stop tricycles for documents’ verification. Building around socket programming, your knowledge of Python programming, and the shortest path algorithms learnt in your second-year courses, you are tasked to propose a client/server solution to Mrs Mashamba to help her drivers “find the least cost path” when starting a trip from a collection point to delivery point in the city. The goal is to develop a system that provide Mrs Mashamba’s drivers services which are similar to Google Map but with the possibility of integrating the cost of potholes and the costs incurred by the presence of traffic cops on each segment along the path from a collection point to a delivery point as provided by Google Waze.

Note that the presence of potholes has been included in the least cost path computation because, on a long term, they will destroy the shock absorbers of the tricycle, while the presence of traffic cops results in reduced income in terms of number of daily trips made by a tricyle as a result of the time wasted during traffic cops’ verifications.

The requirements are as follow

  • The server process maintains a graph of different locations/stations in the city, some of them being shopping centers while others are only transit/dropping stations between two shopping centers. The server is also equipped with algorithms (Dijkstra and Bellman Ford algorithms covered in your second year) to compute/find the least cost path between a collection station and a delivery station.
  • The client process maintains a file of routes that records the paths travelled by the tricycle during the day. For each trip, the client process (used by the driver) will provide to the server process through its socket a source location (a collection station) and a destination location (a delivery station).
  • The client process will then wait for a response from the server which consists of an explicit path proposed by the server with all the points/stations traversed by the tricycle from the source to the destination. Such least cost path will be saved in the file of routes travelled for accountability and further insights (e.g. statistics on routes’ usage, classification and prediction using machine learning).
Expert Solution
steps

Step by step

Solved in 4 steps

Blurred answer
Knowledge Booster
Types of System Design
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education