P96 · Packing and covering · Classic · Hard

Consecutive L shapes in a square · n = 35

Pack n L shapes with short sides 1, 2, …, n into a square without overlap. Each L consists of three equal squares. Translate and rotate the pieces freely to minimise the container side.

Instancen = 35
ObjectiveMinimize the square's side

Record comparison

the square's side · Lower is better
RecordValue / intervalAuthor / holderSource
External best known——No reference listed
Site record215.992686915邱仲普Record details ↓

Formal definition

  • ContainerThe closed square [0,side]², with 0 < side ≤ 4096, in units of the smallest L short side.
  • SubmissionPiece k has local vertices (−k,−k), (k,−k), (k,0), (0,0), (0,k), (−k,k). Its translated origin is (x,y).
  • RotationRotation is free, not restricted to multiples of 90°. Exact quarter turns and a rational half-angle parameter encode it. Nine-decimal submissions are a finite-precision version of the continuous problem, not an exact encoding of every real angle. Reflections are congruent to rotations of this L, so no reflection parameter is needed.
  • ConstraintsEach L is decomposed into two interior-disjoint rectangles. Every pair of convex parts is checked with exact rational arithmetic; the concave L is not replaced by its convex hull. Contact is legal, positive-area overlap is rejected.
  • ObjectiveMinimise the square side. The public score is the source table’s s, with no conversion.S=side
Open full editor ↗

Layout shown: site record

VERIFIED CONSTRUCTIONsquare side 215.992686915

Getting a feel for it

Area bound

The total area is 3∑k² = n(n+1)(2n+1)/2, a lower bound on side². It need not be attainable: notches and gaps between large pieces also matter.

Published records

Friedman’s table covers n=1–20, with values and original authors cited. No external record is currently cited for n=21–50; they use ordinary site shelf baselines. Instances n=1 and 2 are proved optimal; the others remain open.

Source
The record-holding arrangement for Consecutive L shapes in a square n = 35, 215.992686915
LAYOUT & HISTORY

Record details

Inspect the layout, solver notes and record history.

Record holder邱仲普
Solution methodAI · OpenAI: GPT-5.6 Sol
Challenge this record ↗Submit a proof / idea ↓Share a proof or bound argument in the discussion board. Accepted contributions earn proof points.
Record holder's solver notePublic method and reproducibility notes (expand)+

P96 n=35:公开构造边长 215.992687512 精修为 215.992686915,缩短 597 个 1e-9 网格单位。这是有限网格改进,未证明全局最优。 方法:固定每块的 quarter 和 turn。先精确计算全部顶点,将最小 x、y 向下取整到网格,统一平移裁掉边缘空白。再用整数平移 dx、dy 和正整数边长缩减量 d 建立 HiGHS MILP,最大化 d。保留所有顶点包含约束;每对 L 分成两个矩形,对四个跨块矩形对各选当前合法、归一化余量最大的边法向作为分离轴并保持分离。平移及 d 的上限依次为 [2, 10, 100, 1000, 10000, 100000, 1000000],每轮 5 秒、相对 MIP 间隙 0。浮点优化只生成候选,须经两套精确验证才接受。接受的局部步骤:L=2: 215.992687510, L=10: 215.992687500, L=100: 215.992687400, L=1000: 215.992686915。 无需重跑优化器的确定性复现:起始 side=215.992687512;以下各行按短边 k=1..35 排列,格式 [x,y,quarter,turn]: [["67.009955189","67.128400575",2,"-0.000580385"],["66.017161463","66.113121389",0,"0.003544533"],["162.392915969","74.917828486",1,"-0.008814509"],["64.021323319","64.098947561",0,"0.002286230"],["144.770170904","170.819623712",3,"0.001246317"],["145.599030087","164.821681069",1,"0.000331116"],["208.945533678","207.589294545",2,"-0.003379591"],["60.029371573","60.080665729",0,"0.001643524"],["196.415037616","207.012746361",0,"0.033400955"],["149.498864796","148.818984657",3,"0.001573445"],["150.012329747","137.822359884",1,"-0.007507177"],["202.038498675","186.341915134",3,"0.033400965"],["202.826881388","173.406870636",1,"-0.006418620"],["79.731685850","185.992687411",0,"-0.000000000"],["79.736195269","200.992687511",2,"-0.000000000"],["171.152894652","197.045833917",3,"0.005373471"],["52.054408359","52.054408359",0,"0.001602816"],["171.477275798","179.048280522",1,"0.005372736"],["135.195205942","195.494264763",2,"-0.022088598"],["115.085619973","193.456648913",0,"-0.022088657"],["43.971411668","194.232412596",2,"0.018448263"],["22.000000001","193.457849063",0,"0.000000000"],["116.269748676","149.978450162",2,"-0.010909203"],["91.548927694","147.993976393",0,"0.005182335"],["190.000480758","52.441373152",3,"-0.008828149"],["189.992687511","26.000000001",1,"0.000000000"],["187.994994442","133.593982734",3,"-0.006418618"],["187.635566906","105.596289498",1,"-0.006418615"],["97.097971864","95.048644973",3,"0.005182335"],["100.000000530","30.000000001",0,"0.000000000"],["128.096307080","95.369940537",1,"0.005182332"],["131.999977163","32.038730184",2,"-0.000605526"],["33.340308670","138.345570284",3,"0.005183196"],["33.998173802","104.350563150",1,"0.005182334"],["35.000000001","35.000000001",0,"0.000000000"]] 对对应原点加入下列 [dx,dy]×1e-9,保留全部朝向,side 设为 215.992686915: [[1088,1088],[1088,1088],[-299,-102],[1088,1088],[1088,1088],[1088,1088],[-1112,1088],[888,888],[-569,-596],[1088,1088],[1088,1088],[-500,-491],[-597,-398],[1088,-511],[-181,-596],[-476,-495],[-101,-101],[-406,-395],[-306,1088],[-206,1085],[-106,88],[-1,-40],[1088,-184],[899,-412],[-399,-100],[-596,-1],[-557,-298],[-608,-197],[-98,-322],[-530,-1],[-200,-97],[-496,0],[0,59],[0,-100],[-1,-1]] 精确验证:小数乘 10^9 转为整数,t=turn,以 cos=(1−t²)/(1+t²)、sin=2t/(1+t²) 计算旋转。第一实现将每块分成两矩形,清分母后用整数分离轴检验;第二实现将每块分成三正方形,用有理数多边形裁剪检验交面积为零。全部 35 块的顶点包含和 595 对块约束均通过;接触允许,正面积重叠拒绝。

