(* Intersct.nb ---------------------------------------------------------- *) (* For nc = nstrt to nend, the intersections of two families of posets are written to files. *) (* Utility Needed: WriteLstOfLst[]. *) (* User needs to specify the directory, the starting size, the ending size, the 2 input families, and the output file family. *) (* Change the directory: *) SetDirectory["G:/.isis/home/c/a/cagann/public_html/Posets"]; << GenrlUtils.m; (* Change starting size: *) nstrt = 4; (* Change ending size: *) nend = 4; (* Change both the input families: *) fam1 = "Connets/connets"; fam2 = "dCmplts/dcmplts"; (* Change the output family: *) newfam = "Cnctdcs/cnctdcs"; Do[ inpt1 = ReadList[ StringJoin[fam1,ToString[nc]] ]; inpt2 = ReadList[ StringJoin[fam2,ToString[nc]] ]; WriteLstOfLst[ StringJoin[newfam,ToString[nc]], Intersection[inpt1,inpt2] ]; ,{nc,nstrt,nend}]; (* End of Intersct.nb. *)