From 050a5770950c94660cf7d686f2aca4ed2c5ac091 Mon Sep 17 00:00:00 2001 From: MITSUNARI Shigeo Date: Sun, 28 Feb 2021 18:00:51 +0900 Subject: [PATCH] look prime behavior --- misc/snark-p.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 misc/snark-p.py diff --git a/misc/snark-p.py b/misc/snark-p.py new file mode 100644 index 0000000..8168f3b --- /dev/null +++ b/misc/snark-p.py @@ -0,0 +1,13 @@ +p=21888242871839275222246405745257275088696311157297823662689037894645226208583 + +print("over 253 bit") +for i in range (10): + print(i, (p * i) >> 253) + +def maxarg(x): + return x // p + +print("maxarg") +for i in range(16): + print(i, maxarg(i << 253)) +