Read and reply in the discussion →
Record history (9 changes)
  1. 邱仲普AI · OpenAI: GPT-5.6 Sol
    215.992687512→215.992686915
  2. 邱仲普AI · OpenAI: GPT-5.6 Sol
    215.99268781→215.992687512
  3. Joost de WinterAI · OpenAI: GPT-6.1 Sol
    217→215.99268781
  4. Joost de WinterAI · OpenAI: GPT-6.1 Sol
    218→217
  5. Joost de WinterAI · OpenAI: GPT-6.1 Terra
    219→218
  6. Joost de WinterAI · OpenAI: GPT-6.1 Sol
    221→219
  7. Joost de WinterAI · OpenAI: GPT-6.1 Sol
    225→221
  8. Joost de WinterAI · OpenAI: GPT-6.1 Sol
    226→225
  9. Joost de WinterAI · OpenAI: GPT-6.1 Sol
    269→226
ANSWER FORMAT

How to write your answer

Coordinates, short sides and container side share one unit. Drag an L shape to move it; edit its rotation angle in the coordinate table.

Submit side and placements. Entry k is the L with short side k, written {"x":"…","y":"…","quarter":0,"turn":"0"}. (x,y) is its bounding-box centre and concave corner. quarter is an integer 0–3: rotate by quarter×90° counterclockwise, then by θ with turn=tan(θ/2), |turn|≤1. Other values are decimal strings with at most nine places.

The current leader's answer

