# DNA Earrings

As my first complete project with my 3D printer, I made my girlfriend a pair of DNA ear-rings.

The fun part was learning some code in openSCAD, below:

rotation = 18; // degrees of rotation about z - be sure to rotate before translate

numBasePairs = 11;

difference(){

union(){
for (i = [0:numBasePairs-1]) {

rotate([0,0,rotation*i]){
translate([-5,-1.25,2.5*i+1]){
cube([10,2.5,2.5]);
}}

rotate([0,0,rotation*i]){
translate([5.5,0,2.5*i+2.25]){
sphere(2.5);
}}

rotate([0,0,rotation*i]){
translate([-5.5,0,2.5*i+2.25]){
sphere(2.5);
}}
}
}

translate([-1,-2,24]){
rotate([0,90,70]){
cylinder( h = 5, r = 1.5);
}}
}


I like the mathematical nature of openSCAD and definitely will be working on some more artistic prints based on matrices and trigonometry. The unit at right below still has the support material attached; which was required for such an odd shape. The material was relatively easily cut away with a razor knife. I then sanded with 220 and 300 grit paper and used an acrylic hobby paint to (hopefully) make the ends indigo.

If you like, they are for sale on Etsy