I hope the following applet is what you wanted.
You can change the size R of each particle(the mass of each particle is propotional R*R*R)
Maximum velocity can be adjusted with vi.
Total number of particles shown can be changed by right slider bar.

VIEW or DOWNLOAD ejs xml source
then click to translate strings for selected locale.

Press the Alt key and the left mouse button to drag the applet off the browser and onto the desktop.