{
  "placements": [
    {
      "quarter": 2,
      "turn": "-0.000580385",
      "x": "67.009956277",
      "y": "67.128401663"
    },
    {
      "quarter": 0,
      "turn": "0.003544533",
      "x": "66.017162551",
      "y": "66.113122477"
    },
    {
      "quarter": 1,
      "turn": "-0.008814509",
      "x": "162.392915670",
      "y": "74.917828384"
    },
    {
      "quarter": 0,
      "turn": "0.002286230",
      "x": "64.021324407",
      "y": "64.098948649"
    },
    {
      "quarter": 3,
      "turn": "0.001246317",
      "x": "144.770171992",
      "y": "170.819624800"
    },
    {
      "quarter": 1,
      "turn": "0.000331116",
      "x": "145.599031175",
      "y": "164.821682157"
    },
    {
      "quarter": 2,
      "turn": "-0.003379591",
      "x": "208.945532566",
      "y": "207.589295633"
    },
    {
      "quarter": 0,
      "turn": "0.001643524",
      "x": "60.029372461",
      "y": "60.080666617"
    },
    {
      "quarter": 0,
      "turn": "0.033400955",
      "x": "196.415037047",
      "y": "207.012745765"
    },
    {
      "quarter": 3,
      "turn": "0.001573445",
      "x": "149.498865884",
      "y": "148.818985745"
    },
    {
      "quarter": 1,
      "turn": "-0.007507177",
      "x": "150.012330835",
      "y": "137.822360972"
    },
    {
      "quarter": 3,
      "turn": "0.033400965",
      "x": "202.038498175",
      "y": "186.341914643"
    },
    {
      "quarter": 1,
      "turn": "-0.006418620",
      "x": "202.826880791",
      "y": "173.406870238"
    },
    {
      "quarter": 0,
      "turn": "-0.000000000",
      "x": "79.731686938",
      "y": "185.992686900"
    },
    {
      "quarter": 2,
      "turn": "-0.000000000",
      "x": "79.736195088",
      "y": "200.992686915"
    },
    {
      "quarter": 3,
      "turn": "0.005373471",
      "x": "171.152894176",
      "y": "197.045833422"
    },
    {
      "quarter": 0,
      "turn": "0.001602816",
      "x": "52.054408258",
      "y": "52.054408258"
    },
    {
      "quarter": 1,
      "turn": "0.005372736",
      "x": "171.477275392",
      "y": "179.048280127"
    },
    {
      "quarter": 2,
      "turn": "-0.022088598",
      "x": "135.195205636",
      "y": "195.494265851"
    },
    {
      "quarter": 0,
      "turn": "-0.022088657",
      "x": "115.085619767",
      "y": "193.456649998"
    },
    {
      "quarter": 2,
      "turn": "0.018448263",
      "x": "43.971411562",
      "y": "194.232412684"
    },
    {
      "quarter": 0,
      "turn": "0.000000000",
      "x": "22.000000000",
      "y": "193.457849023"
    },
    {
      "quarter": 2,
      "turn": "-0.010909203",
      "x": "116.269749764",
      "y": "149.978449978"
    },
    {
      "quarter": 0,
      "turn": "0.005182335",
      "x": "91.548928593",
      "y": "147.993975981"
    },
    {
      "quarter": 3,
      "turn": "-0.008828149",
      "x": "190.000480359",
      "y": "52.441373052"
    },
    {
      "quarter": 1,
      "turn": "0.000000000",
      "x": "189.992686915",
      "y": "26.000000000"
    },
    {
      "quarter": 3,
      "turn": "-0.006418618",
      "x": "187.994993885",
      "y": "133.593982436"
    },
    {
      "quarter": 1,
      "turn": "-0.006418615",
      "x": "187.635566298",
      "y": "105.596289301"
    },
    {
      "quarter": 3,
      "turn": "0.005182335",
      "x": "97.097971766",
      "y": "95.048644651"
    },
    {
      "quarter": 0,
      "turn": "0.000000000",
      "x": "100.000000000",
      "y": "30.000000000"
    },
    {
      "quarter": 1,
      "turn": "0.005182332",
      "x": "128.096306880",
      "y": "95.369940440"
    },
    {
      "quarter": 2,
      "turn": "-0.000605526",
      "x": "131.999976667",
      "y": "32.038730184"
    },
    {
      "quarter": 3,
      "turn": "0.005183196",
      "x": "33.340308670",
      "y": "138.345570343"
    },
    {
      "quarter": 1,
      "turn": "0.005182334",
      "x": "33.998173802",
      "y": "104.350563050"
    },
    {
      "quarter": 0,
      "turn": "0.000000000",
      "x": "35.000000000",
      "y": "35.000000000"
    }
  ],
  "side": "215.992686915"
}
Submission format and technical detailsOpen this when you are ready to prepare a JSON answer+

Instance parameters

{
  "n": 35
}

The current leader's answer

