refactored particle initialization functions