#makeTables.maple # # This file creates the .html tables of the data from the RSSS project. # ############################################################## interface(quiet=true): read(`HTML_Procedures.maple`): if not(type(Files,list)) then printf("\nThis file has 1 mode:\n"): printf(" maple -q -c \"Files:=[\\""Dir\\"",\\""problem\\"",\\""num Sols\\""]:\" makeTables.maple \n"): printf(" This reads the data file and makes the table. \n"): quit; fi: if nops(Files)<>3 then printf("\nThis file has 1 mode:\n"): printf(" maple -q -c \"Files:=[\\""Dir\\"",\\""problem\\"",\\""num Sols\\""]:\" makeTables.maple \n"): printf(" This reads the data file and makes the table. \n"): quit; fi: Files:=[convert(Files[1],string),convert(Files[2],string),convert(Files[3],string)]: Data_File:=sprintf("%s/%s.%s.data",Files[1],Files[2],Files[3]): Html_File:=sprintf("%s/%s.%s.html",Files[1],Files[2],Files[3]): ###################################################################################### # # Get the data aboput projections and preimages # read(Pointers): preimages:=Preimages[StringTools[Split](StringTools[Split](Data_File,".")[1],"/")[2]]: images:=Images[StringTools[Split](StringTools[Split](Data_File,".")[1],"/")[2]]: ###################################################################################### ######## This is for proper navigation of the pictures up:="../": ########################################################## read(Data_File): fixMachine(): TopPage:=sprintf("Fl%d.html",FlagVariety[nops(FlagVariety)]): TYPE:=flagType(FlagVariety): SortedConditions:=SortConditions(FlagVariety,EnumerativeProblem): ######################################################################### # # SortedConditions[0]: [n, k_1, k_2, ..., k_s], where # the variety is Fl(k_1, ..., k_s; n) # SortedConditions[k]: Grassmannian conditions with descent k, listed # in order of length # SortedConditions[n]: Non-Grassmannian conditions, in order of length # ######################################################################### necklaceSymbols:=makeNecklaceSymbols(): ######################################################################### # # This is a table of coloured symbols representing the conditions # for making the necklaces more visible # ######################################################################### file := fopen(Html_File,WRITE): fprintf(file, " \n"): fprintf(file, " \n"): fprintf(file, " Enumerative problem with %d ",NumberOfSolutions): fprintf(file, "solutions on Fl(%s) \n",TYPE): fprintf(file, " \n"): fprintf(file, " \n"): fprintf(file, " \n"): fprintf(file, "

Enumerative problem %s",ProblemString("Big",FlagVariety,EnumerativeProblem)): fprintf(file, " = %d ",NumberOfSolutions): fprintf(file, " on Fl(%s)

\n",TYPE): fprintf(file, " \n"): fprintf(file, "
\n"): ##################################################################### fprintf(file, " \n",TopPage,TYPE): fprintf(file, "
\n"): #################################################################### fprintf(file, "\n"): fprintf(file, " \n"): if nops(images)+nops(preimages)>0 then fprintf(file, " \n"): fprintf(file, " \n"): fi: fprintf(file, " \n \n
Experimental dataRelated Problems
\n"): #################################################################### # # Table of Experimental data # #################################################################### fprintf(file, " \n"): fprintf(file, " \n \n"): fprintf(file, " \n "): for i from (NumberOfSolutions mod 2) to NumberOfSolutions by 2 do fprintf(file, " ",i): if i mod 5 = 0 then fprintf(file, "\n "): fi: od: fprintf(file, " \n"): Sort:=inOrder(Necklaces, Table): for i from 1 to nops(Sort) do Necklace:=Necklaces[Sort[i]]: NecklaceString:=necklaceSymbols[EnumerativeProblem[1]]: for k from 1 to nops(Necklace) do for j from 1 to nops(Necklace) do if k=Necklace[j] then NecklaceString := sprintf("%s%s",NecklaceString,necklaceSymbols[EnumerativeProblem[j+1]]): fi: od: od: fprintf(file, " \n ",NecklaceString): j:=1: for Number in Table[Sort[i]] do fprintf(file, "", Number): if j mod 4 = 0 then fprintf(file, "\n "): fi: j:=j+1: od: fprintf(file, " \n"): od: fprintf(file, "
Number of Real Solutions
  Necklaces     %d  
  %s     %d  
