N-body simulations of star forming regions