2. (AUS 3) Ali Barber, the carpet merchant, has a rectangular piece of carpet whose dimensions are unknown. Unfortunately, his tape measure is broken and he has no other measuring instruments. However, he finds that if he lays it flat on the floor of either of his storerooms, then each corner of the carpet touches a different wall of that room. If the two rooms have dimensions of 38 feet by 55 feet and 50 feet by 55 feet, what are the carpet dimensions?
2. Let the carpet have width $x$, length $y$. Suppose that the carpet $E F G H$ lies in a room $A B C D, E$ being on $A B, F$ on $B C, G$ on $C D$, and $H$ on $D A$. Then $\triangle A E H \equiv \triangle C G F \sim \triangle B F E \equiv \triangle D H G$. Let $\frac{y}{x}=k, A E=\alpha$ and $A H=b$. In that case $B E=k b$ and $D H=k a$.
Thus $a+k b=50, k a+b=55$, whence $a=\frac{55 k-50}{k^{2}-1}$ and $b=\frac{5 a k-55}{k^{2}-1}$. Hence $x^{2}=a^{2}+b^{2}=\frac{325 d^{2}-1100 k+5525}{\left(k^{2}-1\right)^{2}}$, i.e.
$$
x^{2}\left(k^{2}-1\right)^{2}=5525 k^{2}-11000 k+5525 .
$$

Similarly, from the equations for the second storeroom, we get
$$
x^{2}\left(k^{2}-1\right)^{2}=4469 k^{2}-8360 k+4469 \text {. }
$$

Combining the two equations, we get $5525 k^{2}-11000 k+5525=4469 k^{2}-$ $8360 k+4469$, which implies $k=2$ or $1 / 2$. Without loss of generality we have $y=2 x$ and $a+2 b=50,2 a+b=55$; hence $a=20, b=15$, $x=\sqrt{15^{2}+20^{2}}=25$, and $y=50$. We have thus shown that the carpet is 25 feet by 50 feet.