sympow: add sage self tests

This commit is contained in:
George Huebner 2024-07-21 14:47:15 -05:00
parent 240ca368e5
commit a9f9650802
No known key found for this signature in database

View File

@ -59,10 +59,17 @@ stdenv.mkDerivation rec {
# Example from the README as a sanity check.
doInstallCheck = true;
installCheckPhase = ''
export HOME=$TMPDIR
"$out/bin/sympow" -sp 2p16 -curve "[1,2,3,4,5]" | grep '8.3705'
'';
installCheckPhase =
''
export HOME=$TMPDIR
"$out/bin/sympow" -curve "[1,2,3,4,5]" -moddeg | grep 'Modular Degree is 464'
echo "[1,-1,0,-79,289]" | "$out/bin/sympow" -analrank | grep ^"Analytic Rank is 4"
"$out/bin/sympow" -curve "[1,-1,0,-79,289]" -analrank | grep ^"Analytic Rank is 4"
"$out/bin/sympow" -curve "[0,1,1,-2,0]" -analrank | grep ^"Analytic Rank is 2"
''
+ lib.optionalString (!stdenv.isAarch64) ''
"$out/bin/sympow" -sp 2p16 -curve "[1,2,3,4,5]" | grep '8.3705'
'';
meta = {
description = "Compute special values of symmetric power elliptic curve L-functions";