×
Log in to StudySoup
Get Full Access to Discrete Mathematics And Its Applications - 7 Edition - Chapter 3.3 - Problem 20e
Join StudySoup for FREE
Get Full Access to Discrete Mathematics And Its Applications - 7 Edition - Chapter 3.3 - Problem 20e

Already have an account? Login here
×
Reset your password

What is the effect in the time required to solve a problem

Discrete Mathematics and Its Applications | 7th Edition | ISBN: 9780073383095 | Authors: Kenneth Rosen ISBN: 9780073383095 37

Solution for problem 20E Chapter 3.3

Discrete Mathematics and Its Applications | 7th Edition

  • Textbook Solutions
  • 2901 Step-by-step solutions solved by professors and subject experts
  • Get 24/7 help from StudySoup virtual teaching assistants
Discrete Mathematics and Its Applications | 7th Edition | ISBN: 9780073383095 | Authors: Kenneth Rosen

Discrete Mathematics and Its Applications | 7th Edition

4 5 1 361 Reviews
26
3
Problem 20E

What is the effect in the time required to solve a problem when you double the size of the input from n to 2n, assuming that the number of milliseconds the algorithm uses to solve the problem with input size n is each of these function? [Express your answer in the simplest form possible, either as a ratio or a difference. Your answer may be a function of n or a constant.]a) log log n________________b) log n________________c) 100 n________________d) n log n________________e) n2________________f) n3________________g) 2n

Step-by-Step Solution:
Step 1 of 3

Solution:Step1Given thatAssuming that the number of milliseconds the algorithm uses to solve the problem with input size n is each of these function.we have to find what is the effect in the time required to solve a problem when you double the size of the input from n to 2nStep2a) log log nn value is expanded by two which is 2n, time change to loglog2n that is not multiplied. In this way the additional time is log 2n – log n = log log2 + . Accordingly, log 1+ .Step3b) log nn value is expanded by two which is 2n, time change to loglog2n that is not multiplied. In this way the time is log of n which makes it expanded by two/multiplied. Along these lines, log 2n - log n = log 2n/n. Which measures up to log2 = 1 millisecond.Step4c) 100 nn value is expanded by two which is 2n, the time which is a computational change is multiplied. No further work is required.Step5d) n log nn value is expanded by two which is 2n, which makes the computational proportion time = 2nlog log n = 2 (1 + ). In view of this time, the proportion is bigger so additional time is required to enable it to expanded or multiplied.Step6e) n2n value is expanded by two which is 2n, which makes the computational proportion time = 4. The indicated time is quadrupled and the input is multiplied in size.Step7f) n3n esteem is expanded by two which is 2n, which makes the computational proportion time as = 9. This indicated time is 9 times while the size of the input is multiplied.Step8g) 2nn value is expanded by two which is 2n, which makes the computational proportion time = . In this way, the time indicated is time while the information is multiplied in size.

Step 2 of 3

Chapter 3.3, Problem 20E is Solved
Step 3 of 3

Textbook: Discrete Mathematics and Its Applications
Edition: 7
Author: Kenneth Rosen
ISBN: 9780073383095

Other solutions

People also purchased

Related chapters

Unlock Textbook Solution

Enter your email below to unlock your verified solution to:

What is the effect in the time required to solve a problem