Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
106 commits
Select commit Hold shift + click to select a range
a805e20
test commit
Aug 19, 2013
5f531ce
Merge branch 'develop' of https://github.com/PCBhagwat/emlab-generati…
Nov 1, 2013
a8642c4
update1
Nov 6, 2013
b87e2db
Dismantling Alogrithm initial coding
Nov 12, 2013
b0275ce
Dismantling V1.01
Nov 12, 2013
42fb844
JUnit Test for dismantling algorithm and update
Nov 13, 2013
a318a90
updates
Nov 13, 2013
add7c10
update
Nov 13, 2013
97de092
Junit
Nov 18, 2013
dc9e436
Commit
Nov 19, 2013
7cd428f
updated dismantling algorithm
Feb 18, 2014
54e5978
done!..for now
Feb 20, 2014
3e7bb61
debugging
Feb 24, 2014
1bcf096
updated
Feb 25, 2014
909f4e0
debug
Feb 27, 2014
cb37646
update
Feb 27, 2014
3c9364a
rconfig
Feb 27, 2014
26df423
data
Feb 27, 2014
70edfc3
data
Feb 27, 2014
d06bab1
update
Feb 27, 2014
96e8551
Merged from develop.
Mar 6, 2014
6ad38af
forecasting interconnector use in two country system
Mar 14, 2014
a7f9cb5
update
Mar 14, 2014
02eb303
EconomicDismantling
May 1, 2014
94cedc6
Merge branch 'develop' into feature/economicDismantling
May 1, 2014
1b919b3
commit
May 1, 2014
cb6dad2
Delete .DS_Store
May 7, 2014
1c2a3f5
Delete .DS_Store
May 7, 2014
dd89dae
Economic Dismantling Update
May 7, 2014
30e9dd4
Merge branch 'feature/economicDismantling' of
May 7, 2014
b69142e
new dismantling commit
Oct 2, 2014
ba4d39b
commit
Oct 3, 2014
9da954c
Delete .DS_Store
Oct 3, 2014
83248cd
Delete .DS_Store
Oct 3, 2014
f061921
Delete .DS_Store
Oct 3, 2014
30346dc
Delete .DS_Store
Oct 3, 2014
80d7674
Delete .DS_Store
Oct 3, 2014
fa152a5
Delete .DS_Store
Oct 3, 2014
c75a687
Delete .DS_Store
Oct 3, 2014
1cb7ee2
Delete .DS_Store
Oct 3, 2014
9f289e6
Delete .DS_Store
Oct 3, 2014
8668b7e
MSR Update
Jan 27, 2015
2c18a31
Merged economic dismantling to current develop.
JCRichstein Jan 27, 2015
670c0b5
Merged also capacity markets. Merge not completed.
JCRichstein Jan 27, 2015
3cc340f
Preliminary finished capacity market merge
JCRichstein Jan 27, 2015
4a73094
Debugged new CM and ED merge
Jan 28, 2015
0f0e5ae
Added FinancialPowerPlantReport.java
JCRichstein Jan 30, 2015
2e69900
Merge branch 'develop' into feature/financialReport
JCRichstein Feb 2, 2015
2a65edf
Started with draft function for financial reports.
JCRichstein Feb 2, 2015
9fb9dcf
Worked on financial reports function.
JCRichstein Feb 3, 2015
3b75d68
Continued work on financial reports.
JCRichstein Feb 5, 2015
ba9bd1f
Merge branch 'develop' into feature/financialReport
JCRichstein Feb 5, 2015
8a64b9d
worked and removed loggers.
JCRichstein Feb 6, 2015
3ea8fe2
updated queries-Ranalysis.properties.
JCRichstein Feb 10, 2015
54b29a1
Merge branch 'develop' into feature/financialReport
JCRichstein Feb 10, 2015
4f2e0a2
reworked financialreport query.
JCRichstein Feb 10, 2015
43f2751
reworked financialreport query.
JCRichstein Feb 10, 2015
d8fc7f4
Worked on adaptive CO2 cap policy.
JCRichstein Feb 24, 2015
aed624d
Merge branch 'develop' into feature/financialReport
JCRichstein Mar 9, 2015
85e0161
Worked on financialreport scripts. Added PredictionAnalysis (overlap …
JCRichstein Mar 13, 2015
f68a767
First prototype of historical CVAR
JCRichstein Mar 19, 2015
8c8f281
Worked on historical CVar.
JCRichstein Mar 20, 2015
c085b5b
Removed hard-coding from HistoricalCVar.
JCRichstein Mar 23, 2015
5fd17d5
Merge branch 'develop' into feature/historicalCVar
JCRichstein Mar 25, 2015
1daf5eb
completed bug fix from develop.
JCRichstein Mar 25, 2015
f4ec3a6
Worked on historical cvar. Added WACC markup for unknown tech.
JCRichstein Mar 28, 2015
6925629
Merge branch 'develop' into feature/adaptiveCO2
JCRichstein Mar 28, 2015
cd1f04a
Merged adaptiveCO2 update to historical cvar.
JCRichstein Mar 28, 2015
2ba970c
Updated the market stability reserve to also accept one year delays.
JCRichstein Mar 29, 2015
189b304
Added new scenarios for CM Paper
Kaveri3012 May 27, 2015
0647d86
Added a new class RenewableSupportScheme. :)
Kaveri3012 Jun 6, 2015
f6478f5
created new class RenewableSupportScheme and edited Role Regulator to
Kaveri3012 Jun 7, 2015
d7a2908
created new class as a generic support price, SupportPriceContract,
Kaveri3012 Jun 7, 2015
57be334
package info for renewablesupportrole
Kaveri3012 Jun 7, 2015
5ec45a7
extended feed in premium role
Kaveri3012 Jun 8, 2015
edeffe4
Finished FeedInPremiumRole, implemented it in DecarbonizationModelRole
Kaveri3012 Jun 10, 2015
b370dca
modified investment role to accommodate the feed in tariff
Kaveri3012 Jun 11, 2015
cba0a15
debugged FeedInPremium Role
Kaveri3012 Jun 16, 2015
069310d
Merge remote-tracking branch 'Jorn/feature/historicalCVar' into
Kaveri3012 Jun 18, 2015
85fd022
changed properteyt of regulator: feedInFactor from regulator to that of
Kaveri3012 Jun 23, 2015
f3e7349
Added newly created scenario based on Jorn's IntRes
Kaveri3012 Jun 23, 2015
51c6c00
Created a new FiP scenario based on Joern's intermittent scenarios.
Kaveri3012 Jun 24, 2015
cdebe56
edited feed in premium role
Kaveri3012 Jul 16, 2015
a02db08
Made ComputePremium(lcoe) role, created a new object, baseCostFip.
Kaveri3012 Jul 26, 2015
171f7ad
Created BaseCost object and repository
Kaveri3012 Jul 27, 2015
920b36b
Completed two main roles of the FeedInPremium
Kaveri3012 Jul 27, 2015
3505272
Completed updating investment algorithm for Feed In Premium Role, and
Kaveri3012 Jul 29, 2015
f156d61
created new basic single country scenario for RES policy research,
Kaveri3012 Jul 30, 2015
8d44243
debugged query error
Kaveri3012 Jul 31, 2015
007d96b
Debugged Compute Premium Role
Kaveri3012 Aug 5, 2015
423c066
made edits to code computePremiumRole and FeedInPremiumRole
Kaveri3012 Aug 6, 2015
9a561a8
Updated Feed in Premium Role and a few other scenarios
Kaveri3012 Aug 7, 2015
793ffe4
Made edits to FeedInPremium Role and ComputePremiumRole
Kaveri3012 Aug 11, 2015
b6adbb3
Added loggers for feed in support role
Kaveri3012 Aug 13, 2015
c23b8d9
A few more edits to feed in premium role
Kaveri3012 Aug 17, 2015
8108cf4
edits to feed in premium and compute premium role
Kaveri3012 Aug 26, 2015
7b663a3
created new scenarios for testing feed in premiums
Kaveri3012 Aug 26, 2015
593562c
changes in scenario files
Kaveri3012 Aug 27, 2015
94c0d11
Created new scenarios, and made small edits to include hourly
Kaveri3012 Sep 7, 2015
ee98648
Added intermittent data to model
Kaveri3012 Sep 7, 2015
15adc6b
making biasFactor technology specific
Kaveri3012 Sep 11, 2015
98a01a1
tried to create tech specificity and added new beans to K_S_Fip scenario
Kaveri3012 Sep 11, 2015
2cba5a2
created working hashmap java bean in scenario
Kaveri3012 Sep 11, 2015
7ae1302
edited baseCostQuery error
Kaveri3012 Sep 19, 2015
309d2f1
Edits to hashmap initialization
Kaveri3012 Sep 21, 2015
3c0f62c
hashmap initializaiton edits
Kaveri3012 Sep 21, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@
*/.project
*/.settings
facedb.lck
doxygenDoc
doxygenDoc
*/.Rapp.history
1 change: 1 addition & 0 deletions emlab-generation/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
*.log
log.roo
facedb.properties
/target/
4 changes: 4 additions & 0 deletions emlab-generation/.settings/org.eclipse.jdt.core.prefs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
org.eclipse.jdt.core.compiler.compliance=1.6
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
org.eclipse.jdt.core.compiler.source=1.6
org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
Expand Down
10 changes: 8 additions & 2 deletions emlab-generation/.settings/org.eclipse.jdt.ui.prefs
Original file line number Diff line number Diff line change
Expand Up @@ -78,25 +78,28 @@ sp_cleanup.always_use_blocks=true
sp_cleanup.always_use_parentheses_in_expressions=false
sp_cleanup.always_use_this_for_non_static_field_access=false
sp_cleanup.always_use_this_for_non_static_method_access=false
sp_cleanup.convert_functional_interfaces=false
sp_cleanup.convert_to_enhanced_for_loop=false
sp_cleanup.correct_indentation=true
sp_cleanup.format_source_code=true
sp_cleanup.format_source_code_changes_only=true
sp_cleanup.format_source_code_changes_only=false
sp_cleanup.insert_inferred_type_arguments=false
sp_cleanup.make_local_variable_final=false
sp_cleanup.make_parameters_final=false
sp_cleanup.make_private_fields_final=true
sp_cleanup.make_type_abstract_if_missing_method=false
sp_cleanup.make_variable_declarations_final=true
sp_cleanup.never_use_blocks=false
sp_cleanup.never_use_parentheses_in_expressions=true
sp_cleanup.on_save_use_additional_actions=true
sp_cleanup.on_save_use_additional_actions=false
sp_cleanup.organize_imports=true
sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
sp_cleanup.remove_private_constructors=true
sp_cleanup.remove_redundant_type_arguments=false
sp_cleanup.remove_trailing_whitespaces=true
sp_cleanup.remove_trailing_whitespaces_all=true
sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
Expand All @@ -110,10 +113,13 @@ sp_cleanup.remove_unused_private_methods=true
sp_cleanup.remove_unused_private_types=true
sp_cleanup.sort_members=false
sp_cleanup.sort_members_all=false
sp_cleanup.use_anonymous_class_creation=false
sp_cleanup.use_blocks=false
sp_cleanup.use_blocks_only_for_return_and_throw=false
sp_cleanup.use_lambda=false
sp_cleanup.use_parentheses_in_expressions=false
sp_cleanup.use_this_for_non_static_field_access=false
sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
sp_cleanup.use_this_for_non_static_method_access=false
sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
sp_cleanup.use_type_arguments=false
3 changes: 2 additions & 1 deletion emlab-generation/facedb.script
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ CREATE SCHEMA PUBLIC AUTHORIZATION DBA
CREATE SCHEMA AGENTSPRING_FACE AUTHORIZATION DBA
SET SCHEMA AGENTSPRING_FACE
CREATE MEMORY TABLE AGENTSPRING_FACE.SOURCES(ID INTEGER GENERATED BY DEFAULT AS IDENTITY(START WITH 0) NOT NULL PRIMARY KEY,TITLE VARCHAR(45) DEFAULT NULL,START VARCHAR(45) DEFAULT NULL,SCRIPT VARCHAR(16777216) NOT NULL)
ALTER TABLE AGENTSPRING_FACE.SOURCES ALTER COLUMN ID RESTART WITH 73
ALTER TABLE AGENTSPRING_FACE.SOURCES ALTER COLUMN ID RESTART WITH 74
CREATE MEMORY TABLE AGENTSPRING_FACE.VISUALS(ID INTEGER GENERATED BY DEFAULT AS IDENTITY(START WITH 0) NOT NULL PRIMARY KEY,TITLE VARCHAR(45) DEFAULT NULL,CLASS VARCHAR(45) DEFAULT NULL,TYPE VARCHAR(45) DEFAULT NULL,YAXIS VARCHAR(45) DEFAULT NULL)
ALTER TABLE AGENTSPRING_FACE.VISUALS ALTER COLUMN ID RESTART WITH 41
CREATE MEMORY TABLE AGENTSPRING_FACE.VISUALS_SOURCES(VISUAL INTEGER NOT NULL,SOURCE INTEGER NOT NULL,PRIMARY KEY(VISUAL,SOURCE),FOREIGN KEY(VISUAL) REFERENCES AGENTSPRING_FACE.VISUALS(ID) ON DELETE CASCADE,FOREIGN KEY(SOURCE) REFERENCES AGENTSPRING_FACE.SOURCES(ID))
Expand Down Expand Up @@ -113,6 +113,7 @@ INSERT INTO SOURCES VALUES(69,'MarketStabilityReserve','Government','["Mark
INSERT INTO SOURCES VALUES(70,'RevenuesProfitA','BigBank','flows = n.getNodes('CashFlow');\u000agroups = flows.groupBy{it.type}\u000aresult = [];\u000atotalCosts = 0;\u000atotalRevenue = 0;\u000atotalSpotRevenue = 0;\u000atotalLTCRevenue = 0;\u000atotalCMRevenue = 0;\u000atotalRESRevenue=0;\u000atotalCO2HedgingRevenue=0;\u000afor (key in groups.keySet()) {\u000a if (key<3 || key>9) {\u000a for (flow in groups[key]) {\u000a if (flow.time != tick) continue;\u000a if (flow.out('TO_AGENT').collect{it.__type__.contains('EnergyProducer')}[0] && flow.out('TO_AGENT').out('INVESTOR_MARKET').out('ZONE').collect{it.name.equals('Country A')}[0]) {\u000a totalRevenue += flow.money;\u000a }\u000a }\u000a \u000a } else {\u000a for (flow in groups[key]) {\u000a if (flow.time != tick) continue;\u000a if (flow.out('FROM_AGENT').collect{it.__type__.contains('EnergyProducer')}[0] && flow.out('FROM_AGENT').out('INVESTOR_MARKET').out('ZONE').collect{it.name.equals('Country A')}[0]) {\u000a totalCosts += flow.money;\u000a }\u000a }\u000a }\u000a \u000a if (key==1) {\u000a for (flow in groups[key]) {\u000a if (flow.time != tick) continue;\u000a if (flow.out('TO_AGENT').collect{it.__type__.contains('EnergyProducer')}[0] && flow.out('TO_AGENT').out('INVESTOR_MARKET').out('ZONE').collect{it.name.equals('Country A')}[0]) {\u000a totalSpotRevenue += flow.money;\u000a }\u000a }\u000a \u000a }\u000a \u000a if (key==2) {\u000a for (flow in groups[key]) {\u000a if (flow.time != tick) continue;\u000a if (flow.out('TO_AGENT').collect{it.__type__.contains('EnergyProducer')}[0] && flow.out('TO_AGENT').out('INVESTOR_MARKET').out('ZONE').collect{it.name.equals('Country A')}[0]) {\u000a totalLTCRevenue += flow.money;\u000a }\u000a }\u000a \u000a }\u000a \u000a if (key==11) {\u000a for (flow in groups[key]) {\u000a if (flow.time != tick) continue;\u000a if (flow.out('TO_AGENT').collect{it.__type__.contains('EnergyProducer')}[0] && flow.out('TO_AGENT').out('INVESTOR_MARKET').out('ZONE').collect{it.name.equals('Country A')}[0]) {\u000a totalCMRevenue += flow.money;\u000a }\u000a }\u000a \u000a }\u000a \u000a \u000a if (key==10) {\u000a for (flow in groups[key]) {\u000a if (flow.time != tick) continue;\u000a if (flow.out('TO_AGENT').collect{it.__type__.contains('EnergyProducer')}[0] && flow.out('TO_AGENT').out('INVESTOR_MARKET').out('ZONE').collect{it.name.equals('Country A')}[0]) {\u000a totalRESRevenue += flow.money;\u000a }\u000a }\u000a \u000a }\u000a\u000aif (key==12) {\u000a for (flow in groups[key]) {\u000a if (flow.time != tick) continue;\u000a if (flow.out('TO_AGENT').collect{it.__type__.contains('EnergyProducer')}[0]) {\u000a totalCO2HedgingRevenue += flow.money;\u000a }\u000a }\u000a }\u000a\u000a}\u000aresult.add(['Total Revenue', totalRevenue]);\u000aresult.add(['Revenue LTC', totalLTCRevenue]);\u000aresult.add(['Revenue Spot', totalSpotRevenue]);\u000aresult.add(['Revenue CM', totalCMRevenue])\u000aresult.add(['Revenue RES',totalRESRevenue])\u000aresult.add(['Revenue CO2Hedge', totalCO2HedgingRevenue]);\u000aresult.add(['Profit', totalRevenue - totalCosts]);\u000areturn result;')
INSERT INTO SOURCES VALUES(71,'WindNodeInstallations','PowerGridNode','capacity=v.in('LOCATION').as('x').out('TECHNOLOGY').filter{it.name=='Wind'}.back('x').sum{it.actualNominalCapacity}\u000aif(capacity == null) capacity = 0\u000a[v.name, capacity]')
INSERT INTO SOURCES VALUES(72,'OriginalCO2Cap','Government','cap=0\u000atry{cap = v.out("CO2CAP_TREND").collect{f.getTrendValue(it, tick)}[0];} catch(Exception e){ \u000acap=v.out("CO2CAP_TREND").timeSeries.next()[tick.toInteger()];}\u000atry{capReduction = v.out("CO2CAPADJUSTMENT_TIMESERIES").timeSeries.next()[tick.toInteger()]} catch(Exception e){\u000a capReduction=0\u000a}\u000areturn ["Original CO2 cap", cap+capReduction]')
INSERT INTO SOURCES VALUES(73,'CheckQuery','PowerGridNode','v.in('LOCATION').as('x').out('TECHNOLOGY') //.filter{it==g.v(tech)}.back('x').filter{(it.dismantleTime > tick) && ((tick - (it.constructionStartTime + it.actualPermittime + it.actualLeadtime)) <= 2)}')
INSERT INTO VISUALS VALUES(0,'Producer Cash Balance','chart','line','Euro')
INSERT INTO VISUALS VALUES(1,'Producer Revenue','chart','area','EUR')
INSERT INTO VISUALS VALUES(2,'CO2 Cap and Emissions','chart','line','')
Expand Down
14 changes: 13 additions & 1 deletion emlab-generation/queries-Ranalysis.properties
Original file line number Diff line number Diff line change
Expand Up @@ -831,4 +831,16 @@ segmentID=s.out('SEGMENTLOAD_SEGMENT').collect{it.segmentID}[0]
hours=s.out('SEGMENTLOAD_SEGMENT').collect{it.lengthInHours}[0]
finalResult.add([tick, s.baseLoad*growthfactor, market, segmentID, hours])
}
return finalResult",
return finalResult",

