The first three terms of a sequence are given by u1=10, u2=6 and u3=5. Given that un is a quadratic polynomial in n, find un in terms of n.