njoy / NJOY2016

Nuclear data processing with legacy NJOY
https://www.njoy21.io/NJOY2016
Other
96 stars 86 forks source link

zero awp values for non photon particles in MF6 cause HEATR crash #144

Closed whaeck closed 4 years ago

whaeck commented 4 years ago

It was brought to our attention that a division by zero occurred in HEATR with the Be10 evaluation from TENDL2017:

 njoy 2016.53  07Nov19                                       01/16/20 14:21:40
 *****************************************************************************

 moder...                                                                 0.0s

 reconr...                                                                0.1s

 ---message from rdf2bw---calculation of angular distribution not installed.

 broadr...                                                                0.1s
      293.0 deg                                                           0.1s
      600.0 deg                                                           0.2s
      900.0 deg                                                           0.2s

 heatr...                                                                 0.2s

 ---message from hinit---mf6, mt102 does not give recoil za=  4011
                          photon momentum recoil used.

Program received signal SIGFPE: Floating-point exception - erroneous arithmetic operation.

Backtrace for this error:
#0  0x7f2d8c7123ef in ???
#1  0x7f2d8d946dfc in df
    at /home/wim/Projects/NJOY2016/njoy2016-photoatomic/src/heatr.f90:2031
#2  0x7f2d8d93fa56 in sixbar
    at /home/wim/Projects/NJOY2016/njoy2016-photoatomic/src/heatr.f90:2835
#3  0x7f2d8d94ab53 in nheat
    at /home/wim/Projects/NJOY2016/njoy2016-photoatomic/src/heatr.f90:1653
#4  0x7f2d8d958164 in __heatm_MOD_heatr
    at /home/wim/Projects/NJOY2016/njoy2016-photoatomic/src/heatr.f90:375
#5  0x401ca8 in njoy
    at /home/wim/Projects/NJOY2016/njoy2016-photoatomic/src/main.f90:205
#6  0x401f01 in main
    at /home/wim/Projects/NJOY2016/njoy2016-photoatomic/src/main.f90:112
Floating point exception

This can be reproduced with the following ENDF file and input file: input2.txt n-Be10-tendl2017.endf.txt

whaeck commented 4 years ago

The issue occurs in the df function (line 2004 in the heatr.f90 file) which is used to calculate damage energy. The division by zero occurs in the following lines (line 2030-2031):

      denom=(zr**twothd+zl**twothd)**threeq*ar**onep5*sqrt(al)
      fl=c2*zr**twothd*sqrt(zl)*(ar+al)**onep5/denom

The value of ar appears to be zero for a non photon secondary particle, these values are read directly from the evaluation.

The evaluation in question appears to have zero atomic weight ratio values for some of the MF6 subsections. This appears to happen for the following MTs and particle subsections in MF6: MT22, particle 2006 MT24, particle 2005 MT106, particle 2008 MT107, particle 2007

whaeck commented 4 years ago

