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

LTEQ Demand Constraint #1106

Open
wants to merge 24 commits into
base: main
Choose a base branch
from
Open

LTEQ Demand Constraint #1106

wants to merge 24 commits into from

Conversation

gidden
Copy link
Member

@gidden gidden commented Mar 20, 2015

Hi folks,

This PR adds the ability for consumers to supply a LTEQ constraint. For example, a reactor can now make a demand for fuel with total fission products less than a threshold. Support has been added for both the Greedy and mathematical programming solvers.

I added basic unit tests, a "trivial" integration test (integrating exchange layer to formulation layer and back), and a less trivial integration test.

…r LTEQ constraints. Previously, request constraints were assumed to be GTEQ constraints and supply constraints were LTEQ. Requesters could now add LTEQ constraints to the DRE limiting a value (e.g. Pu concentration) given their request. This API has *not* yet been exposed to the higher-level CapacityConstraint class, only to the RequestGroup/ExchangeNodeGroup classes at the ExchangeGraph level.
…traints. both clp and greedy fail. greedy failure expected
…en if the solver-wide exclusive option was turned off
@scopatz scopatz added this to the v1.3 milestone Mar 20, 2015
/// @param capacity a capacitating value
/// @param type the type, e.g., LTEQ or GTEQ
/// @param converter a conversion function pointer
// @{
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

triple slash?

/// greater-than-or-equal-to (GTEQ) are supported
enum CapType {
LTEQ = 0,
GTEQ,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that the standard abbreviations are GE and LE. That would be more consistent with the same names they are given in the query filters.

/// @param faux_id a false arc id for surplus supply
/// @param cap_rows the capacity rows which will be appended to
/// @param ctx the translation context
static void XlateCaps(ExchangeNodeGroup* grp,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am still not a huge fan of using X to mean Trans. (GCSG: http://google-styleguide.googlecode.com/svn/trunk/cppguide.html#General_Naming_Rules). However, there is wiggle room here since it is more important to be consistent. I dunno. Your call. My 2 drachmas.

@scopatz
Copy link
Member

scopatz commented Mar 20, 2015

Hi @gidden! Thanks for putting this in. It looks very useful. There are a couple of small-ish issues to be dealt with in-line. The only thing I would request is some more detailed developer docs about the method. The implementation of the constraints didn't match exactly the math in my mind originally, but does make a certain amount of sense. A write up of what is being implemented I think would have helped. This can be either a mathematical formulation or an algorithmic one. Thanks!

@gidden
Copy link
Member Author

gidden commented Mar 21, 2015

Hi @scopatz. Thanks for the review! I agree that we should have more developer docs. I made #1107 to that effect, and am fine with it blocking this PR for now. The docs in question will likely come from my thesis and/or DRE publication, so should be relatively easy to generate. I will try to get to them post haste.

@scopatz
Copy link
Member

scopatz commented Mar 23, 2015

Hi @gidden! Ok! Sounds great!

@gidden
Copy link
Member Author

gidden commented Apr 24, 2015

moving to 1.4

@gidden gidden modified the milestones: v1.4, v1.3 Apr 24, 2015
@rwcarlsen rwcarlsen modified the milestones: v1.4, v1.5 Nov 17, 2015
@scopatz scopatz changed the base branch from develop to master September 7, 2017 18:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants