Skip to content

Commit

Permalink
Rename fp-mul-test2 circuit
Browse files Browse the repository at this point in the history
  • Loading branch information
SoraSuegami committed Oct 10, 2024
1 parent 41d6579 commit 5f549d5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion packages/circuits/tests/fp-mul.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ describe('FpMul', () => {
circuit2 = await wasm_tester(
path.join(
__dirname,
'./test-circuits/fp-mul-test2.circom'
'./test-circuits/fp-mul-test-range-check.circom'
),
{
recompile: true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,15 @@ include "../../lib/bigint.circom";
include "../../lib/bigint-func.circom";


/// @title FpMul
/// @notice Multiple two numbers in Fp
/// @title FpMul_TestRangeCheck
/// @notice Multiple two numbers in Fp, where q and r are also provided as inputs only for test purposes
/// @param a Input 1 to FpMul; assumes to consist of `k` chunks, each of which must fit in `n` bits
/// @param b Input 2 to FpMul; assumes to consist of `k` chunks, each of which must fit in `n` bits
/// @param p The modulus; assumes to consist of `k` chunks, each of which must fit in `n` bits
/// @param q The quotient; assumes to consist of `k` chunks, each of which must fit in `n` bits
/// @param r The remainder; assumes to consist of `k` chunks, each of which must fit in `n` bits
/// @output out The result of the FpMul
template FpMul(n, k) {
template FpMul_TestRangeCheck(n, k) {
assert(n + n + log_ceil(k) + 2 <= 252);

signal input a[k];
Expand Down

0 comments on commit 5f549d5

Please sign in to comment.