Write about your observations on timing measurements

Assignment Help Computer Engineering
Reference no: EM132121139

Referring to the slides from text book, Chapter 5, there are two versions of Fibonacci number calculators:

BinaryFib(n) and LinearFibonacci(n).

The first algorithm has exponential time complexity, while the second one is linear. In this programming assignment, you will implement in Java both the versions of Fibonacci calculators and experimentally compare their runtime performances.

For that, with each implemented version you will calculate Fibonnaci (5), Fibonacci (10), etc. in increments of 5 up to Fibonacci (100) (or higher value if required for your timing measurement) and measure the corresponding run times. You need to use Java's built-in time function for this purpose.

You should redirect the output of each program to an out.txt file. You should write about your observations on timing measurements in a separate text or pdf file.

You are required to submit the two fully commented Java source files, the compiled executables, and the text/pdf files. Briefly explain why the first algorithm is of exponential complexity and the second one is linear (more specifically, how the second algorithm resolves some specific bottleneck(s) of the first algorithm).

You can write your answer in a separate file and submit it together with the other submissions. Do any of the previous two algorithms use tail recursion? Why or why not? Explain your answer.

If your answer is "No" then design the pseudo code for a tail recursive version of Fibonacci calculator; implement the corresponding Java program and repeat the same experiments as in part (a) above.

You will need to submit both the pseudo code and the Java program, together with your experimental results. Submit all your answers to written questions in PDF or text formats only.

For the Java programs. you must submit the source files together with the compiled executables. The solutions to all the questions should be zipped together into one .zip file and submitted via EAS (Refer to the course outline for more details on submission guidelines).

Reference no: EM132121139

Questions Cloud

The difference between multivalued and composite attribute : What is the difference between multivalued and composite attribute? Explain with Example.
Explain briefly what is a pixel : Regarding terminology for the quality of a picture, explain briefly What is a pixel? What is color depth?
Summarize the methodologies you used for your system : Summarize your selected software system to provide context for your colleagues. Summarise the methodologies you used for your system.
Difference between virtual memory and a memory map : What is the relation between virtual memory, a memory map, physical memory and swapping to secondary memory?
Write about your observations on timing measurements : You should redirect the output of each program to an out.txt file. You should write about your observations on timing measurements in a separate text or pdf fil
How you are going to control the loading of this register : Register design A CPU register is simply a row of flip-flops (i.e. SR, JK, T, etc) put side by side in an array to make the size of register required.
What are static variables and instance variables : What is constructor? the purpose of default constructor?What are static variables and instance variables?
Identifies the key features of the organization : M5A3 Research Project - Write a short paper that identifies the key features of the organization's performance management system
Identify the primary key for each table : A client is requesting a relational database system to manage their present store with the anticipation of adding more stores in the future.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

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