Factor completely:
Substitute at the midpoint so the expression becomes symmetric. The two bases and are centred on , so setting makes them and . Expanding directly in would produce a messy quartic; this choice is what makes the odd terms cancel:
Expand and watch the odd powers cancel.
so the expression becomes .
Treat the bracket as a quadratic in . With ,
since and . Back in : .
Factor the difference of squares and stop at the irreducible piece. , while has no real roots and stays intact:
Substitute back. , , and :
Verify by evaluating both forms at several integers. Checking , the original and agree at every one of those points — far more than the needed to pin down a quartic, so the factorization is exact.
Need to solve a different problem like this? Open the solver →