*To*: mathgroup@smc.vnet.net*Subject*: [mg11186] lattice definition: help*From*: Christofer Edling <cedling@sociology.su.se>*Date*: Wed, 25 Feb 1998 03:31:55 -0500*Organization*: Algonet/Tninet

I would be most grateful if someone could help me with this one. I've tried to solve the problem with the "Table" function without much success. I wish to generate an n*n lattice with the following characteristics: 1. Each cell in the lattice can be in one out of three possible states, i.e. A,B,C. 2. The distribution of states across the whole lattice is defined by user input, i.e. 30% A's, 20% B's, 50% C's. 3. Given the defined distribution, each cell in the lattice should be randomly assigned a state (A,B or C). Any suggestions appreciated, Christofer (cedling@sociology.su.se)