lenght and coderate calculated