COSC 1285 Algorithms and Analysis Assignment

Assignment Help Data Structure & Algorithms
Reference no: EM132863894

COSC 1285 Algorithms and Analysis - RMIT University

Learning Outcome 1: Compare, contrast, and apply the key algorithmic design paradigms: brute force, divide and conquer, decrease and conquer, transform and conquer, greedy, dynamic programming and iterative improvement;
Learning Outcome 2: Compare, contrast, and apply key data structures: trees, lists, stacks, queues, hash tables and graph representations;
Learning Outcome 3: Define, compare, analyse, and solve general algorithmic problem types: sorting, searching, graphs and geometric;
Learning Outcome 4: Theoretically compare and analyse the time complexities of algorithms and data structures; and
Learning Outcome 5: Implement, empirically compare, and apply fundamental algorithms and data structures to real-world problems.

Task A: Implement the Graph Representations, their Operations and the Networked SIR model

In this task, you will implement data structures for representing undirected, unweighted graphs using the adjacency list, adjacency matrix and incidence matrix representations. Your implementation should also model vertices that have SIR model states associated with them. Your implementation should support the following operations:
ˆ Create an empty undirected graph (implemented as a constructor that takes zero arguments).
ˆ Add a vertex to the graph.
ˆ Add an edge to the graph.
ˆ Toggle the SIR state on vertices. ˆ Delete a vertex from the graph. ˆ Delete an edge from the graph.
ˆ Compute the k hop neighbours of a vertex in the graph.
ˆ Print out the set of vertices and their SIR states.
ˆ Print out the set of edges.

In addition, we want you to implement the (networked) SIR epidemic model to sim- ulate how a virus can spread through a population.
Note that you are welcome to implement additional functionality. When constructing our solutions to the assignment, we have found that adding some methods was helpful, particularly for implementing the SIR model. But the above functionalities are ones you should complete and ones you will be assessed on.

Data Structure Details
Graphs can be implemented using a number of data structures. You are to implement the graph abstract data type using the following data structures:
ˆ Adjacency list, using an array of linked lists.
ˆ Adjacency matrix, using a 2D array (an array of arrays).
ˆ Incidence matrix, using a 2D array (an array of arrays).

For the above data structures, you must program your own implementation, and not use the LinkedList or Matrix type of data structures in java.utils or any other libraries. You must implement your own nodes and methods to handle the operations. If you use java.utils or other implementation from libraries, this will be considered as an invalid implementation and attract 0 marks for that data structure. The only exceptions are:
ˆ if you choose to implement a map of vertex labels to a row or column index for the adjacency matrix or incidence matrix, you may use one of the existing Map classes to do this.
ˆ if you choose to implement a map of vertex labels to its associated SIR state, you may use of the existing Map classes to do so.

Task B: Evaluate your Data Structures and SIR model

In this second task, you will evaluate your implemented structures in terms of their time complexities for the different operations and different use case scenarios. Scenarios arise from the possible use cases of contract tracing and epidemic modelling on a graph. In addition, run some epidemic modelling simulations to evaluate your structures within an application (epidemic modelling and simulation) and to explore more about the effect of the model parameters on epidemic spreading.

Write a report on your analysis and evaluation of the different implementations. Con- sider and recommend in which scenarios each type of implementation would be most appropriate. Report the outcomes of your SIR epidemic model simulations. The report should be 10 pages or less, in font size 12. See the assessment rubric (Appendix A) for the criteria we are seeking in the report.

Use Case Scenarios
Typically, you use real usage data to evaluate your data structures. However, for this as- signment, you will write data generators to enable testing over different scenarios of interest. We are also interested in the effect of the average degree of the graph3 on these scenarios. There are many possibilities, but for this assignment, consider the following scenarios:

Scenario 1 k-hop Neighbourhoods: When doing contract tracing and/or epidemic modelling, computing neighbourhoods is an important function. In this scenario, the graph is not changing, but important operations such as k-hop neighbourhood (recall this is all neighbours up to k-hops away) are requested.
You are to evaluate the performance of the the k-hop neighbourhood implementations, as the average degree of the evaluated graph and k are varied.

Scenario 2 Dynamic Contact Conditions: In the real world, the contact conditions between people are likely not static and there will be need to update these over time. In this scenario, the contacts are changing (been added and deleted). In this scenario, you are to evaluate the performance of your implementations in terms of:
ˆ edge additions
ˆ edge deletions
You are to evaluate the performance the edge operations as the average degree and size (number of vertices) of the initial graph (before edge changes) are varied.

Scenario 3 Dynamic People Tracing: As time goes on, the people been traced will change. Although it is possible to have a large graph that tries to capture every possible person, it is computationally difficult to do so and run simulations on it. In this scenario, you are to evaluate the performance of your implementations in terms of:
ˆ vertex addition
ˆ vertex deletion
You are to evaluate the performance the vertex operations as the average degree and size (number of vertices) of the initial graph (before vertex changes) are varied.

