fixed bit position calculation