So, with a lot of tries and errors I've found out how to perform such analysis. I'm using a library for Python called MDAnalysis. It can load Gromacs topologies and extract charges from them. Using them dipole moment for each molecule can be easily calculated and ordering parameters can be calculated from it.
Here is the code. It may not be perfect, but it ...
I think VASP has limited electric field ability right now, but someone may come along later and correct me. If you have a surface in the Z direction, you could enable an electric field as such.
EFIELD = X # Units eV/A
IDIPOL = 3 # Z direction
LDIPOL = .TRUE. # Enable dipole corrections
These PDEs are typical diffusion-drift PDEs that arise in a huge number of fields (including my field, which is electrochemistry) and are routinely solved using any numerical method of your choice, e.g. finite difference method and finite element method, in both open-source and commercial software. Nonlinearities are generally not an issue in my experience ...
From the ORCA forum thread:
Actually there is an undocumented feature for this purpose:
efield X-field-strength-in-a.u. , Y-field-strength-in-a.u. , Z-field-strength-in-a.u.
I have used it to compare dipole moments obtained via numeric and analytic differentiation and it worked fine. But do be careful as undocumented features do not officially ...
You could simplify long range interaction by reducing precision with range. Useful algorithm for it is:
It is usually used for gravity, but it can be applied for other forces too. With it you can do something better than just to ignore long range interaction, as is usually done, especially important ...
I assume that you have relaxed your geometry structure and can perform the VASP calculation. And I support the necessary input cards for SCF and NSCF calculations below.
SCF calculation to obtain the converged charge density and wavefunction:
From looking at the very long wavelength you specified, I assume your intent is to apply a static field to the calculation?
I read here that EFIELD is intended for applying laser pulses and that you should use EXTERNAL_POTENTIAL instead, with the READ_FROM_CUBE option.
Not sure whether printing the imposed potential is possible, but you could print the ...