Justification of other data structures and design issues.


Added on  2019-09-23

2 Pages453 Words568 Views
1.Justification of other data structures and design issuesAns: 2 Dimensional array data structure is also a good option to use it, It’s better for performance as it has random access. Array has contiguous memory allocation and thus we can access it randomly. So Ii has fast access and can beneficial when size of matrix is so large.2.Description of stack implementation and justification for choiceAns: Linked list based stack is an option for calculating the determinant for matrix of different order. As linked list is data structure which uses memory chunks which are not contiguous so it an memory saver data structure and give as better performance in terms of memory.3.Discuss stacks - Was it a good choice for this lab? Ans: Performance wise it’s not best but considering the memory it is an good option.4.Discussion of algorithm efficiency – time complexityAns: Time complexity of this algo is size of list * complexity for recursive call to calculate the minor matrix. Recursive call for calculating minor would be linear. So complexity should be O(n*n) i.e. O(n^2)5.Discussion of algorithm efficiency - space complexityAns: Space complexity is size of node * number of node.6.Potential use of recursionAns: Solution is recursive as its being calculated by calling minor matrices. Minor matrix is size smaller than parent matrix. This would be done until we get 1X1 matrix.

End of preview

Want to access all the pages? Upload your documents or become a member.

Related Documents
Data Structures and Operations

Iterative Version for Reversing a Singly Linked List

Programming, Algorithms and Data Structure: Weekly Tasks and Exercises

How to Create a Test File in C++ PDF

Network Optimisation using Graph Theory | Desklib

Linked Lists From Scratch: Implementing Singly Linked Nodes in Java