$fn = 64; // Parameters strip_length = 100; strip_width = 15; strip_thickness = 5; // Magnet dimensions (slightly oversized for press-fit/glue clearance) magnet_diameter = 6.2; magnet_thickness = 3.2; num_magnets = 4; // Calculated spacing magnet_spacing = strip_length / num_magnets; start_offset = magnet_spacing / 2; difference() { // Main strip body translate([-strip_length/2, -strip_width/2, 0]) cube([strip_length, strip_width, strip_thickness]); // Embedded magnet cutouts (from the bottom surface) for (i = [0 : num_magnets - 1]) { x_pos = -strip_length/2 + start_offset + (i * magnet_spacing); // Cutout cylinder extended slightly below 0 for clean manifold subtraction translate([x_pos, 0, -0.01]) cylinder(d=magnet_diameter, h=magnet_thickness + 0.01); } }