add TOTAL_PARTICLES, move Particle declaration