fix inversion and consistency