I'd like to create a simple model that demonstrates the basic values of thermodinamics of an ideal gas. I begin with two rooms, several molecules in them. Every data of every individual molecule is given (position, mass, speed, etc), so I can easily calculate the total energy, pressure, temperature. Now I open up the small door between the two rooms and I can easily model how the molecules mixing, causing the two rooms finally balancing their temperature and pressure. But I have problems with calculating the entropy. Can you please help me? Is there a formula for this? (If it is necessary, we can say that the available positions of the molecules are limited) Thanks in advance.