/
New Improvements in Optimal Rectangle Packing Eric Huang and Richard E New Improvements in Optimal Rectangle Packing Eric Huang and Richard E

New Improvements in Optimal Rectangle Packing Eric Huang and Richard E - PDF document

stefany-barnette
stefany-barnette . @stefany-barnette
Follow
458 views
Uploaded On 2014-12-20

New Improvements in Optimal Rectangle Packing Eric Huang and Richard E - PPT Presentation

Korf Computer Science Department University of California Los Angeles Los Angeles CA 90095 ehuangcsuclaedu korfcsuclaedu Abstract The rectangle packing problem consists of 64257nd ing an enclosing rectangle of smallest area that can contain a given ID: 26900

Korf Computer Science Department

Share:

Link:

Embed:

Download Presentation from below link

Download Pdf The PPT/PDF document "New Improvements in Optimal Rectangle Pa..." is the property of its rightful owner. Permission is granted to download and print the materials on this web site for personal, non-commercial use only, and to display it on your personal computer provided you do not modify the materials and that you retain all copyright notices contained in the materials. By downloading content from our website, you accept the terms of this agreement.


Presentation Transcript

NewImprovementsinOptimalRectanglePackingEricHuangRichardE.KorfComputerScienceDepartmentUniversityofCalifornia,LosAngelesLosAngeles,CA90095ehuang@cs.ucla.edu,korf@cs.ucla.eduTherectanglepackingproblemconsistsof“nd-inganenclosingrectangleofsmallestareathatcancontainagivensetofrectangleswithoutoverlap.Ouralgorithmpicksthe-coordinatesofalltherectanglesbeforepickinganyofthe-coordinates.Forthe-coordinates,wepresentadynamicvari-ableorderingheuristicandanadaptationofaprun-ingalgorithmusedinprevioussolvers.Wethentransformtherectanglepackingproblemintoaper-fectpackingproblemthathasnoemptyspace,andpresentinferencerulestoreducetheinstancesize.Forthe-coordinateswesearchaspacethatmodelsemptypositionsasvariablesandrectanglesasval-ues.Oursolverisover19timesfasterthanthepre-viousstate-of-the-artonthelargestproblemsolvedtodate,allowingustoextendtheknownsolutionsforaconsecutive-squarepackingbenchmarkfrom=27to1IntroductionGivenasetofrectangles,ourproblemisto“ndallenclosingrectanglesofminimumareathatwillcontainthemwithoutoverlap.Werefertoanenclosingrectangleasabounding.TheoptimizationproblemisNP-hard,whiletheprob-lemofdecidingwhetherasetofrectanglescanbepackedinagivenboundingboxisNP-complete,viaareductionfrombin-packingngKorf,2003.Theconsecutive-squarepackingbenchmarkisasimplesetofincreasinglydif“cultbench-marksforthisproblem,wherethetaskisto“ndtheboundingboxesofminimumareathatcontainasetofsquaresofsizes1x1,2x2,...,uptooKorf,2003.Forexample,Figure1isanoptimalsolutionfor=32.Weusethisbenchmarkherebutnoneofthetechniquesintroducedinthispaperarespe-ci“ctopackingsquaresasopposedtorectangles.Rectanglepackinghasmanypracticalapplications.Itap-pearswhenloadingasetofrectangularobjectsonapalletwithoutstackingthem,andalsoinVLSIdesignwhererect-angularcircuitcomponentsmustbepackedontoarectangu-larchip.Variousothercuttingstockandlayoutproblemsalsohaverectanglepackingattheircore. Figure1:AnoptimalsolutionforN=32withaboundingboxof85x135. (a)Compulsorypartofa5x2atx=[0,2] (b)Assigninga4x2to[0,2].Figure2:Examplesofcompulsorypartsandintervals.2PreviousWorkKorff2003]dividedtherectanglepackingproblemintotwosubproblems:theminimalboundingboxproblemandthecontainmentproblem.Theformer“ndsaboundingboxofleastareathatcancontainagivensetofrectangles,whilethelattertriestopackthegivenrectanglesinagivenboundingbox.Thealgorithmthatsolvestheminimalboundingboxproblemcallsthealgorithmthatsolvesthecontainmentprob-lemasasubroutine.2.1MinimalBoundingBoxProblemAsimplewaytosolvetheminimalboundingboxproblemisto“ndtheminimumandmaximumareasthatdescribethesetoffeasibleandpotentiallyoptimalboundingboxes.Boundingboxesofalldimensionscanbegeneratedwithar-easwithinthisrange,andthentestedinnon-decreasingorderofareauntilallfeasiblesolutionsofsmallestareaarefound.Theminimumareaisthesumoftheareasofthegivenrectan-gles.Themaximumareaisdeterminedbytheboundingboxofagreedysolutionfoundbysettingtheboundingboxheighttothatofthetallestrectangle,andthenplacingtherectanglesinthe“rstavailablepositionwhenscanningfromlefttoright,andforeachcolumnscanningfrombottomtotop.2.2ContainmentProblemKorfss2003]absoluteplacementapproachmodeledrectan-glesasvariablesandemptylocationsintheboundingboxasvalues.Mof“ttandPollackss2006]relativeplacementap-proachusedavariableforeverypairofrectanglestorepresenttherelationsabove,below,left,andright.Absoluteplace-mentwasfasterthanrelativeplacementplacementKorfetal.,2009whichinturnwasfasterthanthemethodsofClautiauxetal.al.2007]andBeldiceanuetal.al.2008].SimonisandOSullivann2008]usedClautiauxetal.ss2007]variableorderwithadditionalconstraintsfromBeldiceanuetal.al.2008]togreatlyoutperformKorfetal.ssolverr2009].TheyusedPrologsbacktrackingenginetosolveasetofconstraintswhichtheyspeci“edpriortothesearcheffort.They“rstassignedthe-coordinatesofalltherectanglesbeforeanyofthe-coordinates.Sinceweusesomeoftheseideas,wereviewthemhere.SimonisandOSullivann2008]usedtwosetsofredundantvariablesforthe-coordinates.The“rstsetofvariablescorrespondtointervalsŽwherearectangleisassignedanintervalof-coordinates.Intervalsizesarehand-pickedforeachrectanglepriortosearch,andtheyinduceasmallerrect-anglerepresentingthecommonintersectingareaofplacingtherectangleinanylocationintheintervalalBeldiceanual.,2008.Largerintervalsresultinweakerconstraintprop-agation(lesspruning)butasmallerbranchingfactor,whilesmallerintervalsresultinstrongerconstraintpropagationbutalargerbranchingfactor.AsshowninFigure2b,a4x2rectangleassignedanintervalof[0,2]consumes2unitsofareaateach-coordinatein[2,3],representedbythedoubly-hatchedarea.Thiscom-pulsorypro“leŽŽBeldiceanuetal.,2008isaconstraintcom-montoallpositionsons,2]oftheoriginal4x2rectan-gle.Iftherewerenofeasiblesetofintervalassignments,thentheconstraintwouldsaveusfromhavingtotryindividualvalues.However,ifwedo“ndasetofintervalassignments,thenwemustsearchforasetofsingle-coordinateval-ues.SimonisandOSullivann2008]usedatotalofvari-ables,assigning(inorder)-intervals,single-coordinates,-intervals,and“nallysingle-coordinates.3OverallSearchStrategyWeseparatethecontainmentproblemfromtheminimalboundingboxproblem,anduseKorfetal.ss2009]al-gorithmtosolvethelatterproblem.LikeSimonisandOSullivann2008],weassignall-coordinatespriortoanycoordinates,anduseintervalvariablesforthe-coordinates.Wesetarectanglesintervalsizeto0.35timesitswidth,whichgaveusthebestperformance.Finally,wedonotuseintervalvariablesforthe-coordinates.Alloftheremainingideaspresentedinthispaperareourcontributions.AlthoughweusesomeideasusedbySimonisandOSullivann2008],wedonottakeaconstraintprogrammingapproachinwhichallconstraintsarespeci“edtoageneralpurposesolverlikeProlog,priortothesearcheffort.Instead,wehaveimplementedourprogramfromscratchinC++,al-lowingustoeasilychoosewhichconstraintsandinferencestouseatwhattime,andgivingusmore”exibilityduringsearch.Forexample,aswewillexplainlater,wemakedifferentin-ferencesdependingonthepartialsolution.Weimplementedachronologicalbacktrackingalgorithmwithdynamicvariableorderingandforwardchecking.Ouralgorithmworksinthreestagesasitgoesfromtherootofthesearchtreedowntotheleaves:1.It“rstworksonthe-coordinatesinamodelwherevariablesarerectanglesandvaluesare-coordinatelo-cations,usingdynamicvariableorderingbyareaandaconstraintthatdetectsinfeasiblesubtrees.2.Foreach-coordinatesolutionfound,itconductsaper-fectpackingtransformation,appliesinferencerulestoreducethetransformedproblemsize,andderivesconti-guityconstraintsbetweenrectangles.3.Itthensearchesforasetof-coordinatesinamodelwherevariablesareemptycornersandvaluesarerect-angles.4AssigningX-CoordinatesForthe-coordinates,weproposeadynamicvariableorderandaconstraintadaptedfromKorfss2003]wasted-spacepruningheuristic.Foraboundingboxofsizeweuse anarrayofsizerepresentingtheamountofavailablespaceinthecolumnateach-coordinate(i.e.,minusthesumoftheheightsofallrectanglesoverlapping).Thearrayallowsustoquicklytestifarectanglecan“tinanygivencolumn.4.1VariableOrderingByAreaOurvariableorderisbasedontheobservationthatplacingrectanglesoflargerareaismoreconstrainingthanplacingthoseofsmallerarea.Atalltimesthevariableorderingheuristicchoosesfromamongtheintervalandthesingleco-ordinatevariables.Figure2ashowsthecompulsorypartin-ducedbyassigninga5x2rectanglethe-interval[0,2].Atthispoint,wecaneitherassignasingle-coordinatetothe5x2,orassignanintervaltoanotherrectangleandplaceitscompulsorypart.Wealwayspickthevariablewhoseassign-mentconsumesthemostarea.Forexample,assigningasin-gle-coordinatetothe5x2rectanglewouldforcethecon-sumptionof4moreunitsofareacomparedtoFigure2a.Wealsorequirethatarectanglesintervalassignmentbemadebeforeweconsiderassigningitssingle-coordinate.Althoughourbenchmarkhasanorderingofsquaresfromlargesttosmallest,wealsomustconsiderintervalassign-mentsthatinducenon-squarecompulsoryparts.Further-more,duringsearchwemayruleoutsomesinglevaluesofanintervalalreadyassigned,increasingtheareaofthecom-pulsorypart,soavariableorderbyareamustbedynamic.4.2PruningInfeasibleSubtreesThepruningheuristicthatwedescribebelowisaconstraintthatcapturesthepruningbehaviorofKorfss2003]wasted-spacepruningalgorithm,adaptedtotheone-dimensionalcase.Givenapartialsolution,Korfsalgorithmcomputedalowerboundontheamountofwastedspace,whichwasthenusedtopruneagainstanupperbound.Inourformulation,wedontcomputeanyboundsandinsteaddetectinfeasibilitywithasingleconstraint.Asrectanglesareplacedintheboundingbox,theremain-ingemptyspacegetschoppedupintosmall,irregularregions.Soontheemptyspaceissegmentedintosmallenoughchunksthattheycannotaccommodatetheremainingunplacedrect-angles,atwhichpointwemaypruneandbacktrack.AssumeinFigure2awechose-coordinatesfora3x2rectangleina6x3boundingbox.Withoutany-coordinatesyet,weonlyknowthat2unitsofareahavebeenconsumedineachofthecolumnswherethe3x2rectanglehasbeenplaced.Wetrackhowmuchemptyspacecan“trectanglesofaspeci“cheight.Here,thereare9emptycells(unitsofareaofemptyspace)thatcan“texactlyitemsofheight3,and3emptycellsthatcan“texactlyitemsofheight1.Foreverygivenheight,theamountofspacethatcanac-commodaterectanglesofheightorgreatermustbeatleastthecumulativeareaofrectanglesofheightorgreater.As-sumewestillhavetopacka2x3anda2x2rectangle.Thus,thetotalareaofrectanglesofheighttwoorgreateris10.Theemptyspaceavailablethatcanaccommodaterectanglesofheighttwoorgreateris9.Thereforewecanpruneandback-track.Ifwepickedaheightof1insteadof2,wewouldntviolatetheconstraint,sowemustcheckallpossibleheightsforconstraintviolations.Wecheckthisconstraintafterevery-coordinateassignment.5PerfectPackingTransformationForevery-coordinatesolution,wetransformtheprobleminstanceintoaperfectpackinginstancebeforeworkingonthe-coordinates.Aperfectpackingproblemisarectan-glepackingproblemwiththepropertythatthesolutionhasnoemptyspace.ThispropertymakesperfectpackingmucheasiersincefastersolutionmethodsexisttKorf,2003.Forexample,bymodelingemptylocationsasvariablesandrect-anglesasvalues,spaceisquicklybrokenupintoregionsthatcantaccommodateanyrectangles.Sincenoemptyspaceisallowedto“lltheseregionsinperfectpacking,thisfrequentlyresultsinpruningclosetotherootofthesearchtree.Wetransformrectanglepackinginstancestoperfectpack-inginstancesbyaddingtotheoriginalsetofrectanglesanumberof1x1rectanglesequaltotheareaofemptyspaceintheoriginalinstance.Sinceweknowhowmuchemptyspacethereisateach-coordinateafterassigningthe-coordinatesoftheoriginalrectangles,wecanassignthe-coordinatesforeachofthenewrectanglesaccordingly.Althoughthenew1x1rectanglesincreasetheproblemsize,thehopeisthattheeaseofsolvingperfectpackingwilloffsetthedif“cultyofpackingmorerectangles.Nextwedescribeinferencerulestoimmediatelyreducetheproblemsize,andfollowwithadescriptionofoursearchspaceforperfectpack-ing.Aswewillshow,ourmethodsrelyontheperfectpackingpropertyofhavingnoemptyspace.5.1ComposingRectanglesandSubsetSumsOccasionallywemayrepresentmultiplerectangleswithasinglerectangle.Thisoccursifwecanshowthattworectan-glesmustbehorizontallynexttoeachotherandhavethesameheightand-coordinate,orverticallystackedandhavethesamewidthand-coordinate.Inthesecases,wecanreplacetherectangleswithasinglelargerone,reducingthenumberofrectangleswehavetopack.Theinferencerulesthatwenowdescribeforinferringcon-tiguitybetweenrectanglesrestonanaturalconsequenceofhavingnoemptyspace:Therightsideofeveryrectanglemustbordertheleftsideofotherrectanglesortheboundingbox.WerefertothisastheborderingconstraintAssumeinFigure3awehavea4x5boundingbox,andasetofrectangleswhose-coordinateshavebeendetermined.Wedontknowtheir-coordinatesyet,sowejustarbitrarilylaythemoutsonotworectanglesoverlaponthe-axis.Nowconsiderallrectangleswhoserightorleftsidesfallonindicatedbythedottedline.Weonlyhavethe1x2ontheleftandtwo1x1sontheright.Duetotheborderingconstraint,the1x2mustshareitsrightborderwiththe1x1s.Furthermore,thisborderforcesthetwo1x1stobeverticallycontiguouswhichwede“netomeanthatthe-axisprojectionsoftheserectanglesmustoverlapandthetopofonemusttouchthebot-tomoftheother.Sincethetwo1x1sareverticallycontiguousandtheyhavethesamewidth,wecanreplacethemwitha1x2rectangleasinFigure3b.InFigure3b,wehavetwo1x2swhoseleftandrightsidesfallon=3.Duetotheborderingconstraint,the1x2onthe (a)Verticalcomposi-tion. (b)Horizontalcom-position. (c)Subsetsums. (d)Horizontalcom-position. (e)Verticalcomposi-tion. (f)Oneofseveralpackingsolution.Figure3:Examplesofcomposingrectanglesandsubsetsums.leftmustborderthe1x2ontherightandhavethesamecoordinatevalues.Sincetheyalsohavethesameheights,wecancomposethemtogetherintoa2x2rectangle.Thesameappliestotherectanglesborderingthelineat=1.TheresultofthesetwohorizontalcompositionsisshowninFigure3c.InFigure3ctherectangleswhoseleftandrightsidesfall=3are2x3,2x1ontheleftand2x2,2x2ontheright.Unlikepreviouscases,sincewehavemorethanonerectangleoneachside,wecantimmediatelyconcludeverti-calcontiguityunlessweshowthatthe4x1canneverseparatetheotherrectanglesvertically.Assumeforthesakeofcon-tradictionthatthe2x3andthe2x1wereseparatedvertically.Thenbytheborderingconstraintthereissomesubsetfrom2x2,2x2thatbordersthe2x1withaheightof1.How-ever,thereisnosuchsubset!Thus,the2x3and2x1mustbeverticallycontiguous,asarethetwo2x2s.Finally,sincetheverticallycontiguousrectangleshavethesamewidths,wecancomposethemtogetherasshowninFigure3d.Usingthesameinferencerules,wecanreplacethetwo2x4sinFigure3dwiththe4x4inFigure3e.Finally,thelasttworectanglesinFigure3emaybealsocomposedtogetherifweconsiderthesidesoftheboundingboxasasingleborder.Sincewekeeptrackoftheorderofrectanglecompositions,wecanextractoneofmanypackingsolutions,asshowninFigure3f.Inthisexampleweinferredthe-coordinateswith-outanysearch,butingeneral,somesearchmayberequired.6AssigningY-CoordinatesNowwepresentredundantandpartialsetsofvariablesthatwillbeconsideredsimultaneouslyinordertoassignthecoordinates.Duringsearch,fromamongallvariablesinallmodels,wechoosetoassignnextthevariablewiththefewestpossiblevalues.Weuseforwardcheckingtoremoveval-uesthatwouldoverlapalready-placedrectangles,andthenpruneonemptydomainsorasrequiredbyKorfss2003]two-dimensionalwasted-spacepruningrule.Finally,weusea2Dbitmaptodrawinplacedrectanglestotestforoverlap. Figure4:Anexampleoftheemptycornermodel.6.1EmptyCornersModelAnalternativetoaskingWhereshouldthisrectanglego?ŽistoaskWhichrectangleshouldgohere?ŽIntheformermodel,rectanglesarevariablesandemptylocationsareval-ues,whereasinthelatter,emptylocationsarevariablesandrectanglesarevalues.Wesearchthelattermodel.Inallperfectpackingsolutions,everyrectangleslower-leftcorner“tsinsomelower-leftemptycornerformedbyotherrectangles,sidesoftheboundingbox,oracombinationofboth.Inthismodel,wehaveonevariableperemptycorner.Sinceeachrectanglegoesintoexactlyoneemptycorner,thenumberofemptycornervariablesisequaltothenumberofrectanglesintheperfectpackinginstance.Thesetofvaluesisjustthesetofunplacedrectangles.Thissearchspacehastheinterestingpropertythatvariablesaredynamicallycreatedduringsearchbecausethecoordinatesofanemptycornerareknownonlyaftertherect-anglesthatcreateitareplaced.Furthermore,placingarect-angleinanemptycornerassignsbothits-coordinates.Notethattheemptycornermodelcandescribeallperfectpackingsolutions.Givenanyperfectpackingsolution,wecanlistauniquesequenceofrectanglesbyscanninglefttoright,bottomtotopforthelower-leftcornersoftherectan-gles.Weusefoursetsofredundantvariables,asthisbetteral-lowsustochoosethevariablewiththefewestvalues.Each SizeOptimalWastedBoxesKMPSimonis08FixedOrderPerfectPackHuang09NSolutionSpaceTestedTimeTimeTimeTimeTime 2034850.69%141:32:022138880.99%209:54:07:03:18:032239980.71%1737:03:51:02:03:022364680.64%193:15:233:58:14:14:122456880.58%1910:17:025:56:40:43:3725431290.40%172:02:58:3640:382:272:152:142670890.47%218:20:14:513:41:4310:259:459:3927471480.37%2234:04:01:0311:30:021:08:5535:1235:12940.37%28631230.45%302:18:12:134:39:314:39:3129811060.36%278:05:368:06:0330511860.33%212:17:34:122:17:32:5231911100.33%304:16:05:084:16:03:4232851350.31%3633:11:36:23 Table1:Minimum-areaboundingboxescontainingallconsecutivesquaresfrom1x1uptosetofvariablescorrespondstoadifferentright-anglerotationoftheemptycorner.Forexample,inFigure4,afterplacing,wenowhavesixemptycornervariables,...,carelower-leftemptycornervariables,whiletheothervariablescorrespondtootherorientationsofanemptycorner.Forwardcheckingthenremovesrectangles-coordinatesinconsistentwiththeemptycornerscoordinatesaswellasremoverectanglesthatwouldoverlapotherrectangleswhenplacedinthecorner.6.2UsingVerticalContiguityDuringSearchRecallthatinFigure3,wecomposedverticallycontiguousrectangleswhentheyhadequalwidths.Evenifwecantcomposerectanglesduetotheirunequalwidths,verticalcon-tiguityisstilluseful.Duringthesearchfor-coordinates,ifweplacearectangleinanemptycorner,thenwecanchoosetoplaceitsverticallycontiguouspartnereitherimmediatelyaboveorbelow,givingusabranchingfactoroftwo.Thiseffectivelyrepresentsanothersetofvariables,eachwithtwopossiblevalues.Weonlyinferverticalcontiguityforcertainpairsofrectangles,sothisisonlyapartialmodel,butourdy-namicvariableorderconsidersthesevariablessimultaneouslywiththoseintheemptycornermodel.7ExperimentalResultsTable1comparestheCPUruntimesof“vesolversontheconsecutive-squarepackingbenchmark.The“rstcolumnreferstotheinstancesize.Thesecondspeci“esthedimen-sionsoftheoptimalsolutionsboundingbox.Thethirdisthepercentageofemptyspaceintheoptimalsolution.Thefourthspeci“esthetotalnumberofboundingboxestheprogramtested.TheremainingcolumnsspecifytheCPUtimesre-quiredbyvariousalgorithmsto“ndalltheoptimalsolutionsintheformatofdays,hours,minutes,andseconds.Whentherearemultipleboxesofminimumareaasin=27,wereportthetotaltimerequiredto“ndallboundingboxes.Huang09includesallofourimprovementsandSimonis08referstothepreviousstate-of-the-artsolvererSimonisandOSullivan,2008.Thelargestproblempreviouslysolvedwas=27andtookSimonis08over11hours.Wesolvedthesameproblemin35minutesandsolve“vemoreopenprob-lemsupto=32.KMPreferstoKorfetal.ss2009]absoluteplacementsolver.FixedOrderassignsall-intervalsbeforeanysingle-coordinates,butincludesallofourotherideas.Huang09sdynamicvariableorderingforthe-coordinateswasanorderofmagnitudefasterthanFixedOrderbyTheorderofmagnitudeimprovementofFixedOrderoverSi-monis08islikelyduetoouruseofperfectpackingforas-signingthe-coordinates.Wedonotincludethetimingforasolverwithperfectpackingdisabledbecauseitwasnotcom-petitive(e.g.,=20tookover2.5hours).InPerfectPackweuseonlythelower-leftcornerwhenas-signing-coordinatesandalsoturnoffallinferencerulesre-gardingrectanglecompositionandverticalcontiguity.NoticethattherunningtimeofthisversiondiffersonlyveryslightlyfromtherunningtimeofHuang09,whichincludesallofouroptimizations.Thissuggeststhatnearlyalloftheperfor-mancegainscanbeattributedtojustusingour-coordinatetechniquesandtheperfectpackingtransformationwiththelower-leftcornerforthe-coordinates.WebenchmarkedoursolversinLinuxona2GHzAMDOpteron246with2GBofRAM.KMPwasbenchmarkedonthesamemachine,sowequotetheirresultsultsKorfetal..Wedonotincludedatafortheirrelativeplacementsolverbecauseitwasnotcompetitive.ResultsforSimo-nis08arealsoquotedquotedSimonisandOSullivan,2008,ob-tainedfromSICStusProlog4.0.2forWindowsona3GHzIntelXeon5450with3.25GBofRAM.Sincetheirmachineisfasterthanours,thesecomparisonsareaconservativeesti-mateofourrelativeperformance.InTable2thesecondcolumnisthenumberofcompletecoordinateassignmentsoursolverfoundovertheentirerunofaparticularprobleminstance.Thethirdisthetotaltimespentinsearchingforthe-coordinate.Thefourthisthetotaltimespentinperformingtheperfectpackingtransformationandsearchingforthe-coordinates.Bothcolumnsrepresent SizeX-CoordinateSecondsSecondsRatioNSolutionsinXinYX:Y 20150.10.02.6216650.82.40.3222832.10.45.62339114.10.622.72487042.02.318.625193160.90.3564.5261,026688.52.8242.5272442,524.40.64,376.6282,71519,867.56.82,919.42911,12934,839.733.11,052.43010,244277,087.029.29,478.9 Table2:CPUtimesspentsearchingfor-coordinates.thetotalCPUtimeoveranentirerunforagivenprobleminstance.Thelastcolumnistheratiooftimeinthethirdcol-umntothatofthefourth.Interestingly,almostallofthetimeisspentonthe-coordinatesasopposedtothe-coordinates,whichsuggeststhatifwecouldef“cientlyenumeratethecoordinatesolutions,wecouldalsoef“cientlysolverectanglepacking.Thisiscon“rmedbythefew-coordinatesolutionsthatexistevenforlargeinstances.ThedatainTable2wasobtainedona3GHzPentium4with2GBofRAMinasepa-rateexperimentfromthatofTable1,whichiswhy=31and=32aremissingfromTable2.8FutureWorkThealternativeformulationofaskingWhatgoesinthislo-cation?ŽtoWheredoesthisgo?Žisnotlimitedtorectanglepacking.Forexample,humanssolvejigsawpuzzlesbybothaskingwhereaparticularpieceshouldgo,aswellasaskingwhatpieceshouldgoinsomeemptyregion.Itwouldbeinter-estingtoseehowapplicablethisdualformulationisinotherpacking,layout,andschedulingproblems.Ouralgorithmcurrentlyonlyconsidersintegervaluesforrectanglesizesandcoordinates.Whilethisisgenerallyap-plicable,themodelbreaksdownwithrectanglesofhigh-precisiondimensions.Forexample,considerdoublingthesizesofallitemsinaprobleminstanceinbothdimensionstogettheinstance2x2,4x4,...,,andthensubstitutethe2x2fora3x3rectangle.Thenewinstanceshouldntbeharderthantheoriginal,butnowwemustconsidertwiceasmanysingle-coordinatevalues,resultinginamuchhigherbranchingfactorthantheoriginalproblem.Thesolutiontothisproblemmayrequireadifferentrepresentationandmanychangestoourtechniques,andsoitremainsfuturework.9ConclusionWehavepresentedseveralnewimprovementsovertheprevi-ousstate-of-the-artinrectanglepacking.Withintheschemaofassigning-coordinatespriorto-coordinates,weintro-ducedadynamicvariableorderforthe-coordinates,andaconstraintthatadaptsKorfss2003]wasted-spacepruningheuristictotheone-dimensionalcase.Forthe-coordinatesweworkontheperfectpackingtransformationoftheoriginalproblem,byusingamodelthatassignsrectanglestoemptycorners,andinferencerulestoreducethemodelsvariablesandderiveverticalcontiguityrelationships.Ourimprovementsinthesearchfor-coordinateshelpussolve=27overanorderofmagnitudefasterthanthepre-viousstate-of-the-art,andourimprovementsinthesearchfor-coordinatesalsogaveusanorderofmagnitudespeedupby=28comparedtoleavingthoseoptimizationsout.Withallourtechniques,weareover19timesfasterthantheprevi-ousstate-of-the-artonthelargestproblemsolvedtodate,al-lowingustoextendtheknownsolutionsfortheconsecutive-squarepackingbenchmarkfrom=27toAllofthetechniquespresentedtopick-coordinatesaretightlycoupledwiththedualviewofaskingwhatmustgoinanemptylocation.Furthermore,whilesearchingforcoordinates,ourpruningruleisbasedontheanalysisofirreg-ularregionsofemptyspace,andourdynamicvariableorderalsorestsontheobservationthatlessemptyspaceleadstoamoreconstrainedproblem.Thesuccessofthesetechniquesinrectanglepackingmakethemworthexploringinmanyotherpacking,layout,orschedulingproblems.10AcknowledgmentsThisresearchwassupportedbyNSFgrantNo.IIS-0713178toRichardE.Korf.ReferencesencesBeldiceanuetal.,2008NicolasBeldiceanu,MatsCarls-son,andEmmanuelPoder.New“lteringforthecumu-lativeconstraintinthecontextofnon-overlappingrect-angles.InLaurentPerronandMichaelA.Trick,editors,CPAIOR,volume5015ofLectureNotesinComputerSci-,pages21…35.Springer,2008.2008.Clautiauxetal.,2007FranoisClautiaux,JacquesCarlier,andAzizMoukrim.Anewexactmethodforthetwo-dimensionalorthogonalpackingproblem.EuropeanJour-nalofOperationalResearch,183(3):1196…1211,2007.2007.Korfetal.,2009RichardKorf,MichaelMof“tt,andMarthaPollack.Optimalrectanglepacking.ToappearinAnnalsofOperationsResearch,2009.2009.Korf,2003RichardE.Korf.Optimalrectanglepacking:Initialresults.InEnricoGiunchiglia,NicolaMuscettola,andDanaS.Nau,editors,ICAPS,pages287…295.AAAI,AAAI,Mof“ttandPollack,2006MichaelD.Mof“ttandMarthaE.Pollack.Optimalrectanglepacking:Ameta-cspapproach.InDerekLong,StephenF.Smith,DanielBorrajo,andLeeMcCluskey,editors,ICAPSpages93…102.AAAI,2006.2006.SimonisandOSullivan,2008HelmutSimonisandBarryOSullivan.Searchstrategiesforrectanglepacking.InPeterJ.Stuckey,editor,,volume5202ofLectureNotesinComputerScience,pages52…66.Springer,2008.