"TABLE_FinancialReports", "DecarbonizationModel", "financialReports=g.idx('__types__')[[className:'emlab.gen.domain.market.electricity.FinancialPowerPlantReport']].filter{it.time==tick};
finalResult = [];
columnNames=['tick', 'spotMarketRevenue', 'capacityMarketRevenue', 'strategicReserveRevenue', 'co2HedgingRevenue', 'overallRevenue','commodityCosts','co2Costs','variableCosts','fixedCosts','fullLoadHours','production','powerPlantName','technology','location','powerPlantOwner','operationalStatus','firstYearOfPowerPlantOperation','nominalCapacity','investedCapital'];
finalResult.add(columnNames);
for(v in financialReports){
firstYearOfOperation=v.out('FINANCIALREPORT_POWERPLANT').constructionStartTime.next()+v.out('FINANCIALREPORT_POWERPLANT').actualPermittime.next()+v.out('FINANCIALREPORT_POWERPLANT').actualLeadtime.next()
powerPlantSize=v.out('FINANCIALREPORT_POWERPLANT').actualNominalCapacity.next()
actualInvestedCapital=v.out('FINANCIALREPORT_POWERPLANT').actualInvestedCapital.next()
finalResult.add([v.time, v.spotMarketRevenue, v.capacityMarketRevenue, v.strategicReserveRevenue, v.co2HedgingRevenue, v.overallRevenue, v.commodityCosts, v.co2Costs, v.variableCosts, v.fixedCosts, v.fullLoadHours, v.production, v.out('FINANCIALREPORT_POWERPLANT').name.next(),v.out('FINANCIALREPORT_POWERPLANT').out('TECHNOLOGY').name.next(),v.out('FINANCIALREPORT_POWERPLANT').out('LOCATION').name.next(),v.out('FINANCIALREPORT_POWERPLANT').out('POWERPLANT_OWNER').name.next(),v.powerPlantStatus,firstYearOfOperation,powerPlantSize,actualInvestedCapital]);
};
return finalResult;",
62 changes: 1 addition & 61 deletions emlab-generation/queries.properties
Original file line number Diff line number Diff line change
Expand Up @@ -38,62 +38,10 @@ return productionsum;",

