To solve the problem, we need to determine the length of \( AC \) in the given right triangle \( \triangle ABC \), where \( \angle BAC = 90^\circ \), \( AD \perp BC \), \( BD = 9 \, \text{cm} \), and \( CD = 16 \, \text{cm} \).
1. Understanding the Geometry:
Since \( AD \perp BC \), \( AD \) is the altitude from \( A \) to the hypotenuse \( BC \). The point \( D \) divides \( BC \) into two segments: \( BD = 9 \, \text{cm} \) and \( CD = 16 \, \text{cm} \). Therefore, the total length of \( BC \) is:
\[
BC = BD + CD = 9 + 16 = 25 \, \text{cm}
\]
2. Using the Geometric Mean Theorem (Altitude-on-Hypotenuse Theorem):
The altitude \( AD \) to the hypotenuse \( BC \) of a right triangle creates two smaller right triangles that are similar to the original triangle and to each other. According to the geometric mean theorem:
\[
AD^2 = BD \cdot CD
\]
Substituting the given values:
\[
AD^2 = 9 \cdot 16 = 144
\]
Thus:
\[
AD = \sqrt{144} = 12 \, \text{cm}
\]
3. Applying the Pythagorean Theorem in \( \triangle ACD \):
In \( \triangle ACD \), \( \angle ADC = 90^\circ \). Using the Pythagorean theorem:
\[
AC^2 = AD^2 + CD^2
\]
Substituting the known values:
\[
AC^2 = 12^2 + 16^2 = 144 + 256 = 400
\]
Thus:
\[
AC = \sqrt{400} = 20 \, \text{cm}
\]
Final Answer:
The length of \( AC \) is \({20 \, \text{cm}}\).