compas / grasp

General Relativistic Atomic Structure Package
https://compas.github.io/grasp/
MIT License
55 stars 25 forks source link

Parity issue in GRASP #6

Open cffischer opened 5 years ago

cffischer commented 5 years ago

The parity issue that was first observed by Kai and traced to the SETCSLL.f90 routine in LIB9290 is present also in other locations of GRASP2018. It was found to be present in RMIXACCUMULATE.f90.

GRASP2018 is a parameterized software package. The default maximum number of orbitals is 127, so we require NCLOSED + NPEEL <= 127. Actually, when reading a CSF file, it is easy to determine the both of these variables and check this constraint. But, more important, NPEEL determines the maximum length of the "lines" that define the CSFs. It is not necessary to simply chose a number.

I have not analyzed all or RMIXACCUMULATE.f90 but the problem disappeared by replacing all dimensions "100" by "200". I suspect the same to be true also for RMIXEXTRACT.

jongrumer commented 5 years ago

So, to keep this issue up to date: @cffischer have now submitted quick fixes to some of the tools routines, extending to dimensions of 200 - these are now in the master branch - but we still need to follow her advice and realize that grasp is a parametrized package, i.e. we should require new code to use e.g. NPEEL to set the maximum length of CSF strings, instead of just choosing a random long enough number. I will try to adhere to this for all new submitted code.