SIR Model Epidemic Simulation
In addition to evaluating how well the graph representations perform for the contract tracing and epidemic modelling simulations, we also want to experiment with how the networked SIR model works and performs.

Run epidemic simulation for different graph types (Erdos-Renyi and Scale-free), differ- ent seed initialisations and different infection and recover probabilities. For performance evaluation, evaluate each of the three data structures on a subset of the possible simula- tion parameters and compare how they perform (in terms of timing efficiency).

We don't expect a comprehensive analysis, but want you to explore and gain a better understanding of epidemic modelling and what it implies for how to limit the spread of epidemics.

Consider how you might present the results, but at a minimum plot the following:
ˆ Number of susceptible, infected and recovered after every iteration.

Data Generation
When generating the vertices and edges to add or remove and find neighbourhoods for, the distribution of these elements, compared to what is in the graph already, will have an effect on the timing performance. However, without the usage and query data, it is difficult to specify what this distributions might be. Instead, in this assignment, uniformly sample from a fixed range, e.g., 0 to max vertex label of your graph when generating the vertices and edges for removing and adding and k-hop neighbourhoods, and a different range (e.g., greater than the largest vertex label when adding vertices (we do not want to repeatingly add vertices that are in the graph already).

For generating graphs with different initial average degrees and sizes, you can either use Pajek or your favourite graph generator, we will not prescribe one particular approach. Whichever method you decide to use, remember to generate graphs of different average degrees to evaluate on. Due to the randomness of the data, you may wish to generate a few graphs with the same average degrees and sizes and take the average across a number of runs when performing the performance evaluation and analysis.

Attachment:- Algorithms and Analysis.rar

Reference no: EM132863894

Questions Cloud

Thomas hobbes ethical view : List the natural laws that are drown from Thomas Hobbes's ethical view.
Describe at least three different legal forms of business : Describe at least three different legal forms of business, and explain the pros and cons of each form.
What are the conduit and entity perspectives : What are the conduit and entity perspectives? What impact does each perspective have on the tax effects for each form of business?
Scenerio of an ethical violation : Can you give a workplace example such as a scenerio of an ethical violation between a supervisor's abuse of power with an employee.
COSC 1285 Algorithms and Analysis Assignment : COSC 1285 Algorithms and Analysis Assignment Help and Solution, RMIT University - Assessment Writing Service - apply the key algorithmic design paradigms
Epa and recycling at work website : Explain whether the EPA and Recycling at Work website sources are primary or secondary, and why they make good sources for your proposal
Make interesting observations and comments : The culture that you ignore most - in terms of its shaping power on yourself - is obviously your own culture. It is very difficult to look at oneself from the o
Facebook racial discrimination business practice : Assess whether Facebook Racial Discrimination business practice is ethical or unethical according to the perspective of the concepts and theories. Explain your
Important steps in the communication process : The communication process involves EIGHT (8) steps. Read the scenario below to answer the questions. You are the Assistant Registrar (Examination Unit)

Reviews

Write a Review

Data Structure & Algorithms Questions & Answers

  Write a function with the heading function nonodes

Write a function with the heading: function NoNodes( t : treeptr) : natural whose value is the number of nodes on the tree t.

  Analyze an algorithm to find a spanning tree

Describe and analyze an algorithm means you must provide pseudocode, a proof of correctness and complexity analysis - Describe and analyze an algorithm.

  Solve problem assuming a minimax rectilinear objective

Armand Bender plans to visit six customers in Manhattan. Three are located in a building at 34th Street and 7th Avenue. The remaining customers are at 48th.

  Creating java program using two arrays

Create a program in Java which defines 2-unconstrained arrays of user defined length n, that contain n Random numbers each and which outputs addition of pairs of elements.

  Describing the data types

Create a 10-12 slide presentation describing the data types. Include the following in your presentation: Introductory slide and Slide for each data type

  Give a recursive algorithm for finding the number of one''s

Give a recursive algorithm for finding the number of one's in a bit string, name the algorothm count-ones.

  Calculate the correlations between er and pgr

Calculate the correlations between er and pgr, b1 and b2, and p1 and p2 (three correlations). What do these tell you about the relationships between these variables

  What is the difference between syntax and semantics

Explain the distinction between an ambiguity in a proposed algorithm and an ambiguity in the representation of an algorithm.

  How cryptography can be properly and improperly used

The reason for this lab is to give you an understanding of how cryptography can be properly and improperly used, and how changes in technology may serve to weaken trusted cryptographic applications

  Conduct space complexity analysis of the algorithm

conduct time complexity analysis of the algorithm (and also mention best case and worst case analysis if applicable).

  Recurrence for the running time of strassens algorithm

Write the recurrence for the running time of Strassens algorithm and Implement a divide and conquer algorithm for the problem

  Draw the 2-3-4 tree that result when the values are inserted

Draw the 2-3-4 tree that results when the values are inserted in the order given:55,66,44,77,33,88,22,99,11.

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