Making legcoeffs consistent with chebcoeffs

legcoeffs(f,n) and chebcoeffs(f,n) both return exactly n coefficients
and not n+1.
minor fix to a test.