# Rules for simplifying algebraic fractions

I'm new to maths and I'm working on simplifying the fraction below:

## x^2+xy

y^2+xy

The answer is x over y but i want to know why i cant simply cancel everything out as it is from the start. I have been taught to cancel out like terms, so can't i say, "xy over xy = 1, x^2 over y^2 is simply X x X and Y x Y, so i can divide those by top and bottom and get answer = 1" and ultimately end up with nothing as the answer?

Also, would the answer simply be 1 or would it be 0 if i did it this way? my teacher cancels out like terms a lot but doesn't always write the 1, so i'm a bit confused.

Or at the very minimum, why is that i cant cancel xy over xy out now, but if i write them out as x(x+y) over x(x+y) i can then cancel out the terms in the brackets?

• $x^2+xy$ is a polynomial, not a fraction. We have $x^2+xy=x(x+y)$ and $y^2+xy=y(x+y)$. So you can cancel $x+y$. Oct 8, 2022 at 18:14
• I'm having trouble interpreting your question. Are you trying to simplify this fraction? $$\frac{x^2 + xy}{y^2 + xy}$$ Oct 8, 2022 at 18:34

There's a lot going on here; let's take it step by step. I'm assuming that the task is to simplify $$\frac{x^2+xy}{y^2+xy}$$.

I have been taught to cancel out like terms, so can't i say, "xy over xy = 1, ...

It sounds like you are trying to do this: $$\frac{x^2 \color{red}{+xy}}{y^2 \color{red}{+ xy}} \color{red}{=} \frac{x^2}{y^2}$$ This is wrong. You can cancel common factors in the numerator and denominator but not common terms. If you try it with $$x=1$$ and $$y=2$$, then the left-hand side of the above is $$\frac{1^2 + 1 \cdot 2}{2^2 + 1 \cdot 2} = \frac{3}{6} = \frac{1}{2}$$, while the right-hand side is $$\frac{1^2}{2^2} = \frac{1}{4}$$.

x^2 over y^2 is simply X x X and Y x Y, so i can divide those by top and bottom and get answer = 1"

It sounds like you are trying to do this: $$\frac{x^2}{y^2} \color{red}{=} \frac{x^2 /x^2}{y^2/y^2} = \frac{1}{1}$$ This is also wrong. You can only divide the top and bottom by the same expression, not different ones.

and ultimately end up with nothing as the answer?

It sounds like you are equating the $$1$$ that arrives from canceling everything in sight with $$0$$ (“nothing"). But a multiplicative nothing is $$1$$, while $$0$$ is the additive nothing.

OK, then, turning to your question about the solution which is correct:

why is that ...if i write them out as x(x+y) over x(x+y) i can then cancel out the terms in the brackets?

You have $$\frac{x^2+xy}{y^2+xy} = \frac{x\color{blue}{(x+y)}}{y\color{blue}{(y+x)}} = \frac{x}{y}$$ Here we see common factors in the numerator in denominator, so they can be canceled. But there isn't anywhere to go from here, since $$x$$ and $$y$$ are independent variables.