Ethan A Merritt wrote:
On Friday 28 November 2008, Mueller, Juergen-Joachim wrote:
Dear all,
does anybody know a program to
fill an unit cell a,b,c randomly by an arbitrary number
of spheres (atoms)?

First you would need to define "random".
 Uniform density throughout the lattice?
 Uniform distribution of neighbor-neighbor distances?
 Uniform fractional coodinates?
 Must the placement conform to space group symmetry?

Although I am sure it was not intended, this might suggest
to some that uniform is equivalent to random-
actually they are the opposite: a random distribution would
have large areas with nothing and other places where two or
three spheres are almost on top of each other.
A uniform distribution is, well, uniform.

Most programming languages have a function to generate a random
number evenly distributed between 0 and 1. Decide how many atoms
you want, get three random numbers for each atom, and those are
your fractional coordinates of your random spheres. Coordconv will
convert to orthogonal angstroms given your cell parameters.

Applesoft came with a BASIC program to do this in two dimensions-
start with a white screen and paint random pixels black for as
long as you let it run. Some black patches developed early on,
and some pixels remained white for hours, not because the random
number generator was faulty, but because that is the nature of
randomness.

Reply via email to