From 21d2438a33a68b30471a272e4e092e55eb0addee Mon Sep 17 00:00:00 2001 From: Paul Miller Date: Tue, 24 Jan 2023 23:30:53 +0000 Subject: [PATCH] BLS: fix tests. Poseidon: more tests --- src/abstract/poseidon.ts | 5 +- src/bls12-381.ts | 5 +- src/stark.ts | 2 +- test/bls12-381.test.js | 2 +- test/ed25519.test.js | 2 +- test/ed448.test.js | 2 +- test/index.test.js | 4 +- test/stark/basic.test.js | 32 +- test/stark/index.test.js | 3 +- test/stark/poseidon.test.js | 112 ++++ test/stark/poseidon/LICENSE | 201 ++++++ test/stark/poseidon/README.md | 35 + test/stark/poseidon/poseidon3.txt | 462 +++++++++++++ test/stark/poseidon/poseidon4.txt | 559 ++++++++++++++++ test/stark/poseidon/poseidon5.txt | 651 ++++++++++++++++++ test/stark/poseidon/poseidon9.txt | 1031 +++++++++++++++++++++++++++++ test/stark/property.test.js | 76 +-- 17 files changed, 3120 insertions(+), 64 deletions(-) create mode 100644 test/stark/poseidon.test.js create mode 100644 test/stark/poseidon/LICENSE create mode 100644 test/stark/poseidon/README.md create mode 100644 test/stark/poseidon/poseidon3.txt create mode 100644 test/stark/poseidon/poseidon4.txt create mode 100644 test/stark/poseidon/poseidon5.txt create mode 100644 test/stark/poseidon/poseidon9.txt diff --git a/src/abstract/poseidon.ts b/src/abstract/poseidon.ts index 82a8ca3..021564f 100644 --- a/src/abstract/poseidon.ts +++ b/src/abstract/poseidon.ts @@ -95,7 +95,7 @@ export function poseidon(opts: PoseidonOpts) { ); return values; }; - return function poseidonHash(values: bigint[]) { + const poseidonHash = function poseidonHash(values: bigint[]) { if (!Array.isArray(values) || values.length !== t) throw new Error(`Poseidon: wrong values (expected array of bigints with length ${t})`); values = values.map((i) => { @@ -114,4 +114,7 @@ export function poseidon(opts: PoseidonOpts) { throw new Error(`Poseidon: wrong number of rounds: last round=${round}, total=${rounds}`); return values; }; + // For verification in tests + poseidonHash.roundConstants = opts.roundConstants; + return poseidonHash; } diff --git a/src/bls12-381.ts b/src/bls12-381.ts index 5f48372..f9626bd 100644 --- a/src/bls12-381.ts +++ b/src/bls12-381.ts @@ -1227,8 +1227,9 @@ export const bls12_381: CurveFn = bls({ point.assertValidity(); if (point.equals(bls12_381.G2.ProjectivePoint.ZERO)) return concatB(COMPRESSED_ZERO, numberToBytesBE(0n, Fp.BYTES)); - const { re: x0, im: x1 } = Fp2.reim(point.x); - const { re: y0, im: y1 } = Fp2.reim(point.y); + const a = point.toAffine(); + const { re: x0, im: x1 } = Fp2.reim(a.x); + const { re: y0, im: y1 } = Fp2.reim(a.y); const tmp = y1 > 0n ? y1 * 2n : y0 * 2n; const aflag1 = Boolean((tmp / Fp.ORDER) & 1n); const z1 = bitSet(bitSet(x1, 381, aflag1), S_BIT_POS, true); diff --git a/src/stark.ts b/src/stark.ts index f9ce157..7da61b0 100644 --- a/src/stark.ts +++ b/src/stark.ts @@ -318,7 +318,7 @@ export type PoseidonOpts = { roundsPartial: number; }; -function poseidonBasic(opts: PoseidonOpts, mds: bigint[][]) { +export function poseidonBasic(opts: PoseidonOpts, mds: bigint[][]) { validateField(opts.Fp); if (!Number.isSafeInteger(opts.rate) || !Number.isSafeInteger(opts.capacity)) throw new Error(`Wrong poseidon opts: ${opts}`); diff --git a/test/bls12-381.test.js b/test/bls12-381.test.js index 4f59007..42a53b5 100644 --- a/test/bls12-381.test.js +++ b/test/bls12-381.test.js @@ -1746,7 +1746,7 @@ describe('verify()', () => { } }); describe('batch', () => { - should.only('verify multi-signature', () => { + should('verify multi-signature', () => { fc.assert( fc.property(FC_MSG_5, FC_BIGINT_5, (messages, privateKeys) => { privateKeys = privateKeys.slice(0, messages.length); diff --git a/test/ed25519.test.js b/test/ed25519.test.js index 2f78e79..40b967c 100644 --- a/test/ed25519.test.js +++ b/test/ed25519.test.js @@ -373,7 +373,7 @@ describe('ed25519', () => { throws(() => RistrettoPoint.fromHex(b), badBytes); } }); - should('ristretto255/should create right points from uniform hash', async () => { + should('ristretto255/should create right points from uniform hash', () => { const labels = [ 'Ristretto is traditionally a short shot of espresso coffee', 'made with the normal amount of ground coffee but extracted with', diff --git a/test/ed448.test.js b/test/ed448.test.js index 0b2b0a0..ca48358 100644 --- a/test/ed448.test.js +++ b/test/ed448.test.js @@ -325,7 +325,7 @@ describe('ed448', () => { }); } - should('not accept >57byte private keys', async () => { + should('not accept >57byte private keys', () => { const invalidPriv = 100000000000000000000000000000000000009000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000090000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800073278156000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000n; throws(() => ed.getPublicKey(invalidPriv)); diff --git a/test/index.test.js b/test/index.test.js index 7fa86a8..c7f2e31 100644 --- a/test/index.test.js +++ b/test/index.test.js @@ -6,9 +6,9 @@ import './nist.test.js'; import './ed448.test.js'; import './ed25519.test.js'; import './secp256k1.test.js'; -import './stark/stark.test.js'; +import './stark/index.test.js'; import './jubjub.test.js'; -// import './bls12-381.test.js'; +import './bls12-381.test.js'; import './hash-to-curve.test.js'; should.run(); diff --git a/test/stark/basic.test.js b/test/stark/basic.test.js index e60cd89..bbb9cea 100644 --- a/test/stark/basic.test.js +++ b/test/stark/basic.test.js @@ -4,49 +4,49 @@ import * as starknet from '../../lib/esm/stark.js'; import { default as issue2 } from './fixtures/issue2.json' assert { type: 'json' }; should('Basic elliptic sanity check', () => { - const g1 = starknet.Point.BASE; + const g1 = starknet.ProjectivePoint.BASE; deepStrictEqual( - g1.x.toString(16), + g1.toAffine().x.toString(16), '1ef15c18599971b7beced415a40f0c7deacfd9b0d1819e03d723d8bc943cfca' ); deepStrictEqual( - g1.y.toString(16), + g1.toAffine().y.toString(16), '5668060aa49730b7be4801df46ec62de53ecd11abe43a32873000c36e8dc1f' ); const g2 = g1.double(); deepStrictEqual( - g2.x.toString(16), + g2.toAffine().x.toString(16), '759ca09377679ecd535a81e83039658bf40959283187c654c5416f439403cf5' ); deepStrictEqual( - g2.y.toString(16), + g2.toAffine().y.toString(16), '6f524a3400e7708d5c01a28598ad272e7455aa88778b19f93b562d7a9646c41' ); const g3 = g2.add(g1); deepStrictEqual( - g3.x.toString(16), + g3.toAffine().x.toString(16), '411494b501a98abd8262b0da1351e17899a0c4ef23dd2f96fec5ba847310b20' ); deepStrictEqual( - g3.y.toString(16), + g3.toAffine().y.toString(16), '7e1b3ebac08924d2c26f409549191fcf94f3bf6f301ed3553e22dfb802f0686' ); const g32 = g1.multiply(3); deepStrictEqual( - g32.x.toString(16), + g32.toAffine().x.toString(16), '411494b501a98abd8262b0da1351e17899a0c4ef23dd2f96fec5ba847310b20' ); deepStrictEqual( - g32.y.toString(16), + g32.toAffine().y.toString(16), '7e1b3ebac08924d2c26f409549191fcf94f3bf6f301ed3553e22dfb802f0686' ); const minus1 = g1.multiply(starknet.CURVE.n - 1n); deepStrictEqual( - minus1.x.toString(16), + minus1.toAffine().x.toString(16), '1ef15c18599971b7beced415a40f0c7deacfd9b0d1819e03d723d8bc943cfca' ); deepStrictEqual( - minus1.y.toString(16), + minus1.toAffine().y.toString(16), '7a997f9f55b68e04841b7fe20b9139d21ac132ee541bc5cd78cfff3c91723e2' ); }); @@ -156,7 +156,7 @@ should('Seed derivation (example)', () => { }); should('Compressed keys', () => { - const G = starknet.Point.BASE; + const G = starknet.ProjectivePoint.BASE; const half = starknet.CURVE.n / 2n; const last = starknet.CURVE.n; const vectors = [ @@ -182,14 +182,14 @@ should('Compressed keys', () => { last - 2n, last - 1n, ].map((i) => G.multiply(i)); - const fixPoint = (pt) => ({ ...pt, _WINDOW_SIZE: undefined }); + const fixPoint = (pt) => pt.toAffine(); for (const v of vectors) { const uncompressed = v.toHex(); const compressed = v.toHex(true); const exp = fixPoint(v); - deepStrictEqual(fixPoint(starknet.Point.fromHex(uncompressed)), exp); - deepStrictEqual(fixPoint(starknet.Point.fromHex(compressed)), exp); - deepStrictEqual(starknet.Point.fromHex(compressed).toHex(), uncompressed); + deepStrictEqual(fixPoint(starknet.ProjectivePoint.fromHex(uncompressed)), exp); + deepStrictEqual(fixPoint(starknet.ProjectivePoint.fromHex(compressed)), exp); + deepStrictEqual(starknet.ProjectivePoint.fromHex(compressed).toHex(), uncompressed); } }); diff --git a/test/stark/index.test.js b/test/stark/index.test.js index 7dbc77b..f27bed9 100644 --- a/test/stark/index.test.js +++ b/test/stark/index.test.js @@ -1,5 +1,4 @@ - import './basic.test.js'; import './stark.test.js'; import './property.test.js'; - +import './poseidon.test.js'; diff --git a/test/stark/poseidon.test.js b/test/stark/poseidon.test.js new file mode 100644 index 0000000..b65121e --- /dev/null +++ b/test/stark/poseidon.test.js @@ -0,0 +1,112 @@ +import { deepStrictEqual, throws } from 'assert'; +import { should } from 'micro-should'; +import * as starknet from '../../lib/esm/stark.js'; +import * as fs from 'fs'; + +function parseTest(path) { + let data = fs.readFileSync(path, 'ascii'); + // Remove whitespaces + data = data.replace(/[ |\t]/g, ''); + const pattern = + 'Rate=(\\d+)\n' + + 'Capacity=(\\d+)\n' + + 'FullRounds=(\\d+)\n' + + 'PartialRounds=(\\d+)\n' + + 'MDS=\\[(.+)\\]\n' + + 'RoundKeys=\\(?\n?\\[\n?(.+)\n?\\]\n?\\)?'; + const r = data.match(new RegExp(pattern, 'ms')); + + function parseArray(s) { + // Remove new lines + s = s.replace(/\n/gms, ''); + return s.match(/(\[.+?\])/g).map((i) => + i + .replace(/^\[(.+)\]$/, '$1') + .split(',') + .filter((i) => !!i) + ); + } + const res = { + rate: +r[1], + capacity: +r[2], + roundsFull: +r[3], + roundsPartial: +r[4], + MDS: parseArray(r[5]).map((i) => i.map((j) => BigInt(j))), + roundConstants: parseArray(r[6]).map((i) => i.map((j) => BigInt(j))), + }; + return res; +} + +function mapPoseidon(parsed) { + return starknet.poseidonBasic( + { + Fp: starknet.Fp251, + rate: parsed.rate, + capacity: parsed.capacity, + roundsFull: parsed.roundsFull, + roundsPartial: parsed.roundsPartial, + }, + parsed.MDS + ); +} + +const parsed = { + poseidon3: parseTest('./test/stark/poseidon/poseidon3.txt'), + poseidon4: parseTest('./test/stark/poseidon/poseidon4.txt'), + poseidon5: parseTest('./test/stark/poseidon/poseidon5.txt'), + poseidon9: parseTest('./test/stark/poseidon/poseidon9.txt'), +}; + +function poseidonTest(name, parsed) { + should(`${name}`, () => { + const fn = mapPoseidon(parsed); + deepStrictEqual(fn.roundConstants, parsed.roundConstants); + }); +} + +poseidonTest('poseidon3', parsed.poseidon3); +poseidonTest('poseidon4', parsed.poseidon4); +poseidonTest('poseidon5', parsed.poseidon5); +poseidonTest('poseidon9', parsed.poseidon9); + +should('Poseidon examples', () => { + const p3 = mapPoseidon(parsed.poseidon3); + deepStrictEqual(p3([0n, 0n, 0n]), [ + 3446325744004048536138401612021367625846492093718951375866996507163446763827n, + 1590252087433376791875644726012779423683501236913937337746052470473806035332n, + 867921192302518434283879514999422690776342565400001269945778456016268852423n, + ]); + const p4 = mapPoseidon(parsed.poseidon4); + deepStrictEqual(p4([0n, 0n, 0n, 0n]), [ + 535071095200566880914603862188010633478042591441142518549720701573192347548n, + 3567335813488551850156302853280844225974867890860330236555401145692518003968n, + 229995103310401763929738317978722680640995513996113588430855556460153357543n, + 3513983790849716360905369754287999509206472929684378838050290392634812839312n, + ]); + const p5 = mapPoseidon(parsed.poseidon5); + deepStrictEqual(p5([0n, 0n, 0n, 0n, 0n]), [ + 2337689130971531876049206831496963607805116499042700598724344149414565980684n, + 3230969295497815870174763682436655274044379544854667759151474216427142025631n, + 3297330512217530111610698859408044542971696143761201570393504997742535648562n, + 2585480844700786541432072704002477919020588246983274666988914431019064343941n, + 3595308260654382824623573767385493361624474708214823462901432822513585995028n, + ]); + const p9 = mapPoseidon(parsed.poseidon9); + deepStrictEqual(p9([0n, 0n, 0n, 0n, 0n, 0n, 0n, 0n, 0n]), [ + 1534116856660032929112709488204491699743182428465681149262739677337223235050n, + 1710856073207389764546990138116985223517553616229641666885337928044617114700n, + 3165864635055638516987240200217592641540231237468651257819894959934472989427n, + 1003007637710164252047715558598366312649052908276423203724288341354608811559n, + 68117303579957054409211824649914588822081700129416361923518488718489651489n, + 1123395637839379807713801282868237406546107732595903195840754789810160564711n, + 478590974834311070537087181212389392308746075734019180430422247431982932503n, + 835322726024358888065061514739954009068852229059154336727219387089732433787n, + 3129703030204995742174502162918848446737407262178341733578946634564864233056n, + ]); +}); + +// ESM is broken. +import url from 'url'; +if (import.meta.url === url.pathToFileURL(process.argv[1]).href) { + should.run(); +} diff --git a/test/stark/poseidon/LICENSE b/test/stark/poseidon/LICENSE new file mode 100644 index 0000000..261eeb9 --- /dev/null +++ b/test/stark/poseidon/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/test/stark/poseidon/README.md b/test/stark/poseidon/README.md new file mode 100644 index 0000000..c65ce05 --- /dev/null +++ b/test/stark/poseidon/README.md @@ -0,0 +1,35 @@ +# StarkWare's Poseidon Hash + +[Poseidon](https://www.poseidon-hash.info/) is a family of hash functions designed for being very efficient as algebraic circuits. +As such, they may be very useful in ZK proving systems such as STARKs and others. + +This repository provides the official parameters of StarkWare's Poseidon hash implementations. + +All the instances are over the prime field: +p = 2^251 + 17 * 2^192 + 1 = 3618502788666131213697322783095070105623107215331596699973092056135872020481 + +A few examples hash results with the different parameters: + +``` +Poseidon3([0,0,0]) = [3446325744004048536138401612021367625846492093718951375866996507163446763827, + 1590252087433376791875644726012779423683501236913937337746052470473806035332, + 867921192302518434283879514999422690776342565400001269945778456016268852423] +Poseidon4([0,0,0,0]) = [535071095200566880914603862188010633478042591441142518549720701573192347548, + 3567335813488551850156302853280844225974867890860330236555401145692518003968, + 229995103310401763929738317978722680640995513996113588430855556460153357543, + 3513983790849716360905369754287999509206472929684378838050290392634812839312] +Poseidon5([0,0,0,0,0]) = [2337689130971531876049206831496963607805116499042700598724344149414565980684, + 3230969295497815870174763682436655274044379544854667759151474216427142025631, + 3297330512217530111610698859408044542971696143761201570393504997742535648562, + 2585480844700786541432072704002477919020588246983274666988914431019064343941, + 3595308260654382824623573767385493361624474708214823462901432822513585995028] +Poseidon9([0,0,0,0,0,0,0,0,0]) = [1534116856660032929112709488204491699743182428465681149262739677337223235050, + 1710856073207389764546990138116985223517553616229641666885337928044617114700, + 3165864635055638516987240200217592641540231237468651257819894959934472989427, + 1003007637710164252047715558598366312649052908276423203724288341354608811559, + 68117303579957054409211824649914588822081700129416361923518488718489651489, + 1123395637839379807713801282868237406546107732595903195840754789810160564711, + 478590974834311070537087181212389392308746075734019180430422247431982932503, + 835322726024358888065061514739954009068852229059154336727219387089732433787, + 3129703030204995742174502162918848446737407262178341733578946634564864233056] +``` \ No newline at end of file diff --git a/test/stark/poseidon/poseidon3.txt b/test/stark/poseidon/poseidon3.txt new file mode 100644 index 0000000..734a87b --- /dev/null +++ b/test/stark/poseidon/poseidon3.txt @@ -0,0 +1,462 @@ +Rate = 2 +Capacity = 1 +FullRounds = 8 +PartialRounds = 83 +MDS = [[3, 1, 1], [1, -1, 1], [1, 1, -2]] +RoundKeys = [ + [ + 2950795762459345168613727575620414179244544320470208355568817838579231751791, + 1587446564224215276866294500450702039420286416111469274423465069420553242820, + 1645965921169490687904413452218868659025437693527479459426157555728339600137, + ], + [ + 2782373324549879794752287702905278018819686065818504085638398966973694145741, + 3409172630025222641379726933524480516420204828329395644967085131392375707302, + 2379053116496905638239090788901387719228422033660130943198035907032739387135, + ], + [ + 2570819397480941104144008784293466051718826502582588529995520356691856497111, + 3546220846133880637977653625763703334841539452343273304410918449202580719746, + 2720682389492889709700489490056111332164748138023159726590726667539759963454, + ], + [ + 1899653471897224903834726250400246354200311275092866725547887381599836519005, + 2369443697923857319844855392163763375394720104106200469525915896159690979559, + 2354174693689535854311272135513626412848402744119855553970180659094265527996, + ], + [ + 2404084503073127963385083467393598147276436640877011103379112521338973185443, + 950320777137731763811524327595514151340412860090489448295239456547370725376, + 2121140748740143694053732746913428481442990369183417228688865837805149503386, + ], + [ + 2372065044800422557577242066480215868569521938346032514014152523102053709709, + 2618497439310693947058545060953893433487994458443568169824149550389484489896, + 3518297267402065742048564133910509847197496119850246255805075095266319996916, + ], + [ + 340529752683340505065238931581518232901634742162506851191464448040657139775, + 1954876811294863748406056845662382214841467408616109501720437541211031966538, + 813813157354633930267029888722341725864333883175521358739311868164460385261, + ], + [ + 71901595776070443337150458310956362034911936706490730914901986556638720031, + 2789761472166115462625363403490399263810962093264318361008954888847594113421, + 2628791615374802560074754031104384456692791616314774034906110098358135152410, + ], + [ + 3617032588734559635167557152518265808024917503198278888820567553943986939719, + 2624012360209966117322788103333497793082705816015202046036057821340914061980, + 149101987103211771991327927827692640556911620408176100290586418839323044234, + ], + [ + 1039927963829140138166373450440320262590862908847727961488297105916489431045, + 2213946951050724449162431068646025833746639391992751674082854766704900195669, + 2792724903541814965769131737117981991997031078369482697195201969174353468597, + ], + [ + 3212031629728871219804596347439383805499808476303618848198208101593976279441, + 3343514080098703935339621028041191631325798327656683100151836206557453199613, + 614054702436541219556958850933730254992710988573177298270089989048553060199, + ], + [ + 148148081026449726283933484730968827750202042869875329032965774667206931170, + 1158283532103191908366672518396366136968613180867652172211392033571980848414, + 1032400527342371389481069504520755916075559110755235773196747439146396688513, + ], + [ + 806900704622005851310078578853499250941978435851598088619290797134710613736, + 462498083559902778091095573017508352472262817904991134671058825705968404510, + 1003580119810278869589347418043095667699674425582646347949349245557449452503, + ], + [ + 619074932220101074089137133998298830285661916867732916607601635248249357793, + 2635090520059500019661864086615522409798872905401305311748231832709078452746, + 978252636251682252755279071140187792306115352460774007308726210405257135181, + ], + [ + 1766912167973123409669091967764158892111310474906691336473559256218048677083, + 1663265127259512472182980890707014969235283233442916350121860684522654120381, + 3532407621206959585000336211742670185380751515636605428496206887841428074250, + ], + [ + 2507023127157093845256722098502856938353143387711652912931112668310034975446, + 3321152907858462102434883844787153373036767230808678981306827073335525034593, + 3039253036806065280643845548147711477270022154459620569428286684179698125661, + ], + [ + 103480338868480851881924519768416587261556021758163719199282794248762465380, + 2394049781357087698434751577708655768465803975478348134669006211289636928495, + 2660531560345476340796109810821127229446538730404600368347902087220064379579, + ], + [ + 3603166934034556203649050570865466556260359798872408576857928196141785055563, + 1553799760191949768532188139643704561532896296986025007089826672890485412324, + 2744284717053657689091306578463476341218866418732695211367062598446038965164, + ], + [ + 320745764922149897598257794663594419839885234101078803811049904310835548856, + 979382242100682161589753881721708883681034024104145498709287731138044566302, + 1860426855810549882740147175136418997351054138609396651615467358416651354991, + ], + [ + 336173081054369235994909356892506146234495707857220254489443629387613956145, + 1632470326779699229772327605759783482411227247311431865655466227711078175883, + 921958250077481394074960433988881176409497663777043304881055317463712938502, + ], + [ + 3034358982193370602048539901033542101022185309652879937418114324899281842797, + 25626282149517463867572353922222474817434101087272320606729439087234878607, + 3002662261401575565838149305485737102400501329139562227180277188790091853682, + ], + [ + 2939684373453383817196521641512509179310654199629514917426341354023324109367, + 1076484609897998179434851570277297233169621096172424141759873688902355505136, + 2575095284833160494841112025725243274091830284746697961080467506739203605049, + ], + [ + 3565075264617591783581665711620369529657840830498005563542124551465195621851, + 2197016502533303822395077038351174326125210255869204501838837289716363437993, + 331415322883530754594261416546036195982886300052707474899691116664327869405, + ], + [ + 1935011233711290003793244296594669823169522055520303479680359990463281661839, + 3495901467168087413996941216661589517270845976538454329511167073314577412322, + 954195417117133246453562983448451025087661597543338750600301835944144520375, + ], + [ + 1271840477709992894995746871435810599280944810893784031132923384456797925777, + 2565310762274337662754531859505158700827688964841878141121196528015826671847, + 3365022288251637014588279139038152521653896670895105540140002607272936852513, + ], + [ + 1660592021628965529963974299647026602622092163312666588591285654477111176051, + 970104372286014048279296575474974982288801187216974504035759997141059513421, + 2617024574317953753849168721871770134225690844968986289121504184985993971227, + ], + [ + 999899815343607746071464113462778273556695659506865124478430189024755832262, + 2228536129413411161615629030408828764980855956560026807518714080003644769896, + 2701953891198001564547196795777701119629537795442025393867364730330476403227, + ], + [ + 837078355588159388741598313782044128527494922918203556465116291436461597853, + 2121749601840466143704862369657561429793951309962582099604848281796392359214, + 771812260179247428733132708063116523892339056677915387749121983038690154755, + ], + [ + 3317336423132806446086732225036532603224267214833263122557471741829060578219, + 481570067997721834712647566896657604857788523050900222145547508314620762046, + 242195042559343964206291740270858862066153636168162642380846129622127460192, + ], + [ + 2855462178889999218204481481614105202770810647859867354506557827319138379686, + 3525521107148375040131784770413887305850308357895464453970651672160034885202, + 1320839531502392535964065058804908871811967681250362364246430459003920305799, + ], + [ + 2514191518588387125173345107242226637171897291221681115249521904869763202419, + 2798335750958827619666318316247381695117827718387653874070218127140615157902, + 2808467767967035643407948058486565877867906577474361783201337540214875566395, + ], + [ + 3551834385992706206273955480294669176699286104229279436819137165202231595747, + 1219439673853113792340300173186247996249367102884530407862469123523013083971, + 761519904537984520554247997444508040636526566551719396202550009393012691157, + ], + [ + 3355402549169351700500518865338783382387571349497391475317206324155237401353, + 199541098009731541347317515995192175813554789571447733944970283654592727138, + 192100490643078165121235261796864975568292640203635147901612231594408079071, + ], + [ + 1187019357602953326192019968809486933768550466167033084944727938441427050581, + 189525349641911362389041124808934468936759383310282010671081989585219065700, + 2831653363992091308880573627558515686245403755586311978724025292003353336665, + ], + [ + 2052859812632218952608271535089179639890275494426396974475479657192657094698, + 1670756178709659908159049531058853320846231785448204274277900022176591811072, + 3538757242013734574731807289786598937548399719866320954894004830207085723125, + ], + [ + 710549042741321081781917034337800036872214466705318638023070812391485261299, + 2345013122330545298606028187653996682275206910242635100920038943391319595180, + 3528369671971445493932880023233332035122954362711876290904323783426765912206, + ], + [ + 1167120829038120978297497195837406760848728897181138760506162680655977700764, + 3073243357129146594530765548901087443775563058893907738967898816092270628884, + 378514724418106317738164464176041649567501099164061863402473942795977719726, + ], + [ + 333391138410406330127594722511180398159664250722328578952158227406762627796, + 1727570175639917398410201375510924114487348765559913502662122372848626931905, + 968312190621809249603425066974405725769739606059422769908547372904403793174, + ], + [ + 360659316299446405855194688051178331671817370423873014757323462844775818348, + 1386580151907705298970465943238806620109618995410132218037375811184684929291, + 3604888328937389309031638299660239238400230206645344173700074923133890528967, + ], + [ + 2496185632263372962152518155651824899299616724241852816983268163379540137546, + 486538168871046887467737983064272608432052269868418721234810979756540672990, + 1558415498960552213241704009433360128041672577274390114589014204605400783336, + ], + [ + 3512058327686147326577190314835092911156317204978509183234511559551181053926, + 2235429387083113882635494090887463486491842634403047716936833563914243946191, + 1290896777143878193192832813769470418518651727840187056683408155503813799882, + ], + [ + 1143310336918357319571079551779316654556781203013096026972411429993634080835, + 3235435208525081966062419599803346573407862428113723170955762956243193422118, + 1293239921425673430660897025143433077974838969258268884994339615096356996604, + ], + [ + 236252269127612784685426260840574970698541177557674806964960352572864382971, + 1733907592497266237374827232200506798207318263912423249709509725341212026275, + 302004309771755665128395814807589350526779835595021835389022325987048089868, + ], + [ + 3018926838139221755384801385583867283206879023218491758435446265703006270945, + 39701437664873825906031098349904330565195980985885489447836580931425171297, + 908381723021746969965674308809436059628307487140174335882627549095646509778, + ], + [ + 219062858908229855064136253265968615354041842047384625689776811853821594358, + 1283129863776453589317845316917890202859466483456216900835390291449830275503, + 418512623547417594896140369190919231877873410935689672661226540908900544012, + ], + [ + 1792181590047131972851015200157890246436013346535432437041535789841136268632, + 370546432987510607338044736824316856592558876687225326692366316978098770516, + 3323437805230586112013581113386626899534419826098235300155664022709435756946, + ], + [ + 910076621742039763058481476739499965761942516177975130656340375573185415877, + 1762188042455633427137702520675816545396284185254002959309669405982213803405, + 2186362253913140345102191078329764107619534641234549431429008219905315900520, + ], + [ + 2230647725927681765419218738218528849146504088716182944327179019215826045083, + 1069243907556644434301190076451112491469636357133398376850435321160857761825, + 2695241469149243992683268025359863087303400907336026926662328156934068747593, + ], + [ + 1361519681544413849831669554199151294308350560528931040264950307931824877035, + 1339116632207878730171031743761550901312154740800549632983325427035029084904, + 790593524918851401449292693473498591068920069246127392274811084156907468875, + ], + [ + 2723400368331924254840192318398326090089058735091724263333980290765736363637, + 3457180265095920471443772463283225391927927225993685928066766687141729456030, + 1483675376954327086153452545475557749815683871577400883707749788555424847954, + ], + [ + 2926303836265506736227240325795090239680154099205721426928300056982414025239, + 543969119775473768170832347411484329362572550684421616624136244239799475526, + 237401230683847084256617415614300816373730178313253487575312839074042461932, + ], + [ + 844568412840391587862072008674263874021460074878949862892685736454654414423, + 151922054871708336050647150237534498235916969120198637893731715254687336644, + 1299332034710622815055321547569101119597030148120309411086203580212105652312, + ], + [ + 487046922649899823989594814663418784068895385009696501386459462815688122993, + 1104883249092599185744249485896585912845784382683240114120846423960548576851, + 1458388705536282069567179348797334876446380557083422364875248475157495514484, + ], + [ + 850248109622750774031817200193861444623975329881731864752464222442574976566, + 2885843173858536690032695698009109793537724845140477446409245651176355435722, + 3027068551635372249579348422266406787688980506275086097330568993357835463816, + ], + [ + 3231892723647447539926175383213338123506134054432701323145045438168976970994, + 1719080830641935421242626784132692936776388194122314954558418655725251172826, + 1172253756541066126131022537343350498482225068791630219494878195815226839450, + ], + [ + 1619232269633026603732619978083169293258272967781186544174521481891163985093, + 3495680684841853175973173610562400042003100419811771341346135531754869014567, + 1576161515913099892951745452471618612307857113799539794680346855318958552758, + ], + [ + 2618326122974253423403350731396350223238201817594761152626832144510903048529, + 2696245132758436974032479782852265185094623165224532063951287925001108567649, + 930116505665110070247395429730201844026054810856263733273443066419816003444, + ], + [ + 2786389174502246248523918824488629229455088716707062764363111940462137404076, + 1555260846425735320214671887347115247546042526197895180675436886484523605116, + 2306241912153325247392671742757902161446877415586158295423293240351799505917, + ], + [ + 411529621724849932999694270803131456243889635467661223241617477462914950626, + 1542495485262286701469125140275904136434075186064076910329015697714211835205, + 1853045663799041100600825096887578544265580718909350942241802897995488264551, + ], + [ + 2963055259497271220202739837493041799968576111953080503132045092194513937286, + 2303806870349915764285872605046527036748108533406243381676768310692344456050, + 2622104986201990620910286730213140904984256464479840856728424375142929278875, + ], + [ + 2369987021925266811581727383184031736927816625797282287927222602539037105864, + 285070227712021899602056480426671736057274017903028992288878116056674401781, + 3034087076179360957800568733595959058628497428787907887933697691951454610691, + ], + [ + 469095854351700119980323115747590868855368701825706298740201488006320881056, + 360001976264385426746283365024817520563236378289230404095383746911725100012, + 3438709327109021347267562000879503009590697221730578667498351600602230296178, + ], + [ + 63573904800572228121671659287593650438456772568903228287754075619928214969, + 3470881855042989871434874691030920672110111605547839662680968354703074556970, + 724559311507950497340993415408274803001166693839947519425501269424891465492, + ], + [ + 880409284677518997550768549487344416321062350742831373397603704465823658986, + 6876255662475867703077362872097208259197756317287339941435193538565586230, + 2701916445133770775447884812906226786217969545216086200932273680400909154638, + ], + [ + 425152119158711585559310064242720816611629181537672850898056934507216982586, + 1475552998258917706756737045704649573088377604240716286977690565239187213744, + 2413772448122400684309006716414417978370152271397082147158000439863002593561, + ], + [ + 392160855822256520519339260245328807036619920858503984710539815951012864164, + 1075036996503791536261050742318169965707018400307026402939804424927087093987, + 2176439430328703902070742432016450246365760303014562857296722712989275658921, + ], + [ + 1413865976587623331051814207977382826721471106513581745229680113383908569693, + 4879283427490523253696177116563427032332223531862961281430108575019551814, + 3392583297537374046875199552977614390492290683707960975137418536812266544902, + ], + [ + 3600854486849487646325182927019642276644093512133907046667282144129939150983, + 2779924664161372134024229593301361846129279572186444474616319283535189797834, + 2722699960903170449291146429799738181514821447014433304730310678334403972040, + ], + [ + 819109815049226540285781191874507704729062681836086010078910930707209464699, + 3046121243742768013822760785918001632929744274211027071381357122228091333823, + 1339019590803056172509793134119156250729668216522001157582155155947567682278, + ], + [ + 1933279639657506214789316403763326578443023901555983256955812717638093967201, + 2138221547112520744699126051903811860205771600821672121643894708182292213541, + 2694713515543641924097704224170357995809887124438248292930846280951601597065, + ], + [ + 2471734202930133750093618989223585244499567111661178960753938272334153710615, + 504903761112092757611047718215309856203214372330635774577409639907729993533, + 1943979703748281357156510253941035712048221353507135074336243405478613241290, + ], + [ + 684525210957572142559049112233609445802004614280157992196913315652663518936, + 1705585400798782397786453706717059483604368413512485532079242223503960814508, + 192429517716023021556170942988476050278432319516032402725586427701913624665, + ], + [ + 1586493702243128040549584165333371192888583026298039652930372758731750166765, + 686072673323546915014972146032384917012218151266600268450347114036285993377, + 3464340397998075738891129996710075228740496767934137465519455338004332839215, + ], + [ + 2805249176617071054530589390406083958753103601524808155663551392362371834663, + 667746464250968521164727418691487653339733392025160477655836902744186489526, + 1131527712905109997177270289411406385352032457456054589588342450404257139778, + ], + [ + 1908969485750011212309284349900149072003218505891252313183123635318886241171, + 1025257076985551890132050019084873267454083056307650830147063480409707787695, + 2153175291918371429502545470578981828372846236838301412119329786849737957977, + ], + [ + 3410257749736714576487217882785226905621212230027780855361670645857085424384, + 3442969106887588154491488961893254739289120695377621434680934888062399029952, + 3029953900235731770255937704976720759948880815387104275525268727341390470237, + ], + [ + 85453456084781138713939104192561924536933417707871501802199311333127894466, + 2730629666577257820220329078741301754580009106438115341296453318350676425129, + 178242450661072967256438102630920745430303027840919213764087927763335940415, + ], + [ + 2844589222514708695700541363167856718216388819406388706818431442998498677557, + 3547876269219141094308889387292091231377253967587961309624916269569559952944, + 2525005406762984211707203144785482908331876505006839217175334833739957826850, + ], + [ + 3096397013555211396701910432830904669391580557191845136003938801598654871345, + 574424067119200181933992948252007230348512600107123873197603373898923821490, + 1714030696055067278349157346067719307863507310709155690164546226450579547098, + ], + [ + 2339895272202694698739231405357972261413383527237194045718815176814132612501, + 3562501318971895161271663840954705079797767042115717360959659475564651685069, + 69069358687197963617161747606993436483967992689488259107924379545671193749, + ], + [ + 2614502738369008850475068874731531583863538486212691941619835266611116051561, + 655247349763023251625727726218660142895322325659927266813592114640858573566, + 2305235672527595714255517865498269719545193172975330668070873705108690670678, + ], + [ + 926416070297755413261159098243058134401665060349723804040714357642180531931, + 866523735635840246543516964237513287099659681479228450791071595433217821460, + 2284334068466681424919271582037156124891004191915573957556691163266198707693, + ], + [ + 1812588309302477291425732810913354633465435706480768615104211305579383928792, + 2836899808619013605432050476764608707770404125005720004551836441247917488507, + 2989087789022865112405242078196235025698647423649950459911546051695688370523, + ], + [ + 68056284404189102136488263779598243992465747932368669388126367131855404486, + 505425339250887519581119854377342241317528319745596963584548343662758204398, + 2118963546856545068961709089296976921067035227488975882615462246481055679215, + ], + [ + 2253872596319969096156004495313034590996995209785432485705134570745135149681, + 1625090409149943603241183848936692198923183279116014478406452426158572703264, + 179139838844452470348634657368199622305888473747024389514258107503778442495, + ], + [ + 1567067018147735642071130442904093290030432522257811793540290101391210410341, + 2737301854006865242314806979738760349397411136469975337509958305470398783585, + 3002738216460904473515791428798860225499078134627026021350799206894618186256, + ], + [ + 374029488099466837453096950537275565120689146401077127482884887409712315162, + 973403256517481077805460710540468856199855789930951602150773500862180885363, + 2691967457038172130555117632010860984519926022632800605713473799739632878867, + ], + [ + 3515906794910381201365530594248181418811879320679684239326734893975752012109, + 148057579455448384062325089530558091463206199724854022070244924642222283388, + 1541588700238272710315890873051237741033408846596322948443180470429851502842, + ], + [ + 147013865879011936545137344076637170977925826031496203944786839068852795297, + 2630278389304735265620281704608245039972003761509102213752997636382302839857, + 1359048670759642844930007747955701205155822111403150159614453244477853867621, + ], + [ + 2438984569205812336319229336885480537793786558293523767186829418969842616677, + 2137792255841525507649318539501906353254503076308308692873313199435029594138, + 2262318076430740712267739371170174514379142884859595360065535117601097652755, + ], + [ + 2792703718581084537295613508201818489836796608902614779596544185252826291584, + 2294173715793292812015960640392421991604150133581218254866878921346561546149, + 2770011224727997178743274791849308200493823127651418989170761007078565678171, + ], +] diff --git a/test/stark/poseidon/poseidon4.txt b/test/stark/poseidon/poseidon4.txt new file mode 100644 index 0000000..990460c --- /dev/null +++ b/test/stark/poseidon/poseidon4.txt @@ -0,0 +1,559 @@ +Rate = 3 +Capacity = 1 +FullRounds = 8 +PartialRounds = 84 +MDS = [[2, 1, 1, 1], [1, 1, 1, 1], [1, 1, 0, 1], [1, 1, 1, -1]] +RoundKeys = [ + [ + 2950795762459345168613727575620414179244544320470208355568817838579231751791, + 1587446564224215276866294500450702039420286416111469274423465069420553242820, + 1645965921169490687904413452218868659025437693527479459426157555728339600137, + 2782373324549879794752287702905278018819686065818504085638398966973694145741, + ], + [ + 3409172630025222641379726933524480516420204828329395644967085131392375707302, + 2379053116496905638239090788901387719228422033660130943198035907032739387135, + 2570819397480941104144008784293466051718826502582588529995520356691856497111, + 3546220846133880637977653625763703334841539452343273304410918449202580719746, + ], + [ + 2720682389492889709700489490056111332164748138023159726590726667539759963454, + 1899653471897224903834726250400246354200311275092866725547887381599836519005, + 2369443697923857319844855392163763375394720104106200469525915896159690979559, + 2354174693689535854311272135513626412848402744119855553970180659094265527996, + ], + [ + 2404084503073127963385083467393598147276436640877011103379112521338973185443, + 950320777137731763811524327595514151340412860090489448295239456547370725376, + 2121140748740143694053732746913428481442990369183417228688865837805149503386, + 2372065044800422557577242066480215868569521938346032514014152523102053709709, + ], + [ + 2618497439310693947058545060953893433487994458443568169824149550389484489896, + 3518297267402065742048564133910509847197496119850246255805075095266319996916, + 340529752683340505065238931581518232901634742162506851191464448040657139775, + 1954876811294863748406056845662382214841467408616109501720437541211031966538, + ], + [ + 813813157354633930267029888722341725864333883175521358739311868164460385261, + 71901595776070443337150458310956362034911936706490730914901986556638720031, + 2789761472166115462625363403490399263810962093264318361008954888847594113421, + 2628791615374802560074754031104384456692791616314774034906110098358135152410, + ], + [ + 3617032588734559635167557152518265808024917503198278888820567553943986939719, + 2624012360209966117322788103333497793082705816015202046036057821340914061980, + 149101987103211771991327927827692640556911620408176100290586418839323044234, + 1039927963829140138166373450440320262590862908847727961488297105916489431045, + ], + [ + 2213946951050724449162431068646025833746639391992751674082854766704900195669, + 2792724903541814965769131737117981991997031078369482697195201969174353468597, + 3212031629728871219804596347439383805499808476303618848198208101593976279441, + 3343514080098703935339621028041191631325798327656683100151836206557453199613, + ], + [ + 614054702436541219556958850933730254992710988573177298270089989048553060199, + 148148081026449726283933484730968827750202042869875329032965774667206931170, + 1158283532103191908366672518396366136968613180867652172211392033571980848414, + 1032400527342371389481069504520755916075559110755235773196747439146396688513, + ], + [ + 806900704622005851310078578853499250941978435851598088619290797134710613736, + 462498083559902778091095573017508352472262817904991134671058825705968404510, + 1003580119810278869589347418043095667699674425582646347949349245557449452503, + 619074932220101074089137133998298830285661916867732916607601635248249357793, + ], + [ + 2635090520059500019661864086615522409798872905401305311748231832709078452746, + 978252636251682252755279071140187792306115352460774007308726210405257135181, + 1766912167973123409669091967764158892111310474906691336473559256218048677083, + 1663265127259512472182980890707014969235283233442916350121860684522654120381, + ], + [ + 3532407621206959585000336211742670185380751515636605428496206887841428074250, + 2507023127157093845256722098502856938353143387711652912931112668310034975446, + 3321152907858462102434883844787153373036767230808678981306827073335525034593, + 3039253036806065280643845548147711477270022154459620569428286684179698125661, + ], + [ + 103480338868480851881924519768416587261556021758163719199282794248762465380, + 2394049781357087698434751577708655768465803975478348134669006211289636928495, + 2660531560345476340796109810821127229446538730404600368347902087220064379579, + 3603166934034556203649050570865466556260359798872408576857928196141785055563, + ], + [ + 1553799760191949768532188139643704561532896296986025007089826672890485412324, + 2744284717053657689091306578463476341218866418732695211367062598446038965164, + 320745764922149897598257794663594419839885234101078803811049904310835548856, + 979382242100682161589753881721708883681034024104145498709287731138044566302, + ], + [ + 1860426855810549882740147175136418997351054138609396651615467358416651354991, + 336173081054369235994909356892506146234495707857220254489443629387613956145, + 1632470326779699229772327605759783482411227247311431865655466227711078175883, + 921958250077481394074960433988881176409497663777043304881055317463712938502, + ], + [ + 3034358982193370602048539901033542101022185309652879937418114324899281842797, + 25626282149517463867572353922222474817434101087272320606729439087234878607, + 3002662261401575565838149305485737102400501329139562227180277188790091853682, + 2939684373453383817196521641512509179310654199629514917426341354023324109367, + ], + [ + 1076484609897998179434851570277297233169621096172424141759873688902355505136, + 2575095284833160494841112025725243274091830284746697961080467506739203605049, + 3565075264617591783581665711620369529657840830498005563542124551465195621851, + 2197016502533303822395077038351174326125210255869204501838837289716363437993, + ], + [ + 331415322883530754594261416546036195982886300052707474899691116664327869405, + 1935011233711290003793244296594669823169522055520303479680359990463281661839, + 3495901467168087413996941216661589517270845976538454329511167073314577412322, + 954195417117133246453562983448451025087661597543338750600301835944144520375, + ], + [ + 1271840477709992894995746871435810599280944810893784031132923384456797925777, + 2565310762274337662754531859505158700827688964841878141121196528015826671847, + 3365022288251637014588279139038152521653896670895105540140002607272936852513, + 1660592021628965529963974299647026602622092163312666588591285654477111176051, + ], + [ + 970104372286014048279296575474974982288801187216974504035759997141059513421, + 2617024574317953753849168721871770134225690844968986289121504184985993971227, + 999899815343607746071464113462778273556695659506865124478430189024755832262, + 2228536129413411161615629030408828764980855956560026807518714080003644769896, + ], + [ + 2701953891198001564547196795777701119629537795442025393867364730330476403227, + 837078355588159388741598313782044128527494922918203556465116291436461597853, + 2121749601840466143704862369657561429793951309962582099604848281796392359214, + 771812260179247428733132708063116523892339056677915387749121983038690154755, + ], + [ + 3317336423132806446086732225036532603224267214833263122557471741829060578219, + 481570067997721834712647566896657604857788523050900222145547508314620762046, + 242195042559343964206291740270858862066153636168162642380846129622127460192, + 2855462178889999218204481481614105202770810647859867354506557827319138379686, + ], + [ + 3525521107148375040131784770413887305850308357895464453970651672160034885202, + 1320839531502392535964065058804908871811967681250362364246430459003920305799, + 2514191518588387125173345107242226637171897291221681115249521904869763202419, + 2798335750958827619666318316247381695117827718387653874070218127140615157902, + ], + [ + 2808467767967035643407948058486565877867906577474361783201337540214875566395, + 3551834385992706206273955480294669176699286104229279436819137165202231595747, + 1219439673853113792340300173186247996249367102884530407862469123523013083971, + 761519904537984520554247997444508040636526566551719396202550009393012691157, + ], + [ + 3355402549169351700500518865338783382387571349497391475317206324155237401353, + 199541098009731541347317515995192175813554789571447733944970283654592727138, + 192100490643078165121235261796864975568292640203635147901612231594408079071, + 1187019357602953326192019968809486933768550466167033084944727938441427050581, + ], + [ + 189525349641911362389041124808934468936759383310282010671081989585219065700, + 2831653363992091308880573627558515686245403755586311978724025292003353336665, + 2052859812632218952608271535089179639890275494426396974475479657192657094698, + 1670756178709659908159049531058853320846231785448204274277900022176591811072, + ], + [ + 3538757242013734574731807289786598937548399719866320954894004830207085723125, + 710549042741321081781917034337800036872214466705318638023070812391485261299, + 2345013122330545298606028187653996682275206910242635100920038943391319595180, + 3528369671971445493932880023233332035122954362711876290904323783426765912206, + ], + [ + 1167120829038120978297497195837406760848728897181138760506162680655977700764, + 3073243357129146594530765548901087443775563058893907738967898816092270628884, + 378514724418106317738164464176041649567501099164061863402473942795977719726, + 333391138410406330127594722511180398159664250722328578952158227406762627796, + ], + [ + 1727570175639917398410201375510924114487348765559913502662122372848626931905, + 968312190621809249603425066974405725769739606059422769908547372904403793174, + 360659316299446405855194688051178331671817370423873014757323462844775818348, + 1386580151907705298970465943238806620109618995410132218037375811184684929291, + ], + [ + 3604888328937389309031638299660239238400230206645344173700074923133890528967, + 2496185632263372962152518155651824899299616724241852816983268163379540137546, + 486538168871046887467737983064272608432052269868418721234810979756540672990, + 1558415498960552213241704009433360128041672577274390114589014204605400783336, + ], + [ + 3512058327686147326577190314835092911156317204978509183234511559551181053926, + 2235429387083113882635494090887463486491842634403047716936833563914243946191, + 1290896777143878193192832813769470418518651727840187056683408155503813799882, + 1143310336918357319571079551779316654556781203013096026972411429993634080835, + ], + [ + 3235435208525081966062419599803346573407862428113723170955762956243193422118, + 1293239921425673430660897025143433077974838969258268884994339615096356996604, + 236252269127612784685426260840574970698541177557674806964960352572864382971, + 1733907592497266237374827232200506798207318263912423249709509725341212026275, + ], + [ + 302004309771755665128395814807589350526779835595021835389022325987048089868, + 3018926838139221755384801385583867283206879023218491758435446265703006270945, + 39701437664873825906031098349904330565195980985885489447836580931425171297, + 908381723021746969965674308809436059628307487140174335882627549095646509778, + ], + [ + 219062858908229855064136253265968615354041842047384625689776811853821594358, + 1283129863776453589317845316917890202859466483456216900835390291449830275503, + 418512623547417594896140369190919231877873410935689672661226540908900544012, + 1792181590047131972851015200157890246436013346535432437041535789841136268632, + ], + [ + 370546432987510607338044736824316856592558876687225326692366316978098770516, + 3323437805230586112013581113386626899534419826098235300155664022709435756946, + 910076621742039763058481476739499965761942516177975130656340375573185415877, + 1762188042455633427137702520675816545396284185254002959309669405982213803405, + ], + [ + 2186362253913140345102191078329764107619534641234549431429008219905315900520, + 2230647725927681765419218738218528849146504088716182944327179019215826045083, + 1069243907556644434301190076451112491469636357133398376850435321160857761825, + 2695241469149243992683268025359863087303400907336026926662328156934068747593, + ], + [ + 1361519681544413849831669554199151294308350560528931040264950307931824877035, + 1339116632207878730171031743761550901312154740800549632983325427035029084904, + 790593524918851401449292693473498591068920069246127392274811084156907468875, + 2723400368331924254840192318398326090089058735091724263333980290765736363637, + ], + [ + 3457180265095920471443772463283225391927927225993685928066766687141729456030, + 1483675376954327086153452545475557749815683871577400883707749788555424847954, + 2926303836265506736227240325795090239680154099205721426928300056982414025239, + 543969119775473768170832347411484329362572550684421616624136244239799475526, + ], + [ + 237401230683847084256617415614300816373730178313253487575312839074042461932, + 844568412840391587862072008674263874021460074878949862892685736454654414423, + 151922054871708336050647150237534498235916969120198637893731715254687336644, + 1299332034710622815055321547569101119597030148120309411086203580212105652312, + ], + [ + 487046922649899823989594814663418784068895385009696501386459462815688122993, + 1104883249092599185744249485896585912845784382683240114120846423960548576851, + 1458388705536282069567179348797334876446380557083422364875248475157495514484, + 850248109622750774031817200193861444623975329881731864752464222442574976566, + ], + [ + 2885843173858536690032695698009109793537724845140477446409245651176355435722, + 3027068551635372249579348422266406787688980506275086097330568993357835463816, + 3231892723647447539926175383213338123506134054432701323145045438168976970994, + 1719080830641935421242626784132692936776388194122314954558418655725251172826, + ], + [ + 1172253756541066126131022537343350498482225068791630219494878195815226839450, + 1619232269633026603732619978083169293258272967781186544174521481891163985093, + 3495680684841853175973173610562400042003100419811771341346135531754869014567, + 1576161515913099892951745452471618612307857113799539794680346855318958552758, + ], + [ + 2618326122974253423403350731396350223238201817594761152626832144510903048529, + 2696245132758436974032479782852265185094623165224532063951287925001108567649, + 930116505665110070247395429730201844026054810856263733273443066419816003444, + 2786389174502246248523918824488629229455088716707062764363111940462137404076, + ], + [ + 1555260846425735320214671887347115247546042526197895180675436886484523605116, + 2306241912153325247392671742757902161446877415586158295423293240351799505917, + 411529621724849932999694270803131456243889635467661223241617477462914950626, + 1542495485262286701469125140275904136434075186064076910329015697714211835205, + ], + [ + 1853045663799041100600825096887578544265580718909350942241802897995488264551, + 2963055259497271220202739837493041799968576111953080503132045092194513937286, + 2303806870349915764285872605046527036748108533406243381676768310692344456050, + 2622104986201990620910286730213140904984256464479840856728424375142929278875, + ], + [ + 2369987021925266811581727383184031736927816625797282287927222602539037105864, + 285070227712021899602056480426671736057274017903028992288878116056674401781, + 3034087076179360957800568733595959058628497428787907887933697691951454610691, + 469095854351700119980323115747590868855368701825706298740201488006320881056, + ], + [ + 360001976264385426746283365024817520563236378289230404095383746911725100012, + 3438709327109021347267562000879503009590697221730578667498351600602230296178, + 63573904800572228121671659287593650438456772568903228287754075619928214969, + 3470881855042989871434874691030920672110111605547839662680968354703074556970, + ], + [ + 724559311507950497340993415408274803001166693839947519425501269424891465492, + 880409284677518997550768549487344416321062350742831373397603704465823658986, + 6876255662475867703077362872097208259197756317287339941435193538565586230, + 2701916445133770775447884812906226786217969545216086200932273680400909154638, + ], + [ + 425152119158711585559310064242720816611629181537672850898056934507216982586, + 1475552998258917706756737045704649573088377604240716286977690565239187213744, + 2413772448122400684309006716414417978370152271397082147158000439863002593561, + 392160855822256520519339260245328807036619920858503984710539815951012864164, + ], + [ + 1075036996503791536261050742318169965707018400307026402939804424927087093987, + 2176439430328703902070742432016450246365760303014562857296722712989275658921, + 1413865976587623331051814207977382826721471106513581745229680113383908569693, + 4879283427490523253696177116563427032332223531862961281430108575019551814, + ], + [ + 3392583297537374046875199552977614390492290683707960975137418536812266544902, + 3600854486849487646325182927019642276644093512133907046667282144129939150983, + 2779924664161372134024229593301361846129279572186444474616319283535189797834, + 2722699960903170449291146429799738181514821447014433304730310678334403972040, + ], + [ + 819109815049226540285781191874507704729062681836086010078910930707209464699, + 3046121243742768013822760785918001632929744274211027071381357122228091333823, + 1339019590803056172509793134119156250729668216522001157582155155947567682278, + 1933279639657506214789316403763326578443023901555983256955812717638093967201, + ], + [ + 2138221547112520744699126051903811860205771600821672121643894708182292213541, + 2694713515543641924097704224170357995809887124438248292930846280951601597065, + 2471734202930133750093618989223585244499567111661178960753938272334153710615, + 504903761112092757611047718215309856203214372330635774577409639907729993533, + ], + [ + 1943979703748281357156510253941035712048221353507135074336243405478613241290, + 684525210957572142559049112233609445802004614280157992196913315652663518936, + 1705585400798782397786453706717059483604368413512485532079242223503960814508, + 192429517716023021556170942988476050278432319516032402725586427701913624665, + ], + [ + 1586493702243128040549584165333371192888583026298039652930372758731750166765, + 686072673323546915014972146032384917012218151266600268450347114036285993377, + 3464340397998075738891129996710075228740496767934137465519455338004332839215, + 2805249176617071054530589390406083958753103601524808155663551392362371834663, + ], + [ + 667746464250968521164727418691487653339733392025160477655836902744186489526, + 1131527712905109997177270289411406385352032457456054589588342450404257139778, + 1908969485750011212309284349900149072003218505891252313183123635318886241171, + 1025257076985551890132050019084873267454083056307650830147063480409707787695, + ], + [ + 2153175291918371429502545470578981828372846236838301412119329786849737957977, + 3410257749736714576487217882785226905621212230027780855361670645857085424384, + 3442969106887588154491488961893254739289120695377621434680934888062399029952, + 3029953900235731770255937704976720759948880815387104275525268727341390470237, + ], + [ + 85453456084781138713939104192561924536933417707871501802199311333127894466, + 2730629666577257820220329078741301754580009106438115341296453318350676425129, + 178242450661072967256438102630920745430303027840919213764087927763335940415, + 2844589222514708695700541363167856718216388819406388706818431442998498677557, + ], + [ + 3547876269219141094308889387292091231377253967587961309624916269569559952944, + 2525005406762984211707203144785482908331876505006839217175334833739957826850, + 3096397013555211396701910432830904669391580557191845136003938801598654871345, + 574424067119200181933992948252007230348512600107123873197603373898923821490, + ], + [ + 1714030696055067278349157346067719307863507310709155690164546226450579547098, + 2339895272202694698739231405357972261413383527237194045718815176814132612501, + 3562501318971895161271663840954705079797767042115717360959659475564651685069, + 69069358687197963617161747606993436483967992689488259107924379545671193749, + ], + [ + 2614502738369008850475068874731531583863538486212691941619835266611116051561, + 655247349763023251625727726218660142895322325659927266813592114640858573566, + 2305235672527595714255517865498269719545193172975330668070873705108690670678, + 926416070297755413261159098243058134401665060349723804040714357642180531931, + ], + [ + 866523735635840246543516964237513287099659681479228450791071595433217821460, + 2284334068466681424919271582037156124891004191915573957556691163266198707693, + 1812588309302477291425732810913354633465435706480768615104211305579383928792, + 2836899808619013605432050476764608707770404125005720004551836441247917488507, + ], + [ + 2989087789022865112405242078196235025698647423649950459911546051695688370523, + 68056284404189102136488263779598243992465747932368669388126367131855404486, + 505425339250887519581119854377342241317528319745596963584548343662758204398, + 2118963546856545068961709089296976921067035227488975882615462246481055679215, + ], + [ + 2253872596319969096156004495313034590996995209785432485705134570745135149681, + 1625090409149943603241183848936692198923183279116014478406452426158572703264, + 179139838844452470348634657368199622305888473747024389514258107503778442495, + 1567067018147735642071130442904093290030432522257811793540290101391210410341, + ], + [ + 2737301854006865242314806979738760349397411136469975337509958305470398783585, + 3002738216460904473515791428798860225499078134627026021350799206894618186256, + 374029488099466837453096950537275565120689146401077127482884887409712315162, + 973403256517481077805460710540468856199855789930951602150773500862180885363, + ], + [ + 2691967457038172130555117632010860984519926022632800605713473799739632878867, + 3515906794910381201365530594248181418811879320679684239326734893975752012109, + 148057579455448384062325089530558091463206199724854022070244924642222283388, + 1541588700238272710315890873051237741033408846596322948443180470429851502842, + ], + [ + 147013865879011936545137344076637170977925826031496203944786839068852795297, + 2630278389304735265620281704608245039972003761509102213752997636382302839857, + 1359048670759642844930007747955701205155822111403150159614453244477853867621, + 2438984569205812336319229336885480537793786558293523767186829418969842616677, + ], + [ + 2137792255841525507649318539501906353254503076308308692873313199435029594138, + 2262318076430740712267739371170174514379142884859595360065535117601097652755, + 2792703718581084537295613508201818489836796608902614779596544185252826291584, + 2294173715793292812015960640392421991604150133581218254866878921346561546149, + ], + [ + 2770011224727997178743274791849308200493823127651418989170761007078565678171, + 3321642244537785916275181932172303118112488081726311374164578600576901819844, + 3522708517589950573320671158134804505970724681591943826922697952040487655044, + 3417974441436557992524691506735790206623600049454586729879955931972546347402, + ], + [ + 175039333145381316571259690443853067809784261609912638686739799135919647022, + 1930713062131033273316869231148248962041053029742760224583505092759642967464, + 2971452932574554603554350185069538580257636405419430340233233400633251319042, + 2774781903758215341037075610938953949868289195845367046186588750871862784919, + ], + [ + 666516874137869653699423537799457099346460194092311952417454613224504932738, + 1900462225013533249140457703727169176351786259991305560412832202759625668041, + 2665631186082687279121709429531834469477679375137509769347092380798929714377, + 837840745988147279235494664091280091563355097569199320366973125128366540061, + ], + [ + 3391544118305848781823721719916289805455110924839794510205940718821197620955, + 2888553035909938253628892138500390690221493345071933642853222968481016605919, + 3386241569867597612447901482685846444743718781330869478721963580925825915450, + 1205126220630896984850042596877918177217334376800874965105642874206963597698, + ], + [ + 3590072615491710252422997155203204584659171612188004116415640739580250394190, + 692469013329617220154003334549812915100479873898898958632988703738125356983, + 1623178235190707102808841905143937367808788834203621005714003335195182126335, + 1972826180775011489122426045504602288576507493792470102803637471568052321297, + ], + [ + 3415141329098504418158191749675997877417539760075593313736376750580696083073, + 587811537889727046473915684463981273175495137461951211739526104349163747811, + 2523982964351069134084525951849317400231659428055762640605248929856135518199, + 2686176526711834950207666047281383173339057216783586039351834948812568447629, + ], + [ + 983144446441739425577690449774542566745526459152966545642451764143532586964, + 171558252019175695567663688494555626159399786667979998273792882504784080805, + 332337623010057542760158225837623039780806442976079546879646069338600179518, + 1264669683963885571544813806669118319675288608634733888843804451222546848295, + ], + [ + 2426165115815723668018318268486497504249785449504758403912155206515511627681, + 11387399609384288947733630450855186629703576293221897150193655994854764608, + 2541728569046079092074077754414781968906176513081761690404588216304985421091, + 47685947554980329431290582269851186106577733250761848107645535357326439312, + ], + [ + 472176388418187405374813530639596064799362505024895746833751173199773896628, + 2764298116617383397920343358525617195195060562266243809245480210157942112738, + 486863835068754002670800862273365477867695879270721744227071001883208334054, + 2973492686137102577527656941792991264994301121122130295965761350095846874635, + ], + [ + 178385615141132702906181473263873416748818415607305319148067639744074654009, + 533624640096756667052211553746016402543259206286603356120804827761339634127, + 819406716720171922688026098737835227857400444543748198788964759773510472096, + 531851793767260921861217458033110066464894334064526987603936107947006031387, + ], + [ + 3269709072483585277009748181134917746036523619604017812342933951952104134829, + 838191718603413598040249006803464503100808192944407407147899973659013630611, + 1574561296941310904780257598780779812250055948216417844567262310524022037406, + 551394354289003977607664358739006072556227894953233419144430578080352094737, + ], + [ + 445076790942318675726839050057337819004979443030540904213920669247413907302, + 1963946696292687224902912968478695543164747600779913024040878700455222386521, + 484284614181963381509745298932402076252103342403432879800905151752488144767, + 2240507606126946994415203252302826782042951346966859379502140796364876543253, + ], + [ + 3237135638753992982179886898758938279897590886053928839613434762582576319619, + 2334333034701915027889533058426879447140084891006486138782876488162658230991, + 14411091399844539897439754491034751977136685514851444574462584316609631592, + 1264480371592407258420308876448697804787923638319277097663041109464608464284, + ], + [ + 671929312763821646360589403212798993954209530574443543917757335777610372144, + 2513909805455654095962542944994577107405216428214873444765576238504714067396, + 870121102846043786263357605823753628974859886859187558617096145653709171231, + 399132620893316356411986266679786708905730068946836982293484206366500277754, + ], + [ + 2855046250836680633532995284655778407402587437073106249445470889390454667586, + 2063679741125384345396981490971605710211281905716315529671473143278849561151, + 1433753212258929925682201698758056443128516570551146995210728194816988328337, + 3334984763425011856632257855270507440816274246647423607159847074739331865077, + ], + [ + 337911293622078184850923533628334646725451591671907148383867096651211846605, + 559587005295238702015018022040357402231957131094636365177008701077975941644, + 885963059604819264377490633589388189646118257469490919900554134369512794660, + 1957748763518471091057032383332840331641373304981058387824598000170709016333, + ], + [ + 3175295982155056798972302481564899381103533409383494814704562889625572018450, + 498987160612401618114584726510347771865331516606886613019084323862447372555, + 947374835104260364630171441676101001841507588423166778786886198914150312958, + 906933977754491302438795274167251538820934378773708095543613756654712689280, + ], + [ + 2170116291766863179909957030577284618726490893598499117272497866180009722894, + 1801335399574515889082584621772588704763181408217893911806726119813067220453, + 1942500232535842474530840356353427989892065499159260166135596750084681859966, + 62936080219825306823124060587235998278756755377419521154040408253893795176, + ], + [ + 3091993939935137795359769774909373279950941171574748645375255810204590357753, + 1283528386884634267663661033944552098742115012555712906773586466375284501324, + 1581820717639229420476069802992937438655873471854930764425841549067913106065, + 2301986095388751633126546121528329200085681648876910655269533407603441046514, + ], + [ + 2850003828037698751961753862613545302539465803982364898225617297398939302949, + 48024691078494936445046366770271288984930221238071705874025261821606393528, + 1482336297033144958942154923925185950152551534403871620222916667536030875354, + 3081177564717719643771186007689458633949181485535169123213511264603782950049, + ], + [ + 3315701127039521853279746297714590495201061397709680410650043502532250578075, + 3514407611000441301995070394422463400067690470546731164089622325748803106020, + 368970178199930154322724953487299516224498421233447528815195701420122548537, + 584353160413525267849669053228533951552602295860601556035386665117717227391, + ], + [ + 752038702160385294706011538400822066722189014251268673051846350397729870418, + 3594041683498798688197194521326299097635429790757880308152971477196489335154, + 1367902435756906062215608264424138718742854099315395230911274560900857414183, + 1828549068951502746189364466794037234789986878381694857475972053743463890779, + ], + [ + 488172495141237210878388657234137733008417573114482400652274985829148564248, + 962906242461930394022372340919543491337923491322497419797555620396501785566, + 2275418085010046236619290386129138234541669589549771944697082317642065048898, + 1966395064658902622886154686288219600816893261614483533899715888994623208964, + ], + [ + 3496095878293416917311185659829821476802828534554531050412634978086916288609, + 3368478822390537245916137403277928093536087427951052230723275731232142463388, + 3397410259276620127103231993277518800970669191016277541098821699302368873803, + 2662600899665871010006649609856695263727220473364611552472965243032255906029, + ], +] diff --git a/test/stark/poseidon/poseidon5.txt b/test/stark/poseidon/poseidon5.txt new file mode 100644 index 0000000..062b3dd --- /dev/null +++ b/test/stark/poseidon/poseidon5.txt @@ -0,0 +1,651 @@ +Rate = 4 +Capacity = 1 +FullRounds = 8 +PartialRounds = 84 +MDS = [[3, 1, 1, 1, 1], [1, 2, 1, 1, 1], [1, 1, 1, 1, 1], [1, 1, 1, -1, 1], [1, 1, 1, 1, -2]] +RoundKeys = [ + [ + 2950795762459345168613727575620414179244544320470208355568817838579231751791, + 1587446564224215276866294500450702039420286416111469274423465069420553242820, + 1645965921169490687904413452218868659025437693527479459426157555728339600137, + 2782373324549879794752287702905278018819686065818504085638398966973694145741, + 3409172630025222641379726933524480516420204828329395644967085131392375707302, + ], + [ + 2379053116496905638239090788901387719228422033660130943198035907032739387135, + 2570819397480941104144008784293466051718826502582588529995520356691856497111, + 3546220846133880637977653625763703334841539452343273304410918449202580719746, + 2720682389492889709700489490056111332164748138023159726590726667539759963454, + 1899653471897224903834726250400246354200311275092866725547887381599836519005, + ], + [ + 2369443697923857319844855392163763375394720104106200469525915896159690979559, + 2354174693689535854311272135513626412848402744119855553970180659094265527996, + 2404084503073127963385083467393598147276436640877011103379112521338973185443, + 950320777137731763811524327595514151340412860090489448295239456547370725376, + 2121140748740143694053732746913428481442990369183417228688865837805149503386, + ], + [ + 2372065044800422557577242066480215868569521938346032514014152523102053709709, + 2618497439310693947058545060953893433487994458443568169824149550389484489896, + 3518297267402065742048564133910509847197496119850246255805075095266319996916, + 340529752683340505065238931581518232901634742162506851191464448040657139775, + 1954876811294863748406056845662382214841467408616109501720437541211031966538, + ], + [ + 813813157354633930267029888722341725864333883175521358739311868164460385261, + 71901595776070443337150458310956362034911936706490730914901986556638720031, + 2789761472166115462625363403490399263810962093264318361008954888847594113421, + 2628791615374802560074754031104384456692791616314774034906110098358135152410, + 3617032588734559635167557152518265808024917503198278888820567553943986939719, + ], + [ + 2624012360209966117322788103333497793082705816015202046036057821340914061980, + 149101987103211771991327927827692640556911620408176100290586418839323044234, + 1039927963829140138166373450440320262590862908847727961488297105916489431045, + 2213946951050724449162431068646025833746639391992751674082854766704900195669, + 2792724903541814965769131737117981991997031078369482697195201969174353468597, + ], + [ + 3212031629728871219804596347439383805499808476303618848198208101593976279441, + 3343514080098703935339621028041191631325798327656683100151836206557453199613, + 614054702436541219556958850933730254992710988573177298270089989048553060199, + 148148081026449726283933484730968827750202042869875329032965774667206931170, + 1158283532103191908366672518396366136968613180867652172211392033571980848414, + ], + [ + 1032400527342371389481069504520755916075559110755235773196747439146396688513, + 806900704622005851310078578853499250941978435851598088619290797134710613736, + 462498083559902778091095573017508352472262817904991134671058825705968404510, + 1003580119810278869589347418043095667699674425582646347949349245557449452503, + 619074932220101074089137133998298830285661916867732916607601635248249357793, + ], + [ + 2635090520059500019661864086615522409798872905401305311748231832709078452746, + 978252636251682252755279071140187792306115352460774007308726210405257135181, + 1766912167973123409669091967764158892111310474906691336473559256218048677083, + 1663265127259512472182980890707014969235283233442916350121860684522654120381, + 3532407621206959585000336211742670185380751515636605428496206887841428074250, + ], + [ + 2507023127157093845256722098502856938353143387711652912931112668310034975446, + 3321152907858462102434883844787153373036767230808678981306827073335525034593, + 3039253036806065280643845548147711477270022154459620569428286684179698125661, + 103480338868480851881924519768416587261556021758163719199282794248762465380, + 2394049781357087698434751577708655768465803975478348134669006211289636928495, + ], + [ + 2660531560345476340796109810821127229446538730404600368347902087220064379579, + 3603166934034556203649050570865466556260359798872408576857928196141785055563, + 1553799760191949768532188139643704561532896296986025007089826672890485412324, + 2744284717053657689091306578463476341218866418732695211367062598446038965164, + 320745764922149897598257794663594419839885234101078803811049904310835548856, + ], + [ + 979382242100682161589753881721708883681034024104145498709287731138044566302, + 1860426855810549882740147175136418997351054138609396651615467358416651354991, + 336173081054369235994909356892506146234495707857220254489443629387613956145, + 1632470326779699229772327605759783482411227247311431865655466227711078175883, + 921958250077481394074960433988881176409497663777043304881055317463712938502, + ], + [ + 3034358982193370602048539901033542101022185309652879937418114324899281842797, + 25626282149517463867572353922222474817434101087272320606729439087234878607, + 3002662261401575565838149305485737102400501329139562227180277188790091853682, + 2939684373453383817196521641512509179310654199629514917426341354023324109367, + 1076484609897998179434851570277297233169621096172424141759873688902355505136, + ], + [ + 2575095284833160494841112025725243274091830284746697961080467506739203605049, + 3565075264617591783581665711620369529657840830498005563542124551465195621851, + 2197016502533303822395077038351174326125210255869204501838837289716363437993, + 331415322883530754594261416546036195982886300052707474899691116664327869405, + 1935011233711290003793244296594669823169522055520303479680359990463281661839, + ], + [ + 3495901467168087413996941216661589517270845976538454329511167073314577412322, + 954195417117133246453562983448451025087661597543338750600301835944144520375, + 1271840477709992894995746871435810599280944810893784031132923384456797925777, + 2565310762274337662754531859505158700827688964841878141121196528015826671847, + 3365022288251637014588279139038152521653896670895105540140002607272936852513, + ], + [ + 1660592021628965529963974299647026602622092163312666588591285654477111176051, + 970104372286014048279296575474974982288801187216974504035759997141059513421, + 2617024574317953753849168721871770134225690844968986289121504184985993971227, + 999899815343607746071464113462778273556695659506865124478430189024755832262, + 2228536129413411161615629030408828764980855956560026807518714080003644769896, + ], + [ + 2701953891198001564547196795777701119629537795442025393867364730330476403227, + 837078355588159388741598313782044128527494922918203556465116291436461597853, + 2121749601840466143704862369657561429793951309962582099604848281796392359214, + 771812260179247428733132708063116523892339056677915387749121983038690154755, + 3317336423132806446086732225036532603224267214833263122557471741829060578219, + ], + [ + 481570067997721834712647566896657604857788523050900222145547508314620762046, + 242195042559343964206291740270858862066153636168162642380846129622127460192, + 2855462178889999218204481481614105202770810647859867354506557827319138379686, + 3525521107148375040131784770413887305850308357895464453970651672160034885202, + 1320839531502392535964065058804908871811967681250362364246430459003920305799, + ], + [ + 2514191518588387125173345107242226637171897291221681115249521904869763202419, + 2798335750958827619666318316247381695117827718387653874070218127140615157902, + 2808467767967035643407948058486565877867906577474361783201337540214875566395, + 3551834385992706206273955480294669176699286104229279436819137165202231595747, + 1219439673853113792340300173186247996249367102884530407862469123523013083971, + ], + [ + 761519904537984520554247997444508040636526566551719396202550009393012691157, + 3355402549169351700500518865338783382387571349497391475317206324155237401353, + 199541098009731541347317515995192175813554789571447733944970283654592727138, + 192100490643078165121235261796864975568292640203635147901612231594408079071, + 1187019357602953326192019968809486933768550466167033084944727938441427050581, + ], + [ + 189525349641911362389041124808934468936759383310282010671081989585219065700, + 2831653363992091308880573627558515686245403755586311978724025292003353336665, + 2052859812632218952608271535089179639890275494426396974475479657192657094698, + 1670756178709659908159049531058853320846231785448204274277900022176591811072, + 3538757242013734574731807289786598937548399719866320954894004830207085723125, + ], + [ + 710549042741321081781917034337800036872214466705318638023070812391485261299, + 2345013122330545298606028187653996682275206910242635100920038943391319595180, + 3528369671971445493932880023233332035122954362711876290904323783426765912206, + 1167120829038120978297497195837406760848728897181138760506162680655977700764, + 3073243357129146594530765548901087443775563058893907738967898816092270628884, + ], + [ + 378514724418106317738164464176041649567501099164061863402473942795977719726, + 333391138410406330127594722511180398159664250722328578952158227406762627796, + 1727570175639917398410201375510924114487348765559913502662122372848626931905, + 968312190621809249603425066974405725769739606059422769908547372904403793174, + 360659316299446405855194688051178331671817370423873014757323462844775818348, + ], + [ + 1386580151907705298970465943238806620109618995410132218037375811184684929291, + 3604888328937389309031638299660239238400230206645344173700074923133890528967, + 2496185632263372962152518155651824899299616724241852816983268163379540137546, + 486538168871046887467737983064272608432052269868418721234810979756540672990, + 1558415498960552213241704009433360128041672577274390114589014204605400783336, + ], + [ + 3512058327686147326577190314835092911156317204978509183234511559551181053926, + 2235429387083113882635494090887463486491842634403047716936833563914243946191, + 1290896777143878193192832813769470418518651727840187056683408155503813799882, + 1143310336918357319571079551779316654556781203013096026972411429993634080835, + 3235435208525081966062419599803346573407862428113723170955762956243193422118, + ], + [ + 1293239921425673430660897025143433077974838969258268884994339615096356996604, + 236252269127612784685426260840574970698541177557674806964960352572864382971, + 1733907592497266237374827232200506798207318263912423249709509725341212026275, + 302004309771755665128395814807589350526779835595021835389022325987048089868, + 3018926838139221755384801385583867283206879023218491758435446265703006270945, + ], + [ + 39701437664873825906031098349904330565195980985885489447836580931425171297, + 908381723021746969965674308809436059628307487140174335882627549095646509778, + 219062858908229855064136253265968615354041842047384625689776811853821594358, + 1283129863776453589317845316917890202859466483456216900835390291449830275503, + 418512623547417594896140369190919231877873410935689672661226540908900544012, + ], + [ + 1792181590047131972851015200157890246436013346535432437041535789841136268632, + 370546432987510607338044736824316856592558876687225326692366316978098770516, + 3323437805230586112013581113386626899534419826098235300155664022709435756946, + 910076621742039763058481476739499965761942516177975130656340375573185415877, + 1762188042455633427137702520675816545396284185254002959309669405982213803405, + ], + [ + 2186362253913140345102191078329764107619534641234549431429008219905315900520, + 2230647725927681765419218738218528849146504088716182944327179019215826045083, + 1069243907556644434301190076451112491469636357133398376850435321160857761825, + 2695241469149243992683268025359863087303400907336026926662328156934068747593, + 1361519681544413849831669554199151294308350560528931040264950307931824877035, + ], + [ + 1339116632207878730171031743761550901312154740800549632983325427035029084904, + 790593524918851401449292693473498591068920069246127392274811084156907468875, + 2723400368331924254840192318398326090089058735091724263333980290765736363637, + 3457180265095920471443772463283225391927927225993685928066766687141729456030, + 1483675376954327086153452545475557749815683871577400883707749788555424847954, + ], + [ + 2926303836265506736227240325795090239680154099205721426928300056982414025239, + 543969119775473768170832347411484329362572550684421616624136244239799475526, + 237401230683847084256617415614300816373730178313253487575312839074042461932, + 844568412840391587862072008674263874021460074878949862892685736454654414423, + 151922054871708336050647150237534498235916969120198637893731715254687336644, + ], + [ + 1299332034710622815055321547569101119597030148120309411086203580212105652312, + 487046922649899823989594814663418784068895385009696501386459462815688122993, + 1104883249092599185744249485896585912845784382683240114120846423960548576851, + 1458388705536282069567179348797334876446380557083422364875248475157495514484, + 850248109622750774031817200193861444623975329881731864752464222442574976566, + ], + [ + 2885843173858536690032695698009109793537724845140477446409245651176355435722, + 3027068551635372249579348422266406787688980506275086097330568993357835463816, + 3231892723647447539926175383213338123506134054432701323145045438168976970994, + 1719080830641935421242626784132692936776388194122314954558418655725251172826, + 1172253756541066126131022537343350498482225068791630219494878195815226839450, + ], + [ + 1619232269633026603732619978083169293258272967781186544174521481891163985093, + 3495680684841853175973173610562400042003100419811771341346135531754869014567, + 1576161515913099892951745452471618612307857113799539794680346855318958552758, + 2618326122974253423403350731396350223238201817594761152626832144510903048529, + 2696245132758436974032479782852265185094623165224532063951287925001108567649, + ], + [ + 930116505665110070247395429730201844026054810856263733273443066419816003444, + 2786389174502246248523918824488629229455088716707062764363111940462137404076, + 1555260846425735320214671887347115247546042526197895180675436886484523605116, + 2306241912153325247392671742757902161446877415586158295423293240351799505917, + 411529621724849932999694270803131456243889635467661223241617477462914950626, + ], + [ + 1542495485262286701469125140275904136434075186064076910329015697714211835205, + 1853045663799041100600825096887578544265580718909350942241802897995488264551, + 2963055259497271220202739837493041799968576111953080503132045092194513937286, + 2303806870349915764285872605046527036748108533406243381676768310692344456050, + 2622104986201990620910286730213140904984256464479840856728424375142929278875, + ], + [ + 2369987021925266811581727383184031736927816625797282287927222602539037105864, + 285070227712021899602056480426671736057274017903028992288878116056674401781, + 3034087076179360957800568733595959058628497428787907887933697691951454610691, + 469095854351700119980323115747590868855368701825706298740201488006320881056, + 360001976264385426746283365024817520563236378289230404095383746911725100012, + ], + [ + 3438709327109021347267562000879503009590697221730578667498351600602230296178, + 63573904800572228121671659287593650438456772568903228287754075619928214969, + 3470881855042989871434874691030920672110111605547839662680968354703074556970, + 724559311507950497340993415408274803001166693839947519425501269424891465492, + 880409284677518997550768549487344416321062350742831373397603704465823658986, + ], + [ + 6876255662475867703077362872097208259197756317287339941435193538565586230, + 2701916445133770775447884812906226786217969545216086200932273680400909154638, + 425152119158711585559310064242720816611629181537672850898056934507216982586, + 1475552998258917706756737045704649573088377604240716286977690565239187213744, + 2413772448122400684309006716414417978370152271397082147158000439863002593561, + ], + [ + 392160855822256520519339260245328807036619920858503984710539815951012864164, + 1075036996503791536261050742318169965707018400307026402939804424927087093987, + 2176439430328703902070742432016450246365760303014562857296722712989275658921, + 1413865976587623331051814207977382826721471106513581745229680113383908569693, + 4879283427490523253696177116563427032332223531862961281430108575019551814, + ], + [ + 3392583297537374046875199552977614390492290683707960975137418536812266544902, + 3600854486849487646325182927019642276644093512133907046667282144129939150983, + 2779924664161372134024229593301361846129279572186444474616319283535189797834, + 2722699960903170449291146429799738181514821447014433304730310678334403972040, + 819109815049226540285781191874507704729062681836086010078910930707209464699, + ], + [ + 3046121243742768013822760785918001632929744274211027071381357122228091333823, + 1339019590803056172509793134119156250729668216522001157582155155947567682278, + 1933279639657506214789316403763326578443023901555983256955812717638093967201, + 2138221547112520744699126051903811860205771600821672121643894708182292213541, + 2694713515543641924097704224170357995809887124438248292930846280951601597065, + ], + [ + 2471734202930133750093618989223585244499567111661178960753938272334153710615, + 504903761112092757611047718215309856203214372330635774577409639907729993533, + 1943979703748281357156510253941035712048221353507135074336243405478613241290, + 684525210957572142559049112233609445802004614280157992196913315652663518936, + 1705585400798782397786453706717059483604368413512485532079242223503960814508, + ], + [ + 192429517716023021556170942988476050278432319516032402725586427701913624665, + 1586493702243128040549584165333371192888583026298039652930372758731750166765, + 686072673323546915014972146032384917012218151266600268450347114036285993377, + 3464340397998075738891129996710075228740496767934137465519455338004332839215, + 2805249176617071054530589390406083958753103601524808155663551392362371834663, + ], + [ + 667746464250968521164727418691487653339733392025160477655836902744186489526, + 1131527712905109997177270289411406385352032457456054589588342450404257139778, + 1908969485750011212309284349900149072003218505891252313183123635318886241171, + 1025257076985551890132050019084873267454083056307650830147063480409707787695, + 2153175291918371429502545470578981828372846236838301412119329786849737957977, + ], + [ + 3410257749736714576487217882785226905621212230027780855361670645857085424384, + 3442969106887588154491488961893254739289120695377621434680934888062399029952, + 3029953900235731770255937704976720759948880815387104275525268727341390470237, + 85453456084781138713939104192561924536933417707871501802199311333127894466, + 2730629666577257820220329078741301754580009106438115341296453318350676425129, + ], + [ + 178242450661072967256438102630920745430303027840919213764087927763335940415, + 2844589222514708695700541363167856718216388819406388706818431442998498677557, + 3547876269219141094308889387292091231377253967587961309624916269569559952944, + 2525005406762984211707203144785482908331876505006839217175334833739957826850, + 3096397013555211396701910432830904669391580557191845136003938801598654871345, + ], + [ + 574424067119200181933992948252007230348512600107123873197603373898923821490, + 1714030696055067278349157346067719307863507310709155690164546226450579547098, + 2339895272202694698739231405357972261413383527237194045718815176814132612501, + 3562501318971895161271663840954705079797767042115717360959659475564651685069, + 69069358687197963617161747606993436483967992689488259107924379545671193749, + ], + [ + 2614502738369008850475068874731531583863538486212691941619835266611116051561, + 655247349763023251625727726218660142895322325659927266813592114640858573566, + 2305235672527595714255517865498269719545193172975330668070873705108690670678, + 926416070297755413261159098243058134401665060349723804040714357642180531931, + 866523735635840246543516964237513287099659681479228450791071595433217821460, + ], + [ + 2284334068466681424919271582037156124891004191915573957556691163266198707693, + 1812588309302477291425732810913354633465435706480768615104211305579383928792, + 2836899808619013605432050476764608707770404125005720004551836441247917488507, + 2989087789022865112405242078196235025698647423649950459911546051695688370523, + 68056284404189102136488263779598243992465747932368669388126367131855404486, + ], + [ + 505425339250887519581119854377342241317528319745596963584548343662758204398, + 2118963546856545068961709089296976921067035227488975882615462246481055679215, + 2253872596319969096156004495313034590996995209785432485705134570745135149681, + 1625090409149943603241183848936692198923183279116014478406452426158572703264, + 179139838844452470348634657368199622305888473747024389514258107503778442495, + ], + [ + 1567067018147735642071130442904093290030432522257811793540290101391210410341, + 2737301854006865242314806979738760349397411136469975337509958305470398783585, + 3002738216460904473515791428798860225499078134627026021350799206894618186256, + 374029488099466837453096950537275565120689146401077127482884887409712315162, + 973403256517481077805460710540468856199855789930951602150773500862180885363, + ], + [ + 2691967457038172130555117632010860984519926022632800605713473799739632878867, + 3515906794910381201365530594248181418811879320679684239326734893975752012109, + 148057579455448384062325089530558091463206199724854022070244924642222283388, + 1541588700238272710315890873051237741033408846596322948443180470429851502842, + 147013865879011936545137344076637170977925826031496203944786839068852795297, + ], + [ + 2630278389304735265620281704608245039972003761509102213752997636382302839857, + 1359048670759642844930007747955701205155822111403150159614453244477853867621, + 2438984569205812336319229336885480537793786558293523767186829418969842616677, + 2137792255841525507649318539501906353254503076308308692873313199435029594138, + 2262318076430740712267739371170174514379142884859595360065535117601097652755, + ], + [ + 2792703718581084537295613508201818489836796608902614779596544185252826291584, + 2294173715793292812015960640392421991604150133581218254866878921346561546149, + 2770011224727997178743274791849308200493823127651418989170761007078565678171, + 3321642244537785916275181932172303118112488081726311374164578600576901819844, + 3522708517589950573320671158134804505970724681591943826922697952040487655044, + ], + [ + 3417974441436557992524691506735790206623600049454586729879955931972546347402, + 175039333145381316571259690443853067809784261609912638686739799135919647022, + 1930713062131033273316869231148248962041053029742760224583505092759642967464, + 2971452932574554603554350185069538580257636405419430340233233400633251319042, + 2774781903758215341037075610938953949868289195845367046186588750871862784919, + ], + [ + 666516874137869653699423537799457099346460194092311952417454613224504932738, + 1900462225013533249140457703727169176351786259991305560412832202759625668041, + 2665631186082687279121709429531834469477679375137509769347092380798929714377, + 837840745988147279235494664091280091563355097569199320366973125128366540061, + 3391544118305848781823721719916289805455110924839794510205940718821197620955, + ], + [ + 2888553035909938253628892138500390690221493345071933642853222968481016605919, + 3386241569867597612447901482685846444743718781330869478721963580925825915450, + 1205126220630896984850042596877918177217334376800874965105642874206963597698, + 3590072615491710252422997155203204584659171612188004116415640739580250394190, + 692469013329617220154003334549812915100479873898898958632988703738125356983, + ], + [ + 1623178235190707102808841905143937367808788834203621005714003335195182126335, + 1972826180775011489122426045504602288576507493792470102803637471568052321297, + 3415141329098504418158191749675997877417539760075593313736376750580696083073, + 587811537889727046473915684463981273175495137461951211739526104349163747811, + 2523982964351069134084525951849317400231659428055762640605248929856135518199, + ], + [ + 2686176526711834950207666047281383173339057216783586039351834948812568447629, + 983144446441739425577690449774542566745526459152966545642451764143532586964, + 171558252019175695567663688494555626159399786667979998273792882504784080805, + 332337623010057542760158225837623039780806442976079546879646069338600179518, + 1264669683963885571544813806669118319675288608634733888843804451222546848295, + ], + [ + 2426165115815723668018318268486497504249785449504758403912155206515511627681, + 11387399609384288947733630450855186629703576293221897150193655994854764608, + 2541728569046079092074077754414781968906176513081761690404588216304985421091, + 47685947554980329431290582269851186106577733250761848107645535357326439312, + 472176388418187405374813530639596064799362505024895746833751173199773896628, + ], + [ + 2764298116617383397920343358525617195195060562266243809245480210157942112738, + 486863835068754002670800862273365477867695879270721744227071001883208334054, + 2973492686137102577527656941792991264994301121122130295965761350095846874635, + 178385615141132702906181473263873416748818415607305319148067639744074654009, + 533624640096756667052211553746016402543259206286603356120804827761339634127, + ], + [ + 819406716720171922688026098737835227857400444543748198788964759773510472096, + 531851793767260921861217458033110066464894334064526987603936107947006031387, + 3269709072483585277009748181134917746036523619604017812342933951952104134829, + 838191718603413598040249006803464503100808192944407407147899973659013630611, + 1574561296941310904780257598780779812250055948216417844567262310524022037406, + ], + [ + 551394354289003977607664358739006072556227894953233419144430578080352094737, + 445076790942318675726839050057337819004979443030540904213920669247413907302, + 1963946696292687224902912968478695543164747600779913024040878700455222386521, + 484284614181963381509745298932402076252103342403432879800905151752488144767, + 2240507606126946994415203252302826782042951346966859379502140796364876543253, + ], + [ + 3237135638753992982179886898758938279897590886053928839613434762582576319619, + 2334333034701915027889533058426879447140084891006486138782876488162658230991, + 14411091399844539897439754491034751977136685514851444574462584316609631592, + 1264480371592407258420308876448697804787923638319277097663041109464608464284, + 671929312763821646360589403212798993954209530574443543917757335777610372144, + ], + [ + 2513909805455654095962542944994577107405216428214873444765576238504714067396, + 870121102846043786263357605823753628974859886859187558617096145653709171231, + 399132620893316356411986266679786708905730068946836982293484206366500277754, + 2855046250836680633532995284655778407402587437073106249445470889390454667586, + 2063679741125384345396981490971605710211281905716315529671473143278849561151, + ], + [ + 1433753212258929925682201698758056443128516570551146995210728194816988328337, + 3334984763425011856632257855270507440816274246647423607159847074739331865077, + 337911293622078184850923533628334646725451591671907148383867096651211846605, + 559587005295238702015018022040357402231957131094636365177008701077975941644, + 885963059604819264377490633589388189646118257469490919900554134369512794660, + ], + [ + 1957748763518471091057032383332840331641373304981058387824598000170709016333, + 3175295982155056798972302481564899381103533409383494814704562889625572018450, + 498987160612401618114584726510347771865331516606886613019084323862447372555, + 947374835104260364630171441676101001841507588423166778786886198914150312958, + 906933977754491302438795274167251538820934378773708095543613756654712689280, + ], + [ + 2170116291766863179909957030577284618726490893598499117272497866180009722894, + 1801335399574515889082584621772588704763181408217893911806726119813067220453, + 1942500232535842474530840356353427989892065499159260166135596750084681859966, + 62936080219825306823124060587235998278756755377419521154040408253893795176, + 3091993939935137795359769774909373279950941171574748645375255810204590357753, + ], + [ + 1283528386884634267663661033944552098742115012555712906773586466375284501324, + 1581820717639229420476069802992937438655873471854930764425841549067913106065, + 2301986095388751633126546121528329200085681648876910655269533407603441046514, + 2850003828037698751961753862613545302539465803982364898225617297398939302949, + 48024691078494936445046366770271288984930221238071705874025261821606393528, + ], + [ + 1482336297033144958942154923925185950152551534403871620222916667536030875354, + 3081177564717719643771186007689458633949181485535169123213511264603782950049, + 3315701127039521853279746297714590495201061397709680410650043502532250578075, + 3514407611000441301995070394422463400067690470546731164089622325748803106020, + 368970178199930154322724953487299516224498421233447528815195701420122548537, + ], + [ + 584353160413525267849669053228533951552602295860601556035386665117717227391, + 752038702160385294706011538400822066722189014251268673051846350397729870418, + 3594041683498798688197194521326299097635429790757880308152971477196489335154, + 1367902435756906062215608264424138718742854099315395230911274560900857414183, + 1828549068951502746189364466794037234789986878381694857475972053743463890779, + ], + [ + 488172495141237210878388657234137733008417573114482400652274985829148564248, + 962906242461930394022372340919543491337923491322497419797555620396501785566, + 2275418085010046236619290386129138234541669589549771944697082317642065048898, + 1966395064658902622886154686288219600816893261614483533899715888994623208964, + 3496095878293416917311185659829821476802828534554531050412634978086916288609, + ], + [ + 3368478822390537245916137403277928093536087427951052230723275731232142463388, + 3397410259276620127103231993277518800970669191016277541098821699302368873803, + 2662600899665871010006649609856695263727220473364611552472965243032255906029, + 2854831720595596992200155718152374313555878203864206470581502555480894633975, + 2417859092561967752135741161218626374900182454089059862468108240576782064037, + ], + [ + 1064506915903089299531724594973601253341866933071158266140674053459433520889, + 243845138053687262800349059300355289745206315347524675450796070948867090098, + 1952653154963756062322124110012629666160000286707762177032475477295929736283, + 2760979128531476595658428672038276216079708408852493051222686009638650156041, + 3341178930260137001230946104398194306290005446746057811731360203227371301716, + ], + [ + 1033242545866274439991875444609632860132556714736615395036273942261573810479, + 3567973410830779135148598005871071456943945697865168835204985462698751038238, + 23014034649293369426970379738102323014738017168969687350330825050016457105, + 1146720508452451012445869043641390200263192255569203352823376998708972325392, + 2553707028642376593497768606567528232999203496079990242456254686325586089356, + ], + [ + 269729857648436699208023125596593246149228245518586029792966091405383426269, + 276912682886955358118649215147238115764108757952690361549816619060658800027, + 2367180947887796341722261610916728725977893583923967218630363334645641817362, + 2398694802751362950028137620758033447242325333923222365760836442417755445092, + 984868389243025029364428136317275892280780834039611841422502834917752411391, + ], + [ + 861353329558771468244040268521983016756775808329676883407171471251365927595, + 2498672969617384807617108262141800974986393948110233099680635130601163654234, + 1336236634145657673540555267430353130305889434115514586892320600753700983325, + 980337801407886250576371882962628290239239581416378379141354256717803603922, + 2308558359523317875952657835109605515063994805873180719205156915762120497245, + ], + [ + 2116737905426837141304542819940293184404010538896700217242374222514653607487, + 2143995283326808680518644927890182524580312777400009071739277407358043120199, + 3038758768133404431511594054950351369492648883179154555267474054094234927849, + 981824005865625678985009911415023115269386212492064371040001594972137748141, + 2427990511715778580869565219059895697855813782250850855111162965998948386792, + ], + [ + 1987498156785173719076522405088076990979859292718600184358583152317049836167, + 1633834915134208237423144264187482951766302060112099587851513525797020813799, + 2895454976388515752029424688351979030650325184941524820409482023485820781526, + 941019661238578826272324221721825852217063629464317974190162904813488515671, + 2529926057929249454763690180607677568685011502604470585585763159431333258299, + ], + [ + 2604831509257756199338105380847564711923112853239827243306562341166492672823, + 2300475954087415591738767759767032267163723345312082546282694920273655145455, + 1954000528502201000509342111010021527425422549437946241062907964768089317082, + 1179936151696782249912570883839105595634344582873818018332922940963046083567, + 3077707030301573630126144767923697288658782137457660869231140049571827937228, + ], + [ + 1062324397142900251844488719868780667589966366756786302007970554437994421840, + 353718609497993885193404630053532608155520921625518104461520254335222009911, + 770557645309607171206012551080400276506165720184677119001983749356594531977, + 3043628430985247363392058521341757139056029350680498644930013342982472853636, + 1694968537785457252742656255724723357998402478572600479401200420305593921487, + ], + [ + 539865665379093791531434211889371819368504193082947002067781562776138072582, + 3473466148775696692731190426971123680342615414200262605154732883324298196699, + 482783534456196983135936103604928650836406142744767857356485953118411089098, + 2389101033971236780034779577432189630800997581132154923233144722790749715251, + 845264223568475649981141803833883014312596504303895519674002924871878791033, + ], + [ + 3027004059915270231142566724881373969831662022738947178800901294120992473905, + 2169574859350740480088697859610203373582027214052754592019828328614087431593, + 3515527080764222354309565181793838292349410992793070639041305826153436624160, + 1817926918350512904327755405973355211358017834277255662858654992240629698587, + 1999148133619270973098477176176178514394558202995832714883251820350860287223, + ], + [ + 1203131300029280096510929599113528018338088236684405405384757591977164161039, + 336815403657101171302040383579077521911288747438919304948637997306314852594, + 986661060847815533035934253464295060766339947679669645818832311132001095573, + 2291116974939980228917916563988261327966840303336559854772343651559589512651, + 3421243089992476528970346847858594146122972226790673723411896208702859892637, + ], + [ + 1015505198663386486420800821559060487156096175034250154764824837183581949724, + 1165880582987807286271819576391581724550686829511475839624601920297855380101, + 904232961143172831178860280790910264843503022179578981166030973682571903458, + 261322216292849827900157598748641385787016033372999683866859675894253115357, + 3060676319159217735181388708455879854358158161989877552543698103915296690395, + ], + [ + 1175560144527845912984609340783959238735643215413930887771084560168082442967, + 2813871258576082360085006002528268796351819524936446195552260262614692343332, + 1841341101531851399935829271555098629075809587212843292354556374386667658235, + 3076135575511709688509914361447080149794919016880133063891720256749999834767, + 753111801049754117414662684453226478940731922961768343984187479992842213733, + ], + [ + 1405657437118503342762241742745888533114216548278983907019917904938403345580, + 3111186124713876864436867307979940633543281080828379725576742174555539054855, + 3404463650394703220454952017098727360005393139199301323890695570346564876407, + 2024087816190101179456573591359233695334184711688920998987373624570170649371, + 2770035625774572095496575568588054654502991645588385802705097377675051032967, + ], + [ + 437058215235292632621847481185406671372191763951486300610124033096831557414, + 1345792773780982398809956395232061067669190682958320579442454533085407626029, + 925357273912625669941681596445839316566672314870287993638671283923476231904, + 3288133122086768300615066039539687885053110015077924175836976549020438910830, + 666190075990703867784232802074474372379358766701681865975596503982238839889, + ], + [ + 2664898601165892062970298960258838238925231697327906221693001926762280012052, + 2075648691532387787722427044464731934171216054855867223374228487601569118337, + 3173725544188532489243684991828985285646224157242834030308807120745121062293, + 1517474443612606408422643323550409253700128234157734252330869178582583531320, + 1593950878945144789965609248470060076911813704207225832606804796819386297511, + ], + [ + 141195541167651298813588829225208004611326987855926870823948793274702167509, + 2990187949585642302497822222637786229364740008175968941859105979392907839776, + 2893807105405820282316438050347503569385510241526138409321358916388308586443, + 1379719211597875648759619903854862028510320482486109668868067715175935658353, + 2702780364788282233075255946852944970202849869091427738791947810055591218061, + ], + [ + 1825815734419326277729273926504439575157952821379179501821641713286627304656, + 1481344458867016048625916723816339719872443766684158199301690902395849166360, + 2014084774259125722186109781197998076881266739680534358898592778318128968629, + 2612744185006548312909661512508122065214170543806989291921289897662387203493, + 2486291022451231582267428921150634472835925206862678364689227838329114330247, + ], +] diff --git a/test/stark/poseidon/poseidon9.txt b/test/stark/poseidon/poseidon9.txt new file mode 100644 index 0000000..f197f1d --- /dev/null +++ b/test/stark/poseidon/poseidon9.txt @@ -0,0 +1,1031 @@ +Rate = 8 +Capacity = 1 +FullRounds = 8 +PartialRounds = 84 +MDS = [ + [5, 1, 1, 1, 1, 1, 1, 1, 1], + [1, 4, 1, 1, 1, 1, 1, 1, 1], + [1, 1, 3, 1, 1, 1, 1, 1, 1], + [1, 1, 1, 2, 1, 1, 1, 1, 1], + [1, 1, 1, 1, 1, 1, 1, 1, 1], + [1, 1, 1, 1, 1, 0, 1, 1, 1], + [1, 1, 1, 1, 1, 1, -1, 1, 1], + [1, 1, 1, 1, 1, 1, 1, -3, 1], + [1, 1, 1, 1, 1, 1, 1, 1, -4], +] +RoundKeys = ( + [ + [ + 2950795762459345168613727575620414179244544320470208355568817838579231751791, + 1587446564224215276866294500450702039420286416111469274423465069420553242820, + 1645965921169490687904413452218868659025437693527479459426157555728339600137, + 2782373324549879794752287702905278018819686065818504085638398966973694145741, + 3409172630025222641379726933524480516420204828329395644967085131392375707302, + 2379053116496905638239090788901387719228422033660130943198035907032739387135, + 2570819397480941104144008784293466051718826502582588529995520356691856497111, + 3546220846133880637977653625763703334841539452343273304410918449202580719746, + 2720682389492889709700489490056111332164748138023159726590726667539759963454, + ], + [ + 1899653471897224903834726250400246354200311275092866725547887381599836519005, + 2369443697923857319844855392163763375394720104106200469525915896159690979559, + 2354174693689535854311272135513626412848402744119855553970180659094265527996, + 2404084503073127963385083467393598147276436640877011103379112521338973185443, + 950320777137731763811524327595514151340412860090489448295239456547370725376, + 2121140748740143694053732746913428481442990369183417228688865837805149503386, + 2372065044800422557577242066480215868569521938346032514014152523102053709709, + 2618497439310693947058545060953893433487994458443568169824149550389484489896, + 3518297267402065742048564133910509847197496119850246255805075095266319996916, + ], + [ + 340529752683340505065238931581518232901634742162506851191464448040657139775, + 1954876811294863748406056845662382214841467408616109501720437541211031966538, + 813813157354633930267029888722341725864333883175521358739311868164460385261, + 71901595776070443337150458310956362034911936706490730914901986556638720031, + 2789761472166115462625363403490399263810962093264318361008954888847594113421, + 2628791615374802560074754031104384456692791616314774034906110098358135152410, + 3617032588734559635167557152518265808024917503198278888820567553943986939719, + 2624012360209966117322788103333497793082705816015202046036057821340914061980, + 149101987103211771991327927827692640556911620408176100290586418839323044234, + ], + [ + 1039927963829140138166373450440320262590862908847727961488297105916489431045, + 2213946951050724449162431068646025833746639391992751674082854766704900195669, + 2792724903541814965769131737117981991997031078369482697195201969174353468597, + 3212031629728871219804596347439383805499808476303618848198208101593976279441, + 3343514080098703935339621028041191631325798327656683100151836206557453199613, + 614054702436541219556958850933730254992710988573177298270089989048553060199, + 148148081026449726283933484730968827750202042869875329032965774667206931170, + 1158283532103191908366672518396366136968613180867652172211392033571980848414, + 1032400527342371389481069504520755916075559110755235773196747439146396688513, + ], + [ + 806900704622005851310078578853499250941978435851598088619290797134710613736, + 462498083559902778091095573017508352472262817904991134671058825705968404510, + 1003580119810278869589347418043095667699674425582646347949349245557449452503, + 619074932220101074089137133998298830285661916867732916607601635248249357793, + 2635090520059500019661864086615522409798872905401305311748231832709078452746, + 978252636251682252755279071140187792306115352460774007308726210405257135181, + 1766912167973123409669091967764158892111310474906691336473559256218048677083, + 1663265127259512472182980890707014969235283233442916350121860684522654120381, + 3532407621206959585000336211742670185380751515636605428496206887841428074250, + ], + [ + 2507023127157093845256722098502856938353143387711652912931112668310034975446, + 3321152907858462102434883844787153373036767230808678981306827073335525034593, + 3039253036806065280643845548147711477270022154459620569428286684179698125661, + 103480338868480851881924519768416587261556021758163719199282794248762465380, + 2394049781357087698434751577708655768465803975478348134669006211289636928495, + 2660531560345476340796109810821127229446538730404600368347902087220064379579, + 3603166934034556203649050570865466556260359798872408576857928196141785055563, + 1553799760191949768532188139643704561532896296986025007089826672890485412324, + 2744284717053657689091306578463476341218866418732695211367062598446038965164, + ], + [ + 320745764922149897598257794663594419839885234101078803811049904310835548856, + 979382242100682161589753881721708883681034024104145498709287731138044566302, + 1860426855810549882740147175136418997351054138609396651615467358416651354991, + 336173081054369235994909356892506146234495707857220254489443629387613956145, + 1632470326779699229772327605759783482411227247311431865655466227711078175883, + 921958250077481394074960433988881176409497663777043304881055317463712938502, + 3034358982193370602048539901033542101022185309652879937418114324899281842797, + 25626282149517463867572353922222474817434101087272320606729439087234878607, + 3002662261401575565838149305485737102400501329139562227180277188790091853682, + ], + [ + 2939684373453383817196521641512509179310654199629514917426341354023324109367, + 1076484609897998179434851570277297233169621096172424141759873688902355505136, + 2575095284833160494841112025725243274091830284746697961080467506739203605049, + 3565075264617591783581665711620369529657840830498005563542124551465195621851, + 2197016502533303822395077038351174326125210255869204501838837289716363437993, + 331415322883530754594261416546036195982886300052707474899691116664327869405, + 1935011233711290003793244296594669823169522055520303479680359990463281661839, + 3495901467168087413996941216661589517270845976538454329511167073314577412322, + 954195417117133246453562983448451025087661597543338750600301835944144520375, + ], + [ + 1271840477709992894995746871435810599280944810893784031132923384456797925777, + 2565310762274337662754531859505158700827688964841878141121196528015826671847, + 3365022288251637014588279139038152521653896670895105540140002607272936852513, + 1660592021628965529963974299647026602622092163312666588591285654477111176051, + 970104372286014048279296575474974982288801187216974504035759997141059513421, + 2617024574317953753849168721871770134225690844968986289121504184985993971227, + 999899815343607746071464113462778273556695659506865124478430189024755832262, + 2228536129413411161615629030408828764980855956560026807518714080003644769896, + 2701953891198001564547196795777701119629537795442025393867364730330476403227, + ], + [ + 837078355588159388741598313782044128527494922918203556465116291436461597853, + 2121749601840466143704862369657561429793951309962582099604848281796392359214, + 771812260179247428733132708063116523892339056677915387749121983038690154755, + 3317336423132806446086732225036532603224267214833263122557471741829060578219, + 481570067997721834712647566896657604857788523050900222145547508314620762046, + 242195042559343964206291740270858862066153636168162642380846129622127460192, + 2855462178889999218204481481614105202770810647859867354506557827319138379686, + 3525521107148375040131784770413887305850308357895464453970651672160034885202, + 1320839531502392535964065058804908871811967681250362364246430459003920305799, + ], + [ + 2514191518588387125173345107242226637171897291221681115249521904869763202419, + 2798335750958827619666318316247381695117827718387653874070218127140615157902, + 2808467767967035643407948058486565877867906577474361783201337540214875566395, + 3551834385992706206273955480294669176699286104229279436819137165202231595747, + 1219439673853113792340300173186247996249367102884530407862469123523013083971, + 761519904537984520554247997444508040636526566551719396202550009393012691157, + 3355402549169351700500518865338783382387571349497391475317206324155237401353, + 199541098009731541347317515995192175813554789571447733944970283654592727138, + 192100490643078165121235261796864975568292640203635147901612231594408079071, + ], + [ + 1187019357602953326192019968809486933768550466167033084944727938441427050581, + 189525349641911362389041124808934468936759383310282010671081989585219065700, + 2831653363992091308880573627558515686245403755586311978724025292003353336665, + 2052859812632218952608271535089179639890275494426396974475479657192657094698, + 1670756178709659908159049531058853320846231785448204274277900022176591811072, + 3538757242013734574731807289786598937548399719866320954894004830207085723125, + 710549042741321081781917034337800036872214466705318638023070812391485261299, + 2345013122330545298606028187653996682275206910242635100920038943391319595180, + 3528369671971445493932880023233332035122954362711876290904323783426765912206, + ], + [ + 1167120829038120978297497195837406760848728897181138760506162680655977700764, + 3073243357129146594530765548901087443775563058893907738967898816092270628884, + 378514724418106317738164464176041649567501099164061863402473942795977719726, + 333391138410406330127594722511180398159664250722328578952158227406762627796, + 1727570175639917398410201375510924114487348765559913502662122372848626931905, + 968312190621809249603425066974405725769739606059422769908547372904403793174, + 360659316299446405855194688051178331671817370423873014757323462844775818348, + 1386580151907705298970465943238806620109618995410132218037375811184684929291, + 3604888328937389309031638299660239238400230206645344173700074923133890528967, + ], + [ + 2496185632263372962152518155651824899299616724241852816983268163379540137546, + 486538168871046887467737983064272608432052269868418721234810979756540672990, + 1558415498960552213241704009433360128041672577274390114589014204605400783336, + 3512058327686147326577190314835092911156317204978509183234511559551181053926, + 2235429387083113882635494090887463486491842634403047716936833563914243946191, + 1290896777143878193192832813769470418518651727840187056683408155503813799882, + 1143310336918357319571079551779316654556781203013096026972411429993634080835, + 3235435208525081966062419599803346573407862428113723170955762956243193422118, + 1293239921425673430660897025143433077974838969258268884994339615096356996604, + ], + [ + 236252269127612784685426260840574970698541177557674806964960352572864382971, + 1733907592497266237374827232200506798207318263912423249709509725341212026275, + 302004309771755665128395814807589350526779835595021835389022325987048089868, + 3018926838139221755384801385583867283206879023218491758435446265703006270945, + 39701437664873825906031098349904330565195980985885489447836580931425171297, + 908381723021746969965674308809436059628307487140174335882627549095646509778, + 219062858908229855064136253265968615354041842047384625689776811853821594358, + 1283129863776453589317845316917890202859466483456216900835390291449830275503, + 418512623547417594896140369190919231877873410935689672661226540908900544012, + ], + [ + 1792181590047131972851015200157890246436013346535432437041535789841136268632, + 370546432987510607338044736824316856592558876687225326692366316978098770516, + 3323437805230586112013581113386626899534419826098235300155664022709435756946, + 910076621742039763058481476739499965761942516177975130656340375573185415877, + 1762188042455633427137702520675816545396284185254002959309669405982213803405, + 2186362253913140345102191078329764107619534641234549431429008219905315900520, + 2230647725927681765419218738218528849146504088716182944327179019215826045083, + 1069243907556644434301190076451112491469636357133398376850435321160857761825, + 2695241469149243992683268025359863087303400907336026926662328156934068747593, + ], + [ + 1361519681544413849831669554199151294308350560528931040264950307931824877035, + 1339116632207878730171031743761550901312154740800549632983325427035029084904, + 790593524918851401449292693473498591068920069246127392274811084156907468875, + 2723400368331924254840192318398326090089058735091724263333980290765736363637, + 3457180265095920471443772463283225391927927225993685928066766687141729456030, + 1483675376954327086153452545475557749815683871577400883707749788555424847954, + 2926303836265506736227240325795090239680154099205721426928300056982414025239, + 543969119775473768170832347411484329362572550684421616624136244239799475526, + 237401230683847084256617415614300816373730178313253487575312839074042461932, + ], + [ + 844568412840391587862072008674263874021460074878949862892685736454654414423, + 151922054871708336050647150237534498235916969120198637893731715254687336644, + 1299332034710622815055321547569101119597030148120309411086203580212105652312, + 487046922649899823989594814663418784068895385009696501386459462815688122993, + 1104883249092599185744249485896585912845784382683240114120846423960548576851, + 1458388705536282069567179348797334876446380557083422364875248475157495514484, + 850248109622750774031817200193861444623975329881731864752464222442574976566, + 2885843173858536690032695698009109793537724845140477446409245651176355435722, + 3027068551635372249579348422266406787688980506275086097330568993357835463816, + ], + [ + 3231892723647447539926175383213338123506134054432701323145045438168976970994, + 1719080830641935421242626784132692936776388194122314954558418655725251172826, + 1172253756541066126131022537343350498482225068791630219494878195815226839450, + 1619232269633026603732619978083169293258272967781186544174521481891163985093, + 3495680684841853175973173610562400042003100419811771341346135531754869014567, + 1576161515913099892951745452471618612307857113799539794680346855318958552758, + 2618326122974253423403350731396350223238201817594761152626832144510903048529, + 2696245132758436974032479782852265185094623165224532063951287925001108567649, + 930116505665110070247395429730201844026054810856263733273443066419816003444, + ], + [ + 2786389174502246248523918824488629229455088716707062764363111940462137404076, + 1555260846425735320214671887347115247546042526197895180675436886484523605116, + 2306241912153325247392671742757902161446877415586158295423293240351799505917, + 411529621724849932999694270803131456243889635467661223241617477462914950626, + 1542495485262286701469125140275904136434075186064076910329015697714211835205, + 1853045663799041100600825096887578544265580718909350942241802897995488264551, + 2963055259497271220202739837493041799968576111953080503132045092194513937286, + 2303806870349915764285872605046527036748108533406243381676768310692344456050, + 2622104986201990620910286730213140904984256464479840856728424375142929278875, + ], + [ + 2369987021925266811581727383184031736927816625797282287927222602539037105864, + 285070227712021899602056480426671736057274017903028992288878116056674401781, + 3034087076179360957800568733595959058628497428787907887933697691951454610691, + 469095854351700119980323115747590868855368701825706298740201488006320881056, + 360001976264385426746283365024817520563236378289230404095383746911725100012, + 3438709327109021347267562000879503009590697221730578667498351600602230296178, + 63573904800572228121671659287593650438456772568903228287754075619928214969, + 3470881855042989871434874691030920672110111605547839662680968354703074556970, + 724559311507950497340993415408274803001166693839947519425501269424891465492, + ], + [ + 880409284677518997550768549487344416321062350742831373397603704465823658986, + 6876255662475867703077362872097208259197756317287339941435193538565586230, + 2701916445133770775447884812906226786217969545216086200932273680400909154638, + 425152119158711585559310064242720816611629181537672850898056934507216982586, + 1475552998258917706756737045704649573088377604240716286977690565239187213744, + 2413772448122400684309006716414417978370152271397082147158000439863002593561, + 392160855822256520519339260245328807036619920858503984710539815951012864164, + 1075036996503791536261050742318169965707018400307026402939804424927087093987, + 2176439430328703902070742432016450246365760303014562857296722712989275658921, + ], + [ + 1413865976587623331051814207977382826721471106513581745229680113383908569693, + 4879283427490523253696177116563427032332223531862961281430108575019551814, + 3392583297537374046875199552977614390492290683707960975137418536812266544902, + 3600854486849487646325182927019642276644093512133907046667282144129939150983, + 2779924664161372134024229593301361846129279572186444474616319283535189797834, + 2722699960903170449291146429799738181514821447014433304730310678334403972040, + 819109815049226540285781191874507704729062681836086010078910930707209464699, + 3046121243742768013822760785918001632929744274211027071381357122228091333823, + 1339019590803056172509793134119156250729668216522001157582155155947567682278, + ], + [ + 1933279639657506214789316403763326578443023901555983256955812717638093967201, + 2138221547112520744699126051903811860205771600821672121643894708182292213541, + 2694713515543641924097704224170357995809887124438248292930846280951601597065, + 2471734202930133750093618989223585244499567111661178960753938272334153710615, + 504903761112092757611047718215309856203214372330635774577409639907729993533, + 1943979703748281357156510253941035712048221353507135074336243405478613241290, + 684525210957572142559049112233609445802004614280157992196913315652663518936, + 1705585400798782397786453706717059483604368413512485532079242223503960814508, + 192429517716023021556170942988476050278432319516032402725586427701913624665, + ], + [ + 1586493702243128040549584165333371192888583026298039652930372758731750166765, + 686072673323546915014972146032384917012218151266600268450347114036285993377, + 3464340397998075738891129996710075228740496767934137465519455338004332839215, + 2805249176617071054530589390406083958753103601524808155663551392362371834663, + 667746464250968521164727418691487653339733392025160477655836902744186489526, + 1131527712905109997177270289411406385352032457456054589588342450404257139778, + 1908969485750011212309284349900149072003218505891252313183123635318886241171, + 1025257076985551890132050019084873267454083056307650830147063480409707787695, + 2153175291918371429502545470578981828372846236838301412119329786849737957977, + ], + [ + 3410257749736714576487217882785226905621212230027780855361670645857085424384, + 3442969106887588154491488961893254739289120695377621434680934888062399029952, + 3029953900235731770255937704976720759948880815387104275525268727341390470237, + 85453456084781138713939104192561924536933417707871501802199311333127894466, + 2730629666577257820220329078741301754580009106438115341296453318350676425129, + 178242450661072967256438102630920745430303027840919213764087927763335940415, + 2844589222514708695700541363167856718216388819406388706818431442998498677557, + 3547876269219141094308889387292091231377253967587961309624916269569559952944, + 2525005406762984211707203144785482908331876505006839217175334833739957826850, + ], + [ + 3096397013555211396701910432830904669391580557191845136003938801598654871345, + 574424067119200181933992948252007230348512600107123873197603373898923821490, + 1714030696055067278349157346067719307863507310709155690164546226450579547098, + 2339895272202694698739231405357972261413383527237194045718815176814132612501, + 3562501318971895161271663840954705079797767042115717360959659475564651685069, + 69069358687197963617161747606993436483967992689488259107924379545671193749, + 2614502738369008850475068874731531583863538486212691941619835266611116051561, + 655247349763023251625727726218660142895322325659927266813592114640858573566, + 2305235672527595714255517865498269719545193172975330668070873705108690670678, + ], + [ + 926416070297755413261159098243058134401665060349723804040714357642180531931, + 866523735635840246543516964237513287099659681479228450791071595433217821460, + 2284334068466681424919271582037156124891004191915573957556691163266198707693, + 1812588309302477291425732810913354633465435706480768615104211305579383928792, + 2836899808619013605432050476764608707770404125005720004551836441247917488507, + 2989087789022865112405242078196235025698647423649950459911546051695688370523, + 68056284404189102136488263779598243992465747932368669388126367131855404486, + 505425339250887519581119854377342241317528319745596963584548343662758204398, + 2118963546856545068961709089296976921067035227488975882615462246481055679215, + ], + [ + 2253872596319969096156004495313034590996995209785432485705134570745135149681, + 1625090409149943603241183848936692198923183279116014478406452426158572703264, + 179139838844452470348634657368199622305888473747024389514258107503778442495, + 1567067018147735642071130442904093290030432522257811793540290101391210410341, + 2737301854006865242314806979738760349397411136469975337509958305470398783585, + 3002738216460904473515791428798860225499078134627026021350799206894618186256, + 374029488099466837453096950537275565120689146401077127482884887409712315162, + 973403256517481077805460710540468856199855789930951602150773500862180885363, + 2691967457038172130555117632010860984519926022632800605713473799739632878867, + ], + [ + 3515906794910381201365530594248181418811879320679684239326734893975752012109, + 148057579455448384062325089530558091463206199724854022070244924642222283388, + 1541588700238272710315890873051237741033408846596322948443180470429851502842, + 147013865879011936545137344076637170977925826031496203944786839068852795297, + 2630278389304735265620281704608245039972003761509102213752997636382302839857, + 1359048670759642844930007747955701205155822111403150159614453244477853867621, + 2438984569205812336319229336885480537793786558293523767186829418969842616677, + 2137792255841525507649318539501906353254503076308308692873313199435029594138, + 2262318076430740712267739371170174514379142884859595360065535117601097652755, + ], + [ + 2792703718581084537295613508201818489836796608902614779596544185252826291584, + 2294173715793292812015960640392421991604150133581218254866878921346561546149, + 2770011224727997178743274791849308200493823127651418989170761007078565678171, + 3321642244537785916275181932172303118112488081726311374164578600576901819844, + 3522708517589950573320671158134804505970724681591943826922697952040487655044, + 3417974441436557992524691506735790206623600049454586729879955931972546347402, + 175039333145381316571259690443853067809784261609912638686739799135919647022, + 1930713062131033273316869231148248962041053029742760224583505092759642967464, + 2971452932574554603554350185069538580257636405419430340233233400633251319042, + ], + [ + 2774781903758215341037075610938953949868289195845367046186588750871862784919, + 666516874137869653699423537799457099346460194092311952417454613224504932738, + 1900462225013533249140457703727169176351786259991305560412832202759625668041, + 2665631186082687279121709429531834469477679375137509769347092380798929714377, + 837840745988147279235494664091280091563355097569199320366973125128366540061, + 3391544118305848781823721719916289805455110924839794510205940718821197620955, + 2888553035909938253628892138500390690221493345071933642853222968481016605919, + 3386241569867597612447901482685846444743718781330869478721963580925825915450, + 1205126220630896984850042596877918177217334376800874965105642874206963597698, + ], + [ + 3590072615491710252422997155203204584659171612188004116415640739580250394190, + 692469013329617220154003334549812915100479873898898958632988703738125356983, + 1623178235190707102808841905143937367808788834203621005714003335195182126335, + 1972826180775011489122426045504602288576507493792470102803637471568052321297, + 3415141329098504418158191749675997877417539760075593313736376750580696083073, + 587811537889727046473915684463981273175495137461951211739526104349163747811, + 2523982964351069134084525951849317400231659428055762640605248929856135518199, + 2686176526711834950207666047281383173339057216783586039351834948812568447629, + 983144446441739425577690449774542566745526459152966545642451764143532586964, + ], + [ + 171558252019175695567663688494555626159399786667979998273792882504784080805, + 332337623010057542760158225837623039780806442976079546879646069338600179518, + 1264669683963885571544813806669118319675288608634733888843804451222546848295, + 2426165115815723668018318268486497504249785449504758403912155206515511627681, + 11387399609384288947733630450855186629703576293221897150193655994854764608, + 2541728569046079092074077754414781968906176513081761690404588216304985421091, + 47685947554980329431290582269851186106577733250761848107645535357326439312, + 472176388418187405374813530639596064799362505024895746833751173199773896628, + 2764298116617383397920343358525617195195060562266243809245480210157942112738, + ], + [ + 486863835068754002670800862273365477867695879270721744227071001883208334054, + 2973492686137102577527656941792991264994301121122130295965761350095846874635, + 178385615141132702906181473263873416748818415607305319148067639744074654009, + 533624640096756667052211553746016402543259206286603356120804827761339634127, + 819406716720171922688026098737835227857400444543748198788964759773510472096, + 531851793767260921861217458033110066464894334064526987603936107947006031387, + 3269709072483585277009748181134917746036523619604017812342933951952104134829, + 838191718603413598040249006803464503100808192944407407147899973659013630611, + 1574561296941310904780257598780779812250055948216417844567262310524022037406, + ], + [ + 551394354289003977607664358739006072556227894953233419144430578080352094737, + 445076790942318675726839050057337819004979443030540904213920669247413907302, + 1963946696292687224902912968478695543164747600779913024040878700455222386521, + 484284614181963381509745298932402076252103342403432879800905151752488144767, + 2240507606126946994415203252302826782042951346966859379502140796364876543253, + 3237135638753992982179886898758938279897590886053928839613434762582576319619, + 2334333034701915027889533058426879447140084891006486138782876488162658230991, + 14411091399844539897439754491034751977136685514851444574462584316609631592, + 1264480371592407258420308876448697804787923638319277097663041109464608464284, + ], + [ + 671929312763821646360589403212798993954209530574443543917757335777610372144, + 2513909805455654095962542944994577107405216428214873444765576238504714067396, + 870121102846043786263357605823753628974859886859187558617096145653709171231, + 399132620893316356411986266679786708905730068946836982293484206366500277754, + 2855046250836680633532995284655778407402587437073106249445470889390454667586, + 2063679741125384345396981490971605710211281905716315529671473143278849561151, + 1433753212258929925682201698758056443128516570551146995210728194816988328337, + 3334984763425011856632257855270507440816274246647423607159847074739331865077, + 337911293622078184850923533628334646725451591671907148383867096651211846605, + ], + [ + 559587005295238702015018022040357402231957131094636365177008701077975941644, + 885963059604819264377490633589388189646118257469490919900554134369512794660, + 1957748763518471091057032383332840331641373304981058387824598000170709016333, + 3175295982155056798972302481564899381103533409383494814704562889625572018450, + 498987160612401618114584726510347771865331516606886613019084323862447372555, + 947374835104260364630171441676101001841507588423166778786886198914150312958, + 906933977754491302438795274167251538820934378773708095543613756654712689280, + 2170116291766863179909957030577284618726490893598499117272497866180009722894, + 1801335399574515889082584621772588704763181408217893911806726119813067220453, + ], + [ + 1942500232535842474530840356353427989892065499159260166135596750084681859966, + 62936080219825306823124060587235998278756755377419521154040408253893795176, + 3091993939935137795359769774909373279950941171574748645375255810204590357753, + 1283528386884634267663661033944552098742115012555712906773586466375284501324, + 1581820717639229420476069802992937438655873471854930764425841549067913106065, + 2301986095388751633126546121528329200085681648876910655269533407603441046514, + 2850003828037698751961753862613545302539465803982364898225617297398939302949, + 48024691078494936445046366770271288984930221238071705874025261821606393528, + 1482336297033144958942154923925185950152551534403871620222916667536030875354, + ], + [ + 3081177564717719643771186007689458633949181485535169123213511264603782950049, + 3315701127039521853279746297714590495201061397709680410650043502532250578075, + 3514407611000441301995070394422463400067690470546731164089622325748803106020, + 368970178199930154322724953487299516224498421233447528815195701420122548537, + 584353160413525267849669053228533951552602295860601556035386665117717227391, + 752038702160385294706011538400822066722189014251268673051846350397729870418, + 3594041683498798688197194521326299097635429790757880308152971477196489335154, + 1367902435756906062215608264424138718742854099315395230911274560900857414183, + 1828549068951502746189364466794037234789986878381694857475972053743463890779, + ], + [ + 488172495141237210878388657234137733008417573114482400652274985829148564248, + 962906242461930394022372340919543491337923491322497419797555620396501785566, + 2275418085010046236619290386129138234541669589549771944697082317642065048898, + 1966395064658902622886154686288219600816893261614483533899715888994623208964, + 3496095878293416917311185659829821476802828534554531050412634978086916288609, + 3368478822390537245916137403277928093536087427951052230723275731232142463388, + 3397410259276620127103231993277518800970669191016277541098821699302368873803, + 2662600899665871010006649609856695263727220473364611552472965243032255906029, + 2854831720595596992200155718152374313555878203864206470581502555480894633975, + ], + [ + 2417859092561967752135741161218626374900182454089059862468108240576782064037, + 1064506915903089299531724594973601253341866933071158266140674053459433520889, + 243845138053687262800349059300355289745206315347524675450796070948867090098, + 1952653154963756062322124110012629666160000286707762177032475477295929736283, + 2760979128531476595658428672038276216079708408852493051222686009638650156041, + 3341178930260137001230946104398194306290005446746057811731360203227371301716, + 1033242545866274439991875444609632860132556714736615395036273942261573810479, + 3567973410830779135148598005871071456943945697865168835204985462698751038238, + 23014034649293369426970379738102323014738017168969687350330825050016457105, + ], + [ + 1146720508452451012445869043641390200263192255569203352823376998708972325392, + 2553707028642376593497768606567528232999203496079990242456254686325586089356, + 269729857648436699208023125596593246149228245518586029792966091405383426269, + 276912682886955358118649215147238115764108757952690361549816619060658800027, + 2367180947887796341722261610916728725977893583923967218630363334645641817362, + 2398694802751362950028137620758033447242325333923222365760836442417755445092, + 984868389243025029364428136317275892280780834039611841422502834917752411391, + 861353329558771468244040268521983016756775808329676883407171471251365927595, + 2498672969617384807617108262141800974986393948110233099680635130601163654234, + ], + [ + 1336236634145657673540555267430353130305889434115514586892320600753700983325, + 980337801407886250576371882962628290239239581416378379141354256717803603922, + 2308558359523317875952657835109605515063994805873180719205156915762120497245, + 2116737905426837141304542819940293184404010538896700217242374222514653607487, + 2143995283326808680518644927890182524580312777400009071739277407358043120199, + 3038758768133404431511594054950351369492648883179154555267474054094234927849, + 981824005865625678985009911415023115269386212492064371040001594972137748141, + 2427990511715778580869565219059895697855813782250850855111162965998948386792, + 1987498156785173719076522405088076990979859292718600184358583152317049836167, + ], + [ + 1633834915134208237423144264187482951766302060112099587851513525797020813799, + 2895454976388515752029424688351979030650325184941524820409482023485820781526, + 941019661238578826272324221721825852217063629464317974190162904813488515671, + 2529926057929249454763690180607677568685011502604470585585763159431333258299, + 2604831509257756199338105380847564711923112853239827243306562341166492672823, + 2300475954087415591738767759767032267163723345312082546282694920273655145455, + 1954000528502201000509342111010021527425422549437946241062907964768089317082, + 1179936151696782249912570883839105595634344582873818018332922940963046083567, + 3077707030301573630126144767923697288658782137457660869231140049571827937228, + ], + [ + 1062324397142900251844488719868780667589966366756786302007970554437994421840, + 353718609497993885193404630053532608155520921625518104461520254335222009911, + 770557645309607171206012551080400276506165720184677119001983749356594531977, + 3043628430985247363392058521341757139056029350680498644930013342982472853636, + 1694968537785457252742656255724723357998402478572600479401200420305593921487, + 539865665379093791531434211889371819368504193082947002067781562776138072582, + 3473466148775696692731190426971123680342615414200262605154732883324298196699, + 482783534456196983135936103604928650836406142744767857356485953118411089098, + 2389101033971236780034779577432189630800997581132154923233144722790749715251, + ], + [ + 845264223568475649981141803833883014312596504303895519674002924871878791033, + 3027004059915270231142566724881373969831662022738947178800901294120992473905, + 2169574859350740480088697859610203373582027214052754592019828328614087431593, + 3515527080764222354309565181793838292349410992793070639041305826153436624160, + 1817926918350512904327755405973355211358017834277255662858654992240629698587, + 1999148133619270973098477176176178514394558202995832714883251820350860287223, + 1203131300029280096510929599113528018338088236684405405384757591977164161039, + 336815403657101171302040383579077521911288747438919304948637997306314852594, + 986661060847815533035934253464295060766339947679669645818832311132001095573, + ], + [ + 2291116974939980228917916563988261327966840303336559854772343651559589512651, + 3421243089992476528970346847858594146122972226790673723411896208702859892637, + 1015505198663386486420800821559060487156096175034250154764824837183581949724, + 1165880582987807286271819576391581724550686829511475839624601920297855380101, + 904232961143172831178860280790910264843503022179578981166030973682571903458, + 261322216292849827900157598748641385787016033372999683866859675894253115357, + 3060676319159217735181388708455879854358158161989877552543698103915296690395, + 1175560144527845912984609340783959238735643215413930887771084560168082442967, + 2813871258576082360085006002528268796351819524936446195552260262614692343332, + ], + [ + 1841341101531851399935829271555098629075809587212843292354556374386667658235, + 3076135575511709688509914361447080149794919016880133063891720256749999834767, + 753111801049754117414662684453226478940731922961768343984187479992842213733, + 1405657437118503342762241742745888533114216548278983907019917904938403345580, + 3111186124713876864436867307979940633543281080828379725576742174555539054855, + 3404463650394703220454952017098727360005393139199301323890695570346564876407, + 2024087816190101179456573591359233695334184711688920998987373624570170649371, + 2770035625774572095496575568588054654502991645588385802705097377675051032967, + 437058215235292632621847481185406671372191763951486300610124033096831557414, + ], + [ + 1345792773780982398809956395232061067669190682958320579442454533085407626029, + 925357273912625669941681596445839316566672314870287993638671283923476231904, + 3288133122086768300615066039539687885053110015077924175836976549020438910830, + 666190075990703867784232802074474372379358766701681865975596503982238839889, + 2664898601165892062970298960258838238925231697327906221693001926762280012052, + 2075648691532387787722427044464731934171216054855867223374228487601569118337, + 3173725544188532489243684991828985285646224157242834030308807120745121062293, + 1517474443612606408422643323550409253700128234157734252330869178582583531320, + 1593950878945144789965609248470060076911813704207225832606804796819386297511, + ], + [ + 141195541167651298813588829225208004611326987855926870823948793274702167509, + 2990187949585642302497822222637786229364740008175968941859105979392907839776, + 2893807105405820282316438050347503569385510241526138409321358916388308586443, + 1379719211597875648759619903854862028510320482486109668868067715175935658353, + 2702780364788282233075255946852944970202849869091427738791947810055591218061, + 1825815734419326277729273926504439575157952821379179501821641713286627304656, + 1481344458867016048625916723816339719872443766684158199301690902395849166360, + 2014084774259125722186109781197998076881266739680534358898592778318128968629, + 2612744185006548312909661512508122065214170543806989291921289897662387203493, + ], + [ + 2486291022451231582267428921150634472835925206862678364689227838329114330247, + 812732996628201940153942564646101963400632767332933831280853155218614715080, + 126094682124221985399366764547520870230937998532279902936706662398013374632, + 2332759540678834650043926399670560164966577916323505669087388602300799707582, + 417191197992716013378878526313154771760403212629214986494703061292527233746, + 2089695210017423032908516519857821046462345030778030443813231752571445398074, + 880130585759037753170821264662529711124286445728744366574528249671219769601, + 1551035990733507525502194076713176690385235627749489730884099764718693503706, + 1132770671667828892358813462377576622449530992975751082967512658313635397452, + ], + [ + 3477222316243451282030967342870586692600879585927570762883148422885177880126, + 3080049058291678698646192553519619053497714415866410414497713306121117176090, + 1604321402782785895646105335040390686287908200515025966267355042491672981783, + 2640938714210250468234433425076241574348084323298050686514885419623248929027, + 2564203982856531683007231108444184587768076678433068616443890909754654594865, + 2687912506275217880298166892170509500356051948363672876435899024071099200810, + 219716020372543256705510422385089985052203154750380145485560690582749108271, + 343381723849000976990296963636087269772788073060444255835069282725333544849, + 2243474000809211591079032482624491823994182313028504837036812101739092732111, + ], + [ + 510707836913016174166098345624702361608064144458606006258116870045128076276, + 371395090737067725542496261329489402726694621471574145027700711252296092473, + 1063936043610565176608970195710082987360134144899399196834878551304512136122, + 544707720186375037932894106759995513684682995260807905779948137170231203256, + 1167581841056359475252426501351748170006442279406978740226100882821697834875, + 2550832549603049808978315522912244192974319892613157360685656734539894800744, + 3050015272873571595886269427380575861071080053492605497359904773596428774905, + 1011138952383662635782533249614710303961470589955599508778623276087024115070, + 630974866360574675289326518371838220431993802135457251698746676305736993797, + ], + [ + 203336260208331554126199732156890427228183089494661054698930408652944582869, + 3340804894119433054713915867442868712009757981630422971971299923461800531010, + 1840281959034802822119513086413059992309732805524856821387047633277185626649, + 2134263600932771904379797125986139141034552186204251021670285390319319224609, + 1275868496238635951012332018362897748265183406010767949984664721625592689653, + 298714102400683025652859857895440654863429901709343005052249120979010481936, + 2692659901233913137581770307185590409816893731730924291707794935777106832966, + 1840634421045406926833254909533036671121305540964021228789778425366681252995, + 2301592761308273654183075324044125709646473530671119594254101577087371615481, + ], + [ + 162723356986030017850051267522864501486478603105186334642960445150366835159, + 2729313679044114139039373945299938550926303502785599920261582606464605651657, + 3473586674725596522829788009544147142400278838876200185683456440105928043211, + 3138951724576997730121663279551894343616534419583092341951468898219423118787, + 2518000166374405494855134931903765294665875855550695091224928394843097721999, + 1338394176744138783874188781598471556143029818796535135036649234778643394639, + 1209841960776472733538070759590481368220441166797021843748599644926482551192, + 547004697865163135194331636776941053012397520037333871290549155075914424489, + 324118807277344035751385895835249523345046875466885854334962332443837176612, + ], + [ + 1524371018506881520083100261651593835154891789369269410049381152191875690939, + 2612389582313939197668814396193090302216660659216813115890918370127340511529, + 3505012887659783602149472050703708639076651779286533348447644142517552213881, + 1400071508461817921137460497127856799560450070978864352002725939967252706688, + 3270992342534985112288385686987052502194283383496380206690024960989162493923, + 2714867367702858160499089419828178114912802960429177662569393409273645078755, + 1813755227762834544802021422835497922586025826063870003206286391738798681111, + 612795972065596844152506740660641174406736839952197915229555506451133128130, + 92404824162871001762374781327909282618644308692517473968425500791518935532, + ], + [ + 1417481623983314082173247075936417600206988773674942350244937901220619611842, + 1436370808434979598032842810056550162095968799722845041329064542251550453786, + 2791141150236052110524344056689185069083340382119727545540275139412603089360, + 844354214878019955822026369142277289422931221816096016943788963230169488347, + 966099903169233717288359622432098994220421693645131311106275824127212467886, + 3377442662368132936445679305267583977275905253905155787275539847677282044250, + 2993456326224537444598366195723759444603769788792265111656341721542375533386, + 1212355518443369118612977724304634146835938372332839927952065713321849642541, + 1971134155048336439141258732599011979565847576850602548531879800493479147831, + ], + [ + 2948442673077096053644288919931275452410464348650015017531708506350479915604, + 2842500084084483780889596172799288044503195998225010948052696608993167985308, + 159223381676530488468791209323333278819534705147966277398763088689596796770, + 1421186706283245189365811773480897972940946260029092196036903184822788804231, + 1576285470010981292429990973639485653180449701200855282138032050861010979826, + 644590671463258847126424543613454651505385158151768911781893220267542566451, + 2088606836412636464057762283447107348222917265252172808200133192379971942897, + 524873106051539924609019910231823992913728344364154737926035425102983890829, + 1902681505875019185809103747479043540171029332608891955558485648212701710295, + ], + [ + 2963416888451418478934206047734203707107862076855090639174282886214224232590, + 2256582971290889516749138306472335755629812576115382520518177914027594030015, + 952631286373337347146679632202839367283048060646689702188339656311873403649, + 676315845378937954265378953256197854230739519367862813657736566229968723226, + 489890103843776265775697540842114573736731262399827559835772741174386638653, + 275533488137297947276426728685266658925238459497144024549786978615126697897, + 3150016598495782867686478036323002393045877380357220885467542798491995222254, + 352436965457163447430854610022316899237536952054748594528867151585026141786, + 3303745650390331235413694156771963791986347007401791376770303232959532224130, + ], + [ + 3149214618588432551359084716320073763219122664674260148633992401279648082354, + 2194350629476186786204506136350097947050675706035590195194968690821216220424, + 558554623896384781750289610086616338774638937494255437861496237046841126214, + 1543446181040850249298033079317080262236611263061632213418048205161606942147, + 2783413390060037392074504680410414696446404944828450566597893824525361890127, + 2055992183020561120315403073370680881768702383915559710733023236255354942657, + 1568126437333644302276753203048405726979844657094047665715779674342623405197, + 707829630087701305070694836599056258256708212664197066041097917026002238757, + 2252590435322323406991091749783982725297255831982560162740712198004279897382, + ], + [ + 3414277057275624795468645312087423885930770047317584725266868985293775275737, + 357330551708988499823018290671739176907440575701822465426819865189974521090, + 3428047733715021011877942034473291498039287445112813833854782803680278440069, + 1043945649053487250558788276777194197214478124443377987323772475971600044275, + 1469460322863003607492879995577086600157279186691895799194170097510240503657, + 3452262498977433534319003473019647409836444073689507898496981033471954432692, + 3534454944063490575696966502029196669843948083535861807335597891702775537827, + 504889234556666427889233485911235515725257826427678498358140222567732121951, + 3000171231450492275601684733270949816745478414622439992817489913400513187523, + ], + [ + 473344561036275427204696962792021746974763386915887274825159398998397905862, + 2824419001338463577395017363382176953618246862173422908321298916732698758844, + 276157303331122459506297710167780793574709801408053132694472091531940102749, + 1767126433744673966278949688006551627720382111902647199455335267288281901267, + 778371508129958354306029607285794841001216014731491483241343727697096386475, + 2060673543778466828658177786049207685932107709257715075623113635406654467437, + 2860676522337563081310698854721936478848971007435036567835120090773720175531, + 3262510727351750340714257327383552567238034386676492645712194002264757448395, + 410655350050585015766874351843827567003172548802452036490946608629058751392, + ], + [ + 2827263689224541190235861986546387369088898813374971256828640436727276698005, + 1514077354035963899080972727313056839216320711790777996707845654692177169187, + 3332693034467588550421472219898251786647881139569903770359697960255197152702, + 3007104381810802394459850070232929711131578783565218932138003600309376797560, + 2932665190269762050514701409323806367759614127088809581305948355211856774225, + 942718997016516390282229857310324888182449186393033984291316546136958214880, + 2400532728820810155472900377882395992265080162940855284148299631746964151358, + 3164457535483121098851726865918842879335471785231376367017871839011507508267, + 1648716579888909218649627372041449799693084010875307922394019079800491124582, + ], + [ + 1934242140720948438923230016033727738635573691594662657035348523706144094205, + 2277804048613250910599596855640203977755963614934292361665561843345094228215, + 384257561496636646053974451942543523264327608081620342679433477243420299887, + 3260489043524397625633128735671581987213312351572930450789041333382286287986, + 279070612286599450107875033190975910776325523870775266490876449750245961006, + 3039177956074048733638502357208417075028657457004224701487457659813896269304, + 100801392374135250696473401829025873649586861459235004636873589680068168268, + 3068313315437337860119595175381524901467292077170355679568672469120985400457, + 588106555382506420101915681098403724169724022909292234591243446113775667213, + ], + [ + 75961998937141302694836565258195150116524445334036399981735777128335626231, + 3608935017459267131172339836127755437145588647916492113428426907730795865883, + 3236051050769258590918696174706128197063353779612044163931711796204384140442, + 3309927932243836707712018365148108219947040055542050970773346172395444286249, + 1379227675723853968298581390344831397477249447398598089307837482927225003692, + 165323930210760061480244632239128995890332884701720423985079205737618806819, + 2475823599963409732228794431108330159053822701972775719440246821411564650255, + 1376060040501111569715383702072177789240761888589668356536964838748610100476, + 639562589140844568139692421566168917777089056646989753560446326200715692412, + ], + [ + 3047370481616622454565807419246844668173177741649030943476057844430253426974, + 157119619971929525114630944146035790688356535500319447899447824612040346959, + 334768068598928901187698267354645263248367437839430885400491100376105177886, + 2999613646055101445087772098885448626056438764387790604431631715210262174941, + 1785831512299493210816577583089927171421814238849132623068418504178963027261, + 3556427232337965902002928541133161872239549155497678192235799639847486128081, + 2706705509664080470135334444730395281633858323868911855455046340983814692442, + 1090032685324965784679005200475480950652104203125117840183419564468432429962, + 1643133985696466912534286392910255558561006040179601728596127987069390053398, + ], + [ + 329302266402754590484707677978873120801833097009157925591066388167548460499, + 3316146390500601487271157807207211278218758546448493160523681436395289596578, + 2681938433358942943244890941577285081894021667357031574395153239058209444370, + 2067238577865192134707566720384689533371052666609238015545263422229486503441, + 412271328458865646460658202874645860938234007453616435270989459945178575742, + 2792582012926756828075048145474984534641031685450421135557201667753387225745, + 1748970797169467371218114245079143620184931692562929567686648283505132220611, + 166779541379814762948723221977869577989885584102038142328172709132371681331, + 1718971763375134636721431116431428192605005483084769258631031214253921160980, + ], + [ + 1436299930616683933649301741282810391905249199327936803818840919613025561181, + 2875920053658101915307791237689797149489720357987960587785172376007584434320, + 3000419677058946947908410396971077371682245985518477892763489598681401633875, + 1413256889462498929924889839145044830455691930479604473324291964006718193824, + 1600037792097028101450492536163766343228131758192592850408010325038208202955, + 973329069775852414867971478549643476764552964842715137707967836988424245238, + 1532059311183943083612079860057298798791038692086469511686852327698505963951, + 3536283989096065939191562794433690513848336262934373276494028669651364247483, + 2857933688084893698076909605577507592108431187558278962904406878515580235662, + ], + [ + 272797172757537573756500804089931431567458327538136359626601095094674393789, + 1045128690302280255544899467208602865672882241540377152077343422905289886473, + 3200120615444753129485047842423681872983153371687851942437665480424097552125, + 1025504106593918423924677374205531716297332772439312979700130173307193552556, + 674744356851299206878268970096766963588578879328564441712019516838898725214, + 1609778216811431081637160306997709606840128097578777515247813601008686900086, + 2211108168491428594212055488285679191337293905665349430480096269957054835619, + 1649448666223104911635198423466058188469512490509406959796198664168543133217, + 906042547538983329548943206515268028717838344283002532670642274379411096098, + ], + [ + 1229127748324267899463769431290803696864996967654860904076344202160069493463, + 694606667190814467086988364564153489609585429943155940697798862416909775672, + 1592639805143717468246931300907904427290413949425546183468390441675978775915, + 1785889417608655647591163755998564561315877835275317710969378211469233762677, + 1294069132957389354328420391585032975441914042318792953068374097543807509412, + 3333159250628803611558441380150567856661970319200706984329458467559186869982, + 2540613736666787789838663064746964381154591884964937002054194336545461092103, + 548571630140346099455160001561583481829470352031172172187303295100627347516, + 1911163942566753468249199036645451742783432402725781069097124782802115980106, + ], + [ + 1566169741655466458474413484644134881358625195394589356140489347664430729712, + 3537610921555766838501849891871545683341751764656851439054690006669870438058, + 3437684618728223910218716316085312417744738173838414178575449857634206735809, + 813046346454172182455055202163272729806109580740226695044901450801095723347, + 3610194706672489217931552174319141024421992647209516204667924899348667966232, + 2833254168578771153639893877294157445446616980535004165034754727569676418284, + 2537294913318276985372537712808599671990782275925115219838135858224298511428, + 2816922400232890669178938382954868512735295101148126878852482432361899464987, + 1301373992639164019944638195915867572888563057894488037629343232815736054372, + ], + [ + 30269122686901999045330138769145373364975048768303424780970735525647821165, + 356159224955021099133353480091253648569344282023523558363785695606414127329, + 600052282626545768175547540446111435882695813436056853597197852957971840399, + 1393243493399833062127515217694874119383837723584497237702438024083005513462, + 1060805636629726176027688725545095691221039090692064592351486203173227943326, + 2398328949908225376099395729927210145814986308688252024886408510027141819624, + 1027281430870307091646645117465907486111170082857695053934837112758985550266, + 2076112470336619898923904084203384284604476596459703906533388026110854643018, + 2011367208019507875236050172752393113650516827864616858695277293233244879064, + ], + [ + 804914370429933356444378397674249095505369793966355853646960826760022114161, + 2158646815209463860645972884633545865640288974960112440598371987666489006884, + 498475102886462996118999389444894502654308137162019779967944609813637566383, + 809639446329314296425012620178736609148314475095887567348544422353931446975, + 1479303399819900931440438924175610717353979337636496822534532750338665492976, + 3352120878323955424343267265626086910157959907203377433787032992040430037562, + 1270511100947529781011301573057039194696255581414220718655391463906841072850, + 689572637145758895312302669022171294981059955204139497945712774253729662901, + 1122475403051339648113208296437614878373524580008296846892907280965803100853, + ], + [ + 641604857394585492096388516561146514646134317495133318214644239362918944492, + 2691745406199568825008867086882820691198132400226768616686473031978181982821, + 1224973224916812932131086832888498146195158041774775887347790037361473452887, + 811390898777213738295965818292524006980579206937824475304433419624727781766, + 347179045923147351917084398650647523202173801383372112704653398073975603306, + 1064303630400492693929054233571088398067218591522507955805149302992890156755, + 820775428855912251536626965649614471106898535301578322360574640298974311119, + 866208913555356501781019205528106643401044938943193294071944228004304549302, + 115514195249410651555209067838633330944755543155276857330146984494189992553, + ], + [ + 252132571003241182944439318634676914124325328500654373824736179436132089371, + 918322066933917466678813178614649697530783351299306085426569323961308925124, + 766241351978071228951162027086616534232672901288039218284796628577416567591, + 1448399122174431849352895941276893258430417332383946295306353017316599812215, + 2099501180164069593890241802207504080377984062090282167163890371487263686521, + 1887552197709345902087901490475127143068068193908591855053479609600129142802, + 3167283923390758228731408378921427738233030621434172014976298058876109690337, + 508686164551082010580548770287093053248626588000522267893396768354545495214, + 3415159336868755962995911546854123253932713316866684932328582276044712780080, + ], + [ + 2831764371933474979950779312697290760187312456589808951378180899857832717639, + 1117351349181189733963201040237413388935342858658594681119886010479394763185, + 1420344791206686908307768150171158359915730449074218990242033345804165106152, + 1643540202670912441608564328198635300607080830225622467080761959531637260283, + 293312804005180449748670778178943484555210705473649470857298453257087130492, + 1186610420650578375868363314506454226331822479524760138229035647427964051716, + 1604658647191427346279686363933966880959339124184041241721592313882511736515, + 484759536232313898380688503358640565178862575742191365809319629525339917683, + 3202333295994703685287153052574132921523738742185074162720736789148029449424, + ], + [ + 1482052875843241531506801762485775085498946225895688413744448806512449149440, + 3724080234815511809117978863691836504457082496928881122664133760178180146, + 1389819861647017358890044627050306908519765136528810636287568285183073838378, + 1650597890916495871025613583643303135348065935114713531218970063420664317715, + 3361948322900994977384185274742310354794641154846128654363051909595010663191, + 606490196811628907926303075392698205884777550525694322622323064115638852469, + 2845332504396589346252475371552863304647079482641751587397482230598384155358, + 2136828430137749250921158430711688663921763557428106393432189490194175179567, + 2603121009100851709852932766334245652675653582444315755067293083596931580826, + ], + [ + 331341793344080936914289344883827755990554515948269616129569306660131329876, + 3078553015281630483814449041146024345591301252745271183458843353665386810124, + 307120557953072399284510407921150554510564871245541060187779733591851206500, + 2468769428341458044041338885525841293986157073329084708921297873697537277061, + 3470102986790831831320168275548472759024412073013424117456470890923568538969, + 185827255675927000513450665380938300662293969530647403860544937994658162295, + 256271664887389285343316871108143200415579992975868778275807315123444726952, + 1827055151936672706000449563668403829196201809444560569513678578768485237432, + 2898288225310275494081066784169817323302183937007162941742624282571076879592, + ], + [ + 2933565141237935770655708722788647501044225819645114807459401410600171852640, + 3416738743454826738496238980980915871713488488457863319506383180688189671463, + 156745893443626187896900550568972819727951121030890394112507977664853175542, + 3283724874882640428716261630351374095091592321096542490875001878468100367248, + 2437699711294696051214668057488520183991546049686213568981682751196761460783, + 1998834570607981674297357653990763238896454745809690982734870906626522295154, + 1096540447778541492593738030843471118116491918916127095579472567515081351049, + 2356725096111069909664338128980658292799461131011049019345986278356452801509, + 90738053114808921116584031195849142116843713567626295867858407827355050172, + ], + [ + 1065221571786594381440761503832908269645361161878122237424095643997231918165, + 1195990087128285262618723047052073662178730708436833337766606931661022097316, + 1607656066508654163826809933503382885732073531823069358637346724301610536933, + 2762835966374533264573600731662570950931597693724669372026589278609779908826, + 568252961304618278068351441235345329515963995645432187413590888566600731843, + 2219805657753619149120152308036959543217034148877902141350385368124440712041, + 2471219352232612737870285149160422977220823386008501313407086981054125942755, + 1702471122844746764510101503246478299375527044876047633765906492860562956831, + 178158973845331048800858217907253266280421415417608633952918717073444360077, + ], + [ + 1153865633793723796061306601912013669438562849380300788791898894941171879867, + 41367034604651858530733678658849966577549188816983763821535989500367860237, + 3468975051489737167843258844554598541552116649054085165189896125507778910171, + 2718226429100290201519165335140959318567294079769437231856399422036987403743, + 3138264754325604917892008246627387480594766630821363896103414333654908043697, + 452694917214803822630598832696287753340679650820606009360737209240673463856, + 1603123741057766982141435126837412229530685362067398656593903838197297519053, + 1193792879975364000281064469466869157446260053337714451909340494648447350193, + 1476795076054263416671130521198457801904142955089395304031729663471081483546, + ], + [ + 1073394976549991982860753364875848742057830634187089640520544760304099031131, + 12007820177468184443440805587506371537708859344042925721341207902864618809, + 2766330776097073388321947747975321570195973271822057851486276882545982239753, + 3539344711396861622746089277246522492983047589590730311661029157147876642889, + 1287500281621363829200752319301391571585156066582693266650037160454386034877, + 2474809947251385063203264736234472955139417607514639842994842370459673548508, + 1090827000220799845492329208329070826899434713506318291045910946781450271361, + 1208187110975043071759413865930622508584020862848375297316149643463496236875, + 3522214401269180332717417631824364224045514177765449931933554174948245884611, + ], + [ + 1520517774829211001662571682209457816363819713230259186312785715386026455755, + 3275568251899007960490753034525695345933766783786462506645639429108202874328, + 2284202457616215888687289509591036742794255009337643292891811240272576571257, + 2535235268866803701211935534866064901669820704204096676755075835612783553811, + 2839362767432080323297677373074471944327172550510674458187351463893937186331, + 3214518375834512592348237126031721467989525832367883161733061449723999150118, + 2329153502403362970616671016159127522602040117124995198540583682232363600232, + 3420309094711218658809805672568522872905261668445363456494421365528062786202, + 2507088055041455218953393069901159963005432925013244799639700572631883052964, + ], + [ + 2337849307492087578069275925125951001032772332907054786449171586159384832918, + 2012877529169317654025016586577098886488733166479383497492969306904591860901, + 602600998694877711417647407990291934686569963025819634858931803310496018058, + 1249611543976194883260410167047725828859756934350285667009827661162016018291, + 3229907636814215019750421069714346697511848423032027955255403645470309231391, + 787676398981677674143810626114223934424207908341477909615732862612515545966, + 3612199473207000589199482562201460897465129412929949343688652779696356029557, + 1016987341341765579099676602014487273787741430354734798713650301682207364304, + 453098757122471941839930595635449763736620895751362257490774646281426254551, + ], + [ + 1815454752370767836141293008049135079113332486270031909177283437543495067754, + 3245282584545343616427404187943756711998110332856283245484853607901000314185, + 443658998885222442290100444193924612797825350037332845912258127128636142226, + 2108619171489959511807880889959477005490266295958693408076403061526818087511, + 1772985726030040403572787219827611302253866172284594261034874743437382906478, + 640937330264976783330810143989997808168068593798905934616975190899343822788, + 2510583208685524453846247712654458992765611568298269433587411758276442175782, + 2907552713090903183796057780443171522666351119543449331065433394645714665493, + 2986622054106443824712535411931198088564985346368672496084094702115400226223, + ], + [ + 2618489700742756590659194734210220484174095805234294064111190699593988824340, + 1200851025280500486687543486735444332101238719790882621083370551852942177405, + 3306552336993725925103654534726585806268627155326783889027144975342461127617, + 3063542570260634805676359492080386970739188902062508927103821964203448748899, + 693003505378768484084486563892808421476039758279021572360026314704091146922, + 113467301561825352691896838102538232200187791556817508708373190844915757366, + 1214962046792065614084887870531889414817599577403445208023676579375118127069, + 219931702697909218595054310136338280042135207117415972689708135890367124057, + 2299725564014674542353370738912933567417489814263486112453515707115807564270, + ], + [ + 260233584167947455747015104760292950169865361374862033890032346147682982796, + 1780703740221760375200878259448067950489014812793850013015302976245316733504, + 2383870415174999450723223179404916004092277121478278309206856807272068323684, + 2937368232441834976234008899358786418457138987041670332617183254283354637959, + 2406359435023651609603661114132143048786533960554882840039256768987182372852, + 231078778048132625678776643951718309707010835988578653090554806633307921704, + 3475656777772243062915421465950955719385799280836882507132736647388648674730, + 1783817692892336259314180968996727438415631857960427138819319518753916485748, + 2814669257730549796627382579560684008971866384238873984955778334212024900791, + ], + [ + 685104779919414425856369032641333716552797615502163759516808340297338511762, + 112000061235888205687323759599013614255254726193594344536758680799184184440, + 1477626103014375842350097316636436071769399650789122440526416121262928558251, + 2551281565031680325132974094806210499031206575513882264577066072598564161917, + 797886210833473888794489228430182508879229606374651803892833025542322720406, + 2999021120449110671151992783291563057172397738873336786308341776029203847275, + 2311005320858138335396404692971794918410784356925946357506788698318665827974, + 2631574241755945078711400023175991554794442449542407127074854924034466599792, + 89478174523017596977683654587638896709356120424128581716882648945742363180, + ], + [ + 628069625011893894806887911699948061285431249502284511487815354255836693104, + 978623052989028294483632751919797903497854881963346061391267437033166745237, + 3021230227659661694051613034230869483481817700949296440222134405801598221739, + 1156220034945735366820341156672851112857802387698985362915195492872975463012, + 2446404897023367563061392594018883328489149706775024742413333245691062894455, + 1244441075461083091497408546019267661034935144320653695946573784985579417781, + 539817108379313677761852492604530197489437745588702433813772949552343440727, + 3073648716268405480938581657784224314266703381723386131346496551049063861367, + 2709183972950951179036437040302528942114766487244535176623080235014108182997, + ], + [ + 787391019149521354373731971817315940033788745392581089786399279247910692226, + 1755559533401306548548040207182050322592808288955452051685841421921866320905, + 3213567648335950773542151377243862695348922745469514361721762984269360873571, + 2703912487522576350317016589444849742114403315933282695240096184576773846063, + 273813455408897951631497502332223109430025601208839182927658142888292721100, + 218163224303846270426737845311945689057427242572728992951873934167057934838, + 1764185184494493936071884936974760595087025165368964066687442881206262895565, + 2644149785756319632094735801614553177585742367501836729649700595851876818993, + 699326657338086091966713478713871722467849809868730193748776193820976180145, + ], + [ + 1118176189000254176761194276061708892166700652918775652400595344208362578057, + 2225054514565424910266955921511417653338574988258164518427057309914998035244, + 1818545623254888077335413379256467198727340831353087896078293590292347853522, + 3488506647515987999710532473612335745604073762819784803250746906631593725009, + 1075586378005576671344929828123726852667078929261341252356063364548347883072, + 1632174034024142215754978795278071217256737203073245281834060267799713628194, + 2472247059618781674374416681867329856736217646075691429217328692034780732241, + 3166691430454237912058115708595594506017768498279434006513941367108779424810, + 2276336540666271350049634783925295780447403042984180959998386955827218754396, + ], + ], +) diff --git a/test/stark/property.test.js b/test/stark/property.test.js index 97e16ad..eab8590 100644 --- a/test/stark/property.test.js +++ b/test/stark/property.test.js @@ -1,49 +1,51 @@ import { deepStrictEqual, throws } from 'assert'; -import { should } from 'micro-should'; +import { describe, should } from 'micro-should'; import * as starknet from '../../lib/esm/stark.js'; import * as fc from 'fast-check'; const FC_BIGINT = fc.bigInt(1n + 1n, starknet.CURVE.n - 1n); -should('Point#toHex() roundtrip', () => { - fc.assert( - fc.property(FC_BIGINT, (x) => { - const point1 = starknet.Point.fromPrivateKey(x); - const hex = point1.toHex(true); - deepStrictEqual(starknet.Point.fromHex(hex).toHex(true), hex); - }) +describe('starknet property', () => { + should('Point#toHex() roundtrip', () => { + fc.assert( + fc.property(FC_BIGINT, (x) => { + const point1 = starknet.ProjectivePoint.fromPrivateKey(x); + const hex = point1.toHex(true); + deepStrictEqual(starknet.ProjectivePoint.fromHex(hex).toHex(true), hex); + }) + ); + }); + + should('Signature.fromCompactHex() roundtrip', () => { + fc.assert( + fc.property(FC_BIGINT, FC_BIGINT, (r, s) => { + const sig = new starknet.Signature(r, s); + deepStrictEqual(starknet.Signature.fromCompact(sig.toCompactHex()), sig); + }) + ); + }); + + should('Signature.fromDERHex() roundtrip', () => { + fc.assert( + fc.property(FC_BIGINT, FC_BIGINT, (r, s) => { + const sig = new starknet.Signature(r, s); + deepStrictEqual(starknet.Signature.fromDER(sig.toDERHex()), sig); + }) + ); + }); + + should('verify()/should verify random signatures', () => + fc.assert( + fc.property(FC_BIGINT, fc.hexaString({ minLength: 64, maxLength: 64 }), (privNum, msg) => { + const privKey = privNum.toString(16).padStart(64, '0'); + const pub = starknet.getPublicKey(privKey); + const sig = starknet.sign(msg, privKey); + deepStrictEqual(starknet.verify(sig, msg, pub), true); + }) + ) ); }); -should('Signature.fromCompactHex() roundtrip', () => { - fc.assert( - fc.property(FC_BIGINT, FC_BIGINT, (r, s) => { - const sig = new starknet.Signature(r, s); - deepStrictEqual(starknet.Signature.fromCompact(sig.toCompactHex()), sig); - }) - ); -}); - -should('Signature.fromDERHex() roundtrip', () => { - fc.assert( - fc.property(FC_BIGINT, FC_BIGINT, (r, s) => { - const sig = new starknet.Signature(r, s); - deepStrictEqual(starknet.Signature.fromDER(sig.toDERHex()), sig); - }) - ); -}); - -should('verify()/should verify random signatures', () => - fc.assert( - fc.asyncProperty(FC_BIGINT, fc.hexaString({ minLength: 64, maxLength: 64 }), (privNum, msg) => { - const privKey = privNum.toString(16).padStart(64, '0'); - const pub = starknet.getPublicKey(privKey); - const sig = starknet.sign(msg, privKey); - deepStrictEqual(starknet.verify(sig, msg, pub), true); - }) - ) -); - // ESM is broken. import url from 'url'; if (import.meta.url === url.pathToFileURL(process.argv[1]).href) {