Nesting Algorithms Explained: Rectangular, True-Shape & Common-Line

⚡ Key Takeaway

True-shape nesting algorithms achieve 82-92% utilization vs 65-75% for rectangular nesting. The key innovation is the No-Fit Polygon (NFP) method, which allows parts to interlock like puzzle pieces. Combined with common-line cutting, modern algorithms save 15-30% material over manual or basic nesting.

Understanding nesting algorithms helps you evaluate software, choose the right strategy for your parts, and optimize utilization. This guide covers the four major algorithm families — from simple rectangular packing to AI-driven optimization. For practical software selection, see our Nesting Software ROI Comparison.

Published: February 11, 2026
Last Updated: February 11, 2026
Skill Level: Advanced / Technical

1. Algorithm Family Comparison

AlgorithmUtilizationSpeedComplexityBest For
Rectangular Packing65-75%< 1 secondLowSimple rectangular parts
True-Shape (NFP)82-90%5-60 secondsHighComplex, irregular parts
Common-Line85-92%10-120 secondsVery HighCompatible geometry pairs
Hybrid / AI88-95%30-300 secondsVery HighMixed production, high-volume

2. Rectangular Packing

The simplest nesting approach: surround each part with a bounding rectangle and arrange rectangles on the sheet using strip-packing or shelf algorithms. This is fast but inherently wasteful because the gaps between the bounding box and the actual part contour become unusable space.

✅ Advantages

• Extremely fast computation (<1 second for 100+ parts)
• Simple to implement and debug
• Predictable, deterministic results
• Works with any CAM system

❌ Limitations

• 15-25% worse utilization than true-shape
• Cannot interlock concave shapes
• L-shaped, C-shaped, and hollow parts waste significant material
• Not economical for production volumes
When to use: Quick quoting (time estimate only), prototype batches (<10 parts), or when all parts are truly rectangular (panels, brackets, plates without cutouts).

3. True-Shape Nesting (NFP Method)

True-shape nesting uses the actual part contour instead of a bounding box. The key mathematical tool is the No-Fit Polygon (NFP): for any two parts A and B, the NFP defines all valid positions where B can touch A without overlapping. This allows parts to interlock, fitting concave regions of one part into convex protrusions of another.

How NFP Works (Simplified)

1
Compute NFPs for all unique part-pair combinations. For N part types, this requires N×(N+1)/2 NFP calculations. Each NFP is a polygon describing the boundary of valid placements.
2
Generate candidate placements using a placement heuristic (bottom-left, gravity, or no-fit polygon guided). The first part is placed in the corner; subsequent parts are placed at the point on the NFP boundary that minimizes waste.
3
Optimize with metaheuristics — genetic algorithms, simulated annealing, or tabu search explore different part orderings and rotations to find the global optimum (or near-optimum). This is the computationally expensive phase.
4
Apply constraints — grain direction, minimum part spacing, edge margins, and rotation limits (0°/90°/180°/270° or free rotation) are enforced during optimization.
Performance note: NFP computation scales with part complexity (number of vertices). A 100-vertex part pair takes ~50ms; 1000-vertex pair takes ~500ms. Simplifying DXF geometry before nesting dramatically improves speed. See our DXF Nesting Best Practices for file optimization techniques.

4. Common-Line Cutting Algorithms

Common-line nesting eliminates the gap between adjacent parts by sharing a cut edge. The laser cuts once where two parts meet, saving material (gap elimination) and time (fewer cuts). This requires compatible geometry — straight edges or matching contours between adjacent parts.

BenefitImprovementImpact
Material savings2-8% additional utilization$12,000-48,000/year on $50K/mo material
Cut length reduction20-40% fewer meters cutProportional gas and consumable savings
Pierce count reduction30-50% fewer piercesExtended nozzle/lens life
Cycle time15-30% faster per sheetIncreased machine throughput
Caution: Common-line cutting requires precise kerf compensation. Parts sharing an edge each lose half the kerf width. For tight-tolerance parts (±0.1mm), verify that this half-kerf deduction is within specification. Use our Kerf Calculator to check dimensions.

5. AI and Hybrid Optimization

Modern nesting software combines multiple algorithms: true-shape NFP for initial placement, common-line detection for compatible edges, and machine-learning models trained on historical production data to predict optimal strategies per job mix. This hybrid approach achieves the highest utilization rates (88-95%) but requires significant computation time.

Population-based optimization: Algorithms like NSGA-II simultaneously optimize multiple objectives — material utilization, cut path length, and thermal distribution — producing a Pareto front of solutions for the operator to choose from.
Reinforcement learning approaches: Some platforms (SigmaNEST 2025+) use RL agents that learn from thousands of historical nests to predict which part orderings and rotations will yield the best utilization for a given part mix.
Dynamic re-nesting: If a sheet has defects detected by vision systems, the software re-optimizes the remaining parts in real-time to avoid defective areas, recovering sheets that would otherwise be scrapped.

Frequently Asked Questions

What is the difference between rectangular and true-shape nesting?

Rectangular nesting uses bounding boxes (65-75% utilization). True-shape nesting uses actual part contours with No-Fit Polygons (82-92% utilization). The 15-20% difference translates directly to material cost savings.

How does common-line cutting improve efficiency?

Common-line cutting shares edges between adjacent parts, eliminating gaps and reducing total cut length by 20-40%. This saves 2-8% material plus proportional gas, consumable, and time savings. For nesting strategy details, see our Nesting Optimization Guide.

What is the NFP method?

The No-Fit Polygon (NFP) method computes all valid positions where one part can be placed relative to another without overlapping. It is the mathematical foundation underpinning all modern true-shape nesting systems.

Related Tools & Guides

Algorithm descriptions are based on published academic literature and verified against implementations in SigmaNEST, ProNest, and Lantek. Utilization figures reflect typical production results — actual performance depends on part mix, sheet size, and constraint parameters.