Skip to content

Commit 582dc80

Browse files
feat: added predefined curves (#8)
* added predefined curves added fully constrained `hash_to_curve` method fixed bug where `evaluate_linear_expression` was not working added `msm` method into `BigCurve` * fmt * removed unused code * updated readme * update readme * updated dependency
1 parent da70f2b commit 582dc80

22 files changed

+2092
-693
lines changed

.github/workflows/test.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ name: Noir tests
22

33
on:
44
push:
5-
branches:
6-
- main
5+
branches:
6+
- main
77
pull_request:
88

99
env:
@@ -16,7 +16,7 @@ jobs:
1616
strategy:
1717
fail-fast: false
1818
matrix:
19-
toolchain: [nightly, 0.34.0]
19+
toolchain: [nightly, 0.35.0]
2020
steps:
2121
- name: Checkout sources
2222
uses: actions/checkout@v4
@@ -38,7 +38,7 @@ jobs:
3838
- name: Install Nargo
3939
uses: noir-lang/[email protected]
4040
with:
41-
toolchain: 0.34.0
41+
toolchain: 0.35.0
4242

4343
- name: Run formatter
4444
run: nargo fmt --check

Nargo.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
name = "noir_bigcurve"
33
type = "lib"
44
authors = [""]
5-
compiler_version = ">=0.34.0"
5+
compiler_version = ">=0.35.0"
66

77
[dependencies]
8-
bignum = {tag = "v0.3.4", git = "https://github.com/noir-lang/noir-bignum"}
8+
bignum = {tag = "v0.3.7", git = "https://github.com/noir-lang/noir-bignum"}
9+
sort = {tag = "v0.1.0", git = "https://github.com/noir-lang/noir_sort"}

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ The most efficient method to evaluate curve operations is `BigCurve::evaluate_li
2424

2525
- When performing MSMs, utilize the Montgomery Ladder to minimize the number of field operations (see `batch_mul` in `barretenberg/src/stdlib/biggroup` for example implementation)
2626
- `ScalarField` is not properly constrained when constructed from a `BigNum` object
27-
- Add tests for curves that have a nonzero `a` parameter
28-
- Add hash to curve method
27+
- [x] Add tests for curves that have a nonzero `a` parameter
28+
- [x] Add hash to curve method
2929
- Add method to check point is in prime-order subgroup for curves with a cofactor
3030
- Parametrise and test with a degree-2 extension field instead of `BigNum`
31-
- Add curve parameters for commonly used curves (BN254, BLS12-381, MNT4, MNT6, Pasta, Vella, Secp256K1, Secp256R1)
31+
- [x] Add curve parameters for commonly used curves (BN254, BLS12-381, MNT4, MNT6, Pasta, Vella, Secp256K1, Secp256R1)
3232
- Create benchmarks
3333
- Add support for curve endomorphisms where applicable (if base field and scalar field both contain cube roots of unity, we can reduce the number of point doublings required for an MSM in half)
3434

0 commit comments

Comments
 (0)