Skip to content

Ensure MatZq samplers return reduced matrices - #535

Open
jnsiemer wants to merge 2 commits into
devfrom
hotfix_reduced_matzq_samplers
Open

jnsiemer wants to merge 2 commits into
devfrom
hotfix_reduced_matzq_samplers

Conversation

@jnsiemer

@jnsiemer jnsiemer commented Oct 6, 2026

Copy link
Copy Markdown
Member

Description

Essentially, the new FLINT version actually doesn't reduce entries anymore when calling fmpz_mod_mat_set_entry. Turns out, I forgot to reduce the sampled values manually before inserting them into MatZq instances.

This PR fixes...

  • sample_binomial
  • sample_discrete_gauss

for/ of MatZq.

Testing

  • I included a test for this edge case

@jnsiemer jnsiemer self-assigned this Oct 6, 2026
@jnsiemer jnsiemer added the hotfix🔥 This issue or PR implements an important change and should be worked on quickly label Oct 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

hotfix🔥 This issue or PR implements an important change and should be worked on quickly

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant