Creating velocities with non uniform/gaussian distribution

Hello, I need to create an ensemble of velocities with a Maxwellian distribution. Any suggestions on how to do it??

Thanks in advance

Why do you need to have exactly a Maxwell distribution and cannot use the Gaussian distribution?

Once you have applied those velocities, what are you going to do with the system?

I am equilibrating the system after creating velocities, but I wanna see how the results are affected by using different distributions.

Well, you already have uniform and Gaussian distributions directly available. The Maxwell distribution is very similar to the Gaussian distribution, specifically if you would have atoms with all the same or very similar masses. So there is not much more to learn.

Common knowledge is that the choice of initial velocity distribution can be ignored since the behavior during equilibration is usually dominated by the potential energy distribution (unless your initial geometry is a minimum potential energy geometry). The impact from the initial velocities will very quickly dissipate. While you still get different trajectories, their differences are equivalent to the differences you get from using different random number seeds.

Thanks for your response

While this is off-topic, I am very curious (and a little confused). Surely a Gaussian distribution of (vector) velocities produces a Maxwellian distribution of (scalar) speeds – and thus the LAMMPS velocity create dist gaussian command already does just what you want.