Propositiones ad Acuendos Juvenes/Problems/5 - De Emptore in C Denariis

by : Problem $5$

 * De Emptore in $\text C$ Denariis: A Merchant and $100$ Pence
 * A merchant wanted to buy $100$ pigs at $100$ pence.
 * For a boar he would pay $10$ pence;
 * ''and for a sow $5$ pence;
 * while he would pay $1$ penny for a couple of piglets.


 * How many boars, sows and piglets must there have been for him to have paid exactly $100$ pence for the $100$ animals?

Solution

 * $1$ boar
 * $9$ sows
 * $90$ piglets.

Proof
Let $x$, $y$ and $z$ denote the number of boars, sows and piglets respectively.

We are to solve for $x, y, z \in \N$:

Note that both $x$ and $y$ need to be (strictly) positive.

We need to find possible values of $x$ such that $100 - 19 x$ is divisible by $9$.

Inspecting possible contenders for such an $x$ individually:

Only one of these satisfies the condition, that is:
 * $x = 1$
 * $y = 9$

which leaves:
 * $z = 100 - 1 - 9 = 90$

Hence the result.