Skip to content

Commit

Permalink
remove tests using gvinvariants and DanilovKhovanskii from StringTori…
Browse files Browse the repository at this point in the history
…cs, so installation will be easier
  • Loading branch information
mikestillman committed Jun 2, 2024
1 parent 3bbdb81 commit ef35220
Show file tree
Hide file tree
Showing 8 changed files with 44 additions and 28 deletions.
4 changes: 2 additions & 2 deletions CYToolsM2/PALPInterface.m2
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ export {

executableDir = "/Users/mike/src/git-from-others/PALPfromTGZ/palp-2.21/";

programPaths#"PALP" = executableDir;
--programPaths#"PALP" = executableDir;
PALP = findProgram("PALP", "poly.x -h")

programPaths#"poly.x" = executableDir;
--programPaths#"poly.x" = executableDir;
polyx = findProgram("poly.x", "poly.x -h")

-* Code section *-
Expand Down
5 changes: 4 additions & 1 deletion CYToolsM2/StringTorics/CYPolytope.m2
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,10 @@ cySetH11H21 = cyData -> (
(h11, h21)
)

rays CYPolytope := List => cyData -> cyData#"rays"
rays CYPolytope := List => {} >> opts -> cyData -> (
cyData#"rays"
)

dim CYPolytope := List => cyData -> dim polytope(cyData, "N")
degrees CYPolytope := List => cyData -> (
if not cyData.cache#?"glsm" then cySetGLSM cyData;
Expand Down
2 changes: 1 addition & 1 deletion CYToolsM2/StringTorics/CYTools.m2
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ moriConeCap CYToolsCY3 := Cone => X -> (
posHull transpose matrix mori
)

rays CYToolsCY3 := List => X -> (
rays CYToolsCY3 := List => {} >> o -> X -> (
filename := (getPolytopeFilePrefix X) | "/points.dat";
if not fileExists filename then return "points.dat doesn't exist for this CY";
rys := (lines get filename)/value/toList; -- format: one ray per line (with comma between values), first one is origin
Expand Down
2 changes: 1 addition & 1 deletion CYToolsM2/StringTorics/CalabiYauInToric.m2
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ normalToricVariety CalabiYauInToric := opts -> X -> (
-- TODO: this fails if the class group is torsion! (Fails: later it gives an inscrutable error...)
)

rays CalabiYauInToric := X -> rays cyPolytope X
rays CalabiYauInToric := List => {} >> o -> X -> rays cyPolytope X
max CalabiYauInToric := X -> X#"triangulation"

-- TODO: triangulation is used with 2 different pieces of data:
Expand Down
3 changes: 2 additions & 1 deletion CYToolsM2/StringTorics/GVInvariants.m2
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,8 @@ extremalCurveInvariant CalabiYauInToric := X -> (
partition(c -> classifyExtremalCurve(gvX, c, deglimit, degvec), mori)
///

TEST ///
"TEST"
///
-- Good test, TODO: place this back in once GVinvariants are working again.
-*
restart
Expand Down
25 changes: 14 additions & 11 deletions CYToolsM2/StringTorics/ToricCompleteIntersections.m2
Original file line number Diff line number Diff line change
Expand Up @@ -196,10 +196,11 @@ restart
assert(variety L === X)
assert(degree L == {1,1,2})

needsPackage "DanilovKhovanskii"
computeHodgeDeligne(-toricDivisor V)
oo#1
matrix for i from 0 to dim X list for j from 0 to dim X list (-1)^(i+j) * oo#(i,j)
-- TODO: ADD BACK IN once DanilovKhovanskii more functional
-- needsPackage "DanilovKhovanskii"
-- computeHodgeDeligne(-toricDivisor V)
-- oo#1
-- matrix for i from 0 to dim X list for j from 0 to dim X list (-1)^(i+j) * oo#(i,j)

-- want to be able to turn this into a CalabiYauInToric...
-- then we can check computations against each other too.
Expand All @@ -226,7 +227,8 @@ restart
///


TEST ///
"TEST"
///
-- DanilovKhovanskii
-*
restart
Expand Down Expand Up @@ -301,10 +303,11 @@ restart
hodgeDiamond X
hh^(1,2) X1 == 69

needsPackage "DanilovKhovanskii"
computeHodgeDeligne (-toricDivisor V) -- this is not the correct answer I think!
oo#1
matrix for i from 0 to dim X list for j from 0 to dim X list (-1)^(i+j) * oo#(i,j)
assert(hh^(1,2) Q == 69)
assert(hh^(1,1) Q == 3)
-- TODO: add back in once DanilovKhovanskii is in the system
-- needsPackage "DanilovKhovanskii"
-- computeHodgeDeligne (-toricDivisor V) -- this is not the correct answer I think!
-- oo#1
-- matrix for i from 0 to dim X list for j from 0 to dim X list (-1)^(i+j) * oo#(i,j)
-- assert(hh^(1,2) Q == 69)
-- assert(hh^(1,1) Q == 3)
///
6 changes: 4 additions & 2 deletions CYToolsM2/StringTorics/test.m2
Original file line number Diff line number Diff line change
Expand Up @@ -1509,7 +1509,8 @@ TEST ///
assert all(Vs, isSimplicial)
///

TEST ///
"TEST"
///
-- XXX
-*
restart
Expand Down Expand Up @@ -1596,7 +1597,8 @@ TEST ///
rays toricMoriCone X
hilbertBasis toricMoriCone X

gvInvariants(X, DegreeLimit => 10)
--TODO: reinstate this test
--gvInvariants(X, DegreeLimit => 10)

-- TODO: add tests for line bundles on X, and their cohomology.
///
Expand Down
25 changes: 16 additions & 9 deletions CYToolsM2/installThese.m2
Original file line number Diff line number Diff line change
@@ -1,21 +1,30 @@
-- To install StringTorics:
-- Do these lines in order.
restart
uninstallAllPackages()
restart
installPackage "IntegerEquivalences"
restart
installPackage "StringTorics"
check "IntegerEquivalences"
check "StringTorics"

-- At this point, GV invariants functions won't work yet, but everything else should.
-- To get GV invariants going, compile the code in ComputeGV
-- and place computeGV on your PATH.

-- to install DanilovKhovanskii
restart
uninstallPackage "DanilovKhovanskii"
restart
installPackage "DanilovKhovanskii"

-- Currently, GV invariants code not functional here, until we can get computeGV compiled and placed here...
-- I have commented out a few tests that use this. All the following tests run.
restart
check "IntegerEquivalences"
check "StringTorics"
check "DanilovKhovanskii"

-- PALP interface
-- for now, need to install PALP on your computer to use this.
-- to install the PALP interface
-- for now, need to install PALP on your computer to use this
-- (place the palp executables, e.g. poly.x, cws.x, on your PATH)
-- then:
restart
uninstallPackage "PALPInterface"
restart
Expand All @@ -24,5 +33,3 @@ restart
installPackage "PALPInterface" -- no documentation or tests at all
check "PALPInterface"

-- We can make a similar interface to GV invariants?
-- maybe called GromovWitten or GVInvariants.

0 comments on commit ef35220

Please sign in to comment.