package tezos-bls12-381-polynomial

  1. Overview
  2. Docs
type fr = Fr.t
type fr_array = Fr_carray.Stubs.t
val compute_domain : fr_array -> int -> fr -> unit

compute_domain res n g computes [one; g; ..; g^{n-1}] for a given blst_fr element g

  • requires: n is even and 0 < n <= size res
  • ensures: res[i] = g^i for i = 0..(n-1)
val rescale : fr_array -> fr_array -> int -> int -> unit

rescale res a size_res size_a writes the result of rescaling the evaluation representation of a polynomial a from domain_a of size size_a to domain_res of size size_res in res

requires:

  • size res = size_res
  • size a = size_a
  • size_res <= size_a
  • res and a are disjoint
  • size_res mod size_a = 0
OCaml

Innovation. Community. Security.