You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The underlying methods in BigDecimal, etc. are already there, and it might save a bit of time and code to do both at once if needed (and they often are used together).
The text was updated successfully, but these errors were encountered:
There is something VERY odd about our remainder / mod result with fractions.
Quotient / remainder should be x = yq + r when x ÷ y but since dividing fractions is just multiplication by the inverse, r will always be zero. If x == a/b and y == c/d, so a/b ÷ c/d = a×d / b×c so q = ad / bc and then yq is c/d × ad / bc or ca / bc or just a/b, in other words x. So r must always be 0 when dividing fractions.
I don't know where I got the "formula" for remainder inside BigFraction, but it seems to be bogus...
The underlying methods in BigDecimal, etc. are already there, and it might save a bit of time and code to do both at once if needed (and they often are used together).
The text was updated successfully, but these errors were encountered: