Add files

This commit is contained in:
jeong0982
2024-03-22 16:53:25 +08:00
parent 725c2d1b3d
commit fd4c4d209c
7 changed files with 35 additions and 4 deletions

0
src/core/verifier.rs Normal file
View File

View File

@@ -1 +1,11 @@
use std::fmt::Debug;
use ff::Field;
// These are different form of multivariate polynomial
pub mod coefficient;
pub mod factored;
pub mod composition;
pub trait MultivariatePolynomial<F: Field>: Clone + Debug {
fn interpolate(points: Vec<F>) -> Self;
}

View File

@@ -0,0 +1,25 @@
use ff::Field;
use crate::poly::Polynomial;
use super::MultivariatePolynomial;
#[derive(Clone, Debug)]
pub struct CoefficientForm<F: Field> {
variables: u64,
coefficients: Vec<F>,
}
impl<F: Field> Polynomial<F> for CoefficientForm<F> {
type Point = Vec<F>;
fn evaluate(&self, point: &Self::Point) -> F {
todo!()
}
}
impl<F: Field> MultivariatePolynomial<F> for CoefficientForm<F> {
fn interpolate(points: Vec<F>) -> Self {
todo!()
}
}

View File

View File

View File

@@ -1 +0,0 @@
pub mod arithmetic;

View File

@@ -1,3 +0,0 @@
use crate::poly::Polynomial;
pub fn interpolate() -> () {}