Skip to content

Precipitation flux calculation #17

Description

@claresinger

Update to include blk2m. Also, L120 where it is overwriting each horz slice as it loops through (from top-to-bottom) is rather confusing and opaque. I think after staring at it for a few minutes it is correct that you want the incoming flux from above to be the net flux when you are calculating precipitation flux in the level below, but it's a bit hidden that this is what's happening. It would be nice to add a comment here explaining this.

else if(this->micro == "blk_1m")
try
{
res = this->h5load_timestep("precip_rate", at); // precip_rate is the difference between influx and outflux
for(int z = this->map["z"] - 2; z>=0; --z)
{
res(this->hrzntl_slice(z)) = res(this->hrzntl_slice(z+1)) - res(this->hrzntl_slice(z));
}
res *= rhod * this->map["dz"] * L_evap;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions