James Miller

Results 13 comments of James Miller

Further benchmarks suggest that, currently, simply using the GCD to find a common denominator for two rationals is a major performance hit. As in, about 95% of the time taken...

I'm not against them. Both look like like good candidates to implement in the low-level part of the library, especially if I decide to implement modular arbitrary-precision integers as a...

How big are the numbers in question? The divide-and-conquer algorithm only really helps when you have a lot of digits, like > 1000 in whatever base you're converting from.

Ah, good catch. Fortunately it's only used for pre-allocating the `Vec`, so it doesn't cause any real issues. Not sure why it passes `size - 1` there.

Yeah, I tried to limit it to small functions/methods anyway, most of the stuff marked `#[inline]` is internal helper stuff (`copy_incr`, `zero`, etc.) or trait implementations that do little more...

Sounds good. I've got an idea for it. Basically a set of traits for the operations, similar to the regular ones or the augmented ones. First though I'm gonna do...

Well right now it says that the bit-shift operators correspond to a multiplication or division by a power-of-two, so the results Ramp gets _are_ correct. That said, I am using...

This shouldn't be too hard to add for MSB-encoding, since that's what the lower-level base conversion functions do already. For LSB-encoded, on a little-endian system I should be able to...

Just realized that I'm missing some information for this feature. `Int`s are stored as signed-magnitude, so that's what would be easiest to encode and decode. Supporting a two's complement representation...