Module plonk_gadgets::scalar[][src]

Expand description

Basic Scalar oriented gadgets collection.

This module actually contains conditional selection implementations as well as equalty-checking gadgets.

Functions

Conditionally selects the value provided or a one instead. NOTE that the select input has to be previously constrained to be either one or zero.

Conditionally selects the value provided or a zero instead. NOTE that the select input has to be previously constrained to be either one or zero.

Provided a Variable and the Scalar it is attached to, the function constraints the Variable to be != Zero.

Returns 1 if a = b and zero otherwise.