Quadratic is a type of problem which deals with a variable multiplied by itself- an operation also known as squaring.
Solution:
Let the speed of stream be $x$ km/hr
Given, speed of boat in still water is $8$km/hr.
So, speed of downstream $=\left( 8+x \right)$ km/hr
And, speed of upstream $=\left( 8-x \right)$ km/hr
Using, speed = distance/ time
Time taken by the boat to go $15$ km upstream $=15/\left( 8-x \right)$hr
And, time taken by the boat to return $22$ km downstream $=22/\left( 8+x \right)$hr
From the question, the boat returns to the same point in $5$ hr.
so, $\frac{15}{\left( 8-x \right)}+\frac{22}{\left( 8+x \right)}=5$
$\frac{15\left( 8+x \right)+22\left( 8-x \right)}{\left( 8-x \right)\left( 8+x \right)}=5$
$\frac{120+15x+176-22x}{64+{{x}^{2}}}=5$
$\frac{296-7x}{64-{{x}^{2}}}=5$
$5{{x}^{2}}-7x+296-320=0$
$5{{x}^{2}}-7x-24=0$
$5{{x}^{2}}-15x+8x-24=0$ [by factorisation method]
$5x\left( x-3 \right)+8\left( x-3 \right)=0$
$\left( x-3 \right)\left( 5x+8 \right)=0$
$\therefore $ $x=3,x=-8/5$
As the speed of the stream can never be negative, only the positive solution is considered.
Therefore, the speed of the stream is $3$ km/hr.