There exists finite set of coin types-coin-changing problem

Assignment Help Basic Computer Science
Reference no: EM1361440

Let An = {a1, a2, ... , an} be a finite set of distinct coin types (for example a1 = 50 cents, a2 = 25 cents, a3 = 10 cents, and so on.) We can assume each ai is an integer and a1 > a2 > ... > an. Each type is available in unlimited quantity. The coin-changing problem is to make up an exact amount C using a minimum total number of coins. C is an integer > 0.

a) Show that if an ≠ 1, then there exists a finite set of coin types and a C for which there is no solution to the coin-changing problem.

b) Show that there is always a solution when an = 1.

c) When an = 1, a greedy solution to the problems makes change by using the coin types in order a1, a2, ... , an. When coin type ai is being considered, as many coins of this type as possible are given. Write an algorithm based on this strategy. Show that this algorithm doesn't necessarily generate solutions that use the minimum total number of coins.

d) Show that if An = {kn-1, kn-2, ... , k0} for some k > 1, then the greedy method of part

(c) always yields solutions with a minimum number of coins.

Reference no: EM1361440

Questions Cloud

Explain how does the price of fertilizer compare : Explain how does the price of fertilizer compare to the average total cost, the average variable cost, and the marginal cost of producing fertilizer.
Find the acceleration of the bucket : suppose that the springs have somehow not yet compressed to their maximum amount. How much are the springs compressed.
Calculate company margin of safety : Van Roekel Corporation sells a single product. The product has a selling price of $100 each unit and variable expenses of 80 percent of sales. If the company's fixed expenses total $150,000 each year,
Disease prevention strategies : Should healthcare organizations develop disease prevention strategies? Why or why not? Do you think ethically it is their responsibility?
There exists finite set of coin types-coin-changing problem : Show that if an ≠ 1, then there exists a finite set of coin types and a C for which there is no solution to the coin-changing problem. Show that there is always a solution when an = 1.
Illustrate what would be the size of the us labor force : Suppose that the U.S. noninstituional adult population is 230 million and the labor force participation rate is 67 percent. Illustrate what would be the size of the U.S. labor force.
Solving finance related problems : In a statement of cash flow, the term cash includes, The ownership of common stock in a corporation usually carries the following rights:
Describe the profit-maximizing amounts of electricity : Describe the profit-maximizing amounts of electricity to produce at the two facilities, the optimal price, and the utility company's profits.
How college receive payments : The college has annual fixed costs of $10 million, and the variable cost for each additional student is $5,000. To continue operating, the college must receive payments equal to its total costs.

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Significant tool to help discover security breaches

Auditing is an significant tool to help discover security breaches, yet many organizations do not implement auditing practices.

  Differentiating conventional decision support system and es

A major difference between a conventional decision support system and an ES is that the former can explain a "how" question whereas the latter can also explain a "why" question.

  Use map to define convert-euro converts list of us dollars

Use map to define the following functions: convert-euro, which converts a list of U.S. dollar amounts into a list of euro amounts based on an exchange rate of 1.22 euro for each dollar.

  How many units of each component ordered from each supplier

If the Edwards production plan for the next period includes 1000 units of component 1 and 800 units of component 2, how many units of each component (C1, C2) should be ordered from each supplier (S1, S2, S3)?

  Explaining multicategory case a set of samples

In multicategory case a set of samples is said to be linearly separable if there exists linear machine which can classify them all correctly.

  Perform a web search on it outsourcing and their result

Perform a web search on IT outsourcing and review the results. Select any two IT outsourcing companies and analyze their services, clients, and capabilities.

  Write bash shell script filestatic to examine number files

Write bash shell script filestatic. Script should examine the number files in directories given as arguments (parameters) to this script.

  Use electronic monitoring to measure employee productivity

A discussion of the current trend to use electronic monitoring to measure employee productivity, bearing in mind the theories of Taylor and McGregor. The key ethical issues and the stakeholders involved.

  Why is internet an attractive marketing arena for business

One B2B marketer used a lot of silliness to increase its Web traffic tenfold and generate thousands of sales leads starting. Why is the Internet such an attractive marketing arena for businesses?

  Explaining minor or major virus threats

Write down two recent virus threats, are they minor or major threats? What software would you utilize to remove these threats?

  Determining contents of the register a

The hexadecimal form of a 3-byte instruction for SIC/XE is 010030. The opcode in the instruction is LDA. Indicate the contents of the register A in decimal.

  Verify local police department-s findings on current case

Your computer investigation firm has been hired to verify local police department's findings on current case. Tension over the case is running high in the city.

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