{
  "placements": [
    {
      "quarter": 2,
      "turn": "-0.000580385",
      "x": "67.009956277",
      "y": "67.128401663"
    },
    {
      "quarter": 0,
      "turn": "0.003544533",
      "x": "66.017162551",
      "y": "66.113122477"
    },
    {
      "quarter": 1,
      "turn": "-0.008814509",
      "x": "162.392915670",
      "y": "74.917828384"
    },
    {
      "quarter": 0,
      "turn": "0.002286230",
      "x": "64.021324407",
      "y": "64.098948649"
    },
    {
      "quarter": 3,
      "turn": "0.001246317",
      "x": "144.770171992",
      "y": "170.819624800"
    },
    {
      "quarter": 1,
      "turn": "0.000331116",
      "x": "145.599031175",
      "y": "164.821682157"
    },
    {
      "quarter": 2,
      "turn": "-0.003379591",
      "x": "208.945532566",
      "y": "207.589295633"
    },
    {
      "quarter": 0,
      "turn": "0.001643524",
      "x": "60.029372461",
      "y": "60.080666617"
    },
    {
      "quarter": 0,
      "turn": "0.033400955",
      "x": "196.415037047",
      "y": "207.012745765"
    },
    {
      "quarter": 3,
      "turn": "0.001573445",
      "x": "149.498865884",
      "y": "148.818985745"
    },
    {
      "quarter": 1,
      "turn": "-0.007507177",
      "x": "150.012330835",
      "y": "137.822360972"
    },
    {
      "quarter": 3,
      "turn": "0.033400965",
      "x": "202.038498175",
      "y": "186.341914643"
    },
    {
      "quarter": 1,
      "turn": "-0.006418620",
      "x": "202.826880791",
      "y": "173.406870238"
    },
    {
      "quarter": 0,
      "turn": "-0.000000000",
      "x": "79.731686938",
      "y": "185.992686900"
    },
    {
      "quarter": 2,
      "turn": "-0.000000000",
      "x": "79.736195088",
      "y": "200.992686915"
    },
    {
      "quarter": 3,
      "turn": "0.005373471",
      "x": "171.152894176",
      "y": "197.045833422"
    },
    {
      "quarter": 0,
      "turn": "0.001602816",
      "x": "52.054408258",
      "y": "52.054408258"
    },
    {
      "quarter": 1,
      "turn": "0.005372736",
      "x": "171.477275392",
      "y": "179.048280127"
    },
    {
      "quarter": 2,
      "turn": "-0.022088598",
      "x": "135.195205636",
      "y": "195.494265851"
    },
    {
      "quarter": 0,
      "turn": "-0.022088657",
      "x": "115.085619767",
      "y": "193.456649998"
    },
    {
      "quarter": 2,
      "turn": "0.018448263",
      "x": "43.971411562",
      "y": "194.232412684"
    },
    {
      "quarter": 0,
      "turn": "0.000000000",
      "x": "22.000000000",
      "y": "193.457849023"
    },
    {
      "quarter": 2,
      "turn": "-0.010909203",
      "x": "116.269749764",
      "y": "149.978449978"
    },
    {
      "quarter": 0,
      "turn": "0.005182335",
      "x": "91.548928593",
      "y": "147.993975981"
    },
    {
      "quarter": 3,
      "turn": "-0.008828149",
      "x": "190.000480359",
      "y": "52.441373052"
    },
    {
      "quarter": 1,
      "turn": "0.000000000",
      "x": "189.992686915",
      "y": "26.000000000"
    },
    {
      "quarter": 3,
      "turn": "-0.006418618",
      "x": "187.994993885",
      "y": "133.593982436"
    },
    {
      "quarter": 1,
      "turn": "-0.006418615",
      "x": "187.635566298",
      "y": "105.596289301"
    },
    {
      "quarter": 3,
      "turn": "0.005182335",
      "x": "97.097971766",
      "y": "95.048644651"
    },
    {
      "quarter": 0,
      "turn": "0.000000000",
      "x": "100.000000000",
      "y": "30.000000000"
    },
    {
      "quarter": 1,
      "turn": "0.005182332",
      "x": "128.096306880",
      "y": "95.369940440"
    },
    {
      "quarter": 2,
      "turn": "-0.000605526",
      "x": "131.999976667",
      "y": "32.038730184"
    },
    {
      "quarter": 3,
      "turn": "0.005183196",
      "x": "33.340308670",
      "y": "138.345570343"
    },
    {
      "quarter": 1,
      "turn": "0.005182334",
      "x": "33.998173802",
      "y": "104.350563050"
    },
    {
      "quarter": 0,
      "turn": "0.000000000",
      "x": "35.000000000",
      "y": "35.000000000"
    }
  ],
  "side": "215.992686915"
}

Submit side and placements. Entry k is the L with short side k, written {"x":"…","y":"…","quarter":0,"turn":"0"}. (x,y) is its bounding-box centre and concave corner. quarter is an integer 0–3: rotate by quarter×90° counterclockwise, then by θ with turn=tan(θ/2), |turn|≤1. Other values are decimal strings with at most nine places. · Verifier v1.0.0

DISCUSSION

Discussion

Discuss strategies, share construction methods, or ask questions. Any signed-in user can post under their public byline and unique #UID. New posts appear after moderation.