inversion number