# [lammps-users] How to calculate Mobility of ion under electric field in LAMMPS?

Dear LAMMPS Users,

I would like to calculate the mobility of ions after applying an electric field to calculate the diffusion coefficient.

I did not find any direct option to calculate the mobility in the LAMMPS manual, is there anything that I overlooked?

Alternatively, It is possible to calculate the mobility from the drift velocity, but I also did not find a way to calculate the drift velocity. Is there anything that can be done from the COM velocity of the atom group? Pardon me if I am missing something very in general.

Thank you
Jeams

Why would the computation of (self-)diffusion depend on the presence of an external field?

This is something I am trying to sort out, in the literature the relationship between mobility and diffusion coefficient is

D= uKT/ze, (u=mobility)

What I understand this mobility is only contributed by the velocity generated due to the electric field.
I would like to calculate the diffusion coefficient in both ways!

Thanks
Jeams

This is something I am trying to sort out, in the literature the relationship between mobility and diffusion coefficient is

D= uKT/ze, (u=mobility)

What I understand this mobility is only contributed by the velocity generated due to the electric field.
I would like to calculate the diffusion coefficient in both ways!

sorry, I don’t understand what you are getting at here.

common sense tells me that the contribution from the electric field to D would be the difference between two calculations of D, one with the electric field present and one without.

the relation above doesn’t explain why computing the diffusion would need to be different. on the contrary, once you have D and KT and z and e, you can compute u.
since D is accessible, I don’t see why you would first want to compute u (which is not) only to use it to compute D.
that logic seems to me inverted.

axel.