This is work towards solving #160. I have changed all real data types to the new rk data type, which stands for "real kind". Currently it is hardcoded to double precision, but might be user-configurable in the future. Currently if you try to switch rk to SP for single precision, SUMMA will crash. Further work needs to be done to make SUMMA run in single precision mode.
Because this changes the data types of some variables, the test cases are not quite bit for bit. Here is a summary of the differences:
Test 1 - Filename: colbeck1976-exp1_output_testSumma_timestep.nc - Total difference: 0.0
Test 2 - Filename: colbeck1976-exp2_output_testSumma_timestep.nc - Total difference: 0.0
Test 3 - Filename: colbeck1976-exp3_output_testSumma_timestep.nc - Total difference: 0.0
Test 4 - Filename: millerClay_output_testSumma_timestep.nc - Total difference: 0.0
Test 5 - Filename: millerLoam_output_testSumma_timestep.nc - Total difference: 0.0
Test 6 - Filename: millerSand_output_testSumma_timestep.nc - Total difference: -6.570511291260431e-08
Test 7 - Filename: mizoguchi1990_output_testSumma_timestep.nc - Total difference: 0.0
Test 8 - Filename: vanderborght2005_exp1_testSumma_timestep.nc - Total difference: 0.0
Test 9 - Filename: vanderborght2005_exp2_testSumma_timestep.nc - Total difference: 0.0
Test 10 - Filename: vanderborght2005_exp3_testSumma_timestep.nc - Total difference: 0.0
Test 11 - Filename: syntheticHillslope-exp1_output_testSumma_timestep.nc - Total difference: -1.6131971171259817e-17
Test 12 - Filename: syntheticHillslope-exp2_output_testSumma_timestep.nc - Total difference: -5.771809888405136e-18
Test 13 - Filename: vegImpactsRad_output_riparianAspenBeersLaw_timestep.nc - Total difference: -5.177737458224159e-13
Test 14 - Filename: vegImpactsRad_output_riparianAspenCLM2stream_timestep.nc - Total difference: 6.579920432262072e-09
Test 15 - Filename: vegImpactsRad_output_riparianAspenNLscatter_timestep.nc - Total difference: 6.136295046746317e-13
Test 16 - Filename: vegImpactsRad_output_riparianAspenUEB2stream_timestep.nc - Total difference: 5.301658083232525e-12
Test 17 - Filename: vegImpactsRad_output_riparianAspenVegParamPerturb_timestep.nc - Total difference: 2.400837730784174e-13
Test 18 - Filename: vegImpactsWind_output_riparianAspenWindParamPerturb_timestep.nc - Total difference: 7.031383693352904e-14
Test 19 - Filename: vegImpactsWind_output_riparianAspenExpWindProfile_timestep.nc - Total difference: -1.0280793821001345e-12
Test 20 - Filename: storckSite_output_hedpom9697_timestep.nc - Total difference: 4.558832319982082e-13
Test 21 - Filename: storckSite_output_hedpom9798_timestep.nc - Total difference: -3.703437631218098e-12
Test 22 - Filename: storckSite_output_storck9697_timestep.nc - Total difference: -4.381672471020549e-12
Test 23 - Filename: storckSite_output_storck9798_timestep.nc - Total difference: 3.817093693456722e-12
Test 24 - Filename: albedoTest_output_reynoldsConstantDecayRate_timestep.nc - Total difference: -4.0012084632823866e-14
Test 25 - Filename: albedoTest_output_reynoldsVariableDecayRate_timestep.nc - Total difference: -2.620408115437422e-14
Test 26 - Filename: albedoTest_output_senatorConstantDecayRate_timestep.nc - Total difference: -5.4488345526507444e-15
Test 27 - Filename: albedoTest_output_senatorVariableDecayRate_timestep.nc - Total difference: -5.4127203883212605e-14
Test 28 - Filename: vegImpactsTranspire_output_ballBerry_timestep.nc - Total difference: -9.788620681050161e-13
Test 29 - Filename: vegImpactsTranspire_output_jarvis_timestep.nc - Total difference: -5.014295773593571e-13
Test 30 - Filename: vegImpactsTranspire_output_simpleResistance_timestep.nc - Total difference: -4.832178677765752e-12
Test 31 - Filename: vegImpactsTranspire_output_perturbRoots_timestep.nc - Total difference: -1.4420709888429733e-13
Test 32 - Filename: basinRunoff_output_1dRichards_timestep.nc - Total difference: 2.0049707661555217e-12
Test 33 - Filename: basinRunoff_output_distributedTopmodel_timestep.nc - Total difference: -0.000989979444414688
Test 34 - Filename: basinRunoff_output_lumpedTopmodel_timestep.nc - Total difference: -9.710885175528568e-09
This is work towards solving #160. I have changed all real data types to the new
rk
data type, which stands for "real kind". Currently it is hardcoded to double precision, but might be user-configurable in the future. Currently if you try to switchrk
toSP
for single precision, SUMMA will crash. Further work needs to be done to make SUMMA run in single precision mode.Because this changes the data types of some variables, the test cases are not quite bit for bit. Here is a summary of the differences: