среда, 27 августа 2014 г.

3D printing crystals

There is a nice paper on 3D printing molecular structures "How to print a crystal in 3D"

However, the method is a bit difficult, it requires many steps and strange soft like Blender. The most important problem is that Blender exports shell-like (mesh) files, rather than convenient solid objects. Converting meth into a solid looks like a simple task, but my FreeCad was unable to do it - it is far too complex task. I needed it to manually make supporting material.

Here I have devised a very simple method to obtain SOLID 3D model of a structure. You need only 2 tools: FreeCad and Excel + XYZ file of your structure.

Step1.
Import XYZ file into Excel and split it into several sheets with each sheet containing only one element. Find radii of your elements.

Step2.
Open FreeCad, Open Python console (menu - View-> Views-> Python console). Type there
import Part
from FreeCAD import Base

Step 3.
Open Excel, number your elements, and create formulae producing this kind of output per coordinate string. here 1.3 is the radius; atom coordinates are in the Base=(X,Y,Z)

sphere1= Part.makeSphere(1.3); sphere1.Placement.Base=(1.548109,12.749561,-1.8855); Part.show(sphere1)

See the file attached for better example. O column contains the final formulae

Step 4. Copy the whole column into python console of FreeCad. Wait. Repeat for every element, changing the radii and ensuring that the sequence numbers are unique.

You model is ready!

Update:
In order to make proper nice-looking balls, you should make supporting material yourself. I have tried making very narrow cylinders (they hold only Oxygen atoms).
 To do it, I have used the coordinates of Oxygen atoms, left only unique XY coordinate pairs in Excel (see page 3). The following function was drawing the cylinders:
sphere2001= Part.makeCylinder(0.06,21);
sphere2001.Placement.Base=(0,8.223867,0);
Part.show(sphere2001);


The radius (0.06) was selected the following way. My scale will be x6, so 0.06*2*6=0.72mm - the actual diameter of the supporting pillars

Комментариев нет:

Отправить комментарий