diff --git a/latextable.py b/latextable.py index 086be7b5ccbd8ae8710f9c5760df19452fb4e919..d186870fe7b1e3945436d6a9b8e72c9abf70d0d9 100644 --- a/latextable.py +++ b/latextable.py @@ -34,7 +34,7 @@ syn = { "homotopycontinuation": "HomotopyContinuation.jl", "macaulay2": "Macaulay2", "sirocco": "SIROCCO", - "pathjump": "jump", + "pathjump": "jump.", "maxwmeanprec": "w. mean", "maxprec": "max.", } diff --git a/synthesize.sage b/synthesize.sage index db8b924a930f48ea112fff1a5c32fba9c69e64b5..2eb8a3053eed7d27fc6632908371b00f50c1bb46 100644 --- a/synthesize.sage +++ b/synthesize.sage @@ -158,15 +158,18 @@ def degrees(data): return [A(f).subs(t=0).degree() for f in d["system"]] # takes a list of degrees + + def tot_degree(degrees): deg_dict = {} for d in degrees: if d not in deg_dict: deg_dict[d] = 0 deg_dict[d] += 1 - + return "$" + " \\cdot ".join([f"{d}" + f"^{{{deg_dict[d]}}}"*(deg_dict[d] > 1) for d in deg_dict if d > 1]) + "$" + def instructions(data, derivative=False): function = "f" if not derivative else "df" for pkg in ["algpath", "adaptive"]: @@ -184,9 +187,18 @@ def name(data): else: name = data_names[0] - name = name.split("-")[0] + type = name.split("-") + if type[0] == "wilkinson": + name = f"$W_{{{type[2]}}}" + " + 1"*(type[1] == "eps") + "$" + elif type[0] == "clustered": + name = type[0] + f" ({type[1]}, {type[2]}, {type[3]})" + elif type[0] == "sumpowlin": + name = "structured" + else: + name = type[0] + name += " *"*("random" in data) + \ - " \\textsuperscript{N}"*("newton" in data) + " \\textsuperscript{F}"*("factorized" in data) + " \\textsuperscript{N}"*("newton" in data) return name @@ -205,12 +217,14 @@ data_stats = { "htype": lambda data: "N" if data.split("_")[0] == "newton" else ("T" if data.split("_")[0] == "linear" else "?") } + def median(L): if L: return numpy.median(L) else: return None + result_stats = { "failures": lambda res: "\\textbf{" + str(res["failures"]) + "}" if res["failures"] != 0 else "", "tottime": lambda res: time_format_2(res["overheadtime"]) if "overheadtime" in res else time_format_2(res["time"]), @@ -222,8 +236,8 @@ result_stats = { "meansteps": lambda res: steps_format(round(numpy.mean([int(p) for p in res["steplist"] if p is not None]), 1)), "stdsteps": lambda res: steps_format(round(numpy.std([int(p) for p in res["steplist"] if p is not None]), 1)), "medsteps": lambda res: steps_format(median([int(p) for p in res["steplist"] if p is not None])), - "minsteps": lambda res: steps_format(min([int(p) for p in res["steplist"] if p is not None], default = None)), - "maxsteps": lambda res: steps_format(max([int(p) for p in res["steplist"] if p is not None], default = None)), + "minsteps": lambda res: steps_format(min([int(p) for p in res["steplist"] if p is not None], default=None)), + "maxsteps": lambda res: steps_format(max([int(p) for p in res["steplist"] if p is not None], default=None)), "q1steps": lambda res: steps_format(round(numpy.quantile([int(p) for p in res["steplist"] if p is not None], 0.25), 1)), "q3steps": lambda res: steps_format(round(numpy.quantile([int(p) for p in res["steplist"] if p is not None], 0.75), 1)), "maxprec": lambda res: str(max([int(p) for p in res["maxpreclist"]])), diff --git a/tables/issac_2025/entries.json b/tables/issac_2025/entries.json index 6cfd0ce15a8857686a51c3e4c0b90b7c6909a5af..669c3c7b6ebe97a96db034630815a838ba9e9e99 100644 --- a/tables/issac_2025/entries.json +++ b/tables/issac_2025/entries.json @@ -17,7 +17,7 @@ "clustered-10-5-10/1" ], "packages": [ - "homotopycontinuation" + "homotopycontinuation" ], "header": { "val": "root", @@ -50,17 +50,12 @@ "children": [] }, { - "val": "steps", - "children": [ - { - "val": "medsteps", - "children": [] - }, - { - "val": "maxsteps", - "children": [] - } - ] + "val": "medsteps", + "children": [] + }, + { + "val": "maxsteps", + "children": [] } ] }, @@ -72,33 +67,19 @@ "children": [] }, { - "val": "prec", - "children": [ - { - "val": "maxprec", - "children": [] - }, - { - "val": "maxwmeanprec", - "children": [] - } - ] + "val": "maxprec", + "children": [] }, { - "val": "steps", - "children": [ - { - "val": "medsteps", - "children": [] - }, - { - "val": "maxsteps", - "children": [] - } - ] + "val": "medsteps", + "children": [] + }, + { + "val": "maxsteps", + "children": [] } ] } ] } -} +} \ No newline at end of file