algorithmica
algorithmica copied to clipboard
Ratio division looks wrong
In the following line:
https://github.com/algorithmica-org/algorithmica/blob/ed1945c3d2de8548b1c744d3161eb668703db808/content/english/hpc/arithmetic/float.md?plain=1#L41
Instead of:
r operator/(r a, r b) { return {a.x * b.x, a.y * b.y}; }
I think this is showing the division of two ratios and it should show:
r operator/(r a, r b) { return {a.x * b.y, a.y * b.x}; }
More generally, the division shows exactly the same as the multiplication which doesn't seem to make sense.