How both the time and space complexity change

Assignment Help Data Structure & Algorithms
Reference no: EM131285101

Part: Programming Questions:

The Canadian Real Estate Association (CREA). Operates on multiple lists of n properties where each property is identified by a unique ULS code of 8 digits (e.g. # ULS: 20942894), some of the lists are local for cities and areas, where n counts few hundred properties. Others are at the provincial level, that is n counts tens of thousands or more. CREA needs your help to design a smart "real estate listing" data structure called SmartULS. Keys of SmartULS entries are integers of 8 digits, and one can retrieve the key of a SmartULS or access a single element by its key. Furthermore, similar to sequences, given a SmartULS element one can access its predecessor or successor (if it exists). SmartULS adapts to their usage and keep the balance between memory and runtime requirements. For instance, if a smart ULS contains only a small number of entries (e.g., few hundreds), it might use less memory overhead but slower (sorting) algorithms. On the other hand, if the number of contained entries is large (greater than 1000 or even in the range of tens of thousands of elements), it might have a higher memory requirement but faster (sorting) algorithms. SmartULS might be almost constant in size or might grow and/or shrink dynamically. Ideally, operations applicable to a single SmartULS entry should be 0(1) but never worse than 0(n). Operations applicable to a complete SmartULS should not exceed 0(n2).

You have been asked to design and implement a SmartULS, a smart data structure which automatically adapts to the dynamic content that it operates on. In other words, it accepts the size (total number of properties 71 identified by their 8 digits ULS number as a key) as a parameter and uses an appropriate (set of) data structure(s) from the one(s) studied in class in order to perform the operations below efficientlyl.

The SmartULS must implement the following methods:

- setSmartThresholdULS(Size): where 100 s Threshold s -500,000 is an integer number that defines when the list size should be implemented with a data structure such as a Tree, Hash Table, AVL tree, binary tree, or sequence, if its size is greater than or equal to value of Threshold.

- generate0: randomly generates new non-existing key of 8 digits
- allKeys(SmartULS): return all keys in SmartULS as a sorted sequence
- add(SmartULS,key,value2): add an entry for the given key and value
- remove(SmartULS,key): remove the entry for the given key
- getValues(SmartULS,key): return the values of the given key
- nextKey(SmartULS,key): return the key for the successor of key
- prevKey(SmartULS,key): return the key for the predecessor of key
- rangeKey(keyl, key2): returns the number of keys that are within the specified range of the two keys keyl and key2.

1. Write the pseudo code for each of the methods above.

2. Write the java code that implements the methods above.

3. Discuss how both the time and space complexity change for each of the methods above if the underlying structure of your SmartULS is an array or a linked list?

You have to submit the following deliverables:

a) A detailed report about your design decisions and specification of your SmartULS ADT including a rationale and comments about assumptions and semantics.

b) Well-formatted and documented Java source code and the corresponding class files with the implemented algorithms.

c) Demonstrate the functionality of your SmartULS by documenting at least 5 different but representative data sets. These examples should demonstrate all cases of your SmartULS ADT functionality (e.g., all operations of your ADT for different sizes).

You have to additionally test your implementation with benchmark files

Reference no: EM131285101

Questions Cloud

What will be the number of shares authorized-outstanding : United Specialists, Inc. has authorized 60,000 shares of $1 par common stock. Prior to 2015, United had issued 30,000 shares to stockholders. Early in 2015, United declared and distributed a 10 percent stock dividend. If United subsequently purchases..
Explain the effect of the environmental movement : Identify three of most environmentally negative impacts of Industrial Revolution and justify your choices. Explain the effect of the environmental movement on the process of industrialization in the United States during 1970s.
Describe the multidisciplinary case management : Describe the multidisciplinary case management needs of the special populations of juvenile offenders now assigned to you.
Difference between monoclinic and orthotropic materials : Show the difference between monoclinic and orthotropic materials by applying normal stress in principal directions and shear stress in principal planes, one at a time and studying the resulting nonzero and zero strains.
How both the time and space complexity change : Write the java code that implements the methods - Discuss how both the time and space complexity change for each of the methods above if the underlying structure of your SmartULS is an array or a linked list?
One-time investment in a training program : An organization lost 125 employees last year, at a cost of $5,000.00 each. (Value is derived from cost to rehire and fill opening, as well as lost investment in the employee.) You suggest that a one-time investment in a training program (costing $..
Examples of product lines that fit in each given category : The Boston Consulting Group matrix identifies products as stars, cash cows, question marks, and dogs. Do you think this is a useful way for organizations to examine their businesses?
Find the stiffness matrix and the compliance matrix : Write the number of independent elastic constants for three-dimensional anisotropic, monoclinic, orthotropic, transversely isotropic, and isotropic materials.
Documenting the appropriate accounting for this transaction : Asset Exchange (Drafting an Issues Memo) Facts: Paper Paper, Inc. transferred equipment to Achoo, Inc. in exchange for the receipt of $1.5 million cash and a 20% equity ownership stake in Achoo. You are in the controller’s group of Paper and need to ..

Reviews

len1285101

11/22/2016 1:16:49 AM

This is a programming question using java - These examples should demonstrate all cases of your SmartULS ADT functionality (e.g., all operations of your ADT for different sizes). You have to additionally test your implementation with benchmark files that will be posted soon here:

Write a Review

Data Structure & Algorithms Questions & Answers

  Identify data structures to organize typical file cabinet

Identify at least two data structures that are used to organize a typical file cabinet. Why do you feel it is necessary to emulate these types of data structures in a computer program?

  What is the time complexity of the algorithm

what is the time complexity of the method and what is the time complexity of the algorithm - what is the time complexity of the binarySearch

  Question 1 explain five types of information systems and

question 1. explain five types of information systems and give an example of each.question 2. describe three common

  Eliminate every other integer beginning with the integer

the Collections class which has an algorithm called rotate(List list, int distance) which can be used to rotate a list left or right. use to eliminate every other Integer beginning with the Integer in the second position. Remember that if you rem..

  Write an algorithm using pseudo code

Write an algorithm, using pseudo code, "Consensus algorithm": A group of ten people need to decide which one flavor of ice cream they will all order, out of three options.

  Develop a profile of various projects for risk visibility

A key point in project portfolio management is that the IT manager must determine the risk associated with each project and develop a profile of various projects for risk visibility.

  Create a graph showing best average and worst case

Create a graph showing best, average, and worst case T scores for your code in number 3 above for n = powers of 2 from 21 to 216. If there are any results you cannot provide be specific as to the reason. You can modify the best/worst by modifying ..

  How implement both a push and pop instruction

A computer has 8 general purpose registers (R0 to R7) but does not have PUSH or POP instructions. The computer does have the register indirect with auto increment mode (post-inc) and register

  Concept learninga write an algorithm called find-g to nd a

concept learninga write an algorithm called find-g to nd a maximally-general consistent hypothesis. you can assume the

  Design time randomized monte carlo algorithm

You have to design an O(n) time randomized Monte Carlo algorithm which computes an (1 + o)- approximate ham-sandwich cut with probability 1 - n-c for any given constant c > 0.

  Write procedures for inserting an item into a sorted array

Write two procedures, one for inserting an item into a sorted array, and one for deleting an item from it. Write a recursive function to determine whether an integer n is perfect.

  Separate inventory database

A 20-year old corporation, SewWorld, comprised of 6-locations in three states, sells sewing machines, sewing related software, and accessories. Each store sells between 3-5 different brands of sewing equipments.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd