Answer
$5xy^3-8x^2y^4$
Work Step by Step
Recall the following rule: $\frac{a^{m}}{a^{n}}=a^{m-n}$
In order to solve this problem, use the rule above and cancel out common factors that are in both the numerator and the denominator of the fraction.
$=\dfrac{-40x^4y^7}{-8x^3y^4} + \dfrac{64x^5y^8}{-8x^3y^4}
\\=5x^{4-3}y^{7-4}- 8x^{5-3}y^{8-4}
\\=5xy^3-8x^2y^4$