WRF Hydro Developers,
The is problematic when the lake surface area is large and the routing timestep is small. The specific problem is calculating the change in height for the lake. From the source code:
dh1 = ((It - discharge)/sap)*dt
dt = routing time step
sap = surface area of the lake in m^2
If the routing timestep dt is small (let's say <10 seconds) and the surface area sap is large (let's say 150km^2 = 150,000,000m^2), you can quite evidently see that dh1 will push towards the edge of the floating point precision, and then the lake height is calculated (H = H + dh), it will cause issues where H would not change even if dh > 0.
An example of this is in a thread I posted a few days ago, where elevation for the most would not change unless the inflow was so high that it essentially forced dh to be significantly higher than the floating point imprecision. It would otherwise stay flat even when we expected a delta in lake elevation.
I'm not sure what solution is best to fix this. You could switch everything over for the lakes to use 8 byte floating point numbers instead of 4 byte floating point numbers to increase the precision. The downside of that is it would be different than the rest of WRF Hydro, and it would take more RAM and compute probably. Modifying the algorithm to work with millimeters instead of meters could also work, but might be messy and still might be problematic with even larger lakes. Please advise and let me know when a fix can be implemented for this.