created inverse method