Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Push negative fraction weirdness into LCM #27

Closed
frostburn opened this issue Apr 20, 2024 · 1 comment · Fixed by #28
Closed

Push negative fraction weirdness into LCM #27

frostburn opened this issue Apr 20, 2024 · 1 comment · Fixed by #28
Labels
bug Something isn't working

Comments

@frostburn
Copy link
Member

The identity a * b = lcm(a, b) * gcd(a, b) is nice even if negative numbers are a bit non-sensical.

@frostburn frostburn added the bug Something isn't working label Apr 20, 2024
frostburn added a commit that referenced this issue Apr 20, 2024
Replicate something similar for radicand analogues.
Fix zero fraction normalization.

ref #27
frostburn added a commit that referenced this issue Apr 20, 2024
Extend gcd and lcm to bigints.
Replicate something similar for radicand analogues.
Fix zero fraction normalization.

ref #27
frostburn added a commit that referenced this issue Apr 20, 2024
Replicate something similar for radical/radicand analogues.
Extend gcd, lcm and mmod to bigints.
Fix zero fraction normalization.

ref #27
@frostburn frostburn linked a pull request Apr 20, 2024 that will close this issue
@frostburn
Copy link
Member Author

Turns out truncation towards zero has even stranger consequences for gcd. Not touching it because it needs to be extra fast.

frostburn added a commit that referenced this issue Apr 20, 2024
Replicate something similar for radical/radicand analogues.
Extend gcd, lcm and mmod to bigints.
Fix zero fraction normalization.

ref #27
frostburn added a commit that referenced this issue Apr 21, 2024
Replicate something similar for radical/radicand analogues.
Extend gcd, lcm and mmod to bigints.
Fix zero fraction normalization.

ref #27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant