Multiwfn official website: http://sobereva.com/multiwfn. Multiwfn forum in Chinese: http://bbs.keinsci.com/wfn
You are not logged in.
Hello,
I am trying to obtain the electronic spatial extent using different software. To do so, I modified the settings.ini file in Multiwfn by setting iuserfunc = 3.
Multiwfn returns a value of 21092.4988259881, whereas my g16.log output gives 18436.6750. Is there a specific reason that could explain such a discrepancy?
I am unable to upload my files to the forum due to their large size, but could you please confirm whether my procedure for obtaining ⟨R²⟩ using Multiwfn is correct, or if I might be doing something wrong?
Thank you
Offline
I think you ran Multiwfn in a wrong way. Taking H2O as an example:
%chk=C:\gtest\H2O.chk
#p hf/6-31G*
test
0 1
O -0.00000000 -0.00000000 0.11930800
H 0.00000000 0.75895300 -0.47723200
H -0.00000000 -0.75895300 -0.47723200
The <r^2> outputted by Gaussian is
Electronic spatial extent (au): <R**2>= 19.0512
If you set iuserfunc to 3, and boot up Multiwfn and load the .fch file produced by the above task, then run
100
4
100
You will obtain
Final result: 19.051245015
which is exactly the same as that outputted by Gaussian
Offline
Okay, this is strange — I noticed that even though I set iuserfunc = 3, it still remains at 0.
So, I decided to use the development version instead of the binary one. However, I couldn't find where the value of iuserfunc is defined in the code. There is no settings.ini file when compiling the code directly.
Can you please tell me wehre the c80tmp (I guess) is defined so I can directly recompile the code. Thanks!
Offline
I just realized that there's no need to modify the settings.ini file (which I could not find in the source code btw).
Launching Multiwfn → 300 → 5 returns the electronic spatial extent.
For some reason, this feature isn't mentioned in the manual — or did I miss it?
I discovered this while digging through the source code
Last edited by Ainosya (2025-05-17 16:23:24)
Offline
settings.ini is in the binary package of Multiwfn, not in source code. You never need to modify or check source code.
After setting iuserfunc to 3, you need to reboot Multiwfn, and you need to make sure that there is no warning shown on screen indicating that Multiwfn didn't find settings.ini.
Please make clear how Multiwfn finds settings.ini.
3.8 Development version also has binary package. I strongly suggest using latest development version, and never using the out-of-dated version 3.7.
Offline
I guess my previous messages were unclear. I have version 3.8 and decided to switch to the source code package.
In doing so, I realized that neither the source code nor the settings.ini file needs to be modified, since this feature is already available in the code—although it's not mentioned in the manual for some reason.
However, since there is no settings.ini file in the source code package, I would like to know how to configure the user-defined functions in case I need to adjust them later
Last edited by Ainosya (2025-05-17 17:12:39)
Offline
After compiling source code, directly copying settings.ini from binary package to source code folder (or where you want to put Multiwfn).
Offline
Offline
After compiling source code, directly copying settings.ini from binary package to source code folder (or where you want to put Multiwfn).
Oh, okay.
I wouldn’t have expected to need to do that, since it means I have to download both somehow.
Thanks!
Offline