Added some functions to BitOperations