"MarketStabilityReserve", "Government", "return v.stabilityReserve",

"MsrUpperTriggerinTonPA", "Government", "try{cap = v.out('STABILITY_RESERVE_UPPER_TRIGGER').collect{f.getTrendValue(it, tick)}[0];} catch(Exception e){
cap=v.out('STABILITY_RESERVE_UPPER_TRIGGER').timeSeries.next()[tick.toInteger()]}
model = points = g.idx('__types__')[[className:'emlab.gen.domain.agent.DecarbonizationModel']].next()
msrActive = model.stabilityReserveIsActive && (tick >= model.stabilityReserveFirstYearOfOperation)
if(msrActive){
return cap
} else{
return 'NA'
}",

"MsrAddingPercentage", "Government", "try{cap = v.out('STABILITY_RESERVE_ADDING_PERCENTAGE').collect{f.getTrendValue(it, tick)}[0];} catch(Exception e){
cap=v.out('STABILITY_RESERVE_ADDING_PERCENTAGE').timeSeries.next()[tick.toInteger()]}
model = points = g.idx('__types__')[[className:'emlab.gen.domain.agent.DecarbonizationModel']].next()
msrActive = model.stabilityReserveIsActive && (tick >= model.stabilityReserveFirstYearOfOperation)
if(msrActive){
return cap
} else{
return 'NA'
}",

