-
Notifications
You must be signed in to change notification settings - Fork 396
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 "with escalation" tables to life cycle cost report #7459
Conversation
…at we causing problems with visualizing Objexx arrays.
@mjwitte or @Myoldmopar would one of you like to review this or suggest someone that would be a good reviewer? |
I'm happy to review this week. |
Thanks |
int curResource_iRT = CashFlow(iCashFlow).Resource; | ||
if (CashFlow(iCashFlow).Resource == iRT_Water || | ||
(CashFlow(iCashFlow).Resource >= iRT_OnSiteWater && CashFlow(iCashFlow).Resource <= iRT_Condensate)) { | ||
continue; |
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.
Just a thought. It would be a little faster if these iRT variables were reordered, with water types at the end, so that only
if (CashFlow(iCashFlow).Resource >= iRT_Water) continue;
could be used. But probably wouldn't save that much since this code is only executed at end? of simulation.
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.
It would make sense to optimize this if it was in a timestep but since this is not it probably is not worth the effort.
int found = 0; | ||
for (nUsePriceEsc = 1; nUsePriceEsc <= numUsePriceEscalation; ++nUsePriceEsc) { | ||
if (UsePriceEscalation(nUsePriceEsc).resource - ResourceTypeInitialOffset == curResource) { | ||
found = nUsePriceEsc; |
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.
Once found, break out of for loop?
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.
Thanks
EXPECT_NEAR(EscalatedEnergy(2, 1), 100., 0.001); | ||
EXPECT_NEAR(EscalatedEnergy(3, 1), 100., 0.001); | ||
EXPECT_NEAR(EscalatedEnergy(4, 1), 100., 0.001); | ||
EXPECT_NEAR(EscalatedEnergy(5, 1), 100., 0.001); |
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.
Probably not a good choice for a unit test (using all 100s) where you don't know if the correct CashFlow(1).yrAmount(x) was used. Would rather see 100, 200, 300... or 101, 102, 103... Might not be worth the effort.
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.
Good idea.
I have reviewed with only minor comments. Hard to understand mods without reviewing results and comparing with hand calcs. |
Thanks for the review @rraustad |
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.
Comments addressed, Things look good, requesting clarification on results before merging.
I don't see any diff's related to these changes. |
I'm not seeing any reason for further review. Merging. |
Have at it, @rraustad |
New Present Value By Year table now shows escalated Total Costs and those costs vary by year. @JasonGlazer since I don't have time to review how the escalated Total Costs should change over time as compared to the non-escalated costs, I'll ask a few questions before merging.
|
Let me take a look. That does seem like a large difference. |
In the example file I see escalation rates of around 1%, that's $100 per year (based on the 11,000 number), not $1000 per year. |
@Myoldmopar Since this adds a column to an output table, is it still ok to merge for 9.2? |
That's structural, so technically no, this should wait until after release. I'll add the proper milestone and you can review and approve the changes still. Then as soon as the release is done this can drop in. |
Darn. I did this one first in hopes that it would be in before the I/O freeze. |
The OutputChange label would have helped prioritize it - sorry. |
Technically no? As if a new column in an LCC table, would cause havoc. I'd rather see correct data in the tables. Oh well, it'll drop in 2 seconds after release as long as reviewer questions are addressed. |
The BND diffs seem completely unrelated. I'm going to merge develop again and hopefully they go away. |
@rraustad and @Myoldmopar I think this ready to be merged as soon as the release goes out. CI had some spurious warnings but that was just because it wasn't caught up to develop. |
Add escalated energy cost tables and a column to the present value by year table that shows the escalated energy costs. This resolves #6144
Review Checklist
This will not be exhaustively relevant to every PR.