Cartesian To Fractional Coordinates Python