"MsrLowerTriggerinTonPA", "Government", "try{cap = v.out('STABILITY_RESERVE_LOWER_TRIGGER').collect{f.getTrendValue(it, tick)}[0];} catch(Exception e){
cap=v.out('STABILITY_RESERVE_LOWER_TRIGGER').timeSeries.next()[tick.toInteger()]}
model = points = g.idx('__types__')[[className:'emlab.gen.domain.agent.DecarbonizationModel']].next()
msrActive = model.stabilityReserveIsActive && (tick >= model.stabilityReserveFirstYearOfOperation)
if(msrActive){
return cap
} else{
return 'NA'
}",

"MsrReleaseQuantityTonPA", "Government", "try{cap = v.out('STABILITY_RESERVE_RELEASE_QUANTITY').collect{f.getTrendValue(it, tick)}[0];} catch(Exception e){
cap=v.out('STABILITY_RESERVE_RELEASE_QUANTITY').timeSeries.next()[tick.toInteger()]}
model = points = g.idx('__types__')[[className:'emlab.gen.domain.agent.DecarbonizationModel']].next()
msrActive = model.stabilityReserveIsActive && (tick >= model.stabilityReserveFirstYearOfOperation)
if(msrActive){
return cap
} else{
return 'NA'
}",

"CO2CapinTonpA", "Government", "try{cap = v.out('CO2CAP_TREND').collect{f.getTrendValue(it, tick)}[0];} catch(Exception e){
cap = v.out('CO2CAP_TREND').timeSeries.next()[tick.toInteger()];}
return ['CO2_cap', cap]",

