Polynomial evaluation related functions added#89
Open
ph4r05 wants to merge 2 commits intoilanschnell:masterfrom
Open
Polynomial evaluation related functions added#89ph4r05 wants to merge 2 commits intoilanschnell:masterfrom
ph4r05 wants to merge 2 commits intoilanschnell:masterfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We implemented few other functions related to the GF(2) polynomial evaluation:
x_i, where there arex_0, ..., x_{block_size}terms. I.e., it is a projection of the input, of i-th bit eachblock_sizebits. This can later serve as basis to construct more complex polynomials evaluated on the whole input data repeatedly.base[i] = base[i].eval_monic(input, i, block_size) for i in range(block_size)]x_2 * x_8 + x_14 = base[2] * base[8] + base[14]HW(x_2 * x_8 + x_14) = (base[2] * base[8]).fast_hw_xor(base[14])- the last XOR is performed in-memory, which is fasterWe also used vector operations from #20.
Check if there is something usable, I can make a PR using just some parts of this code.