ColRadPy
ColRadPy copied to clipboard
Bugfix for reading ADF04 files
I encountered a bug reading an ADF04 file for neutral tungsten where the J numbers of the levels were not being parsed correctly. The cause appears to be that ADF04 files are inconsistent about putting a space before the J number. For example, the be1+ file has the ground state as (2)0( 0.5) (space before 0.5), while the w0 file I'm using has the ground state as (5)2(0.0) (no space before 0.0).
I fixed this by changing the regular expression format for processing the level information. This works for the w0 file I'm using and the be1+ file used by the example, but I haven't tested this extensively.