If you get a match, then you can use mpi parallelization. Next step is to check how many CPUs your computer has with lscpu command. and whether nwchem distributes the process among all available available ones. Run the command again and in another shell run top. If the number of CPUs is bigger than 1, but there is only one nwchem process, then you must explicitly run nwchem in multiple cores. You should run instead:linux$ ldd /usr/bin/nwchem | grep libmpi
Not the entire optimization process is completely parallelizable, so parallelization does not meant that if you run the process in 4 cpus, it will take 4 times less time, but for sure will improve it. Improvement also depends on the kind of calculation you are performing. Some tasks are more paralellizable than others.linux$ mpirun -n <number of cpus> nwchem l-proline
Once you achieved the optimized geometry, the output files are what you need for performing other calculations with it. But if you want as output a new xyz file for visualization or other purposes (even using this optimized geometry in a geometry block of another nwchem file), you can print it, by including
This command will generate a new xyz file for each optimization step performed. So, lets modify our nwchem input file:driver xyz l-proline_opt end
(we don't need the geometry block here, as we will work with the generated vector files, but if you do include it, it will be ignored)basis * library 6-31g end driver xyz l-proline_opt end task scf optimize
As we are working with an already converged solution, nwchem will perform some few more steps (and then discover that convergence was already achieved), so you will get some few l-proline_opt* files, consecutively numbered. The last one contains the optimized geometry. You can then do:
and open the file with jmol for visualization.linux$ babel l-proline_opt-002.xyz l-proline.mol
You can also use the optimized geometry for a further task instead of the nwchem output vector files. You can generate the last exactly in the same way we generated them the first time, but with the optimized xyz file instead in the geometry block. As geometry is already optimized, nwchem will achieve convergence very fast, in a pair of steps. Even faster, you can use task scf energy instead of task scf optimize. This will generate all the vector files without performing any optimization.
A typical strategy for optimizing molecule geometry with a higher order (more accurate and more CPU demanding) basis set, is to pre optimize molecule geometry with a fast, less accurate one, so the optimization with the higher one will take really much less time. For example, after we got an optimized state with 6-31g, we can run a further one with cc-pvdz:
basis * library cc-pvdz end task scf optimize