NCAR / micm

A model-independent chemistry module for atmosphere models
https://ncar.github.io/micm/
Apache License 2.0
6 stars 4 forks source link

testing backward euler with most of the analytical tests #576

Closed K20shores closed 1 week ago

K20shores commented 2 weeks ago

Closes #499

Backward euler passes all tests, but the robertson tests (the solver fails to converge and seems to get stuck, will be investigated by #498). I don't know how to test backward euler against HIRES, Oregonator, E5, but hopefully that can be fixed with #575

K20shores commented 2 weeks ago

How do you decide the tolerance values? It is interesting to see they vary between each solver type and rate constant type.

it was super duper scientific. I set a value of 1e-8 and when that failed for a particular test I subtracted one from the exponent until it passed.

A more intelligent way would be to play with the solver tolerances to choose values that minimize the error

boulderdaze commented 2 weeks ago

How do you decide the tolerance values? It is interesting to see they vary between each solver type and rate constant type.

it was super duper scientific. I set a value of 1e-8 and when that failed for a particular test I subtracted one from the exponent until it passed.

A more intelligent way would be to play with the solver tolerances to choose values that minimize the error

Haha I see. Yeah that makes sense but would require a good amount of work to investigate that. I guess we don't need to worry about it for now

codecov-commenter commented 2 weeks ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Please upload report for BASE (main@854ca2d). Learn more about missing BASE report.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #576 +/- ## ======================================= Coverage ? 92.89% ======================================= Files ? 49 Lines ? 3477 Branches ? 0 ======================================= Hits ? 3230 Misses ? 247 Partials ? 0 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.