Skip to content
This repository has been archived by the owner on Mar 1, 2023. It is now read-only.

calculation of soil properties #2207

Open
kmdeck opened this issue May 27, 2021 · 0 comments
Open

calculation of soil properties #2207

kmdeck opened this issue May 27, 2021 · 0 comments
Assignees
Labels
land - soil general label for land-soil modeling

Comments

@kmdeck
Copy link
Contributor

kmdeck commented May 27, 2021

Description

The soil has different parameters (~10) at different points in space, but these parameters are constant in time. These parameters are needed by multiple balance law functions. Currently, we pass in functions (of aux) for these parameters as part of the SoilModel structure. Each balance law method has access to these functions, so that they can be evaluated at that nodal point's position (aux.x, aux.y, aux.z). However, that means that each timestep, at each point, we evaluate a function O(10)x# of balance law methods that need them. If these functions are not written carefully, it can slow things down a lot (20 min to ~2-5 hrs in one example). This is inefficient - we don't need to compute them every timestep, they are constant, and shouldnt need to calculate them anew in different balance law functions for the same point in the same timestep.

I think the alternative is storing a look up table (not huge, O(10) params xO(100) points per column) in the SoilModel, and then the "function" we eval at each timestep at each point is just the look up, which is fast. Or maybe we store the values of these parameters at the points as part of aux, and we never update them, so they are only initialized once and dont add any unnecessary computation at each time step.

This should wait until after the software redesign since aux will change, the balance law may change, etc.

@jakebolewski just as a heads up that I'll ask your opinion on this when we get there!

@kmdeck kmdeck added the land - soil general label for land-soil modeling label May 27, 2021
@kmdeck kmdeck self-assigned this May 27, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
land - soil general label for land-soil modeling
Projects
None yet
Development

No branches or pull requests

1 participant