If PQR ~ SQT, find the value of x

Given:
Given that the triangle PQR is similar to SQT.
The length of PS is (x + 5)
The length of SQ is 8.
The length of ST is (x - 9)
The length of PR is 21.
We need to determine the value of x.
Value of x:
Using the similar triangles property, we shall determine the value of x.
Hence, we have;
[tex]\frac{PQ}{SQ}=\frac{PR}{ST}[/tex]
Substituting the values, we get;
[tex]\frac{x+5+8}{8}=\frac{21}{x-9}[/tex]
[tex]\frac{x+13}{8}=\frac{21}{x-9}[/tex]
Cross multiplying, we get;
[tex](x+13)(x-9)=(21)(8)[/tex]
[tex]x^2+13x-9x-117=168[/tex]
[tex]x^2+4x-285=0[/tex]
The value of x can be determined using the quadratic formula.
Thus, we have;
[tex]x=\frac{-4 \pm \sqrt{16+1140}}{2}}[/tex]
[tex]x=\frac{-4 \pm \sqrt{1156}}{2}}[/tex]
[tex]x=\frac{-4 \pm 36}{2}}[/tex]
[tex]x=\frac{-4+36}{2}} \ or \ x=\frac{-4-36}{2}}[/tex]
[tex]x=\frac{32}{2}} \ or \ x=\frac{-40}{2}}[/tex]
[tex]x=16 \ or \ x=-20[/tex]
Since, x cannot take negative values, then x = 16.
Hence, the value of x is 16.