There are two Quadratic circuit examples in circuits/
:
quadratic.circom
- Proves that x is known in:
x^2 + x + 5 = 11
- Proves that x is known in:
circuits/Abcx.circom
- Proves that x is known in:
ax^2 + bx + c = right
- a, b, c, and right are public inputs
- x is private input
- Proves that x is known in:
- Signals can only be positive. Negative inputs underflow.
- "Not Quadratic" errors from the circom compiler mean you have more than one multiplication in a single constraint. Break the constraints up so that there is one multiplication per constraint. See
circuits/Abcx.circom
for an example of this.
yarn
yarn circom:dev
yarn test
Uses Date.now()
as entropy in the trusted setup.
yarn circom:prod