 # Problem of the Week Problem A and Solution Black Box Calculations

## Problem

The CEMC has created black box machines that process numbers. The machines accept an input number, then do calculations based on that number, then produce an output.

Ronit set up his black box machine to first multiply the input number by $$2$$, and then add $$8$$ to the result. For example, if Ronit inputs the number $$10$$, his black box machine will first multiply it by $$2$$ to produce the number $$20$$. Then it will take the number $$20$$ and add $$8$$ to produce the final output of $$28$$.

Amrita set up her black box machine to first multiply the input number by $$4$$, and then subtract $$6$$ from the result. 1. Amrita inputs the number $$10$$ into her black box machine. What number will the machine output?

2. Ronit and Amrita are the same age and they are older than $$3$$. They each put their age number into their black box machine and were surprised to get the same output as each other. How old are Ronit and Amrita?

3. Write two black box machine setups that have an input of $$10$$ and and output of $$16$$. You can use any two of the following operations: addition, subtraction, multiplication, or division.

## Solution

1. If Amrita inputs the number $$10$$, the black box machine will first multiply it by $$4$$ to produce the number $$40$$. Then it will take the number $$40$$ and subtract $$6$$ to produce the final output of $$34$$. So her black box machine will output $$34$$.

2. One way to solve this problem is to create a table for each machine and keep track of the output produced for different inputs, starting at $$4$$.

Ronit’s Machine

Input Result after multiplying by $$2$$ Result after adding $$8$$ Output
$$4$$ $$4\times 2=8$$ $$8+8=16$$ $$16$$
$$5$$ $$5\times 2=10$$ $$10+8=18$$ $$18$$
$$6$$ $$6\times 2=12$$ $$12+8=20$$ $$20$$
$$7$$ $$7\times 2=14$$ $$14+8=22$$ $$22$$

Amrita’s Machine

Input Result after multiplying by $$4$$ Result after subtracting $$6$$ Output
$$4$$ $$4\times 4=16$$ $$16-6=10$$ $$10$$
$$5$$ $$5\times 4=20$$ $$20-6=14$$ $$14$$
$$6$$ $$6\times 4=24$$ $$14-6=18$$ $$18$$
$$7$$ $$7\times 4=28$$ $$28-6=22$$ $$22$$

From these tables we see that when the input is $$7$$, the output is $$22$$ for both machines. So one possibility is that Ronit and Amrita are $$7$$ years old.

Is it possible that Ronit and Amrita are a different age? Looking at the Output columns in the tables, we see that the output from Ronit’s black box machine increases by $$2$$ as the input increases by $$1$$. However, the output from Amrita’s black box machine increases by $$4$$ as the input increases by $$1$$. Since the output from Amrita’s black box machine is increasing faster than the output from Ronit’s black box machine, this tells us that their outputs will not be the same for any other possible ages.

So Ronit and Amrita must both be $$7$$ years old.

3. There are many possible setups that would produce an output of $$16$$ given an input of $$10$$. Some setups are shown below.

• First divide by $$5$$, then add $$14$$.

• First multiply by $$2$$, then subtract $$4$$.

• First add $$22$$, then divide by $$2$$.

• First subtract $$2$$, then multiply by $$2$$.

Extension: We could describe the setup of each machine by writing a mathematical formula that describes the operations for the black box. The formula would use a letter such as $$n$$ to represent the input number. Can you write a mathematical formula for each of the two machine setups from part (a)?