Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[flow routing] Can tempslope be set when x<1 rather than x<=2? #22

Open
dvalters opened this issue Jul 1, 2018 · 0 comments
Open

[flow routing] Can tempslope be set when x<1 rather than x<=2? #22

dvalters opened this issue Jul 1, 2018 · 0 comments
Assignees
Labels
eCSE project Issue arising from the eCSE project question

Comments

@dvalters
Copy link
Owner

dvalters commented Jul 1, 2018

This is the only place in the code where we check the leftmost + 2 grid cells to set tempslope, it would make it easier for the libgeodecomp refactor if this was consistent on all edges of the model domain.

Perhaps it is some legacy code from an older version of the CAESAR code?

if (x <= 2) tempslope = 0 - edgeslope;

It means that in libgeodecomp, there is lots of complicated "edge" cases:

// must still figure out best way to accumulate total across cells during update executed by LibGeodecomp
switch(celltype){
case INTERNAL:
case EDGE_WEST_INNER:
case EDGE_NORTH_INNER:
case CORNER_NW_INNER:
case CORNER_NW_XPLUS1:
case CORNER_NW_YPLUS1:
case CORNER_NE_YPLUS1:
case CORNER_SW_XPLUS1:

Which make for lots of case statements

Try running the standard test with this changed to x<=1 and run standard case. (Arno and I could not see a reason why this wouldbe necessary at first glance.)

@dvalters dvalters added question eCSE project Issue arising from the eCSE project labels Jul 1, 2018
@dvalters dvalters self-assigned this Jul 1, 2018
@dvalters dvalters changed the title Can tempslope be set when x<=1 rather than x<=2? [flow-routing] Can tempslope be set when x<=1 rather than x<=2? Jul 1, 2018
@dvalters dvalters changed the title [flow-routing] Can tempslope be set when x<=1 rather than x<=2? [flow routing] Can tempslope be set when x<1 rather than x<=2? Jul 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
eCSE project Issue arising from the eCSE project question
Projects
None yet
Development

No branches or pull requests

1 participant