Three Simple Math Problems
April 12, 2019
Here are three simple math problems. They are intended to be solved analytically, with number theory, without using a computer or a calculator. But I cheated. All three problems come from the YouTube channel Mind Your Decisions, where you will find lots of similar problems.
- Solve for x and y where both are integers: 615 + x2 = 2y
- Find a three-digit number abc = 100a + 10b + c with none of the digits 0 such that abc = a! + b! + c!
- Find a three-digit number pie = 100p + 10i + e with none of the digits 0 such that √pi + e = √ pie
Your task is to solve the three problems; you can write programs to solve them, if you wish, but it is fun to solve them by hand. When you are finished, you are welcome to or run a suggested solution, or to post your own solution or discuss the exercise in the comments below.
Here’s a Haskell solution. I decided that overkill was appropriate and used the Z3 SMT solver via the SBV library. Problem 3 turned out to the most difficult one, as the straightforward problem statement mixed integers and algebraic reals which current solvers have great difficulty with. Reorganizing the expression to use only integers fixed that issue. (Also, the factorial function had to be written in a particular way to prevent the solver from going off the rails…)