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

Fix/neg factorial #1158

Merged
merged 5 commits into from
Jun 7, 2024
Merged

Fix/neg factorial #1158

merged 5 commits into from
Jun 7, 2024

Conversation

Tabaie
Copy link
Contributor

@Tabaie Tabaie commented Jun 6, 2024

Description

leastauthority pointed out that the sumcheck package incorrectly yields negFactorial(1) = 1 (should be -1)
This PR puts the correct implementation from the polynomial package in internal to be used by both.

Update:
The incorrect version of negFactorial was used by InterpolateInRange which itself wasn't used anywhere. negFactorial is back in polynomial.go and InterpolateInRange is deleted.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Tests

  • TestNegFactorial

Checklist:

  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • I did not modify files generated from templates
  • golangci-lint does not output errors locally
  • New and existing unit tests pass locally with my changes

@Tabaie Tabaie requested a review from gbotrel June 6, 2024 16:55
@Tabaie Tabaie requested a review from gbotrel June 7, 2024 21:13
@Tabaie Tabaie merged commit 89b9809 into master Jun 7, 2024
6 checks passed
@Tabaie Tabaie deleted the fix/neg-factorial branch June 7, 2024 21:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants