APSIMInitiative/ApsimX

suspected bug: Release filling in missing particle size can lead to errors

KirstenVer opened this issue · 4 comments

What happened?

We had a simulation where the temperature model threw an error on account of being -52C or something like that. We found the particle size distribution had two columns in black and one in red. The red one being the one prefilled in a recent release with dummy values to allow the soil temp module to run. However, with the prefilled numbers the total far exceeded 100%. Once the real values were entered the problem went away. While I don't know why we had one column missing PSA, it may be useful to check how the release prefilling missing numbers has worked out, because I suspect there may be more soils (eg. apsoils) where people had only entered clay numbers as these were previously the only ones required.

What Operating System are you on?

Windows

This is not the particle size information (as far as I can tell). We thought we had this one sorted before review. Either we lost a fix or it didn't to the full job. Suggest that you go back to the old model until this is sorted.

I tried to recreate the problem, but have indeed not been able to do so with PSA > 100% - at least not running versions from past week. Not enough time to go back tracking.

Looking at another file that got additional prefilled info in red - did this action also add default rocks%? If so, what effect does this have - on temperature or elsewhere?

Spoke (wrote) too soon - this simulation recreates the issue with attached file. Ran it with Version 2024.8.7578.0.

It has an experiment with four simulations. The two SWIM runs had an error like the first below in layer 18. SoilWat the one below that in layer 10.
SoilWat layer 10 = 1400-1600 mm depth, SWIM3 layer 18 = 1450-1550 mm depth

I couldn't spot anything particular about that depth. It also happens well within the simulation at different times for the different simulations. Figure of avg soil temp for layer 10 suggests some instability, although the direction of the instability is contrary to the reported error.

newTemps(18) = 100.15930466755906 is outside range of -50 to 100
newTemps(10) = -50.389606780049164 is outside range of -50 to 100

image

If I replace the silt % by: 13, 12, 11, 11, 11, 11, 12, 12, 17, 21, 21 for the layers in physical respectively, the simulation runs fine.

CSULysimeter.zip

I added figure for avg temp layer 10 in this zip, so can ignore the first zip uploaded.
CSULysimeter.zip

Image below is for the fixed version: when I use the correct silt % (note that layer 10 is shallower for SWIM3 run)
image

The simulation in question (see screenshot below) has particle size information in black which means they were entered by the user, not calculated by APSIM. Yes, sand+silt+clay is > 100 but that is user error. Or am I missing something?

Having said that, I did notice, a while ago, when I was debugging soil temperature that the temperature of the bottom 'real' layer was very negative (e.g. close to -50oC). The 'extra' layers below that seem to be ok. I should have saved the simulation I was debugging at the time but I did not. I'm still looking for a simulation that reproduces the problem. Perhaps it was fixed in a subsequent change to soil temp.

image