if match("no-check-flag", teststring) then (
checkmsg("skipping", desc);
return true);
+ if (m := regex("(?<=no-check-architecture:)[^(\\n]*", teststring)) =!= null
+ then (
+ badarchs := apply(separate(", ", substring(m#0, teststring)),
+ s -> replace("^\\s*|\\s*$", "", s));
+ if member(version#"architecture", badarchs) then (
+ checkmsg("skipping", desc);
+ return true));
+
-- TODO: remove this when capture uses ArgQ
if usermode === not noinitfile then
-- try capturing in the same process
///
TEST ///
+-- no-check-flag #1903
kk = ZZ/32003
R = kk<|x,y,z,w|>
I = ideal {x*y-y*x-7*z*w-7*w*z, 3*x*z-4*y*w-3*z*x-4*w*y, 31*x*w+25*y*z+25*z*y-31*w*x, x*y+y*x-z*w+w*z, x*z+y*w+z*x-w*y, x*w-y*z+z*y+w*x}
///
TEST ///
+-- no-check-flag #1903
-- testing kernels
-*
restart
///
TEST ///
+-- no-check-flag #1903
-- support tests
-*
restart
TEST ///
-*
+ no-check-flag #2162
restart
needsPackage "CharacteristicClasses"
*-
TEST ///
-*
+ no-check-flag #2162
restart
needsPackage "CharacteristicClasses"
*-
TEST ///
-*
+ no-check-flag #2162
restart
needsPackage "CharacteristicClasses"
installPackage "CharacteristicClasses"
///
TEST /// -- singularLocus
+-- no-check-flag #1581
X10 = coincidentRootLocus(toList(10:1),ZZ/101,Variable=>x)
A10 = {{},{{10}},{{10}},{{9,1}},{{10}},{{7,3},{8,2},{9,1}},{{8,1,1}},{{10}},{{6,4},{7,3},{9,1}},{{8,2}},{{6,2,2},{6,3,1},{7,2,1},{8,1,1}},{{7,1,1,1}},{},{{5,5},{6,4},{9,1}},{{5,5},{7,3},{8,2}},{{5,4,1},{6,3,1},{8,1,1}},{{5,3,2},{6,2,2},{7,2,1}},{{5,2,2,1},{5,3,1,1},{6,2,1,1},{7,1,1,1}},{{5,5},{6,1,1,1,1}},{{6,4}},{{5,4,1}},{{7,3}},{{4,3,3},{4,4,2},{5,3,2},{5,4,1},{6,3,1},{7,2,1}},{{4,3,3},{4,4,1,1},{5,3,1,1},{7,1,1,1}},{{4,4,2},{6,2,2}},{{4,2,2,2},{4,3,2,1},{4,4,1,1},{5,2,2,1},{6,2,1,1}},{{4,2,2,1,1},{4,3,1,1,1},{4,4,2},{5,2,1,1,1},{6,1,1,1,1}},{{4,4,1,1},{5,1,1,1,1,1}},{{4,3,3}},{{5,3,2}},{{3,3,2,2},{3,3,3,1},{4,3,2,1},{5,3,1,1}},{{3,3,3,1},{4,3,1,1,1}},{{3,3,2,2},{4,2,2,2},{5,2,2,1}},{{3,2,2,2,1},{3,3,2,1,1},{3,3,2,2},{4,2,2,1,1},{5,2,1,1,1}},{{3,2,2,1,1,1},{3,3,1,1,1,1},{3,3,2,1,1},{4,2,1,1,1,1},{5,1,1,1,1,1}},{{3,3,1,1,1,1},{4,1,1,1,1,1,1}},{},{{2,2,2,2,2},{3,2,2,2,1}},{{2,2,2,2,1,1},{3,2,2,1,1,1},{4,4,2}},{{2,2,2,1,1,1,1},{3,2,1,1,1,1,1},{4,4,1,1}},{{2,2,1,1,1,1,1,1},{3,1,1,1,1,1,1,1}},{}}
assert(sort apply(apply(subsets X10,singularLocus),L -> sort apply(L,partition)) === sort apply(A10,sort))
-- TESTS
TEST /// -- Quadratic case: over QQ, RR, CC
+-- no-check-flag #1746
S = QQ[x1,x2,x3]
f = 1 - 8*x1*x2 - 4*x1*x3 - 100*x2^2 - 12*x2*x3 - x3^2 - 5*x1^2
M = first detRep(f, Tolerance => 1e-10)
///
TEST /// -- cholesky, randomPSD
+-- no-check-flag #1745
eps = 1e-15
A = randomPSD 5
E = eigenvectors(A, Hermitian => true)
///
TEST ///
+-- no-check-flag #2162
R1 = ZZ/32003[w,x,y,z,MonomialOrder => Lex]
J1 = ideal"
-2w2+9wx+8x2+9wy+9xy+6y2-7wz-3xz-7yz-6z2-4w+8x+4y+8z+2,
///
TEST ///
+-- no-check-flag #2205
setRandomSeed "10"
needsPackage "BGG"
S = ZZ/101[x_0..x_5] -- P^5
///
TEST /// -- groebnerWalk
+-- no-check-flag #1563
R1 = QQ[x,y,z, MonomialOrder=>Weights=>{1,1,10}]
I1 = ideal(y^2-x, z^3-x)
R2 = QQ[x,y,z, MonomialOrder=>Weights=>{10,1,1}]
--huneke2
TEST ///
-*
+ no-check-flag #2162
restart
loadPackage("IntegralClosure", Reload => true)
*-
///
TEST ///
+-- no-check-flag #2319
for g from 3 to 12 do (
for d from 3 to 5 do (
<<"(g,d,n) = "<<(g,d,0)<<endl;
///
TEST /// -- randomMukaiThreefoldContainingLine
+-- no-check-flag #2319
debug K3Surfaces;
K = ZZ/333331;
setRandomSeed 123456789
///
TEST ///
+-- no-check-flag #2319
for g from 3 to 7 do (
setRandomSeed 123456789;
<<"(g,d,n) = "<<(g,2,-2)<<endl;
///
TEST ///
+-- no-check-flag #2319
for g in {3,4,5,6,7,8,9} do (<<"g = "<<g<<endl; time K3 g);
///;
///
TEST ///
+-- no-check-flag #1064
R = QQ[x,r,v,u,b, MonomialOrder=>{Lex=>5}]
I = ideal(b^3-7*b^2+14*b-7,r^2-u*r+(-2*b^2+9*b-5)*u^2+b^2-4*b,x^2+(b-2)*x*r+r^2+b^2-4*b)
elapsedTime C = minprimes(I, Verbosity=>2);
///
TEST ///
+-- no-check-flag #1064
-- Over a tower of rings
R = QQ[b][u][x,r,v, MonomialOrder=>{Lex=>3}]
I = ideal(b^3-7*b^2+14*b-7,r^2-u*r+(-2*b^2+9*b-5)*u^2+b^2-4*b,x^2+(b-2)*x*r+r^2+b^2-4*b)
///
TEST ///
+-- no-check-flag #1064
-- this test occurs as a crash in github issue #190.
-- seems to work after recent changes to factory.
-- it might be too long for a test...
///
TEST ///
+-- no-check-flag #2162
ringP4 := ZZ/300007[a..e];
f = rationalMap minors(2,matrix {{a,b,c,d},{b,c,d,e}});
g = rationalMap(minors(2,matrix{{a,b,c},{b,c,d}}) + ideal e);
///
TEST///
+-- no-check-flag #2162
Phi = last graph rationalMap projectiveVariety({1},{4},ZZ/300007);
assert(multidegree(,Phi) == multidegree Phi)
assert(projectiveDegrees Phi == multidegree Phi)
///
TEST /// -- parametrizations 3
+-- no-check-flag #1539
needsPackage "SpecialFanoFourfolds";
debug SpecialFanoFourfolds;
checkInverseParametrization = X -> (
///
TEST /// -- Twisted cubic projections
+-- no-check-flag #2183
R = CC[x_0..x_3]
I = monomialCurveIdeal(R, {1,2,3})
F1 = random(R^1, R^{3:-1})
///
TEST ///
+-- no-check-architecture: arm (#2651)
-- check that there are not to many non-detected problems in the construction.
-- This code finds errors in codimension 4 with high probability
-- since 3^4 \approx 100
///
TEST ///
+-- no-check-architecture: arm (#2651)
-- check that the certification sometimes works
-- (only errors in codim 1 are detected)
setRandomSeed("alpha")
TEST ///
+-- no-check-flag #2162
-- union of coordinate axes in PP3 (diagonal)
-*
restart
TEST ///
-*
+ no-check-flag #2162
restart
needsPackage "SegreClasses"
*-
///
TEST ///
+-- no-check-flag #2162
-- union of coordinate axes in PP3 (diagonal)
-*
restart
TEST ///
-*
+no-check-flag #2162
restart
needsPackage "SegreClasses"
*-
TEST ///
-*
+no-check-flag #2162
restart
needsPackage "SegreClasses"
*-
TEST ///
-*
+no-check-flag #2162
restart
needsPackage "SegreClasses"
*-
TEST ///
-*
+no-check-flag #2162
restart
needsPackage "SegreClasses"
*-
TEST ///
-*
+no-check-flag #2162
restart
needsPackage "SegreClasses"
*-
TEST ///
-*
+no-check-flag #2162
restart
needsPackage "SegreClasses"
*-
///
TEST /// -- Corollary 2.2, p. 256 [GKZ]
+-- no-check-flag #2162
property = (M) -> (
M = transpose matrix M;
K := ZZ/33331; n := numRows M;
------------------------------------------------------------------------
TEST /// -- Test 0 -- cubic fourfolds from strings: describe, discriminant, parameterCount
+-- no-check-flag #2162
strIn := {"quintic del Pezzo surface", "quartic scroll", "3-nodal septic scroll", "one-nodal septic del Pezzo surface", "general cubic 4-fold of discriminant 38", "general cubic 4-fold of discriminant 42", "cubic 4-fold of discriminant 48"};
strOut := "Special cubic fourfold of discriminant 14
containing a (smooth) surface of degree 5 and sectional genus 1
///
TEST /// -- Test 1 (1/2) -- GM fourfolds from strings: describe, discriminant, parameterCount, toGrass
+-- no-check-flag #1539
strIn := {"sigma-plane", "rho-plane", "tau-quadric"};
strOut := "Special Gushel-Mukai fourfold of discriminant 10('')
containing a surface in PP^8 of degree 1 and sectional genus 0
///
TEST /// -- Test 2 (2/2) -- GM fourfolds from strings: describe, discriminant, parameterCount, toGrass
+-- no-check-flag #1539
strIn := {"cubic scroll", "quintic del Pezzo surface", "general GM 4-fold of discriminant 20"};
strOut := "Special Gushel-Mukai fourfold of discriminant 12
containing a surface in PP^8 of degree 3 and sectional genus 0
///
TEST /// -- Test 3 -- 21 examples from GMtables
+-- no-check-flag #1539
X = for i from 1 to 21 list (
A = GMtables(i,ZZ/65521);
time specialGushelMukaiFourfold((rationalMap(ideal A_0,Dominant=>2)) ideal A_1,InputCheck=>0)
///
TEST /// -- Test 4 -- parametrizations of Fano fourfolds
+-- no-check-flag #1539
setRandomSeed 0;
for dg in {(2,0),(3,1),(4,1),(5,1),(4,3),(6,4),(8,5),(10,6),(12,7),(14,8),(16,9),(18,10)} do (
<<"(d,g) = "<<dg<<endl;
///
TEST /// -- Test 6 (1/3) -- associated K3 surfaces
+-- no-check-flag #1539
f = last building associatedK3surface(specialCubicFourfold "quartic scroll",Verbose=>true);
assert(f#"image" =!= null and dim image f == 2 and degree image f == 14 and dim target f == 8)
///
TEST /// -- Test 7 (2/3) -- associated K3 surfaces
+-- no-check-flag #1539
g = last building associatedK3surface(specialCubicFourfold "quintic del Pezzo surface",Verbose=>true);
assert(g#"image" =!= null and dim image g == 2 and degree image g == 14 and dim target g == 8)
///
TEST /// -- Test 8 (3/3) -- associated K3 surfaces
+-- no-check-flag #2162
building associatedK3surface(specialGushelMukaiFourfold "tau-quadric",Verbose=>true);
///
TEST /// -- Test 9 -- simple tests on schubertCycle
+-- no-check-flag #1539
debug MultiprojectiveVarieties;
S = schubertCycle({2,2},GG(ZZ/33331,1,4),Standard=>true)
assert(idealOfSubvariety S == idealOfSubvariety tangentialChowForm(projectiveVariety ideal((Grass(0,4,ZZ/33331,Variable=>"x"))_0,(Grass(0,4,ZZ/33331,Variable=>"x"))_1),1,1))
///
TEST /// -- Test 11 (2/2) -- detectCongruence
+-- no-check-flag #1539
use Grass(1,4,ZZ/33331);
S31 = ideal(p_(3,4),p_(2,4),p_(1,4),p_(0,4),p_(2,3),p_(1,3),p_(1,2));
Y = specialGushelMukaiFourfold(S31,InputCheck=>0);
///
TEST /// -- Test 12 (1/2) -- GM fourfolds containing nodal surfaces
+-- no-check-flag #2162
debug SpecialFanoFourfolds;
K = ZZ/65521;
X = makeGMfromCurveOnSurfaceInP6((surface({2,0,0,0},K,ambient=>6)).cache#"takeCurve" (1,(0,0,0)),InputCheck=>0);
///
TEST /// -- Test 13 (2/2) -- GM fourfolds containing nodal surfaces
+-- no-check-architecture: s390x (#2162)
X = specialGushelMukaiFourfold("nodal surface of degree 11 and genus 3 with class (7,4)",ZZ/33331,InputCheck=>0);
assert(discriminant X == 26 and last cycleClass X == (7,4) and degree surface X == 11 and sectionalGenus surface X == 3);
Y = specialGushelMukaiFourfold("nodal D44",ZZ/33331,InputCheck=>0);
///
TEST /// -- Test 15
+-- no-check-flag #1539
debug SpecialFanoFourfolds
L = takeGMsfromSurfaceInP6(surface({3,1,1,0},ambient=>6),InputCheck=>0,"Gluing"=>"cubic scroll",Degrees=>hashTable{1=>(1,1),2=>(19,infinity),3=>(0,0)});
X = first L;
--11
TEST /// --lowerBound
+-- no-check-flag #1579
debug needsPackage "SumsOfSquares"
results := checkLowerBound("CSDP")
assert all(results,t->t=!=false);
)
TEST///
+-- no-check-flag #1984
R1 = QQ[x_0..x_3];
R2 = QQ[z_0..z_2];
R = superRing(R1, R2);
)
TEST ///
+-- no-check-flag #1984
R1 = QQ[x_0..x_3];
R2 = QQ[z_0..z_2];
R = superRing(R1, R2);