Given eg x = 2y and x == 6 (mod 8), we do not know the value of y (mod 8), but we can say y == 3 (mod 4). Do we already have some variant of divmod, say div2mod, that would return (3, 4) for div2mod(6, 2, 8)? As far as I can see that just involves dividing all arguments by the common gcd before invoking divmod, so if we don't already have something like that it might be a useful convenience function to add.
Given eg x = 2y and x == 6 (mod 8), we do not know the value of y (mod 8), but we can say y == 3 (mod 4). Do we already have some variant of divmod, say div2mod, that would return (3, 4) for div2mod(6, 2, 8)? As far as I can see that just involves dividing all arguments by the common gcd before invoking divmod, so if we don't already have something like that it might be a useful convenience function to add.