Posted on

Compilers

Back in college (Colombia), having access to powerful software was really difficult. If you plugged a usb drive into any pc running windows in campus you’d get a virus, and buying software was an expensive dream. The best alternative is switching to software libre. You get plenty of versatile programs, but at the cost of learning how to program in many languages. Sometimes it’s frustrating, especially when dealing with wifi and other accessories.

Anyway, at this point I’m feeling temptation by the dark side to try intel libraries, math kernel library (mkl), for example. It seems faster than other free libraries.  It’s interesting this mkl is available to you at no cost… if you are a student, researcher, or open source developer. These libraries are compatible with libre gnu compilers. But some folks might think, “I should keep everything under intel’s control”. If you’re a student you can download their ifort and icc, $0. But researchers must purchase it for only $700. Apparently, you could get a 50% discount…
Posted on

Excited-state Light Absorption

Scheme I: Caffeine molecule, in electronic state S1, being probed by alien


I totally forgot to write something about this paper. But before getting to that, an anecdote: Last month some friends and I were sitting out in a hallway of one of the hotels hosting the ACS national meeting. We were definitely looking tired. A guy, who seemed to be experienced in hiring, started talking to us about not giving up and practice more on elevator conversations: your ability to ultra-summarize your work to others. He did spend some time sharing his experiences with us. We must’ve looked really tired (especially me)…

So here is that elevator report for you (web visitor): We got a paper published on estimating the absorption spectrum of excited-states, here. You select an excited state (based on its symmetry, transition energy and oscillator strength from the ground state), and the program outputs its absorption spectrum (in terms of oscillator strengths). 

With some extra details, you run a regular linear-response “TDDFT” calculation (starting from the ground-state orbitals),  and choose the state. The algorithm perturbs the orbitals using the transition vectors of the chosen state, and then runs the linear-response calculations once again. At the end it prints out the oscillator strengths for transitions starting from the chosen excited-state. The tests I’ve run indicate the printed results are ok against experimental data. The paper is backed by a theory based on quantum mechanics (exact in principle), and the approximations are improvable.

If somebody paid me for an honest brief review of this paper, I’d say: Incomprehensible, intricate, complicated, but seems useful. I love it, but I understand the formalism is hard, but the implementation is quite simple. Applications to organic semiconductors are coming

Posted on

Chaotic Microchips

                                                    Anarchy(chaos)+Microchip = Happiness
“Chaos” is an interesting word in science, maybe ’cause is synonym of (according to thesaurus.com): anarchy, disorder, lawlessness, pandemonium, among others?. Aren’t those words that draw our attention? (Many movies are about creating disorder and the journey of some folk trying to restore order). Anyway, it’s been a while since the last post… my bad. 

 
I found this article about microchips operating under chaotic conditions https://news.ncsu.edu/2016/09/kia-mooreslaw/
Like 99% of the time, I don’t understand the full operation. But the authors fabricated an integrated circuit that exploits the dynamical, non-linear behavior of the system (scientific paper here). It seems the circuit receives a combination of binary inputs, like 01, and the circuit shows a distinguishable response to it. The circuit is capable of identifying when the response is chaotic or stable periodic (if I understand correctly). I think the final goal would be developing circuits able of performing the function of many traditional transistors, exploiting complexity instead of miniaturization 

 

Posted on

El Capitan drinks Quantum Espresso

To compile a slow version of quantum espresso for an iMac: i) Download last version, and extract somewhere. ii), use this script, “qe_conf.sh”:


FL=-L/opt/local/lib -lfftw3
CC=gcc
F77=gfortran
LAPACK_LIBS=-L/lapack-folder -llapack -lrefblas
BLAS_LIBS=-L/lapack-folder -lrefblas

./configure CC=$CC F77=$F77 LAPACK_LIBS=$LAPACK_LIBS
  BLAS_LIBS=$BLAS_LIBS FFT_LIBS=$FL –enable-openmp

If you don’t have fftw libs type in a terminal “sudo port install fftw-3“. Follow the steps from previous post to get consistent mpi commands. iii), Build your module typing “make X”, where X = pw, ph, pwcond, etc. Note: There is an ATLAS package that can be installed with port, but I don’t know yet how much it will speed up the computations. 
Posted on

NWChem in El Capitan

I installed it in a mid 2011 iMac, and used gcc compilers. First, get the right compilers (or make sure gcc5, or alike, is installed). 

