Optimizing U.S. Coin Values for Cashier's Algorithm

  • Thread starter Sebastian Martinez
  • Start date
  • Tags
    Usa
In summary, the cashier's algorithm is a "greedy algorithm" that involves picking the denomination of closest value to the expected amount. It is optimal for U.S coins because the coin denominations satisfy the sufficient conditions for optimality. This algorithm may not work optimally for other denomination sets. It is also known as the coin-changing problem and there is a lot of related material available on it. The attached table provides an explanation of the cashier algorithm.
  • #1
Sebastian Martinez
11
0

Homework Statement


I can't understand why cashier's algorithm is optimal for U.S coins: 1, 5,10,25,100

Homework Equations

The Attempt at a Solution


The way cashier's algorithm works is that you pick the denomination of closest value to the expected amount. I am trying to read a lot of slides but it's not clear. One key point to understand is that each denomination is a multiple of the previous denomination, but what does that tell me about its optimality?... I am trying to understand the attached table
 

Attachments

  • Screenshot (24).png
    Screenshot (24).png
    34.8 KB · Views: 340
Last edited:
Physics news on Phys.org
  • #2
Sebastian Martinez said:

Homework Statement


I can't understand why cashier's algorithm is optimal for U.S coins: 1, 5,10,25,100

Homework Equations

The Attempt at a Solution


The way cashier's algorithm works is that you pick the denomination of closest value to the expected amount. I am trying to read a lot of slides but it's not clear. One key point to understand is that each denomination is a multiple of the previous denomination, but what does that tell me about its optimality?

Sufficient conditions for optimality of the "greedy algorithm" (which is the formal name given to the algorithm you describe) can be found in the paper
http://www.cs.yorku.ca/~andy/courses/3101/lecture-notes/CoinChange.pdf . The U.S. (and Canadian) coin denominations satisfy those conditions, so you can be sure that the "usual" way of making change results in the smallest number of coins, for any change amount. Of course, counterexamples exist for other denomination sets, so you cannot use the usual method to make change optimally in every country.

Google "coin-changing problem" for lots of related material.
 
  • #3
Ray Vickson said:
Sufficient conditions for optimality of the "greedy algorithm" (which is the formal name given to the algorithm you describe) can be found in the paper
http://www.cs.yorku.ca/~andy/courses/3101/lecture-notes/CoinChange.pdf . The U.S. (and Canadian) coin denominations satisfy those conditions, so you can be sure that the "usual" way of making change results in the smallest number of coins, for any change amount. Of course, counterexamples exist for other denomination sets, so you cannot use the usual method to make change optimally in every country.

Google "coin-changing problem" for lots of related material.
I have attached a table that explains cashier algorithm. I would be glad if you orient me.
 

1. What is the Cashier's Algorithm?

The Cashier's Algorithm is a mathematical method used to determine the optimal combination of coins to give as change for a given amount of money. It is commonly used by cashiers to minimize the number of coins needed for a transaction.

2. Why is it important to optimize U.S. coin values for the Cashier's Algorithm?

Optimizing U.S. coin values for the Cashier's Algorithm helps to save time and resources for cashiers and businesses. It reduces the amount of coins needed for transactions, making it easier to manage and count coins in the cash register.

3. How do you optimize U.S. coin values for the Cashier's Algorithm?

To optimize U.S. coin values for the Cashier's Algorithm, you need to determine the most efficient combination of coins for every possible amount of change. This can be done by using a computer program or by manually calculating the values.

4. Are there any limitations to optimizing U.S. coin values for the Cashier's Algorithm?

Yes, there are some limitations to optimizing U.S. coin values for the Cashier's Algorithm. It may not be practical for smaller businesses or those with limited resources to implement this method. Additionally, it may not always be possible to give the exact amount of change using the optimized coin values.

5. Can optimizing U.S. coin values for the Cashier's Algorithm benefit customers as well?

Yes, optimizing U.S. coin values for the Cashier's Algorithm can benefit both cashiers and customers. It can make transactions more efficient and reduce the amount of time spent counting and sorting coins. This can lead to a smoother and faster checkout experience for customers.

Similar threads

  • Precalculus Mathematics Homework Help
Replies
1
Views
1K
  • Programming and Computer Science
Replies
1
Views
946
  • Programming and Computer Science
Replies
2
Views
773
  • Introductory Physics Homework Help
2
Replies
38
Views
3K
  • Precalculus Mathematics Homework Help
Replies
11
Views
3K
  • General Engineering
Replies
23
Views
2K
  • Calculus and Beyond Homework Help
Replies
2
Views
1K
  • Engineering and Comp Sci Homework Help
Replies
4
Views
2K
  • Programming and Computer Science
Replies
2
Views
2K
Back
Top