\n"): ################################################################################## # # Makes the table of projected problems # ################################################################################## if nops(images)+nops(preimages)>0 then fprintf(file, "
\n"): #################################################################################### if nops(images)>0 then fprintf(file, " \n \n"): fprintf(file, " \n
Projections
\n"): fprintf(file, " \n"): fprintf(file, " "): for P in images do fprintf(file, " \n"): if nops(P[2])=2 then fprintf(file, " \n",flagType(P[2])): else if P[4]<>0 then fprintf(file, " \n",flagType(P[2])): else fprintf(file, " \n",flagType(P[2])): end if: fi: fprintf(file, " \n",P[4]): else fprintf(file, " \n"): end if: od: fprintf(file, "
VarietyProblem#
Fl(%s)",Directory(P[2]),titleString("",P[2],P[3],""),P[4]): fprintf(file, "Fl(%s)Fl(%s) %s \n",ProblemString("Small",P[2],P[3])): if P[4]<>0 then fprintf(file, " %d
\n"): fprintf(file, "
\n"): fi: ####################################################################################### if nops(preimages)>0 then fprintf(file, " \n \n",ProblemString("Small",FlagVariety,EnumerativeProblem)): fprintf(file, " \n
Problems fibred over\n"): fprintf(file, " %s
\n"): fprintf(file, " \n"): fprintf(file, " "): for P in preimages do fprintf(file, " \n"): if nops(P[2])=2 then fprintf(file, " \n",flagType(P[2])): else if P[4]<>0 then fprintf(file, " \n",flagType(P[2])): else fprintf(file, " \n",flagType(P[2])): end if: fi: fprintf(file, " \n",P[4]): else fprintf(file, " \n"): end if: od: fprintf(file, "
VarietyProblem#
Fl(%s)",Directory(P[2]),titleString("",P[2],P[3],""),P[4]): fprintf(file, "Fl(%s)Fl(%s) %s \n",ProblemString("Small",P[2],P[3])): if P[4]<>0 then fprintf(file, " %d
\n"): fprintf(file, "
\n"): fi: ####################################################################################### fi: fprintf(file, "
\n"): ################################################################################### read(Data_File): fixMachine(): HtmlConditions:=htmlConditions("Small",FlagVariety,EnumerativeProblem): fprintf(file, "
\n"): fprintf(file, "\n"): fprintf(file, " \n"): fprintf(file, " \n"): fprintf(file, "
\n"): fprintf(file, " \n"): fprintf(file, " \n"): fprintf(file, " "): fprintf(file, " "): fprintf(file, " "): fprintf(file, " \n"): n:=FlagVariety[nops(FlagVariety)]: for k in SortedConditions[0] do if k=n then color:=Color[black]: else color:=Color[COLOURS[n-3][k]]: fi: for w in SortedConditions[k] do fprintf(file, " \n "): fprintf(file, " \n", HtmlConditions[w]): fprintf(file, " \n",necklaceSymbols[w]): fprintf(file, " \n \n",Length(w)): od: od: fprintf(file, "
Key
ConditionNameSymbolCodimension
 ",color): for i from 1 to FlagVariety[nops(FlagVariety)-1] do fprintf(file, "%d",w[i]): od: fprintf(file, "  ",color): fprintf(file, "%s  %s  ",color): fprintf(file, "%d 
\n"): fprintf(file, "
Point Selection
\n"): fprintf(file, " \n",Files[2],Files[3]): fprintf(file, "
\n"): ##################################################################### fprintf(file, "
\n"): fprintf(file, "%s on %s\n",TimeString(PreTime+GroebnerTime+RealTime,Machine),Machine): ##################################################################### fprintf(file, "
\n"): NumberSolved:= sum(Table[1][ll],ll=1..nops(Table[1]))*nops(Necklaces): fprintf(file, "%s Polynomial systems solved\n",parseNumber(NumberSolved)): ##################################################################### fprintf(file, "
\n"): fprintf(file, "The coefficients of a typical eliminant had %d digits.
\n",trunc(CoefficientHeight)): BYTES:=trunc(CoefficientHeight*(NumberOfSolutions+1)+5*NumberOfSolutions-1): fprintf(file, "The typical eliminant had size %d bytes.\n",BYTES): ##################################################################### fprintf(file, "
\n"): fprintf(file, " This table automatically generated from the data in "): fprintf(file, "This File using ",Files[2],Files[3]): fprintf(file, "This Maple Script\n"): ##################################################################### fprintf(file, "
\n"): fprintf(file, " \n"): fprintf(file, "Created: %s",ssystem("date",1)[2]): fprintf(file, " \n"): fprintf(file, " \n"): fclose(file): quit;