Updated windows algorithm, fixed size