In grasshopper there is a component to generate one crystal. David Rutten has done a script to make crystals
also