-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add coset fft API * modify code to match coset fft * remove hardcoded coset_gens * small clean-up * add initial comment * add a note on the computed interpolation value * Add more comments and move random linear commitment to the proofs in the same place * fix: doc numbering
- Loading branch information
1 parent
fb1aff3
commit ee9c693
Showing
5 changed files
with
133 additions
and
84 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
use bls12_381::{ff::Field, Scalar}; | ||
|
||
/// CosetFFt contains a generator(coset) element that can be used | ||
/// to compute a coset FFT and its inverse which consequently can be used to | ||
/// compute a coset IFFT | ||
#[derive(Debug, Clone)] | ||
pub struct CosetFFT { | ||
pub generator: Scalar, | ||
pub generator_inv: Scalar, | ||
} | ||
|
||
impl CosetFFT { | ||
pub fn new(gen: Scalar) -> Self { | ||
Self { | ||
generator: gen, | ||
generator_inv: gen.invert().expect("cosets should be non-zero"), | ||
} | ||
} | ||
} |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
mod coset_fft; | ||
pub mod domain; | ||
mod fft; | ||
pub mod poly_coeff; | ||
|
||
pub use coset_fft::CosetFFT; |