"OriginalCO2CapinTonpA", "Government", "cap=0
try{cap = v.out('CO2CAP_TREND').collect{f.getTrendValue(it, tick)}[0];} catch(Exception e){
cap=v.out('CO2CAP_TREND').timeSeries.next()[tick.toInteger()];}
try{capReduction = v.out('CO2CAPADJUSTMENT_TIMESERIES').timeSeries.next()[tick.toInteger()]} catch(Exception e){
capReduction=0
}
return ['OriginalCO2Cap', cap+capReduction]",

"CO2CapReductioninTonpA", "Government", "try{capReduction = v.out('CO2CAPADJUSTMENT_TIMESERIES').timeSeries.next()[tick.toInteger()]} catch(Exception e){
capReduction=0}
return ['Co2CapReductioninTonpA', capReduction]",

"NationalMinCO2PriceinEURpTon", "NationalGovernment","try{price = v.out('MINCO2PRICE_TREND').collect{f.getTrendValue(it, tick)}[0];} catch(Exception e){
price = v.out('MINCO2PRICE_TREND').timeSeries.next()[tick.toInteger()];}
return [v.out('GOVERNED_ZONE').collect{it.name}[0], price];",
Expand Down Expand Up @@ -131,15 +79,7 @@ return [v.name, sum]",
if(!point.hasNext()){price = 0} else {price=point.next().getProperty('price')}
return price",

"MsrEmergencyTrigger", "CO2Auction", "point=v.in('MARKET_POINT').filter{it.time==tick && it.forecast==false}
if(!point.hasNext()){emergencyTrigger=false} else {emergencyTrigger=point.next().getProperty('emergencyTriggerActivated')}
return emergencyTrigger",

"MsrEmergencyTriggerOutflow", "CO2Auction", "point=v.in('MARKET_POINT').filter{it.time==tick && it.forecast==false}
if(!point.hasNext()){outflow = 0} else {outflow=point.next().getProperty('emergencyTriggerOutflow')}
return outflow",

"Forc_CO2Auction", "CO2Auction", "point=v.in('MARKET_POINT').filter{it.time==tick+3 && it.forecast==true}
"Forc_CO2Auction", "CO2Auction", "point=v.in('MARKET_POINT').filter{it.time==tick && it.forecast==true}
if(!point.hasNext()){price = 0} else {price=point.next().getProperty('price')}
return price",

Expand Down
Loading