Skip to content

Commit

Permalink
Fixed wrong answer for tau for alternating knots when epsilon = -1
Browse files Browse the repository at this point in the history
Reported by Kyle Hayden.  Tested by doing RII moves on alternating knots
to make them nonalternating and then applying the general algorithm.
  • Loading branch information
NathanDunfield committed Apr 18, 2021
1 parent 544f6f3 commit fee0ad7
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 25 deletions.
37 changes: 16 additions & 21 deletions ComputeHFKv2/Alternating.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -190,9 +190,22 @@ void KnotFloerForAlternatingKnots(PlanarDiagram Diag, ostream & os)
else os<<"Fibered : No\n";
if(LSpaceKnot) os<<"L-space knot : Yes\n";
else os<<"L-space knot : No\n";
os<<"Tau : "<<delta<<endl;
os<<"Nu : "<<delta<<endl;
int epsilon=0; if(delta >0) epsilon=1; if(delta<0) epsilon=-1;
int epsilon, tau, nu;
tau = delta;
if(delta > 0){
epsilon = 1;
nu = delta;
}
if(delta == 0){
epsilon = 0;
nu = 0;
}
if(delta < 0){
epsilon = -1;
nu = delta + 1;
}
os<<"Tau : "<<tau<<endl;
os<<"Nu : "<<nu<<endl;
os<<"Epsilon : "<<epsilon<<endl;
}

Expand All @@ -204,23 +217,5 @@ void KnotFloerForAlternatingKnots(PlanarDiagram Diag, ostream & os)























21 changes: 18 additions & 3 deletions ComputeHFKv2/PyWrapper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -153,16 +153,31 @@ static py::object KnotFloerForAlternatingKnotsAsDict(PlanarDiagram Diag, int pri
int MaxAlex = -(*Range.begin()).first;
int LeadingCoeff = (*Range.begin()).second;

int epsilon, tau, nu;
tau = delta;
if(delta > 0){
epsilon = 1;
nu = delta;
}
if(delta == 0){
epsilon = 0;
nu = 0;
}
if(delta < 0){
epsilon = -1;
nu = delta + 1;
}

return std::map<std::string, py::object>{
{ "modulus", prime },
{ "ranks", ranks },
{ "total_rank", TotalRank },
{ "seifert_genus", MaxAlex / 2 },
{ "fibered", (LeadingCoeff == 1 || LeadingCoeff == -1) },
{ "L_space_knot", LSpaceKnot },
{ "tau", delta },
{ "nu", delta },
{ "epsilon", (delta > 0) - (delta < 0) } };
{ "tau", tau },
{ "nu", nu },
{ "epsilon", epsilon } };
}

// The one and only function exported by this module.
Expand Down
2 changes: 1 addition & 1 deletion python_src/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
__version__ = '1.0.1'
__version__ = '1.0.2'

from .hfk import pd_to_morse, pd_to_hfk

0 comments on commit fee0ad7

Please sign in to comment.