Well, if it's an M16, then by all means go with a 14.5" like all the other M4's. However, you will be giving up a lot of terminal performance in which case go with the 20" like the marines. A bayonet is a poor implement for anything less than the 20". When bayonets were widely used way back when, they were waaaay out there and were quite long making them quite effective in stand off attacks, but if you have it mounted on a short barreled weapon, the enemy is going to already be too close - I would rather have the knife in my hand at that distance.
Curiously though, how many times have you seen bayonets mounted, much less USED in such a manner over there? I am not saying it doesn't happen, but I am curious because I have never personally seen or read of a bayonet attack with modern weapons but I am sure it happens from time to time.