A non-heuristic approach to the general two water jugs problem

Research output: Contribution to conferencePaper


The two water jugs problems is a classic problem in recreational mathematics, problem-solving, artificial intelligence and mathematical programming. The methods of solutions are often based on heuristics or search methods. In this talk, we will present a non-heuristic approach to tackle this problem, which can be modeled by a Diophant equation. By using simple arithmetic only, the special solutions can be easily found by such an approach. Also, a formula for determining an upper bound on the number of pouring steps involved will be derived, based on the method of linear congruence. Copyright © 2013 MIT Departmental Seminar.
Original languageEnglish
Publication statusPublished - Dec 2013


Heuristic Method
Mathematical Programming
Search Methods
Artificial Intelligence
Upper bound


Man, Y. K. (2013, December). A non-heuristic approach to the general two water jugs problem. Paper presented at the MIT Departmental Seminar, The Hong Kong Institute of Education, China.