Lattice models are attractive, useful teaching tools and not easy to construct. The diamond lattice is a traditional example. Diamond crystallizes to form a cubic cell in which each carbon atom forms four bonds. The diamond lattice has octahedral symmetry and the view into each of the 12 edges of the cell is the same.
The Naval Research Laboratory in Washington has long had a Division for the Structure of Matter. NRL hosts a large collection of crystal lattice structures.
Note : The NRL no longer hosts these pages - new links below -
On one of their web pages I found a downloadable set of coordinates for the diamond unit cell.
As in "Buckyballs" I used a fortran program to make openSCAD module calls. Expand_diamond.f takes the unit cell coordinates of diamond, expands them to a 27 cell cube, and outputs the required calls.
I was surprised at how well the model printed. I recently installed a MK7 extruder which seems to produce cleaner results. There were 276 atoms in the first prints and all but four printed perfectly. Four atoms, two at each of two edges, slanted downwards and did not print well. I removed them from the model and began to get perfect prints.
The picture displays three of the models. The smaller version in the center shows the build surface; the atoms detached from the raft have marks on their surfaces. The larger models are about 65 mm on a side; the one on the right shows a view into an edge.
The fortran program used to generate the diamond openSCAD module calls, expand_diamond.f, is below as are the openSCAD program and the stl output that printed best.
I printed all my models using rafts. The stl file is oriented so that 23 atoms touch the build surface. The software makes 23 little pads which easily pop off the completed print to give a nice sturdy model. On examining a finished print it will be obvious where the missing atoms should go.
I've made several attempts to print more open models by decreasing the size of the carbon atoms but the results were not very good. If you want to try to print such a model you can, for example, change the atomic radius in the openSCAD atom calls from .5 to .3 and compile and render the code. It takes about 7 hours to render on my machine.