-
Notifications
You must be signed in to change notification settings - Fork 15
Open
Labels
gadgetWrite a circuit using clean. Usually well-suited for external contributionsWrite a circuit using clean. Usually well-suited for external contributionsgood first issueGood for newcomersGood for newcomers
Description
Formalize the BinSub (binary subtraction) circuit from circomlib.
The BinSub circuit performs binary subtraction with borrow bit handling.
Implementation details
- Located in circomlib/circuits/binsub.circom
- Implements n-bit binary subtraction: (in[0] + 2^n) - in[1] = out + aux*2^n
- Takes two n-bit binary inputs and produces n-bit output plus auxiliary borrow bit
- Similar complexity to BinSum which is already being formalized
References
- Parent epic: Formalize all of circomlib #155 (Formalize all of circomlib)
- Related: Formalize BinSum gadget #198 (Formalize BinSum gadget)
- Original circomlib source
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
gadgetWrite a circuit using clean. Usually well-suited for external contributionsWrite a circuit using clean. Usually well-suited for external contributionsgood first issueGood for newcomersGood for newcomers