Skip to main content

evals_eq_hypercube

Function evals_eq_hypercube 

Source
pub unsafe fn evals_eq_hypercube(
    out: &mut DeviceBuffer<EF>,
    xs: &[EF],
    device_ctx: &GpuDeviceCtx,
) -> Result<(), KernelError>
Expand description

Given vector x in F^n, populates out with eq_n(x, y) for y on hypercube H_n.

Note: This function launches n CUDA kernels.

The multilinear equality polynomial is defined as:

    eq(x, z) = \prod_{i=0}^{n-1} (x_i z_i + (1 - x_i)(1 - z_i)).

ยงSafety

  • n is set to the length of xs.
  • out must have length >= 2^n.