Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Need help in this assignment. With the continuous development of data science, we see an increasing presence of smart devices and IoT systems. With more

Need help in this assignment.

With the continuous development of data science, we see an increasing presence of smart devices and IoT systems. With more and more devices appearing more and more, the demand for processing and manipulating data is increasing.

In this exercise, students are required to perform operations on a set of actual data collected from the devices sent to the server. Students manipulate appropriate data structures to perform, limiting to linked lists.

Data entered

The input of the program is contained in the input file as follows:

Header 12 byte VRecord data 4 byte number of records N?i dung 1 VRecord 2 VRecord 3 VRecord ... Detailed record information is specified in the VRecord structure. This structure consists of the device ID, the location (x is the longitude, y is the latitude), and the timestamp is the time the data is sent. The distanceVR function is given to calculate the distance between two devices, the return value is the distance in km.

Export data

Student data should comply with the following rules:

Integer: no format needed True: 12-digit precision, set in main.cpp. Data streams: For each request, students output information on the same line, separated by spaces. If the request is a command, the student outputs : Succeed / Failed. Requirements

Requests can be processed on the database.

Description Code CNV Calculates the number of devices in the database VFF Find the storage device first VFL Find the last stored device VFY Finds the first stored y coordinate of the device VFX Finds the first stored x coordinate of the device VLY Find the last stored y of the device VLX Find the last stored x-coordinate of the device VFT Find the starting point of the device VLT Find the end time of the device VCR Calculates the record number of the device VCL Calculates the journey length of the device VMT Calculate the travel time of the device VFS Find the first stop of device , output (x y) VLS Finds the last stop of the device VMS Find the longest idle time of the device VAS Find the average distance between two crawls of the device MST Find the longest stopping time of all devices CNR Calculates the number of records in the database MRV Find the device with the most number of records LRV Find the device with the least number of records MTV Find the device that has the longest total travel time MVV Find the device with the fastest moving average CNS Calculates the number of moving and non-stop devices CAS Calculates the average distance for data collection across all devices LPV Find the device with the longest journey SPV Find the device with the shortest itinerary RVR Deletes the record of the device Note: If there are multiple results that can be returned then select the first result in the order of the saved data.

Realistic

Students are provided the following files:

main.cpp: the main source of the program listLib.h: file contains the definition of linked list library dbLib.h: header file contains the prototype needed to manage the database dbLib.cpp: source code implements database management functions requestLib.h: header file contains the prototype needed to handle events requestLib.cpp: source code implements event handlers processData.cpp: Student Reality Code Students are given the following functions:

distanceVR: calculates the distance between two points on the ground with the given latitude (y), longitude (x). loadVDB: reads the file and loads the data into the list strPrintTime: prints out a string in the requested format For the library file listLib.h, students are provided with a basic definition. In addition, to complete the program, students need to complete the remaining functions in the list. Students can add features to the library if needed.

processData.cpp Student implements the request through the processRequest function. Do not change the prototype of this function.

Students are allowed to customize, edit source files except the main.cpp file because it will be overwritten at dots.

Students are not allowed to use libraries other than libraries used in the framework.

Here is the files :

https://github.com/saitamandd/DSA172A01

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Processing

Authors: David Kroenke

11th Edition

0132302675, 9780132302678

More Books

Students also viewed these Databases questions

Question

What is the Definition for Third Normal Form?

Answered: 1 week ago

Question

Provide two examples of a One-To-Many relationship.

Answered: 1 week ago