-
Notifications
You must be signed in to change notification settings - Fork 35
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
Add Pipe Drain Evaluator #253
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Two minor changes, then this looks good.
energ_loss_coeff_subweir_ = plist.get<double>("energy losses coeff submerged weir", 0.056); | ||
energ_loss_coeff_orifice_ = plist.get<double>("energy losses coeff orifice", 0.167); | ||
|
||
sw_domain_name_ = plist.get<std::string>("surface domain name", "surface"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can one of these domains be inferred from the key being evaluated? E.g, if you are evaluating "surface-pipe_drainage" then prefer to use:
sw_domain_name_ = Keys::getDomain(my_keys_.front().first);
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your comment.
The domain is obtained using "Keys::getDomain(my_keys_.front().first)" to identify if we are in the surface or pipe network domain later in the code (line 54) when using the pipe_drain_evaluator.
Hence we need to set the default name of sw_ or pipe_ domain before we use "Keys::getDomain(my_keys_.front().first)" to obtain the current domain.
if (domain1 == pipe_domain_name_) { | ||
for (const auto& dep : dependencies_) { | ||
auto domain = Keys::getDomain(dep.first); | ||
if (pipe_domain_name_ == domain) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What happens if the domain isn't pipe_domain_name? You should still set this evaluator's expectations of what the dependency's structure is.
Likely you should be making two "fac" variables, one with pipe_domain, one with surface_domain as the mesh. Then loop over each dependency and Update with the correct one.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dasvyat could you please help with this comment?
Thanks @ecoon . @nvohra0016 would you mind addressing Ethan's comments? |
This PR adds a pipe drain evaluator modeling the flow of water through manholes between an overland flow model and an underground pipe network model. This PR is the companion of amanzi/amanzi#824