The function stateq() is called separately for each species, but the species number is not passed to the call to getjbar(), which just returns values for species 0. Of course where there is only 1 species, this is harmless. For >1 species, ok even if getjbar() were fixed, the cross-excitation would still not be calculated properly, but returning jbar values from species 0 for species !=0 is simply wrong.
The function
stateq()is called separately for each species, but the species number is not passed to the call togetjbar(), which just returns values for species 0. Of course where there is only 1 species, this is harmless. For >1 species, ok even ifgetjbar()were fixed, the cross-excitation would still not be calculated properly, but returningjbarvalues from species 0 for species !=0 is simply wrong.