A branch was created (https://github.com/njoy/NJOY2016/tree/fix/tendl-zero-awr) to detect this issue in the future and to make NJOY exit gracefully. As this is an issue related to an error in an evaluation, we cannot fix this problem.

I'll do a proper pull request next week.

@jchsublet You may want to take note of this one.

jchsublet commented 4 years ago

@whaeck I will thank you but you may also take this to the true evaluator(s) for B010 and B011, much nearer to you, as they are copy of ENDF/B-VIII.O in TENDL-2017, and TENDL-2019

paulromano commented 4 years ago

The original issue said Be10. Are we talking about Be10 or B10?

kahlerac commented 4 years ago

All, There seem to be two different threads on this topic. Below is what I sent out on the other thread a few hours ago ... " All, Wim's (and Mike's) email points to TENDL-2017 Be10, not B10. I've checked these subsections and agree that its an evaluation file error. See the attachment where I've pulled out the relevant lines where outgoing particles are defined. It seems like residuals up to 4He are ok but heavier residuals in these subsections have the bad awp=0. This is not an issue with TENDL2019 10Be as none of these mf6 subsections are present in that file. I haven't checked the other files noted by Mike, nor have I checked whether the issue has made it into the other TENDL-2019 files. " Skip

On Fri, Jan 17, 2020 at 3:46 PM Paul Romano notifications@github.com wrote:

The original issue said Be10. Are we talking about Be10 or B10?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/njoy/NJOY2016/issues/144?email_source=notifications&email_token=AEHJISIHM3TQUUW7PEVTDDDQ6IKJJA5CNFSM4KH22W4KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJI5N4Q#issuecomment-575788786, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEHJISMMZJZ7QG2GDLWEHULQ6IKJJANCNFSM4KH22W4A .

-- Dr. A. C. (Skip) Kahler Kahler Nuclear Data Services, LLC kahler3ac@gmail.com +1 321 368 3645

mat428/mt22 header and neutron emission with correct awp: 4.010000+3 9.927514+0 0 3 4 0 428 6 22 1 1.000000+0 1.000000+0 0 1 1 2 428 6 22 2 2 2 428 6 22 3 8.155880+6 1.000000+0 2.000000+8 1.000000+0 428 6 22 4 . . .

mat428/mt22 alpha emission with correct awp: 2.004000+3 3.968219+0 0 1 1 2 428 6 22 58 2 2 428 6 22 59 8.155880+6 1.000000+0 2.000000+8 1.000000+0 428 6 22 60 . . .

mat428/mt22. Oops 6He emission but awp=0: 2.006000+3 0.000000+0 0 1 1 2 428 6 22 79 2 2 428 6 22 80 8.155880+6 1.000000+0 2.000000+8 1.000000+0 428 6 22 81 . . .

mat428/mt24 header and neutron emission with correct awp: 4.010000+3 9.927514+0 0 3 4 0 428 6 24 1 1.000000+0 1.000000+0 0 1 1 2 428 6 24 2 2 2 428 6 24 3 1.003860+7 2.000000+0 2.000000+8 2.000000+0 428 6 24 4 . . .

mat428/mt24 alpha emission with correct awp: 2.004000+3 3.968219+0 0 1 1 2 428 6 24 80 2 2 428 6 24 81 1.003860+7 1.000000+0 2.000000+8 1.000000+0 428 6 24 82 . . .

mat428/mt24. Oops 5He emission but awp=0: 2.005000+3 0.000000+0 0 1 1 2 428 6 24 118 2 2 428 6 24 119 1.003860+7 1.000000+0 2.000000+8 1.000000+0 428 6 24 120 . . .

mat428/mt106 header and 3He emission with correct awp: 4.010000+3 9.927514+0 0 3 3 0 428 6106 1 2.003000+3 2.990120+0 0 1 1 2 428 6106 2 2 2 428 6106 3 2.846720+7 1.000000+0 2.000000+8 1.000000+0 428 6106 4 . . .

mat428/mt106. Oops 8He emission with awp=0: 2.008000+3 0.000000+0 0 1 1 2 428 6106 23 2 2 428 6106 24 2.846720+7 1.000000+0 2.000000+8 1.000000+0 428 6106 25 . . .

mat428/mt107 header and 4He emission with correct awp: 4.010000+3 9.927514+0 0 3 3 0 428 6107 1 2.004000+3 3.968219+0 0 1 1 2 428 6107 2 2 2 428 6107 3 8.606860+6 1.000000+0 2.000000+8 1.000000+0 428 6107 4 . . .

mat428/mt107. Oops 7He emission with awp=0: 2.007000+3 0.000000+0 0 1 1 2 428 6107 114 2 2 428 6107 115 8.606860+6 1.000000+0 2.000000+8 1.000000+0 428 6107 116 . . .

jchsublet commented 4 years ago

@paulromano Mea culpa Be isotopes it was an no B !! and for Be10 and Be11 TENDL-2017 MF6 is incorrect as Skip pointed out, but then my very similar HEATR sequence did not crashed, having said that division by 0 and FFLAGS have a said in the matter. So the for the above the files, the evaluation are at faults, definitely

As TENDL-2017 has just been superseded by TENDL-2019 (That's include quite a few format correction) I have checked the above input2.txt sequence with NJOY2016.53 and its works without crashing for TENDL-2019, Be010, Be011 and CO14. More complex HEATR sequences were achieved in the production of the Ace-TENDL-2019 library.

whaeck commented 4 years ago

This will now be detected in NJOY2016.