⚡ Zigzag Blade System

Multi-Segment Blade Generation for Formed Parts

🎯 Overview

For formed sheet metal parts, blades must follow non-linear paths that zigzag around bends, following the part profile. The zigzag blade system processes each segment independently using the proven rotation technique, then unites them into a single blade body.

TOP VIEW - Part with Zigzag Blade Path Part Profile ┌─────────────┐ │ │ │ │ Seg 1 │ Seg 2 │ Seg 3 ════════╪═════════════╪════════ │ │ │ │ └─────────────┘ Each segment rotates around its own line independently, then all segments are boolean united together.

🔄 Algorithm Flow

1
Get Path Kurve

Multi-segment kurve defines blade centerline

2
Extract Segments

Process each span independently

3
Create Blade Section

Extrude, subtract part

4
Rotate & Sculpt

Lay flat, modify, stand up

5
Unite All

Boolean union at corners

Detailed Algorithm

FOR each span in blade path kurve:
    1. Get span endpoints (xS, yS) → (xE, yE)
    
    2. Create blade rectangle along span line
       - Width = blade thickness
       - Length = span length (+ extension for overlap mode)
    
    3. Extrude to part height
    
    4. Subtract part geometry (create the pocket)
    
    5. Rotate 90° around span line (lay flat)
       sld rotate 1 i_blade xS yS 0 xE yE 0 90
    
    6. [SCULPTING ZONE - do modifications while flat]
       - Edge treatments
       - Grippers  
       - Weight reduction
    
    7. Rotate -90° around span line (stand back up)
       sld rotate 1 i_blade xS yS 0 xE yE 0 -90
    
    8. Apply corner treatment (Mode 0, 1, or 2)
    
    9. Unite with previous segments

OUTPUT: Complete zigzag blade solid

📐 Corner Handling Modes

Mode Name Description Best For
0 Overlap + Union Extend segments past bend, boolean unite Prototyping, robustness
1 Miter Cut Cut at bisector angle for clean joint Production tooling
2 Radius Blend Add fillet at corner Smooth material flow

See detailed corner mode documentation →

🏭 Blade Identity: One vs Multiple

⚠️
Critical Design Decision: Zigzag segments may represent either ONE physical blade (cut flat, then bent at bend lines) or MULTIPLE separate blades (if bends are too sharp or gaps too large). This affects DXF output, blade numbering, and manufacturing workflow.
SCENARIO A: Segments Connect as ONE Blade 3D ASSEMBLED FLAT PATTERN FOR CUTTING Seg 3 Seg 1 Seg 2 Seg 3 ───────── ══════════════════════════════ ╱ │ │ │ │ ╱ Seg 2 │ BENDBEND │ ╱ │ LINELINE │ ───────── Seg 1 ══════════════════════════════ Manufacturing: Cut ONE piece, bend at marked lines Blade ID: "BLADE-001" (single ID) SCENARIO B: Segments are SEPARATE Blades 3D ASSEMBLED FLAT PATTERNS (3 pieces) Seg 3 ═══════════ BLADE-001-C ───────── ╱ ╱ Seg 2 ═══════════ BLADE-001-B ╱ ───────── Seg 1 ═══════════ BLADE-001-A Manufacturing: Cut THREE pieces, install separately Blade IDs: "BLADE-001-A", "BLADE-001-B", "BLADE-001-C"

Decision Criteria

Factor Connect as One Separate Blades
Bend Angle ≤ 90° typically > 90° (material may crack)
Material Ductile (aluminum, mild steel) Brittle or hardened
Bend Radius ≥ 2× material thickness < 2× thickness
Gap at Bend < 5mm (adjustable) Large gaps

📊 Bend Compensation

When a blade is bent, the neutral axis shifts, requiring compensation in the flat pattern length.

BEND CROSS-SECTION Inside (compression) ╭────╮ ╱ ╲ │ ─ ─ ─ │ ← Neutral axis (not at center!) ╲ ╱ ╰────╯ Outside (tension) The neutral axis position is determined by the K-factor.

Bend Allowance Formula

Bend Allowance (BA) = π × (R + K × T) × (A / 180)

Where:
  R = Inside bend radius
  K = K-factor (typically 0.3 - 0.5)
  T = Material thickness
  A = Bend angle in degrees
  
Flat Length = Leg1 + BA + Leg2

K-Factor Reference

Material K-Factor
Soft aluminum 0.30 - 0.35
Brass, soft copper 0.35
Hard aluminum, mild steel 0.40 - 0.45
Stainless steel 0.45 - 0.50

💻 Usage

Basic Call

'*** Create a zigzag blade from a path kurve
call fxZigzagBlade i_pathKurve i_partBody w_bladeThickness i_cornerMode

'*** Parameters:
'***   i_pathKurve     - Kurve number defining blade centerline
'***   i_partBody      - Part solid body ID
'***   w_bladeThickness - Blade material thickness
'***   i_cornerMode    - 0=Overlap, 1=Miter, 2=Radius

'*** Returns:
'***   i_return = Final blade body ID (or i_ERROR)

Example: 3-Segment Zigzag

'*** Define blade path (3 segments around a corner)
k5 e x-0.5" y-0.5" x1" y-0.5" x1.5" y1" x1.5" y3.5" ek

'*** Create part (simple box for testing)
k1 e x0 y0 x2" y0 x2" y3" x0 y3" x0 y0 ek
sld cnv kurve sheet k1 i_partBody
sld body thicken 1 i_partBody 0 1" i_ret

'*** Generate zigzag blade with overlap mode
call fxZigzagBlade 5 i_partBody 0.125" 0
i_bladeBody = i_return

'*** Clean up
delete k1 k5

Test Macro

'*** Run the test harness with a corner mode
call fxTestZigzagBlade 0   '*** Overlap mode
call fxTestZigzagBlade 1   '*** Miter mode  
call fxTestZigzagBlade 2   '*** Radius mode

📁 Related Files

File Purpose
fxZigzagBlade.ovm Main orchestrator - processes path kurve
fxCreateBladeSegment.ovm Creates single segment with rotation
fxCornerHandling.ovm Corner mode implementations
fxTestZigzagBlade.ovm Test harness

See complete file reference →