Final tidy up of comments and vector length code