Gamess-US: automatic compilation on Raspberry Pi model 4B
Motivation:See main part for compiling Gamess-US. I pay homage to Mark Gordon and his team (tongue in cheek!): A full Gamess on a credit card computer, smaller is impossible (until next year)! See my entry for the first realization of Gamess on the RPi in 2016 ...
(Btw, NWCHEM 6.8.1 - full version - is included in the Rpi-4 repository "Add/Remove Software", and installed by one click. It is precompiled and runs immediately! It can replace most of and has modules not available in Gamess.)
Our script automatically builds a new version of Gamess-US 30 September 2019 (R2) on RPi's Debian Linux system. After compilation of several hundred fortran source files with gfortran 8.3, these are linked to gamess.00.x, then the test suite of the gamess package is run and results checked. It takes about 1 hour with RPi 4B-4GB (5 times faster than with RPi 3B+
Here are the details: For the following to make sense, we assume that you have obtained a password and downloaded gamess-current.tar.gz or gamess-current.tar.Z from Gamess-US into your home directory /home/$USER, usually /home/pi.
Now download and save the script raspigam19pi also in /home/$USER
Overview of procedure:Running the script raspigam19pi automatically downloads all necessary programs and libraries. Then it starts a build script buildgamess192pi. This unpacks the Gamess tarball, edits all required scripts from the Gamess-US distribution to reflect RPi's environment, and finally builds gamess.00.x. This takes about 50 min! When successfully finished, the test suite starts, running 47 short Gamess jobs which engage a large number of the computational tools embedded in Gamess. This takes another 10 min including a comparison of the results to a table of correct numerical values that ends the fully automated procedure.
All timings now pertain to RPi 4B-4GB: In about 58 min, gamess.00.x and some other execs are made and Checktst tells you: All 47 test results are correct. Congratulations! your Raspberry Pi now groks Gamess which is permanently installed on RPi's SD card. Here is the summary of a build session with RPi 4B-4GB.
This is a 32-bit build! It needs several corrections to comp and lked (gamess 30 JUN (R1 patch1) and Gamess 30 SEP 2019 (R2)) which are automatically applied by buildgamess192pi.
Note: The RPI-4 (NOOBS 3.2.1) is a 64-bit arm-system. But the 64-bit kernel for this is still in development as of Oct 27, 2019). It is possible to compile ddikick and gamess after applying these commands: sudo rpi-update (which loads kernel8.img) and arm_64bit=1 added to /boot/config.txt and reboot, then giving uname -m (not -p) "aarch64" instead of "unknown" as before. You have to correct uname -p to uname -m in compddi, comp, compall, and lked.
6 out of 47 tests of gamess do not give correct numerical results and 2 do not run to normal completion, however. In a few months the 64-bit kernel should be operational! Meanwhile the 32-bit Gamess runs flawlessly, even on the 64-bit Rpi.
You can download several runs of practical interest from RPi Gamess in the samples directory (Note: in this, all timings are for the RPi 2B. They are halved for RPi 3B). Eg computing the structure, the energy, orbitals and several properties of benzene takes 3.6 min, for SiF4 62 sec, for Ethene 14.6 sec (all approx. 20 times slower than on a i7-2900, 3.4 GHz). The slowest job is SiF4_g3mp2. It accurately computes the formation enthalpy of gaseous SiF4 at 0 and 298 K with a complex series of routines, taking 144 min on the RPi B2.
The same output with Raspberry Pi, model 4, are given with the endings "-4". Compare the CPU or wallclock times. For SiF4_g3mp2 it takes 4.25 min instead of 144 min! RPi 4 can now make use of the 4 cores for parallel execution with the ddikick.x routine of Gamess (this did not work with the predecessors).
Running jobs: Now you can run new jobs by composing correct inputfiles, jobname.inp, in ~/gamess, see .inp files in samples or exam??.inp in ~/gamess/tests/standard, and the commandline:
./rungms jobname > jobname.log ↵
The output file *.log is a text file and can be studied with a text reader, editor, printed out, or read-in to a visualizer program.
Instead of using the terminal and writing an input file it is much more fun to use one of several graphical programs to compose such a file. One of the most outstanding ones is WebMO, now version 19.0.009 (Sept. 2019). In the internet browser you can draw a molecule and then let the program write the input file for the properties you want computed, save and run it! WebMO runs perfectly on Raspberry Pi 4 and is easy to install with excellent support.
This prize-winning, web-based interface for computational chemistry, also exists as an App for iPhone/iPad (free of charge). This allows to compose e.g. a Gamess computation from where your mobile is, send it to your Raspberry Pi (in the local network or even on the web with a forwarded IP) to run the job and get the results back to you for visualizing and printing! What a feat for doing simple quantum chemistry in the class-room!
back to QC