sudo port install gcc5 +gfortran+universal 

(I needed to make symbolic links in /opt/local/bin for gfortran, gcc, g++, and cpp. Port installs them as gsomething-mp-5). Also make sure you have mpich. If not, type 

sudo port install mpich-gcc5

then 

sudo port select –set mpi mpich-gcc5-fortran

This last step is to use the mpi commands linked to gcc, instead of clang.

Download nwchem-6.6 from here, and extract the .tar.gz file into some folder. The environmental variables are:

export NWCHEM_TOP=`pwd`
export NWCHEM_MODULES=all
export NWCHEM_TARGET=MACX64
export CFLAGS_FORGA=-DMPICH_NO_ATTR_TYPE_TAGS
export USE_MPI=y
export USE_MPIF=y
export USE_MPIF4=y
export CFLAGS_FORGA=-DMPICH_NO_ATTR_TYPE_TAGS
export LIBMPI= -lmpifort -lmpi -lpmpi -lpthread
export BLASOPT= 
export FC=gfortran
export CC=gcc

To compile:

cd $NWCHEM_TOP/src
make nwchem_config


make

All these variables and make commands can be written into a my_comp.sh file and just be run as “sh my_comp.sh”. I ran some QA tests and they looked fine. Finally, note that blasopt is empty. NWChem uses its internal BLAS. I tried to compile ATLAS to get optimize libraries but failed in the attempt :_(   Apparently, ATLAS has some issues working with Apple machines from Hell.
Posted on

Deleting Native Apps in Mac OS X

I like to keep my mac laptop with minimal number of apps. El Capitan comes with an additional protection feature that does not let you delete native apps. The solution is to reboot the computer, while the screen is dark hold command+r to enter recovery mode. Once there open a terminal and type “csrutil disable”. Then restart, find the app, change its permissions, and delete; you could also do this by entering the applications folder and typing “rm -rf /Applications/dying.app”. Then go back to recovery mode, open a terminal and type “csrutil enable” to reactivate the feature.

Posted on

Finding Cutoffs for Quantum Espresso Calculations

Critical numbers to check before running plane-wave calculations are the kinetic energy and density cut-offs. I found a useful guide to check these cutoffs, http://larrucea.eu/checking-optimum-cutoff-qe/. I uploaded a copy here. The script needs the location of the pseudopotential file and the executable, pw.x, location. One can modify the script, for example changing the numbers in the list of trial cutoffs to search for the best numbers. For ultrasoft potentials I guess one has to make sure the density cutoffs are high enough so the calculations for the last values in the list of kinetic energy cutoffs are reliable enough. [Update: the new QE library based on rrkjus pseudopotentials includes the cut-offs]

Posted on

2d Silicon Hybrid Material

I noticed an article on a new 2d sheet combining silicon, nitrogen, and boron. It’s another honeycomb-shaped system, challenging the almighty graphene When I first read the news article I thought this had been synthesized, which would’ve been really nice. But at this point the work is only computational, but it’s still quite interesting. There are so many candidates for 2d semiconductors out there… makes me think, which one will be the king? Link

Posted on

JPCA Paper Out

We finally got our paper on hybrid functionals and the local density approximation (lda) accepted. This work presents some basic conditions hybrid XC functionals should satisfy and a discussion on the balance between correlation, HF, and local exchanges. We suggested an adiabatic functional, cam-lda0, which can be used to speed up calculations a little bit. Copies available at the JPCA website, here

This paper started after thinking for a while about the pbe0 xc functional. Our impatience and desperation with cluster computations led us to consider removing the gradient contributions. We then further did this for cam-b3lyp, and noted that the gaps did not change significantly.
I’m proud this is the birth of a new field, “functional dedeveloping”
Update 08/2020: Functional dedeveloping has led us to domain separated DFT. Will post more about it later…
Posted on

Ravens and the Theory of Mind

These birds are among the smartest flying beings. A recent study claims proving that ravens are capable of anticipating what other birds might do. This would mean ravens have a theory of mind, they could think as if they were other birds. This is simply fascinating. Ravens are quite intelligent mammals, and, I think, very clever. Perhaps, a theory of mind can help them to secure food resources, plan strategies. There are many other studies, even in TV shows, illustrating their relative brilliance. The Washington post announced this study