Why does the room with less temperature involve more atoms in the given example? 
Suppose we have two rooms A and B that are the same size and connected by an open doorway, so the air has the same pressure and volume in both rooms. This means that
$P_AV_A = P_BV_B$ and $n_AT_A = n_BT_B$.
If room A is warmer than room B then $n_A < n_B$ so room B contains the greater mass of air.

I understand it from the equations but I want to be able to imagine it. Is it because the energy that comes from the sun increase the mean kinetic energy in the room that is closer to the sun and that results in higher probability of molecules moving into the other room in long enough period of time?
 A: Pressure can be thought of as the average force per unit area caused by molecules hitting the walls of the chamber, or the average rate of change of momentum of molecules hitting the walls.   The molecules of warm air have a higher average kinetic energy.  Higher kinetic energy means higher average speed.  Higher average speed means higher average momentum.  Higher momentum means a greater change in momentum when the molecule hits the wall.  So for constant $n$ and $V$, the chamber with the higher temperature will have the higher pressure.   If you open a channel between the two chambers molecules will, on average, move from the higher pressure chamber to the lower.  In fact, molecules move both ways.  But because the warmer molecules are moving faster than the cooler, more move from warm to cool than from cool to warm.  After the pressure equilizes, there will be more molecules in the cooler chamber.
A: It is not concerned with why A is warmer, just the fact that it is. Warm air expands more than colder air. So there is more mass in colder more dense air when the air pressure is equal.
