Skip to content
Snippets Groups Projects
sets.gms 102 KiB
Newer Older
Lavinia Baumstark's avatar
Lavinia Baumstark committed
*** |  (C) 2006-2019 Potsdam Institute for Climate Impact Research (PIK)
*** |  authors, and contributors see CITATION.cff file. This file is part
*** |  of REMIND and licensed under AGPL-3.0-or-later. Under Section 7 of
*** |  AGPL-3.0, you are granted additional permissions described in the
*** |  REMIND License Exception, version 1.0 (see LICENSE file).
*** |  Contact: remind@pik-potsdam.de
*** SOF ./core/sets.gms

***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
***            Definition of all super-sets "all_*"
***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
SETS
c_expname "c_expname as set for use in GDX"
/
%c_expname%
/
all_POPscen     " all possible population scenarios"
/
pop_SDP         "SDP population scenario"
pop_SSP1        "SSP1 population scenario"
pop_SSP2        "SSP2 population scenario"
pop_SSP3        "SSP3 population scenario"
pop_SSP4        "SSP4 population scenario"
pop_SSP5        "SSP5 population scenario"
pop_a1
pop_a2
pop_b1
pop_b2
/

all_GDPscen    "all possible GDP scenarios"
/
gdp_SDP         "SDP fastGROWTH medCONV"
gdp_SSP1        "SSP1 fastGROWTH medCONV"
gdp_SSP2        "SSP2 medGROWTH medCONV"
gdp_SSP3        "SSP3 slowGROWTH slowCONV"
gdp_SSP4        "SSP4  medGROWTH mixedCONV"
gdp_SSP5        "SSP5 fastGROWTH fastCONV"
gdp_a1
gdp_a2
gdp_b1
gdp_b2
/

all_GDPpcScen    "all possible GDP per capita scenarios (GDP and Population from the same SSP-scenario"
/
SDP         "SDP scenario"
SSP1        "SSP1 fastGROWTH medCONV"
SSP2        "SSP2 medGROWTH medCONV"
SSP3        "SSP3 slowGROWTH slowCONV"
SSP4        "SSP4  medGROWTH mixedCONV"
SSP5        "SSP5 fastGROWTH fastCONV"
a1
a2
b1
b2
/

all_SSP_forcing_adjust  "all possible forcing targets and budgets according to SSP scenario such that magicc forcing meets the target"
/
forcing_SSP1
forcing_SSP2
forcing_SSP3
forcing_SSP4
forcing_SSP5
/

all_rcp_scen   "all possible RCP scenarios"
/none,rcp20,rcp26,rcp37,rcp45,rcp60,rcp85/

all_delayPolicy   "all possible SPA policy choices"
/
SPA0            "no baseline policy"
SPAx            "moderate baseline policy, depends on the SSP-scenario"
/

all_APscen     "all air pollutant scenarios"
/
SSP1
SSP2
SSP3
SSP4
SSP5
CLE
FLE
FLE_building_transport
MFR
MFR_Transports
GlobalEURO6
SLCF_building_transport
/

all_LU_emi_scen  "all emission baselines for CH4 and N2O land use emissions from MAgPIE"
/
    SDP         "very low emissions (from SDP scenario in MAgPIE)"
    SSP1        "low    emissions (from SSP1 scenario in MAgPIE)"
    SSP2        "medium emissions (from SSP2 scenario in MAgPIE)"
    SSP3        "currently not available"
    SSP4        "currently not available"
    SSP5        "high   emissions (from SSP5 scenario in MAgPIE)"
/

all_fossilScen    "all possible scenarios for fossils"
/
lowCoal,medCoal,highCoal,
lowGas,medGas,highGas,
lowOil,medOil,highOil
/
all_te          "all energy technologies, including from modules"
/
        ngcc            "natural gas combined cycle"
        ngccc           "natural gas combined cycle with capture"
        ngt             "natural gas turbine"
        gastr           "transformation of gases"
        gaschp          "combined heating power using gas"
        gashp           "heating plant using gas"
        gash2           "gas to hydrogen"
        gash2c          "gas to hydrogen with capture"
        gasftrec        "gas based fischer-tropsch recycle"
        gasftcrec       "gas based fischer-tropsch with capture recycle"
        refliq          "refinery oil to se liquids"
        dot             "diesel oil turbine"
        dhp             "diesel oil heating plant"
        igcc            "integrated coal gasification combined cycle"
        igccc           "integrated coal gasification combined cycle with capture"
        pc              "pulverised coal power plant"
$ifthen setGlobal cm_ccsfosall        
        pcc             "pulverised coal power plant with capture"
        pco             "pulverised coal power plant with oxyfuel capture"
$endif
        coalchp         "combined heat powercoal"
        coalhp          "heating plantcoal"
        coaltr          "tranformation of coal"
        coalgas         "coal gasification"
        coalftrec       "coal based fischer-tropsch recycle"
        coalftcrec      "coal based fischer-tropsch with capture recycle"
        coalh2          "coal to hydrogen"
        coalh2c         "coal to hydrogen with capture"
        biotr           "transformation of biomass"
        biotrmod        "modern solids from biomass"
        biotrtradIEA    "only needed for reporting"
        biotrmodIEA     "only needed for reporting"
        biochp          "biomass combined heat and power"
        biohp           "biomass heating plant"
        bioigcc         "integrated biomass gasification combined cycle"
        bioigccc        "integrated biomass gasification combined cycle with CCS"
        biogas          "gasification of biomass"
        bioftrec        "biomass based fischer-tropsch recycle"
        bioftcrec       "biomass based fischer-tropsch with capture recycle"
        bioh2           "biomass to hydrogen"
        bioh2c          "biomass to hydrogen with capture"
        bioethl         "biomass to ethanol"
        bioeths         "sugar and starch biomass to ethanol"
        biodiesel       "oil biomass to biodiesel"
        geohdr          "geothermal electric hot dry rock"
        geohe           "geothermal heat"
        hydro           "hydro electric"
        wind            "wind power converters"
        spv             "solar photovoltaic"
        csp             "concentrating solar power"
        solhe           "solar thermal heat generation"
        tnrs            "thermal nuclear reactor (simple structure)"
        fnrs            "fast nuclear reactor (simple structure)"
        elh2            "hydrogen elecrolysis"
        h2turb          "hydrogen turbine for electricity production"
		elh2VRE         "dummy technology: hydrogen electrolysis; to demonstrate the capacities and SE flows inside the storXXX technologies"
        h2turbVRE       "dummy technology: hydrogen turbine for electricity production; to demonstrate the capacities and SE flows inside the storXXX technologies"
        h2curt          "hydrogen production from curtailment"
        h22ch4          "Methanation, H2 + 4 CO2 --> CH4 + 2 H20"
        MeOH			"Methanol production /liquid fuel, CO2 hydrogenation, CO2 + 3 H2 --> CH3OH + H20"
		tdels           "transmission and distribution for electricity to stationary users"
        tdeli           "transmission and distribution for electricity to industry"
        tdelb           "transmission and distribution for electricity to buildings"
        tdelt           "transmission and distribution for electricity to transport"
        tdbiogas        "transmission and distribution for gas from biomass origin to stationary users"
		tdfosgas        "transmission and distribution for gas from fossil origin to stationary users"
        tdbiogai        "transmission and distribution for gas from biomass origin to industry"
		tdfosgai        "transmission and distribution for gas from fossil origin to industry"
        tdbiogab        "transmission and distribution for gas from biomass origin to buildings"
		tdfosgab        "transmission and distribution for gas from fossil origin to buildings"
        tdbiogat        "transmission and distribution for gas from biomass origin to transportation"
		tdfosgat        "transmission and distribution for gas from fossil origin to transportation"
        tdbiohos        "transmission and distribution for heating oil from biomass origin to transportation"
        tdfoshos        "transmission and distribution for heating oil from fossil origin to stationary users"
        tdbiohoi        "transmission and distribution for heating oil from biomass origin to industry"
		tdfoshoi        "transmission and distribution for heating oil from fossil origin to industry"
        tdbiohob        "transmission and distribution for heating oil from biomass origin to buildings"
        tdfoshob        "transmission and distribution for heating oil from fossil origin to buildings"
        tdh2s           "transmission and distribution for hydrogen to stationary users"
        tdh2t           "transmission and distribution for hydrogen to transportation"
        tdbiodie        "transmission and distribution for diesel from biomass origin to stationary users"
        tdfosdie        "transmission and distribution for diesel from fossil origin to stationary users"
		tdbiopet        "transmission and distribution for petrol from biomass origin to stationary users"
        tdfospet        "transmission and distribution for petrol from fossil origin to stationary users"
        tdbiosos        "transmission and distribution for solids from biomass origin to stationary users"
        tdfossos        "transmission and distribution for solids from fossil origin to stationary users"
        tdbiosoi        "transmission and distribution for solids from biomass origin to industry"
        tdfossoi        "transmission and distribution for solids from fossil origin to industry"
Lavinia Baumstark's avatar
Lavinia Baumstark committed
201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763
        tdbiosob        "transmission and distribution for solids from biomass origin to buildings"
		tdfossob        "transmission and distribution for solids from fossil origin to buildings"
        tdhes           "transmission and distribution for heat to stationary users"
        tdhei           "transmission and distribution for heat to industry"
        tdheb           "transmission and distribution for heat to buildings"

*        ccscomp         "compression of co2"
*        ccspipe         "transportation of co2"
        ccsinje         "injection of co2"
*        ccsmoni         "monitoring of co2"
*RP* Storage technology:
        storspv         "storage technology for photo voltaic (PV)"
        storwind        "storage technology for wind"
        storcsp         "storage technology for concentrating solar power (CSP)"
*RP* grid technology
        gridspv         "grid between areas with high pv production and the rest"
        gridcsp         "grid between areas with high csp production and the rest"
        gridwind        "grid between areas with high wind production and the rest"
*AJS* transport technologies (ESH2T etc..) are defined in the transport module. 
 	apCarPeT        "Cars using final energy petrol (FEPET) to produce useful energy in form of petrol for transport (UEPET) "
    apCarDiT        "Vehicles using final energy diesel (FEDIE) to produce heavy-duty useful energy (uedit, e.g. freight, busses, planes, ships)."
    apcarDiEffT     "More efficient vehicles using final energy diesel (FEDIE) and electricity (FEELT) to produce heavy-duty useful energy (uedit, e.g. freight, busses, planes, ships)."
    apcarDiEffH2T   "Even more efficient vehicles using final energy diesel (FEDIE), electricity (FEELT) and Hydrogen (FEH2T) to produce heavy-duty useful energy (uedit, e.g. freight, busses, planes, ships)."
    apCarH2T        "Cars using final energy hydrogen for transport (FEH2T) to produce useful energy as hydrogen for transport (ESH2T)."
        apCarElT        "Cars using final energy electricity (FEELT) to produce useful energy as electricity for transport (UEELT)"
        apTrnElT        "Trains using final energy electricity (FEELT) to produce useful energy as electricity for transport (UEELT)"
***  appCarGaT  "Cars using FEGAT to produce ESGAT."  ???
        rockgrind       "grinding rock for enhanced weathering"
        dac             "direct air capture"
        x_gas2elec
        d_bio2elec      "d_* transmission and distribution losses"
        d_coal2elec
        d_gas2elec
        d_feel
        d_fehe
        d_fesobio
		d_fesofos
        d_fegabio
		d_fegafos
        d_coal2coal
        d_oil2coal
        d_gas2coal
        d_elec2coal
        d_oil2og
        d_gas2og
        d_elec2og
        d_oil2oil
        d_oil2gas
        d_gas2oil
        d_gas2gas
        d_elec2oil
        d_elec2gas
        tdgai_cs
        tdhoi_cs
        o_feel
/

all_enty             "all types of quantities"
/
        peoil        "PE oil"
        pegas        "PE gas"
        pecoal       "PE coal"
        peur         "PE uranium"
        pegeo        "PE geothermal"
        pehyd        "PE hydropower"
        pewin        "PE wind"
        pesol        "PE solar"
        pebiolc      "PE biomass lignocellulosic"
        pebios       "PE biomass sugar and starch"
        pebioil      "PE biomass sunflowers, palm oil, etc"
		all_seliq	 "all to SE liquids" 
		seliqbio     "SE liquids from biomass (ex. ethanol)"
		seliqfos     "SE liquids from fossil pe (ex. petrol and diesel)"
        all_seso	 "all to SE solids" 
		sesobio      "SE solids from biomass"
		sesofos      "SE solids from fossil pe"
        seel         "SE electricity"
        seh2         "SE hydrogen"
        all_sega	 "all to SE gas" 
		segabio      "SE gas from biomass"
		segafos      "SE gas from fossil pe"
        sehe         "SE district heating nd heat pumps"
        fegas        "FE gas stationary"
        fegab
        fegai
        fegat
        fega
        fehos        "FE heating oil stationary"
        fehob
        fehoi
        fesos        "FE solids stationary"
        feso
        fesoi
        fesob
        feels        "FE electricity stationary"
        feelb
        feeli
        feel
        fehes        "FE district heating (including combined heat and power), and heat pumps stationary"
        feheg
        fehei
        feheb
        fehe
        feh2s        "FE hydrogen stationary"
        fepet        "FE petrol transport"
        fedie        "FE diesel transport"
        felit        "FE liquids for transport (includes diesel and petrol)"
        fetf         "FE transport fuels"
        feh2t        "FE hydrogen transport"
        feelt        "final energy electricity for transport"
        fehoi_cs     "final energy in industry diesel - carbon stored"
        fegai_cs     "final energy in industry natural gas - carbon stored "

        ueHDVt       "transport useful energy heavy duty vehicles"
        ueLDVt       "transport useful energy light duty vehicles"
        ueelTt       "transport useful energy for electric trains"

        !! emissions
        co2          "carbon dioxide emissions"  
        ch4          "methane emissions"
        n2o          "n2o emissions from the energy system"		
        so2          "sulfur dioxide emissions"
        ch4coal    "fugitive emissions from coal mining"
        ch4gas     "fugitive emissions from gas production"
        ch4oil     "fugitive emissions from oil production"
        ch4wstl    "ch4 emissions from solid waste disposal on land"	
        ch4wsts    "ch4 emissions from waste water"		
        ch4rice    "ch4 emissions from rice cultivation (rice_ch4)"
        ch4animals "ch4 emissions from enteric fermentation of ruminants (ent_ferm_ch4)"
        ch4anmlwst "ch4 emissions from animal waste management(awms_ch4)"
        ch4agwaste "ch4 emissions from agricultural waste burning (no MAC available)"
        ch4forest  "ch4 emissions from forest burning"
        ch4savan   "ch4 emissions from savannah burnging"
        n2oforest  "n2o emissions from forest burning"
        n2osavan   "n2o emissions from savannah burnging"
        n2otrans   "n2o emissions from transport"
        n2oacid    "n2o emissions from acid production (only 2005 EDGAR data for calibration of n2oadac and n2onitac baselines)"
        n2oadac    "n2o emissions from adipic acid production"
        n2onitac   "n2o emissions from nitric acid production"				
        n2ofert    "MAC for n2o emissions from fertilizer (starting with n2ofert)"
        n2ofertin  "n2o emissions from Inorganic fertilizers (inorg_fert_n2o)"		
        n2ofertcr  "n2o emissions from decay of crop residues (resid_n2o)"
        n2ofertsom "n2o emissions from soil organic matter loss (som_n2o)"
        n2oanwst   "MAC for n2o emissions from animal waste (starting with n2oanwst)"	
        n2oanwstc  "n2o emissions from manure applied to croplands (man_crop_n2o)"	
        n2oanwstm  "n2o emissions from animal waste management (awms_n2o)"
        n2oanwstp  "n2o emissions from manure excreted on pasture (man_past_n2o)"
        n2oagwaste "n2o emissions from agricultural waste burning (no MAC available)"		
        n2owaste   "n2o emissions from waste (domestic sewage)"
        co2luc     "co2 emissions from land use change"
        co2cement_process  "co2 from cement production (only process emissions)"
        n2obio       "N2O emissions from pebiolc "
        bc           "black carbon from fossil fuel combustion"
        oc           "organic carbon from fossil fuel combustion"
        NOx          "nitrogen oxide emissions"
        CO           "carbon monoxide emissions"
        VOC          "volatile organic compound emissions"
        NH3          "ammonia emissions"

        !! emissions from industry sub-sectors
        co2cement      "CO2 emissions from clinker and cement production"
        co2chemicals   "CO2 emissions from chemicals production"
        co2steel       "CO2 emissions from steel production"
        co2otherInd    "CO2 emissions from other industry (used only for reporting)"

        !! various emissions
        emiFgasTotal    "XXX"
        emiFgasPFC      "XXX"
        emiFgasCF4      "XXX"
        emiFgasC2F6     "XXX"
        emiFgasC6F14    "XXX"
        emiFgasHFC      "XXX"
        emiFgasHFC23    "XXX"
        emiFgasHFC32    "XXX"
        emiFgasHFC43-10 "XXX"
        emiFgasHFC125   "XXX"
        emiFgasHFC134a  "XXX"
        emiFgasHFC143a  "XXX"
        emiFgasHFC227ea "XXX"
        emiFgasHFC245fa "XXX"
        emiFgasSF6      "XXX"
        ccuco2short  "CCU related parameter for short term stored co2 in ccu products"
        CtoH         "co2 emissions ratio C to H for CCU-technologies"
        cco2         "captured CO2"
***       pco2         "CCS related parameter during compression of CO2"
***       tco2         "CCS related parameter during transportation of CO2"
        ico2         "CCS related parameter during injection of CO2"
***       sco2         "CCS related parameter during storage of CO2 - monitoring ???"
        uedit        "Useful Energy: DIesel for Transport. Unit: TWa (not yet a real ES, only copied 1:1 from FE)"
        uepet        "Useful Energy: PEtrol for Transport. Unit: TWa (not yet a real ES, only copied 1:1 from FE)"
        ueelt        "Useful Energy: ELectricity for Transport. Unit: TWa (not yet a real ES, only copied 1:1 from FE)"
*** uegat   "Useful Energy: GAs for Transport. Unit: TWa (not yet a real ES, only copied 1:1 from FE)"
*** ueh2t   "Useful Energy: H2 for Transport. Unit: TWa (not yet a real ES, only copied 1:1 from FE)"
	
	good         "Generic good"     
         perm         "Carbon permit"
         peog         "aggregated oil and gas, only relevant for calibration because IEA only provides aggregated data"
/

all_esty "energy services"
/
*** Transport module: Energy services
	espet_pass_sm
	esdie_pass_sm
	esdie_pass_lo
	eselt_pass_sm
	esdie_frgt_lo
	esdie_frgt_sm
	eselt_frgt_sm
*    esh2t_pass_sm
*    esgat_pass_sm
*    esh2t_frgt_sm
*    esgat_frgt_sm

*** Buildings module: Energy services (useful energy)
    ueshheb  "buildings space heating district heat"
    ueshhob  "buildings space heating liquids"
    ueshsob  "buildings space heating solids"
    ueshstb  "buildings space heating traditional solids"
    ueshgab  "buildings space heating district heat"
    ueshh2b  "buildings space heating hydrogen"
    ueshelb  "buildings space heating electricity resistance"
    ueshhpb  "buildings space heating electricity heat pump"
    
    uecwhob  "buildings cooking and water heating liquids"
    uecwsob  "buildings cooking and water heating solids"
    uecwstb  "buildings cooking and water heating traditional solids"
    uecwgab  "buildings cooking and water heating gas"
    uecwheb  "buildings cooking and water heating district heat"
    uecwh2b  "buildings cooking and water heating hydrogen"
    uecwelb  "buildings cooking and water heating electricity"
    uecwhpb  "buildings cooking and water heating heat pump"
/

all_sectorEmi     "all sectors with emissions"
/       indst        "emissions from industry sector"
        res          "emissions from residential sector"
        trans        "emissions from transport sector"
        power        "emissions from power sector"
        solvents     "emissions from solvents"
        extraction   "emissions from fuel extraction"
        indprocess   "process emissions from industry"
/

all_exogEmi     " all exogenous emission types"
/       Aviation         "Exog emi from Aviation"
        InternationalShipping "Ecog emi from Int. Shipping" 
        Waste            "???"
        Agriculture      "Exogenous emissions from Agriculture" 
        AgWasteBurning   "Exogenous emissions from Ag Waste Burning"
        ForestBurning    "Exogenous emissions from Forest Burning"
        GrasslandBurning "Exogenous emissions from Grassland Burning"
/

  all_in   "all inputs and outputs of the CES function"
  /
    inco    "macroeconomic output"  

    lab     "labour input"
    kap     "capital input"
    en      "energy input"

    ens     "stationary energy use"
    ensh    "stationary heat energy use"
    fesos   "stationary use of solid energy carriers"
    fehos   "stationary use of liquid energy carriers"
    fegas   "stationary use of gaseous energy carriers"
    feh2s   "stationary use of hydrogen"
    fehes   "stationary use of district heat"
    feels   "stationary use of electricity"

    enb     "buildings energy use"
    enhb    "buildings heat energy use"
    fesob   "buildings use of solid energy carriers"
    fehob   "buildings use of liquid energy carriers"
    fegab   "buildings use of gaseous energy carriers"
    feh2b   "buildings use of hydrogen"
    feheb   "buildings use of district heat"
    feelb   "buildings use of electricity"

    eni     "industry energy use"
    enhi    "industry heat energy use"
    fesoi   "industry use of solid energy carriers"
    fehoi   "industry use of liquid energy carriers"
    fegai   "industry use of gaseous energy carriers"
    feh2i   "industry use of hydrogen"
    fehei   "industry use of district heat"
    feeli   "industry use of electricity"

    fehcsob  "buildings heating and cooking solids final energy"
    fehcelb  "buildings heating and cooking electricity final energy" 
    fehcheb  "buildings heating and cooking district heat final energy"
    fehcgab  "buildings heating and cooking gas final energy"
    fehchob  "buildings heating and cooking liquids final energy"
    fealelb  "buildings appliances and light electricity final energy"
    fecwsob  "buildings cooking and water heating solids final energy"
    fecwelb  "buildings cooking and water heating electricity final energy" 
    fecwhpb  "buildings cooking and water heating electricity heat pump final energy" 
    fecwheb  "buildings cooking and water heating district heat final energy"
    fecwgab  "buildings cooking and water heating gas final energy"
    fecwhob  "buildings cooking and water heating liquids final energy"
    fescelb  "buildings space cooling electricity final energy"
    feshsob  "buildings space heating solids final energy"
    feshelb  "buildings space heating electricity final energy" 
    feshheb  "buildings space heating district heat final energy"
    feshgab  "buildings space heating gas final energy"
    feshhob  "buildings space heating liquids final energy"
    feshhpb  "buildings space heating electricity heat pump final energy"
    
    esswb   "buildings weatherization energy service"
    uehcb    "buildings heating and cooking useful energy"
    uecwb    "buildings cooking and water heating useful energy"
    uescb    "buildings space cooling useful energy"
    ueshb    "buildings space heating useful energy"
    uealb  "buildings appliances and light, useful energy"
    ueswb   "buildings weatherization"
    feshh2b  "buildings space heating hydrogen"
    fecwb    "buildings cooking and water heating FE"
    fecwh2b  "buildings cooking and water heating hydrogen"
*** FIXME this should be reworked with Robert when revising the transport module
    entrp   "transport energy use"
    fetf    "transport fuel use"
    ueLDVt   "transport useful energy light duty vehicles"
    ueHDVt   "transport useful energy heavy duty vehicles"
    feh2t   "transport hydrogen use"
    ueelTt    "transport useful energy for electric trains"

    entrp_pass    "passenger transport"
    entrp_frgt    "freight transport"
    entrp_pass_sm    "short-to-medium distance passenger transport"
    entrp_pass_lo    "long distance passenger transport"
    entrp_frgt_sm    "short-to-medium distance freight transport"
    entrp_frgt_lo    "long distance freight transport"
    fepet_pass_sm    "short-to-medium distance passenger transport, petrol"
    fedie_pass_sm    "short-to-medium distance passenger transport, diesel"
    feelt_pass_sm    "short-to-medium distance passenger transport, electricity"
    fedie_pass_lo    "long distance passenger transport, diesel"
    fedie_frgt_sm    "short-to-medium distance freight transport, diesel"
    feelt_frgt_sm    "short-to-medium distance freight transport, electricity"
    fedie_frgt_lo    "long distance freight transport, diesel"

    kaphc     "buildings capital stock insulation"
    kapsc     "buildings capital stock space cooling"
    kapal     "buildings capital stock appliances and light"
    
    !! production factors of industry with subsectors
    ue_industry   "useful energy of industry sector"

    ue_cement                "useful energy of cement production"
    en_cement                "energy use of cement production"
    kap_cement               "energy efficiency capital of cement production"
    en_cement_non_electric   "non-electric energy use of cement production"
    feso_cement              "solids energy use of cement production"
    feli_cement              "liquids energy use of cement production"
    fega_cement              "gases energy use of cement production"
    feh2_cement              "hydrogen energy use of cement production"
    feel_cement              "electricity energy use of cement production"
 

    ue_chemicals         "useful energy of chemicals production"
    en_chemicals         "energy use of chemicals production"
    kap_chemicals        "energy efficiency capital of chemicals production"
    en_chemicals_fhth    "feedstock and high temperature heat enery use of chemicals production"
    feso_chemicals       "solids energy use of cement production"
    feli_chemicals       "liquids energy use of chemicals production"
    fega_chemicals       "gases energy use of chemicals production"
    feh2_chemicals       "hydrogen energy use of chemicals production"
    feelhth_chemicals    "high temperature heat electricity energy use of chemicals production"
    feelwlth_chemicals   "work and low temperature heat electricity energy use of chemicals production"

    ue_steel               "useful energy of steel production"
    ue_steel_primary       "useful energy of primary steel production"
    ue_steel_secondary     "useful energy of secondary steel production"
    en_steel_primary       "energy use of primary steel production"
    kap_steel_primary      "energy efficiency capital of primary steel production"
    kap_steel_secondary    "energy efficiency capital of secondary steel production"
    en_steel_furnace       "non-electric energy use of primary steel production"
    feso_steel             "solids energy use of primary steel production"
    feli_steel             "liquids energy use of primary steel production"
    fega_steel             "gases energy use of primary steel production"
    feh2_steel             "hydrogen energy use of primary steel production"
    feel_steel_primary     "electricity energy use pf primary steel production"
    feel_steel_secondary   "electricity energy use of secondary steel production"

    ue_otherInd         "useful energy of other industry production"
    en_otherInd         "energy use of other industry production"
    kap_otherInd        "energy efficiency capital of other industry production"
    en_otherInd_hth     "non-electric energy use of other industry production"
    feso_otherInd       "solids energy use of other industry production"
    feli_otherInd       "liquids energy use of other industry production"
    fega_otherInd       "gases energy use of other industry production"
    feh2_otherInd       "hydrogen energy use of other industry production"
    fehe_otherInd       "heat energy use of other industry production"
    feelhth_otherInd    "high temperature heat electricity energy use of other industry production"
    feelwlth_otherInd   "work and low temperature heat electricity energy use of other industry production"
  /

all_teEs                 "energy service technologies"
/
*** transport module
    te_espet_pass_sm "short-to-medium distance passenger transport CES node"
    te_esdie_pass_sm "short-to-medium distance passenger transport CES node"
    te_eselt_pass_sm "short-to-medium distance passenger transport CES node"
*    te_esh2t_pass_sm "short-to-medium distance passenger transport CES node"
*    te_esgat_pass_sm "short-to-medium distance passenger transport CES node"
    te_esdie_pass_lo "long distance passenger transport (aviation) CES node"
    te_esdie_frgt_sm "short-to-medium distance freight transport CES node"
    te_eselt_frgt_sm "short-to-medium distance freight transport CES node"
*    te_esh2t_frgt_sm "short-to-medium distance freight transport CES node"
*    te_esgat_frgt_sm "short-to-medium distance freight transport CES node"
    te_esdie_frgt_lo "long distance freight transport CES node" 

*** Buildings module
    te_ueshheb  "buildings space heating district heat"
    te_ueshhob  "buildings space heating liquids"
    te_ueshsob  "buildings space heating solids"
    te_ueshstb  "buildings space heating traditional solids"
    te_ueshgab  "buildings space heating district heat"
    te_ueshh2b  "buildings space heating hydrogen"
    te_ueshelb  "buildings space heating electricity resistance"
    te_ueshhpb  "buildings space heating electricity heat pump"
    
    te_uecwhob  "buildings cooking and water heating liquids"
    te_uecwsob  "buildings cooking and water heating solids"
    te_uecwstb  "buildings cooking and water heating traditional solids"
    te_uecwgab  "buildings cooking and water heating gas"
    te_uecwheb  "buildings cooking and water heating district heat"
    te_uecwh2b  "buildings cooking and water heating hydrogen"
    te_uecwelb  "buildings cooking and water heating electricity"
    te_uecwhpb  "buildings cooking and water heating heat pump" 
/

teEs(all_teEs)           "ES technologies which are actually used (to be filled by module realizations)."
//
    
;

***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
***                 Definition of region sets
***-----------------------------------------------------------------------------


***-----------------------------------------------------------------------------
***###############################################################################
***######################## R SECTION START (SETS) ###############################
*** THIS CODE IS CREATED AUTOMATICALLY, DO NOT MODIFY THESE LINES DIRECTLY
*** ANY DIRECT MODIFICATION WILL BE LOST AFTER NEXT INPUT DOWNLOAD
*** CHANGES CAN BE DONE USING THE RESPECTIVE LINES IN scripts/start_functions.R

sets

   all_regi "all regions" /CAZ,CHA,EUR,IND,JPN,LAM,MEA,NEU,OAS,REF,SSA,USA/

   ext_regi "extended regions list (includes subsets of H12 regions)" / EUR_regi,CAZ,CHA,EUR,IND,JPN,LAM,MEA,NEU,OAS,REF,SSA,USA /

   regi_group(ext_regi,all_regi) "region groups (regions that together corresponds to a H12 region)"
      /
        EUR_regi .(EUR)
      /
 
   iso "list of iso countries" /
       ABW,AFG,AGO,AIA,ALA,ALB,AND,ARE,ARG,ARM,
       ASM,ATA,ATF,ATG,AUS,AUT,AZE,BDI,BEL,BEN,
       BES,BFA,BGD,BGR,BHR,BHS,BIH,BLM,BLR,BLZ,
       BMU,BOL,BRA,BRB,BRN,BTN,BVT,BWA,CAF,CAN,
       CCK,CHN,CHE,CHL,CIV,CMR,COD,COG,COK,COL,
       COM,CPV,CRI,CUB,CUW,CXR,CYM,CYP,CZE,DEU,
       DJI,DMA,DNK,DOM,DZA,ECU,EGY,ERI,ESH,ESP,
       EST,ETH,FIN,FJI,FLK,FRA,FRO,FSM,GAB,GBR,
       GEO,GGY,GHA,GIB,GIN,GLP,GMB,GNB,GNQ,GRC,
       GRD,GRL,GTM,GUF,GUM,GUY,HKG,HMD,HND,HRV,
       HTI,HUN,IDN,IMN,IND,IOT,IRL,IRN,IRQ,ISL,
       ISR,ITA,JAM,JEY,JOR,JPN,KAZ,KEN,KGZ,KHM,
       KIR,KNA,KOR,KWT,LAO,LBN,LBR,LBY,LCA,LIE,
       LKA,LSO,LTU,LUX,LVA,MAC,MAF,MAR,MCO,MDA,
       MDG,MDV,MEX,MHL,MKD,MLI,MLT,MMR,MNE,MNG,
       MNP,MOZ,MRT,MSR,MTQ,MUS,MWI,MYS,MYT,NAM,
       NCL,NER,NFK,NGA,NIC,NIU,NLD,NOR,NPL,NRU,
       NZL,OMN,PAK,PAN,PCN,PER,PHL,PLW,PNG,POL,
       PRI,PRK,PRT,PRY,PSE,PYF,QAT,REU,ROU,RUS,
       RWA,SAU,SDN,SEN,SGP,SGS,SHN,SJM,SLB,SLE,
       SLV,SMR,SOM,SPM,SRB,SSD,STP,SUR,SVK,SVN,
       SWE,SWZ,SXM,SYC,SYR,TCA,TCD,TGO,THA,TJK,
       TKL,TKM,TLS,TON,TTO,TUN,TUR,TUV,TWN,TZA,
       UGA,UKR,UMI,URY,USA,UZB,VAT,VCT,VEN,VGB,
       VIR,VNM,VUT,WLF,WSM,YEM,ZAF,ZMB,ZWE /

   regi2iso(all_regi,iso) "mapping regions to iso countries"
      /
       CAZ . (AUS,CAN,HMD,NZL,SPM)
       CHA . (CHN,HKG,MAC,TWN)
       EUR . (ALA,AUT,BEL,BGR,CYP,CZE,DEU,DNK,ESP,EST)
       EUR . (FIN,FRA,FRO,GBR,GGY,GIB,GRC,HRV,HUN,IMN)
       EUR . (IRL,ITA,JEY,LTU,LUX,LVA,MLT,NLD,POL,PRT)
       EUR . (ROU,SVK,SVN,SWE)
       IND . (IND)
       JPN . (JPN)
       LAM . (ABW,AIA,ARG,ATA,ATG,BES,BHS,BLM,BLZ,BMU)
       LAM . (BOL,BRA,BRB,BVT,CHL,COL,CRI,CUB,CUW,CYM)
       LAM . (DMA,DOM,ECU,FLK,GLP,GRD,GTM,GUF,GUY,HND)
       LAM . (HTI,JAM,KNA,LCA,MAF,MEX,MSR,MTQ,NIC,PAN)
       LAM . (PER,PRI,PRY,SGS,SLV,SUR,SXM,TCA,TTO,URY)
       LAM . (VCT,VEN,VGB,VIR)
       MEA . (ARE,BHR,DZA,EGY,ESH,IRN,IRQ,ISR,JOR,KWT)
       MEA . (LBN,LBY,MAR,OMN,PSE,QAT,SAU,SDN,SYR,TUN)
       MEA . (YEM)
       NEU . (ALB,AND,BIH,CHE,GRL,ISL,LIE,MCO,MKD,MNE)
       NEU . (NOR,SJM,SMR,SRB,TUR,VAT)
       OAS . (AFG,ASM,ATF,BGD,BRN,BTN,CCK,COK,CXR,FJI)
       OAS . (FSM,GUM,IDN,IOT,KHM,KIR,KOR,LAO,LKA,MDV)
       OAS . (MHL,MMR,MNG,MNP,MYS,NCL,NFK,NIU,NPL,NRU)
       OAS . (PAK,PCN,PHL,PLW,PNG,PRK,PYF,SGP,SLB,THA)
       OAS . (TKL,TLS,TON,TUV,UMI,VNM,VUT,WLF,WSM)
       REF . (ARM,AZE,BLR,GEO,KAZ,KGZ,MDA,RUS,TJK,TKM)
       REF . (UKR,UZB)
       SSA . (AGO,BDI,BEN,BFA,BWA,CAF,CIV,CMR,COD,COG)
       SSA . (COM,CPV,DJI,ERI,ETH,GAB,GHA,GIN,GMB,GNB)
       SSA . (GNQ,KEN,LBR,LSO,MDG,MLI,MOZ,MRT,MUS,MWI)
       SSA . (MYT,NAM,NER,NGA,REU,RWA,SEN,SHN,SLE,SOM)
       SSA . (SSD,STP,SWZ,SYC,TCD,TGO,TZA,UGA,ZAF,ZMB)
       SSA . (ZWE)
       USA . (USA)
      /
iso_regi "all iso countries and EU and greater China region" /  EUR,CHA,
       ABW,AFG,AGO,AIA,ALA,ALB,AND,ARE,ARG,ARM,
       ASM,ATA,ATF,ATG,AUS,AUT,AZE,BDI,BEL,BEN,
       BES,BFA,BGD,BGR,BHR,BHS,BIH,BLM,BLR,BLZ,
       BMU,BOL,BRA,BRB,BRN,BTN,BVT,BWA,CAF,CAN,
       CCK,CHN,CHE,CHL,CIV,CMR,COD,COG,COK,COL,
       COM,CPV,CRI,CUB,CUW,CXR,CYM,CYP,CZE,DEU,
       DJI,DMA,DNK,DOM,DZA,ECU,EGY,ERI,ESH,ESP,
       EST,ETH,FIN,FJI,FLK,FRA,FRO,FSM,GAB,GBR,
       GEO,GGY,GHA,GIB,GIN,GLP,GMB,GNB,GNQ,GRC,
       GRD,GRL,GTM,GUF,GUM,GUY,HKG,HMD,HND,HRV,
       HTI,HUN,IDN,IMN,IND,IOT,IRL,IRN,IRQ,ISL,
       ISR,ITA,JAM,JEY,JOR,JPN,KAZ,KEN,KGZ,KHM,
       KIR,KNA,KOR,KWT,LAO,LBN,LBR,LBY,LCA,LIE,
       LKA,LSO,LTU,LUX,LVA,MAC,MAF,MAR,MCO,MDA,
       MDG,MDV,MEX,MHL,MKD,MLI,MLT,MMR,MNE,MNG,
       MNP,MOZ,MRT,MSR,MTQ,MUS,MWI,MYS,MYT,NAM,
       NCL,NER,NFK,NGA,NIC,NIU,NLD,NOR,NPL,NRU,
       NZL,OMN,PAK,PAN,PCN,PER,PHL,PLW,PNG,POL,
       PRI,PRK,PRT,PRY,PSE,PYF,QAT,REU,ROU,RUS,
       RWA,SAU,SDN,SEN,SGP,SGS,SHN,SJM,SLB,SLE,
       SLV,SMR,SOM,SPM,SRB,SSD,STP,SUR,SVK,SVN,
       SWE,SWZ,SXM,SYC,SYR,TCA,TCD,TGO,THA,TJK,
       TKL,TKM,TLS,TON,TTO,TUN,TUR,TUV,TWN,TZA,
       UGA,UKR,UMI,URY,USA,UZB,VAT,VCT,VEN,VGB,
       VIR,VNM,VUT,WLF,WSM,YEM,ZAF,ZMB,ZWE /

   map_iso_regi(iso_regi,all_regi) "mapping from iso countries to regions that represent country" 
         /
       CHA . CHA
       EUR . EUR
       IND . IND
       JPN . JPN
       USA . USA
      /
;
***######################### R SECTION END (SETS) ################################
***###############################################################################

*** FS: definition of regional sensitivity/scenario sets

$IFTHEN.RegScenNuc "%c_regi_nucscen%" == "all"
  set regi_nucscen(all_regi) "regions which nucscen applies to";
  regi_nucscen(all_regi)=YES;
$ELSE.RegScenNuc
  set regi_nucscen(all_regi) "regions which nucscen applies to" / %c_regi_nucscen% /;
$ENDIF.RegScenNuc

$IFTHEN.RegScenCapt "%c_regi_capturescen%" == "all"
  set regi_capturescen(all_regi) "regions which capturescen applies to";
  regi_capturescen(all_regi)=YES;
$ELSE.RegScenCapt
  set regi_capturescen(all_regi) "regions which capturescen applies to" / %c_regi_capturescen% /;
$ENDIF.RegScenCapt

Lavinia Baumstark's avatar
Lavinia Baumstark committed
***###############################################################################
***######################## R SECTION START (MODULES) ###############################
*** THIS CODE IS CREATED AUTOMATICALLY, DO NOT MODIFY THESE LINES DIRECTLY
*** ANY DIRECT MODIFICATION WILL BE LOST AFTER NEXT MODEL START
*** CHANGES CAN BE DONE USING THE RESPECTIVE LINES IN scripts/start_functions.R
Lavinia Baumstark's avatar
Lavinia Baumstark committed

sets

       modules "all the available modules"
       /
       PE_FE_parameters
       initialCap
       aerosols
       climate
       downscaleTemperature
       growth
       tax
       subsidizeLearning
       capitalMarket
       agCosts
       CES_parameters
       biomass
       fossil
       power
       CDR
       transport
       buildings
       industry
       stationary
       CCU
       techpol
       emicapregi
       banking
       carbonprice
       regipol
       damages
       internalizeDamages
       water
       optimization
       codePerformance
       /

module2realisation(modules,*) "mapping of modules and active realisations" /
Lavinia Baumstark's avatar
Lavinia Baumstark committed
824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200
       PE_FE_parameters . %PE_FE_parameters%
       initialCap . %initialCap%
       aerosols . %aerosols%
       climate . %climate%
       downscaleTemperature . %downscaleTemperature%
       growth . %growth%
       tax . %tax%
       subsidizeLearning . %subsidizeLearning%
       capitalMarket . %capitalMarket%
       agCosts . %agCosts%
       CES_parameters . %CES_parameters%
       biomass . %biomass%
       fossil . %fossil%
       power . %power%
       CDR . %CDR%
       transport . %transport%
       buildings . %buildings%
       industry . %industry%
       stationary . %stationary%
       CCU . %CCU%
       techpol . %techpol%
       emicapregi . %emicapregi%
       banking . %banking%
       carbonprice . %carbonprice%
       regipol . %regipol%
       damages . %damages%
       internalizeDamages . %internalizeDamages%
       water . %water%
       optimization . %optimization%
       codePerformance . %codePerformance%
      /
;
***######################### R SECTION END (MODULES) ################################
***###############################################################################

sets

regi(all_regi)  "all regions used in the solution process"   

*** region sets used for MAGICC
RCP_regions_world_bunkers "five RCP regions plus total (world) and bunkers"
/
  WORLD
  R5OECD
  R5REF
  R5ASIA
  R5MAF
  R5LAM
  BUNKERS
/

RCP_regions_world(RCP_regions_world_bunkers) "five RCP regions plus total (world)"
/
  WORLD
  R5OECD
  R5REF
  R5ASIA
  R5MAF
  R5LAM
  BUNKERS
/
;

***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
***   Miscellaneous sets
***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
Sets 
  counter   "helper set to facilitate looping in defined order"   / 1 * 20 /
;

***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
***   Definition of time-related sets
***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------

SETS
tall            "time index"
        /
        1900*3000
        /

*LB* Different time-steps are used for the flags cm_less_TS (default), test_TS, 
*** and END2110. If none of these flags is set, five year steps are used.
*** test_TS: 2005,2010,2020,2030,2040,2050,2070,2090,2110,2130,2150
*** cm_less_TS: 2005,2010,2015,2020,2025,2030,2035,2040,2045,2050,2055,2060,
*** 2070,2080,2090,2100,2110,2130,2150
*** END2110: 2005:5:2105,2120
*AJS* Defining ttot as sum of t and tsu will give errors from compiler, so do 
*** it manually instead: 
ttot(tall)      "time index with spin up"
/
        1900, 1905, 1910, 1915, 1920, 1925,
        1930, 1935, 1940, 1945, 1950, 1955,
        1960, 1965, 1970, 1975, 1980, 1985,
        1990, 1995,
        2000, 2005, 2010,
$if not setGlobal test_TS   2015,
                            2020,
$if not setGlobal test_TS   2025,
                            2030,
$if not setGlobal test_TS   2035,
                            2040,
$if not setGlobal test_TS   2045,
                            2050,
$if not setGlobal test_TS   2055,
$if not setGlobal test_TS   2060,
$if not setGlobal test_TS $if %cm_less_TS% == "off"  2065,
                            2070,
$if not setGlobal test_TS $if %cm_less_TS% == "off"  2075,
$if not setGlobal test_TS   2080,
$if not setGlobal test_TS $if %cm_less_TS% == "off"  2085,
                            2090,
$if not setGlobal test_TS $if %cm_less_TS% == "off"  2095,
$if not setGlobal test_TS   2100,
$if not setGlobal test_TS $if %cm_less_TS% == "off"  2105,
$if setGlobal END2110       2120
$if not setGlobal END2110 $if setGlobal test_TS  2110, 2130, 2150
$if not setGlobal END2110 $if %cm_less_TS% == "on"  2110, 2130, 2150
$if not setGlobal END2110 $if not setGlobal test_TS $if %cm_less_TS% == "off"  2110, 2115, 2120, 2125, 2130, 2135, 2140, 2145, 2150
/

$if not setGlobal test_TS $if %cm_less_TS% == "off" t_interpol(ttot)/ 2065,2075,2085,2095,2105,2115,2125,2135,2145/

*cb the content of those subsets is defined 16 lines further down
t(ttot) "modeling time, usually starting in 2005, but later for fixed delay runs",
tsu(ttot) "spin up-time before 2005",

opTimeYr            "actual life time of ??? in years"
/
        1*100
/
opTime5(opTimeYr)            "actual life time of ??? in years - 5 years time steps for the past to calculate vintages (???)"

/
        1,6,11,16,21,26,31,36,41,46,51,56,61,66,71,76,81,86,91,96
/
t0(tall)   "start of modelling time, not optimization" /2005/    

t_input_gdx(ttot)     "t loaded from input.gdx, used for t interpolation"
t_interpolate(ttot)   "periods that need interpolation"
;

t(ttot)$(ttot.val ge cm_startyear)=Yes;
tsu(ttot)$(ttot.val lt 2005)=Yes;
display ttot;

*** time sets used for MAGICC
Sets
  t_magiccttot(tall) "time periods including spin-up"
  t_magicc(tall)     "time periods exported to magicc"
  t_extra(tall)      "averaging between REMIND and MAGICC" / 2000 * 2004 /
;





***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
***                 Definition of SETS of ESM
***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------

***-----------------------------------------------------------------------------
*** Definition of the main technology set 'te':
***-----------------------------------------------------------------------------
SETS
te(all_te)              "energy technologies"
/
        ngcc            "natural gas combined cycle"
        ngccc           "natural gas combined cycle with capture"
        ngt             "natural gas turbine"
        gastr           "transformation of gases"
        gaschp          "combined heat and power using gas"
        gashp           "heating plant using gas"
        gash2           "gas to hydrogen"
        gash2c          "gas to hydrogen with carbon capture"
        gasftrec        "gas based fischer-tropsch recycle"
        gasftcrec       "gas based fischer-tropsch with capture recycle"		
        refliq          "refinery oil to SE liquids"
        dot             "diesel oil turbine"
        igcc            "integrated coal gasification combined cycle"
        igccc           "integrated coal gasification combined cycle with carbon capture"
        pc              "pulverised coal power plant"
$ifthen setGlobal cm_ccsfosall
        pcc             "pulverised coal power plant with capture"
        pco             "pulverised coal power plant with oxyfuel capture"
$endif
        coalchp         "combined heat powercoal"
        coalhp          "heating plant coal"
        coaltr          "tranformation of coal"
        coalgas         "coal gasification"
        coalftrec       "coal based fischer-tropsch recycle"
        coalftcrec      "coal based fischer-tropsch with capture recycle"
        coalh2          "coal to hydrogen"
        coalh2c         "coal to hydrogen with capture"
        biotr           "transformation of biomass"
        biotrmod        "modern solids from biomass"
        biochp          "biomass combined heat and power"
        biohp           "biomass heating plant"
        bioigcc         "integrated biomass gasification combined cycle"
        bioigccc        "integrated biomass gasification combined cycle with CCS"
        biogas          "gasification of biomass"
        bioftrec        "biomass based fischer-tropsch recycle"
        bioftcrec       "biomass based fischer-tropsch with capture recycle"
        bioh2           "biomass to hydrogen"
        bioh2c          "biomass to hydrogen with capture"
        bioethl         "biomass to ethanol"
        bioeths         "sugar and starch biomass to ethanol"
        biodiesel       "oil biomass to biodiesel"
        geohdr          "geothermal electric hot dry rock"
        geohe           "geothermal heat"
        hydro           "hydro electric"
        wind            "wind power converters"
        spv             "solar photovoltaic"
        csp             "concentrating solar power"
        solhe           "solar thermal heat generation"
        tnrs            "thermal nuclear reactor (simple structure)"
        fnrs            "fast nuclear reactor (simple structure)"
        elh2            "hydrogen elecrolysis"
        h2turb          "hydrogen turbine for electricity production"
		elh2VRE         "dummy technology: hydrogen electrolysis; to demonstrate the capacities and SE flows inside the storXXX technologies"
        h2turbVRE       "dummy technology: hydrogen turbine for electricity production; to demonstrate the capacities and SE flows inside the storXXX technologies"
        h2curt      	"hydrogen production from curtailment"
        tdels           "transmission and distribution for electricity to stationary users"
        tdelt           "transmission and distribution for electricity to transport"
        tdbiogas        "transmission and distribution for gas from biomass origin to stationary users"
        tdfosgas        "transmission and distribution for gas from fossil origin to stationary users"
        tdbiohos        "transmission and distribution for heating oil from biomass origin to transportation"
        tdfoshos        "transmission and distribution for heating oil from fossil origin to transportation"
        tdh2s           "transmission and distribution for hydrogen to stationary users"
        tdh2t           "transmission and distribution for hydrogen to transportation"
        tdbiodie        "transmission and distribution for diesel from biomass origin to stationary users"
        tdfosdie        "transmission and distribution for diesel from fossil origin to stationary users"
        tdbiopet        "transmission and distribution for petrol from biomass origin to stationary users"
		tdfospet        "transmission and distribution for petrol from fossil origin to stationary users"
        tdbiosos        "transmission and distribution for solids from biomass origin to stationary users"
        tdfossos        "transmission and distribution for solids from fossil origin to stationary users"
        tdhes           "transmission and distribution for heat to stationary users"

*        ccscomp         "compression of co2, CCS related"
*        ccspipe         "transportation of co2, CCS related"
        ccsinje         "injection of co2, CCS related"
*        ccsmoni         "monitoring of co2, CCS related"

        storspv         "storage technology for photo voltaic"
        storwind        "storage technology for wind"
        storcsp         "storage technology for concentrating solar power"

        gridspv         "grid between areas with high pv production and the rest"
        gridcsp         "grid between areas with high csp production and the rest"
        gridwind        "grid between areas with high wind production and the rest"
/
teAdj(all_te)           "technologies with adjustment costs on capacity additions"
/
  ngcc            "natural gas combined cycle"
  ngccc           "natural gas combined cycle with capture"
  ngt             "natural gas turbine"
  gastr           "transformation of gases"
  gaschp          "combined heat and power plant using gas"
  gashp           "heating plant using gas"
  gash2           "gas to hydrogen"
  gash2c          "gas to hydrogen with capture"
  gasftrec        "gas based fischer-tropsch recycle"
  gasftcrec       "gas based fischer-tropsch with capture recycle"  
  dot             "diesel oil turbine"
  igcc            "integrated coal gasification combined cycle"
  igccc           "integrated coal gasification combined cycle with capture"
  pc              "pulverised coal power plant"
$ifthen setGlobal cm_ccsfosall
  pcc             "pulverised coal power plant with capture"
  pco             "pulverised coal power plant with oxyfuel capture"
$endif
  coalchp         "combined heat powercoal"
  coalhp          "heating plant coal"
  coaltr          "tranformation of coal"
  coalgas         "coal gasification"
  coalftrec       "coal based fischer-tropsch recycle"
  coalftcrec      "coal based fischer-tropsch with capture recycle"
  coalh2          "coal to hydrogen"
  coalh2c         "coal to hydrogen with capture"
  biotr           "transformation of biomass"
  biotrmod        "modern solids from biomass"
  biochp          "heating plant bio"
  biohp           "heating plant bio"
  bioigcc         "integrated biomass gasification combined cycle"
  bioigccc        "integrated biomass gasification combined cycle with CCS"
  biogas          "gasification of biomass"
  bioftrec        "biomass based fischer-tropsch recycle"
  bioftcrec       "biomass based fischer-tropsch with capture recycle"
  bioh2           "biomass to hydrogen"
  bioh2c          "biomass to hydrogen with capture"
  bioethl         "biomass to ethanol"
  bioeths         "sugar and starch biomass to ethanol"
  biodiesel       "oil biomass to biodiesel"
  geohdr          "geothermal electric hot dry rock"
  geohe           "geothermal heat"
  hydro           "hydro electric"
  wind            "wind power converters"
  spv             "solar photovoltaic"
  csp             "concentrating solar power"
  solhe           "solar thermal heat generation"
  tnrs            "thermal nuclear reactor (simple structure)"
  fnrs            "fast nuclear reactor (simple structure)"
  elh2            "hydrogen elecrolysis"
  h2turb          "hydrogen turbine for electricity production"
  h2curt      	  "hydrogen production from curtailment"
*** ccscomp         "compression of co2, CCS related"
*** ccspipe         "transportation of co2, CCS related"
  ccsinje         "injection of co2, CCS related"
*** ccsmoni         "monitoring of co2, CCS related"

  storspv         "storage technology for PV"
  storwind        "storage technology for wind"
  storcsp         "storage technology for CSP"
  
  refliq          "refinery oil to SE liquids"
  
  gridspv         "grid between areas with high pv production and the rest"
  gridcsp         "grid between areas with high csp production and the rest"
  gridwind        "grid between areas with high wind production and the rest"
/

***-----------------------------------------------------------------------------
*** Definition of subsets of 'te':
***-----------------------------------------------------------------------------

teRLDCDisp(all_te)     "RLDC Dispatchable technologies that produce seel"
/
/

teLearn(all_te)     "Learning technologies (investment costs can be reduced)"
/
        wind        "wind power converters"
        spv         "solar photovoltaic" 
        csp         "concentrating solar power"
        storspv     "storage technology for spv"
        storwind    "storage technology for wind"
        storcsp     "storage technology for csp"
/

teNoLearn(all_te)   "Technologies without learning effect"

teEtaIncr(all_te)       "Technologies with time variable efficiency parameter eta"   
*RP* computationally the explicit build-time tracking for teEtaIncr is expensive. Therefore, I removed the heating plants, because there the efficiency is anyway high and doesn't have such a large influence
/
  pc    
  igcc  
  igccc 
  ngcc  
  ngccc 
  ngt   
  bioigcc
  bioigccc
/

teEtaConst(all_te)      "Technologies with constant eta"

teCCS(all_te)       "Technologies with CCS"
/
  ngccc       "natural gas combined cycle with carbon capture"
  gash2c      "gas to hydrogen with capture"     
  igccc       "integrated coal gasification combined cycle with carbon capture"
$ifthen setGlobal cm_ccsfosall
  pcc         "pulverized coal power plant with capture"
  pco         "pulverized coal power plant with oxyfuel capture"
$endif
  coalftcrec  "coal based fischer-tropsch with capture recycle"
  coalh2c     "coal to hydrogen with capture"
  bioftcrec   "biomass based fischer-tropsch with capture recycle"
  bioh2c      "biomass to hydrogen with capture"
  bioigccc    "integrated biomass gasification combined cycle with CCS"
/

teNoCCS(all_te)     "Technologies without CCS"

teChp(all_te)       "Technologies that produce seel as main output und sehe as secondary output - dynamically defined"

teBio(all_te)      "biomass energy systems technologies"
/
        biotr       "transformation of biomass"
        biotrmod    "modern solids from biomass"
        biochp      "biomass combined heat and power"
        biohp       "biomass heating plant"
        bioigcc     "integrated biomass gasification combined cycle"
        bioigccc    "integrated biomass gasification combined cycle with CCS"
        biogas      "gasification of biomass"
        bioftrec    "biomass based fischer-tropsch recycle"
        bioftcrec   "biomass based fischer-tropsch with capture recycle"
        bioh2       "biomass to hydrogen"
        bioh2c      "biomass to hydrogen with capture"
        bioethl     "biomass to ethanol"
        bioeths     "sugar and starch biomass to ethanol"
        biodiesel   "oil biomass to biodiesel"
/
teRe(all_te)     "renewable technologies including biomass"
/
        biotr       "transformation of biomass"
        biotrmod    "modern solids from biomass"
        biochp      "biomass combined heat and power"
        biohp       "biomass heating plant"
        bioigcc     "integrated biomass gasification combined cycle"
        bioigccc    "integrated biomass gasification combined cycle with CCS"
        biogas      "gasification of biomass"
        bioftrec    "biomass based fischer-tropsch recycle"
        bioftcrec   "biomass based fischer-tropsch with capture recycle"
        bioh2       "biomass to hydrogen"
        bioh2c      "biomass to hydrogen with capture"
        bioethl     "biomass to ethanol"
        bioeths     "sugar and starch biomass to ethanol"
        biodiesel   "oil biomass to biodiesel"
        geohdr      "geothermal electric hot dry rock"
        geohe       "geothermal heat"
        hydro       "hydro electric"
        wind        "wind power converters"
        spv         "solar photovoltaic"
        csp         "concentrating solar power"
        solhe       "solar thermal heat generation"
/
teReNoBio(all_te) "renewable technologies except for biomass"
/
        geohdr      "geothermal electric hot dry rock"
        geohe       "geothermal heat"
        hydro       "hydro electric"
        wind        "wind power converters"
        spv         "solar photovoltaic"
        csp         "concentrating solar power"
***        solhe       "solar thermal heat generation"
/
teNoRe(all_te)        "Non renewable energy technologies"

teVRE(all_te)      "technologies requiring storage"
/
        wind        "wind power converters"
        spv         "solar photovoltaic"
        csp         "concentrating solar power"
/

teStor(all_te)        "storage technologies"
/
        storspv     "storage technology for spv"
        storwind    "storage technology for wind"
        storcsp     "storage technology for csp"
/
teLoc(all_te)      "centralized technologies which require grid"
/
        wind        "wind power converters"
        spv         "solar photovoltaic"
        csp         "concentrating solar power"
/
teGrid(all_te)      "grid between areas"
/
    gridspv     "grid between areas with high pv production and the rest"
    gridcsp     "grid between areas with high csp production and the rest"
    gridwind    "grid between areas with high wind production and the rest"
/
teFosCCS(all_te)    "fossil technologies with CCS"
/
        ngccc       "natural gas combined cycle with carbon capture"
	gash2c      "gas to hydrogen with capture"     
        gasftcrec       "gas based fischer-tropsch with capture recycle"
        igccc       "integrated coal gasification combined cycle with carbon capture"
$ifthen setGlobal cm_ccsfosall
        pcc         "pulverized coal power plant with capture"
        pco         "pulverized coal power plant with oxyfuel capture"
$endif
        coalftcrec  "coal based fischer-tropsch with capture recycle"
        coalh2c     "coal to hydrogen with capture"
/
teFosNoCCS(all_te)  "fossil technologies without CCS"
/
        ngcc         "natural gas combined cycle"
        gash2        "gas to hydrogen"
        igcc         "integrated coal gasification combined cycle"
        pc           "pulverized coal power plant"
        coalftrec    "coal based Fisher-Tropsch recycle"
        coalh2       "coal to hydrogen"
        ngt          "natural gas turbine"
        gastr        "transformation of gases"
        gaschp       "gas combined heat and power"
        gashp        "gas heating plant"
        dot          "diesel oil turbine"
        coalchp      "coal combined heat and power"
        coalhp       "coal heating plant"
        coalgas      "coal gasification"
        coaltr       "transformation of coal"
$IF %cm_OILRETIRE% == "on"   refliq
/
teBioPebiolc(all_te)      "biomass technologies using pebiolc"
/
        biotr
        biotrmod
        biochp
        biohp
        bioigcc
        bioigccc
        biogas
        bioftrec
        bioftcrec
        bioh2
        bioh2c
        bioethl
/
teNoTransform(all_te) "all technologies that do not transform energy but still have investment and O&M costs (like storage or grid)"
/
       storspv       "storage technology for photo voltaic (PV)"
       storwind      "storage technology for wind"
       storcsp       "storage technology for concentrating solar power (CSP)"

       gridspv       "grid between areas with high pv production and the rest"
       gridcsp       "grid between areas with high csp production and the rest"
       gridwind      "grid between areas with high wind production and the rest"   
/
teRegTechCosts(all_te) "all technologies for which we differantiate tech costs"
/
       pc
       igcc      
       ngcc       
       ngt
       gaschp       
       pcc       
       pco
       igccc
       ngccc
       tnrs
       bioigcc
       biogas
       biochp
       geohdr
       hydro
       spv
       csp
       wind      
/
feForUe(all_enty)    "final energy types that are transformed into useful energys - is filled automatically from the content of fe2ue"
ppfenFromUe(all_in)  "all ppfEn that are equivalent to UE - is filled automatically from the content of fe2ue"

feForEs(all_enty)    "final energy types that are transformed into final energys - is filled automatically from the content of fe2es"
ppfenFromEs(all_in)  "all ppfEn that are equivalent to ES - is filled automatically from the content of fe2ue"
feViaEs2ppfen(all_enty,all_in,all_teEs) "map final energies to the primar production factor - is filled automatically from the content of fe2es and es2ppfen"

fe2ppfEn(all_enty,all_in) "mapping between CES FE variables and ESM FE variables" /  /
***-----------------------------------------------------------------------------
*** Definition of the main set of quantities 'enty':
***-----------------------------------------------------------------------------


enty(all_enty)       "all types of quantities"
/
        peoil        "primary energy oil"
        pegas        "primary energy gas"
        pecoal       "primary energy coal"
        peur         "primary energy uranium"
        pegeo        "primary energy geothermal"
        pehyd        "primary energy hydropower"
        pewin        "primary energy wind"
        pesol        "primary energy solar"
        pebiolc      "primary energy biomass lignocellulosic"
        pebios       "primary energy biomass sugar nd starch"
        pebioil      "primary energy biomass sunflowers, palm oil, etc"
        seliqbio     "secondary energy liquids from biomass (ex. ethanol)"
		seliqfos     "secondary energy liquids from fossil primary energy (ex. petrol and diesel)"
        sesobio      "secondary energy solids from biomass"
		sesofos      "secondary energy solids from fossil primary energy"
        seel         "secondary energy electricity"
        seh2         "secondary energy hydrogen"
        segabio      "secondary energy gas from biomass"
		segafos      "secondary energy gas from fossil primary energy"
        sehe         "secondary energy district heating nd heat pumps"
        fegas        "final energy gas stationary"
        fehos        "final energy heating oil stationary"
        fesos        "final energy solids stationary"
        feels        "final energy electricity stationary"
        fehes        "final energy district heating (including combined heat nd power), nd heat pumps stationary"
        feh2s         "final energy hydrogen stationary"
        fepet         "final energy petrol transport"
        fedie         "final energy diesel transport"
	feelt         "final energy electricity for transport"
        fetf          "final energy transport fuels"
        feh2t         "final energy hydrogen transport"
        co2          "carbon dioxide emissions"  
        ch4          "methane emissions"
        n2o          "n2o emissions from the energy system"
        so2          "sulfur dioxide emissions"
        ch4coal    "fugitive emissions from coal mining"
        ch4gas     "fugitive emissions from gas production"
        ch4oil     "fugitive emissions from oil production"
        ch4wstl    "ch4 emissions from solid waste disposal on land"	
        ch4wsts    "ch4 emissions from waste water"		
        ch4rice    "ch4 emissions from rice cultivation (rice_ch4)"
        ch4animals "ch4 emissions from enteric fermentation of ruminants (ent_ferm_ch4)"
        ch4anmlwst "ch4 emissions from animal waste management(awms_ch4)"
        ch4agwaste "ch4 emissions from agricultural waste burning (no MAC available)"
        ch4forest  "ch4 emissions from forest burning"
        ch4savan   "ch4 emissions from savannah burnging"
        n2oforest  "n2o emissions from forest burning"
        n2osavan   "n2o emissions from savannah burnging"
        n2otrans   "n2o emissions from transport"
        n2oacid    "n2o emissions from acid production (only 2005 EDGAR data for calibration of n2oadac and n2onitac baselines)"
        n2oadac    "n2o emissions from adipic acid production"
        n2onitac   "n2o emissions from nitric acid production"				
        n2ofert    "MAC for n2o emissions from fertilizer (starting with n2ofert)"
        n2ofertin  "n2o emissions from Inorganic fertilizers (inorg_fert_n2o)"		
        n2ofertcr  "n2o emissions from decay of crop residues (resid_n2o)"
        n2ofertsom "n2o emissions from soil organic matter loss (som_n2o)"
        n2oanwst   "MAC for n2o emissions from animal waste (starting with n2oanwst)"	
        n2oanwstc  "n2o emissions from manure applied to croplands (man_crop_n2o)"	
        n2oanwstm  "n2o emissions from animal waste management (awms_n2o)"
        n2oanwstp  "n2o emissions from manure excreted on pasture (man_past_n2o)"	
        n2oagwaste "n2o emissions from agricultural waste burning (no MAC available)"		
        n2owaste   "n2o emissions from waste (domestic sewage)"
        co2luc     "co2 emissions from land use change"
        co2cement_process  "co2 from cement production (only process emissions)"
        n2obio       "N2O emissions from pebiolc"
        bc           "black carbon from fossil fuel combustion"
        oc           "organic carbon from fossil fuel combustion"
        NOx
        CO
        VOC
        NH3
        cco2         "captured CO2"
*        pco2         "CCS related parameter during compression of CO2"
*        tco2         "CCS related parameter during transportation of CO2"
        ico2         "CCS related parameter during injection of CO2"
*        sco2         "CCS related parameter during storage of CO2 - monitoring ???"
	good         "Generic good"     
	perm         "Carbon permit"

        !! emissions from industry sub-sectors
        co2cement      "CO2 emissions from clinker and cement production"
        co2chemicals   "CO2 emissions from chemicals production"
        co2steel       "CO2 emissions from steel production"
/

***-----------------------------------------------------------------------------
*** Definition of subsets of 'enty':
***-----------------------------------------------------------------------------
entyPe(all_enty)      "Primary energy types (PE)"
        /
        peoil        "PE oil"
        pegas        "PE gas"
        pecoal       "PE coal"
        peur         "PE uranium"
        pegeo        "PE geothermal"
        pehyd        "PE hydropower"
        pewin        "PE wind"
        pesol        "PE solar"
        pebiolc      "PE biomass lignocellulosic"
        pebios       "PE biomass sugar and starch"
        pebioil      "PE biomass sunflowers, palm oil, etc"
/
peBio(all_enty)      "biomass primary energy types"
/
        pebiolc      "PE biomass lignocellulosic"
        pebios       "PE biomass sugar and starch"
        pebioil      "PE biomass sunflowers, palm oil, etc"
/
peRe(all_enty)    "Renewable primary energy sources"
/
        pegeo        "PE geothermal"
        pehyd        "PE hydropower"
        pewin        "PE wind"
        pesol        "PE solar"
        pebiolc      "PE biomass lignocellulosic"
        pebios       "PE biomass sugar and starch"
        pebioil      "PE biomass sunflowers, palm oil, etc"
/
peFos(all_enty)      "primary energy fossil fuels"
/
        peoil        "PE oil"
        pegas        "PE gas"
        pecoal       "PE coal"
/

peEx(all_enty)    "exhaustible primary energy carriers"
/
        peoil        "PE oil"
        pegas        "PE gas"
        pecoal       "PE coal"
        peur         "PE uranium"
/

peExPol(all_enty)   "primary energy fuels with polynomial"
/
        peur        "PE uranium"
/

peExGrade(all_enty) "exhaustible pe with step as entyPe ex-peExPol - s.b."

peRicardian(all_enty)    "Ricardian PE"

peReComp(all_enty) "Renewable PE used by several technologies, thus the competition between te is modeled by q_limitGeopot equation"
/
        pesol        "PE solar"
/
entySe(all_enty)       "secondary energy types"
/
        seliqbio     "secondary energy liquids from biomass"
		seliqfos     "secondary energy liquids from fossil primary energy"
        sesobio      "secondary energy solids from biomass"
		sesofos      "secondary energy solids from fossil primary energy"
        seel         "SE electricity"
        seh2         "SE hydrogen"
        segabio      "secondary energy gas from biomass"
		segafos      "secondary energy gas from fossil primary energy"
        sehe         "SE district heating nd heat pumps"
/

entyFe(all_enty)      "final energy types. Calculated in sets_calculations"

esty(all_esty)      "energy service types. Have to be added by modules."
//
buildMoBio(all_esty) "modern biomass in buildings"
//
entyUe(all_enty)      "Useful energy types"
//

entyFeStat(all_enty)  "final energy types from stationary sector"
/
        fegas        "FE gas stationary"
        fehos        "FE heating oil stationary"
        fesos        "FE solids stationary"
        feels        "FE electricity stationary"
        fehes        "FE district heating (including combined heat and power), and heat pumps stationary"
        feh2s        "FE hydrogen stationary"
/
entyFeTrans(all_enty) "final energy types from transport sector"
/
        fepet        "FE petrol transport"
        fedie        "FE diesel transport"
        feh2t        "FE hydrogen transport"
	feelt        "FE electricity for transport"
/

feForCes(all_enty)   "limit q_balFeForCes to entyFe in fe2ppfEn"

emi(all_enty)      "types of emissions, these emissions are given to the climate module"

emiTe(all_enty)   "types of climate-relevant energy emissions for climate coupling and reporting"
/
        co2     "energy system co2"
        so2     "energy system so2"
        bc      "black carbon from fossil fuel combustion"
        oc      "organic carbon from fossil fuel combustion"
        ch4     "energy system ch4"
        n2o     "energy system n2o"
/
emiExog(all_enty)  "exogenous emissions"
/ 
        so2
        bc
        oc

/
emiAP(all_enty) "Used for allocation of emission factors"
/
        bc
        oc
/
emiMac(all_enty)  "sum over sub-emissions from emiMacSector"
/
        co2
        n2o
        ch4
/
emiMacSector(all_enty)  "types of climate-relevant non-energy emissions with mac curve. Emissions in this set HAVE to be in emiMac2mac as well - if no MAC is available it will be set to zero automatically."
/
        ch4coal    "fugitive emissions from coal mining"
        ch4gas     "fugitive emissions from gas production"
        ch4oil     "fugitive emissions from oil production"
        ch4wstl    "ch4 emissions from solid waste disposal on land"	
        ch4wsts    "ch4 emissions from waste water"	
        ch4rice    "ch4 emissions from rice cultivation (rice_ch4)"
        ch4animals "ch4 emissions from enteric fermentation of ruminants (ent_ferm_ch4)"
        ch4anmlwst "ch4 emissions from animal waste management(awms_ch4)"
        ch4agwaste "ch4 emissions from agricultural waste burning (no MAC available)"
        ch4forest  "ch4 emissions from forest burning (no MAC available)"
        ch4savan   "ch4 emissions from savannah burning (no MAC available)"
        n2oforest  "n2o emissions from forest burning (no MAC available)"
        n2osavan   "n2o emissions from savannah burning (no MAC available)"
        n2otrans   "n2o emissions from transport"
        n2oadac    "n2o emissions from adipic acid production"
        n2onitac   "n2o emissions from nitric acid production"				
        n2ofertin  "n2o emissions from Inorganic fertilizers (inorg_fert_n2o)"
        n2ofertcr  "n2o emissions from decay of crop residues (resid_n2o)"
        n2ofertsom "n2o emissions from soil organic matter loss (som_n2o)"
        n2oanwstc  "n2o emissions from manure applied to croplands (man_crop_n2o)"	
        n2oanwstm  "n2o emissions from animal waste management (awms_n2o)"
        n2oanwstp  "n2o emissions from manure excreted on pasture (man_past_n2o)"
        n2oagwaste "n2o emissions from agricultural waste burning (no MAC available)"		
        n2owaste   "n2o emissions from waste (domestic sewage)"
        co2luc     "co2 emissions from land use change"
        co2cement_process  "co2 from cement production (only process emissions)"
/

MacSector(all_enty)  "sectors for which mac curves exist. Some MACs are used for several emission sectors in emiMacSector."
/
        ch4coal    "coal mining"
        ch4gas     "gas production"
        ch4oil     "oil production"
        ch4wstl    "solid waste disposal on land"	
        ch4wsts    "waste water"	
        ch4rice    "rice cultivation"
        ch4animals "enteric fermentation of ruminants"
        ch4anmlwst "animal waste management"
        n2otrans   "transport"
        n2oadac    "adipic acid production"
        n2onitac   "nitric acid production"				
        n2ofert    "Inorganic fertilizers"
        n2oanwst   "manure applied to croplands"	
        n2owaste   "waste (domestic sewage)"
        co2luc     "land use change"
        co2cement  "cement production (only process emissions)"
        co2chemicals
        co2steel
/

MacSectorMagpie(all_enty)  "land-use sectors for which mac curves exist in REMIND and in MAgPIE"
/
        ch4rice    "rice cultivation"
        ch4animals "enteric fermentation of ruminants"
        ch4anmlwst "animal waste management"
        n2ofert    "Inorganic fertilizers"
        n2oanwst   "manure applied to croplands"	
        co2luc     "land use change"
/

emiMacMagpie(all_enty)  "types of climate-relevant non-energy emissions with mac curve where baseline emissions come from MAgPIE only"
emiMacMagpieN2O(all_enty)  "types of climate-relevant non-energy N2O emissions with mac curve where baseline emissions come from MAgPIE only"
/
        n2ofertin  "n2o emissions from Inorganic fertilizers (inorg_fert_n2o)"
        n2ofertcr  "n2o emissions from decay of crop residues (resid_n2o)"
        n2ofertsom "n2o emissions from soil organic matter loss (som_n2o)"
        n2oanwstc  "n2o emissions from manure applied to croplands (man_crop_n2o)"	
        n2oanwstm  "n2o emissions from animal waste management (awms_n2o)"
        n2oanwstp  "n2o emissions from manure excreted on pasture (man_past_n2o)"
/
emiMacMagpieCH4(all_enty)  "types of climate-relevant non-energy CH4 emissions with mac curve where baseline emissions come from MAgPIE only"
/
        ch4rice    "ch4 emissions from rice cultivation (rice_ch4)"
        ch4animals "ch4 emissions from enteric fermentation of ruminants (ent_ferm_ch4)"
        ch4anmlwst "ch4 emissions from animal waste management(awms_ch4)"	
/
emiMacMagpieCO2(all_enty)  "types of climate-relevant non-energy CH4 emissions with mac curve where baseline emissions come from MAgPIE only"
/
        co2luc     "co2 emissions from land use change"			
/

emiMacExo(all_enty)  "types of climate-relevant non-energy emissions with mac curve where baseline emissions are exogenous"
emiMacExoN2O(all_enty) "types of climate-relevant non-energy N2O emissions with mac curve where baseline emissions are exogenous"
/
        n2oforest  "n2o emissions from forest burning (no MAC available)"
        n2osavan   "n2o emissions from savannah burning (no MAC available)"
		n2oagwaste "n2o emissions from agricultural waste burning (no MAC available)"		
/
emiMacExoCH4(all_enty)  "types of climate-relevant non-energy CH4 emissions with mac curve where baseline emissions are exogenous"
/
        ch4agwaste "ch4 emissions from agricultural waste burning (no MAC available)"	
        ch4forest  "ch4 emissions from forest burning (no MAC available)"
        ch4savan   "ch4 emissions from savannah burning (no MAC available)"	
/

emiFuEx(all_enty)   "fugitive emissions"
/
        ch4coal    "fugitive emissions from coal mining"
        ch4gas     "fugitive emissions from gas production"
        ch4oil     "fugitive emissions from oil production"
/
sectorEndoEmi(all_sectorEmi)   "sectors with endogenous emissions"
/
        indst    "industry"
        res      "residential"
        trans    "transport"
        power    "power"
/
sectorExogEmi(all_sectorEmi) "sectors with exogenous emissions"
/
    solvents
    extraction
    indprocess
/
ccsCo2(all_enty)    "only cco2 (???)"
/
        cco2
/
rlf             "cost levels of fossil fuels"
/ 
      1*12 
/
integ           "set of integers for looping etc"
/
	1*100
/
xirog       "parameters decribing exhaustible extraction coss including long-run marginal costs and short term adjustment costs"
/
      xi1, xi2, xi3, xi4, xi5, xi6, xi7, xi8
/
*** emissions exported to MAGICC
  emiRCP "emission types exported to MAGICC"
  /
    FossilCO2
    OtherCO2
    CH4
    N2O
    SOx
    CO
    NMVOC
    NOx
    BC
    OC
    NH3
    CF4
    C2F6
    C6F14
    HFC23
    HFC32
    HFC43-10
    HFC125
    HFC134a
    HFC143a
    HFC227ea
    HFC245fa
    SF6
  /

  p                "parameter for ch4 and n2o waste emissions and co2 cement emissions"
  /
  p1
  p2
  p3
  p4
  /
*** This is a work-around to ensure emissions are printed in correct order.
  numberEmiRCP "number of emission types" / 1 * 23 /

  unitsMagicc "units used for MAGICC"
  /
    GtC
    kt
    Mt
    MtCH4
    MtCO
    MtN
    MtN2O-N
    MtS
  /

***-----------------------------------------------------------------------------
*** Definition of the main characteristics set 'char':
***-----------------------------------------------------------------------------
char            "characteristics of technologies"
/
  mix0            "share in the production of v*_INIdemEn0, which is the energy demand in t0 minus the energy produced by couple production"
  ccap0           "cumulated installed capacity in t0. Unit: TW"
  inco0           "investment costs in t0. Unit: $/kW"
  incolearn       "Investment costs that can be reduced through learning. Unit: $/kW"
  floorcost       "Floor investment costs for learning technologies. Unit: $/kW"
  eta             "conversion efficiency"
  omf             "fixed o&m"
  omv             "variable o&m"
  tlt             "techical life time"
  delta           "depreciation rate"
  learn           "learning rate"
  learnMult_woFC  "multiplicative parameter in learning equation (without taking into account floor costs)"
  learnExp_woFC   "exponent in learning equation (without taking into account floor costs)"
  learnMult_wFC   "multiplicative parameter in learning equation, adjusted to take floor costs into account"
  learnExp_wFC    "exponent in learning equation, adjusted to take Floor Costs into account"
  bgrl            "lower bound on growth rate"
  bgru            "upper bound on growth rate"
  bcal            "lower bound on capacity"
  bcau            "upper bound on capacity"
  bmil            "lower bound on contribution to energy mix"
  bmiu            "upper bound on contribution to energy mix"
  bscu            "upper bound on combined heat power contribution to electricity production"
  nur             "multiplicator for nu"
  maxprod         "maximum annual production"
  cost            "marginal costs of extraction"
  quan            "quantity of fuel class"
  leak            "leakage rate of CCS sequestration"
  omeg            "NOT USED ANYMORE. New parameter: pm_omeg. Weight factor of still available capacities."
  seed            "initial value for control variable constraint"
  lingro          "linear growth of control variable additions p.a."
  linconstela     "elastaticity of investment costs for linear growth constraint"
  limitGeopot        "geographical annual solar potential"
  luse            "land use factor of solar technologies"
  capacity        "capacity of solar technologies" 
  constrTme       "Construction time in years, needed to calculate turn-key cost premium compared to overnight costs"
  tkpremused      "turn-key cost premium used in the model (with a discount rate of 3+ pure rate of time preference); in comparison to overnight costs)"
  lifetime        "average lifetime of a technology (integral under the omeg-curve). Unit: years"
  flexibility                        "representing ramping constraints or additional costs for partial load of technologies in power sector"
  tech_stat       "technology status: how close a technology is to market readiness. Scale: 0-3, with 0 'I can go out and build a GW plant today' to 3 'Still some research necessary'" 
  Xport           "imports"
  Mport           "exports"
  use             "financial trade costs for PE use [trl$US per TWa]"
  XportElasticity "PE trade adjustment cost parameter that influences the export supply elasticity"
  tradeFloor      "PE trade adjustment cost parameter that allows for smallest trade increase without adjustment cost"
  min             "minimum"
  max             "maximum"
  usehr            "number of hours in a year when the technology is used"
  elh2VREcapRatio    "ratio of elh2VRE capacity to storage technology capacity"
  h2turbVREcapRatio  "ratio of h2turbVRE capacity to storage technology capacity"
  batteryVREcapRatio  "ratio of battery capacity to storage technology capacity"
/

***-----------------------------------------------------------------------------
*** Definition of subsets of 'char':
***-----------------------------------------------------------------------------
charPeRe(char) "characteristics of renewables"
/
        cost       "marginal costs of production"
        maxprod    "maximum annual production"
/
s_statusTe   "technology status: how close a technology is to market readiness. Scale: 0-3, with 0 'I can go out and build a GW plant today' to 3 'Still some research necessary'"
/ 
      0 * 3 
/
;

***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
***                 Definition of SETS of MACRO
***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------

Sets
  in(all_in)        "all inputs and outputs of the CES function"
  /
    inco    "macroeconomic output"  
    lab     "labour input"
    kap     "capital input"
    en      "energy input"
  /

  ppf(all_in)                "all primary production factors"
  ipf(all_in)                "all intermediate production factors"
  ppfKap(all_in)              "primary production factors capital"   / kap /
  ppfEn(all_in)              "primary production factors energy" /  /
  in_putty(all_in)               "production factors subject to putty-clay dynamics"
  ppf_putty(all_in)           "all putty-clay primary production factors"
  ipf_putty(all_in)           "all putty-clay intermediate production factors"
  ppfIO_putty(all_in)         "factors treated in the normal CES as ppf and in putty-clay as output"
  nests_putty(all_in,all_in)  "defines factors which are in the same putty subnest. The first all_in gives the higher factors of the subnest"
  in_complements(all_in)           "factors which are perfect complements" 
  //
  in_enerSerAdj(all_in)                "energy services factors which should be constrained by adjustment costs"
  //
  complements_ref(all_in,all_in)    "correspondence between complementary factors. Necessary to have a reference factor for the constraints equations"
 
  fe_tax_sub_sbi(all_in,all_in) "correspondence between tax and subsidy input data resolution and model sectoral resolution. For FE which takes the pathway I to the CES "
  //
  fe_tax_subEs(all_in,all_esty) "correspondence between tax and subsidy input data resolution and model sectoral resolution. For FE which takes the pathway III to the CES "
  //
  cesParameter   "parameters of the CES functions and for calibration"
  /
    quantity   "quantity of CES function input/output"
    price      "price of CES function input/output"
    eff        "baseyear efficiency of CES function input/output"
    effgr      "multiplicative efficiency growth of CES function input/output"
    rho        "CES function elasticity parameter rho = 1 - (1 / sigma)"
    xi         "baseyear income share of CES function input/output"
    offset_quantity "quantity offset for the CES tree if the quantity is null"
    compl_coef    "coefficients for the perfectly complementary factors"
  /

  trade(all_enty)             "all traded commodities"
  //
  tradeMacro(all_enty)      "traded macro-economic commodities"
  /good, perm/
  tradePe(all_enty)         "traded primary energy commodities"
  /
  peoil, pecoal, pegas, peur, pebiolc
  /
  tradeSe(all_enty)         "traded secondary energy commodities"
  /
  null
  /

***-------------------------------------------------------------------------------
***                 SETS for fragmented policy regimes
***-------------------------------------------------------------------------------
period1(tall) "first commitment period"
/
       2010,2015,2020
/
period2(tall) "second commitment period"
/
       2025,2030,2035,2040,2045,2050
/
period3(tall)"rest of century"
/
       2055,2060,2065,2070,2075,2080,2085,2090,2095,2100
/
period4(tall)      "period 4"
period12(tall)     "period 1 and 2"
period123(tall)    "period 1,2, and 3"
period1234(tall)   "period 1,2,3,and 4"

***-------------------------------------------------------------------------------
***                             HYBRID-SETS
***-------------------------------------------------------------------------------

sol_itr       "iterator for inner solution process within one Negishi iteration"
/
      1*10
/

iteration     "iterator for main (Negishi/Nash) iterations" 
/    
      1*200
/
steps         "iterator for MAC steps" 
/
      1*801
/
;

***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
***                             Helpful constructs: alias
***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
alias(t,t2);
alias(t,t3);
alias(tall,tall2);
alias(tall,tall3);
alias(ttot,ttot2);
alias(opTimeYr,opTimeYr2);
alias(teVRE,teVRE2);
alias(teLoc,teLoc2);
alias(all_te,all_te2);
alias(te,te2);
alias(all_enty,all_enty2);
alias(enty,enty2);
alias(enty,enty3);
alias(enty,enty4);
alias(enty,enty5);
alias(enty,enty6);
alias(enty,enty7);
alias(entyPE,entyPE2);
alias(entySe,entySe2);
alias(entyFe,entyFe2);
alias(teEs,teEs2);
alias(esty,esty2);
alias(rlf,rlf2);
alias(regi,regi2);
alias(in,out);
alias(steps,steps2);
alias(in,in2,in3);
alias(ipf,ipf2);

***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
***                 Definition of  MAPPINGS
***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
Sets

*NB* mappings resulting from set opertations
en2en(all_enty,all_enty,all_te)  "all energy conversion mappings"
en2en2(all_enty,all_enty,all_te) "alias of en2en: all energy conversion mappings"
en2se(all_enty,all_enty,all_te)   "all energy conversion mappings producing SE"
te2rlf(all_te,rlf)               "all technologies to grades"

pe2se(all_enty,all_enty,all_te) "map primary energy carriers to secondary"
/
        pegas.seel.ngcc
        pegas.seel.ngccc
        pegas.seel.ngt
        pegas.seel.gaschp
        pegas.segafos.gastr
        pegas.seh2.gash2
        pegas.seh2.gash2c
        pegas.sehe.gashp
        pegas.seliqfos.gasftrec
        pegas.seliqfos.gasftcrec
        pecoal.seel.igcc
        pecoal.seel.igccc
        pecoal.seel.pc
$ifthen setGlobal cm_ccsfosall
        pecoal.seel.pcc
        pecoal.seel.pco
$endif
        pecoal.seel.coalchp
        pecoal.sesofos.coaltr
        pecoal.segafos.coalgas
        pecoal.seh2.coalh2
        pecoal.seh2.coalh2c
        pecoal.sehe.coalhp
        peoil.seliqfos.refliq
        pecoal.seliqfos.coalftrec
        pecoal.seliqfos.coalftcrec
        pebiolc.seliqbio.bioftrec
        pebiolc.seliqbio.bioftcrec
        pebioil.seliqbio.biodiesel
        pebios.seliqbio.bioeths
        pebiolc.seliqbio.bioethl
        peoil.seel.dot
        pebiolc.seel.biochp
        pebiolc.seel.bioigcc
        pebiolc.seel.bioigccc
        pebiolc.seh2.bioh2
        pebiolc.seh2.bioh2c
        pebiolc.sehe.biohp
        pebiolc.sesobio.biotr
        pebiolc.sesobio.biotrmod
        pebiolc.segabio.biogas
        pegeo.seel.geohdr
        pegeo.sehe.geohe
        pehyd.seel.hydro
        pewin.seel.wind
        pesol.seel.spv
        pesol.seel.csp
        pesol.sehe.solhe
        peur.seel.tnrs
        peur.seel.fnrs
/

seAgg(all_enty) "secondary energy aggregations"
/
	all_seliq
	all_seso
	all_sega
/

seAgg2se(all_enty,all_enty) "map secondary energy aggregation to se"
/
	all_seliq.seliqbio
	all_seliq.seliqfos
	all_seso.sesobio
	all_seso.sesofos
	all_sega.segabio
	all_sega.segafos
/

*RP* mappings for storage technologies
VRE2teStor(all_te,teStor)   "mapping to know which technology uses which storage technology"
/
        spv.storspv
        wind.storwind
        csp.storcsp
/

VRE2teVRElinked(all_te,all_te)    "mapping between the technologies requiring storage which use the same fluctutating source (so the shareseel counts half towards the other shareseel)"
/
        spv.csp
        csp.spv
/

*RP* mappings for grid technologies
VRE2teGrid(all_te,teGrid)              "mapping to know which technology needs which grid technology (length/siting)"
/
        spv.gridspv
        wind.gridwind
        csp.gridcsp
/

te2teLoclinked(teLoc,teLoc2)   "mapping between the technologies requiring grids which use similarly sited resources (so the shareseel counts 1/4 towards the other shareseel)"
/
        spv.csp
        csp.spv
/

se2se(all_enty,all_enty,all_te)  "map secondary energy to secondary energy using a technology"
/
        seel.seh2.elh2
        seh2.seel.h2turb
        seel.seh2.elh2VRE
        seh2.seel.h2turbVRE
/

se2fe(all_enty,all_enty,all_te)   "map secondary energy to end-use energy using a technology"
/
        seel.feels.tdels
        segabio.fegas.tdbiogas
		segafos.fegas.tdfosgas
        seliqbio.fehos.tdbiohos
		seliqfos.fehos.tdfoshos
        sesobio.fesos.tdbiosos
		sesofos.fesos.tdfossos
        seh2.feh2s.tdh2s
        sehe.fehes.tdhes
        seel.feelt.tdelt
        seliqbio.fepet.tdbiopet
		seliqfos.fepet.tdfospet
        seliqbio.fedie.tdbiodie
		seliqfos.fedie.tdfosdie
        seh2.feh2t.tdh2t
/

fe2ue(all_enty,all_enty,all_te)    "map FE carriers to ES via appliances"
//

fe2es(all_enty,all_esty,all_teEs)    "map FE carriers to ES via ES technologies"
//

pc2te(all_enty,all_enty,all_te,all_enty)    "mapping for own consumption of technologies"
/
        pecoal.seel.coalchp.sehe
        pebiolc.seliqbio.bioethl.seel
        pebiolc.seliqbio.bioftrec.seel
        pebiolc.seliqbio.bioftcrec.seel
        pegas.seel.gaschp.sehe
        pecoal.seh2.coalh2.seel
        pecoal.seh2.coalh2c.seel
        pebiolc.seel.biochp.sehe
        segabio.fegas.tdbiogas.seel
		segafos.fegas.tdfosgas.seel
        pegeo.sehe.geohe.seel
        cco2.ico2.ccsinje.seel
        fedie.uedit.apCarDiEffT.feelt
        fedie.uedit.apCarDiEffH2T.feelt
        fedie.uedit.apCarDiEffH2T.feh2t
/
*NB* mappings for emissions, capture and leakage
emi2te(all_enty,all_enty,all_te,all_enty)    " map emissions to technologies"
/
        pegas.seel.ngcc.co2
        pegas.seel.ngt.co2
        pegas.seel.gaschp.co2
        pegas.seel.ngccc.co2
        pegas.seel.ngccc.cco2
        pegas.segafos.gastr.co2
        pegas.seh2.gash2.co2
        pegas.seh2.gash2c.co2
        pegas.seh2.gash2c.cco2
        pegas.sehe.gashp.co2
        pegas.seel.ngcc.n2o
        pegas.seel.ngt.n2o
        pegas.seel.gaschp.n2o
        pegas.seel.ngccc.n2o
        pegas.segafos.gastr.n2o
        pegas.seh2.gash2.n2o
        pegas.seh2.gash2c.n2o
        pegas.sehe.gashp.n2o
        pegas.seliqfos.gasftrec.co2
        pegas.seliqfos.gasftcrec.co2
        pegas.seliqfos.gasftcrec.cco2
        pecoal.seel.igcc.co2
        pecoal.seel.pc.co2
        pecoal.seel.coalchp.co2
        pecoal.seel.pc.so2
        pecoal.seel.coalchp.so2
        pecoal.seel.pc.bc
        pecoal.seel.coalchp.bc
        pecoal.seel.pc.oc
        pecoal.seel.coalchp.oc
        pecoal.seel.igccc.co2
$ifthen setGlobal cm_ccsfosall
        pecoal.seel.pcc.co2
        pecoal.seel.pco.co2
        pecoal.seel.pcc.cco2
        pecoal.seel.pco.cco2
        pecoal.seel.pcc.n2o
        pecoal.seel.pco.n2o
$endif
        pecoal.seel.igccc.cco2
        pecoal.sesofos.coaltr.co2
        pecoal.sesofos.coaltr.so2
        pecoal.sesofos.coaltr.bc
        pecoal.sesofos.coaltr.oc
        pecoal.sesofos.coaltr.ch4
        pecoal.sehe.coalhp.co2
        pecoal.sehe.coalhp.so2
        pecoal.sehe.coalhp.bc
        pecoal.sehe.coalhp.oc
        pecoal.seh2.coalh2.co2
        pecoal.seh2.coalh2c.co2
        pecoal.seh2.coalh2c.cco2
        pecoal.segafos.coalgas.co2
        pecoal.seliqfos.coalftrec.co2
        pecoal.seliqfos.coalftcrec.co2
        pecoal.seliqfos.coalftcrec.cco2
        pecoal.seel.igcc.n2o
        pecoal.seel.pc.n2o
Lavinia Baumstark's avatar
Lavinia Baumstark committed
2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548
        pecoal.seel.coalchp.n2o
        pecoal.seel.igccc.n2o
        pecoal.sesofos.coaltr.n2o
        pecoal.sehe.coalhp.n2o
        pecoal.seh2.coalh2.n2o
        pecoal.seh2.coalh2c.n2o
        pecoal.segafos.coalgas.n2o
        peoil.seliqfos.refliq.co2
        peoil.seliqfos.refliq.so2
        peoil.seel.dot.co2
        peoil.seel.dot.so2
        peoil.seel.dot.bc
        peoil.seel.dot.oc
        peoil.seel.dot.n2o
        pebiolc.seliqbio.bioftcrec.co2
        pebiolc.seliqbio.bioftcrec.cco2
        pebiolc.seh2.bioh2c.co2
        pebiolc.seh2.bioh2c.cco2
        pebiolc.sesobio.biotr.bc
        pebiolc.sesobio.biotr.oc
        pebiolc.sesobio.biotrmod.bc
        pebiolc.sesobio.biotrmod.oc
        pebiolc.sesobio.biotr.ch4
        pebiolc.sesobio.biotrmod.ch4
        pebiolc.seel.biochp.bc
        pebiolc.seel.biochp.oc
        pebiolc.sehe.biohp.bc
        pebiolc.sehe.biohp.oc
        pebiolc.seliqbio.bioethl.bc
        pebios.seliqbio.bioeths.bc
        pebioil.seliqbio.biodiesel.bc
        pebiolc.seliqbio.bioethl.oc
        pebios.seliqbio.bioeths.oc
        pebioil.seliqbio.biodiesel.oc
        pebiolc.seh2.bioh2c.n2o
        pebiolc.seel.biochp.n2o
        pebiolc.sehe.biohp.n2o
        pebiolc.sesobio.biotr.n2o
        pebiolc.sesobio.biotrmod.n2o
        pebiolc.seel.bioigccc.n2o
        pebiolc.seel.bioigcc.n2o
        pebiolc.segabio.biogas.n2o
        segabio.fegas.tdbiogas.ch4
		segafos.fegas.tdfosgas.ch4
*        cco2.pco2.ccscomp.co2
*        pco2.tco2.ccspipe.co2
        cco2.ico2.ccsinje.co2
        pebiolc.seel.bioigccc.co2
        pebiolc.seel.bioigccc.cco2
        seliqbio.fehos.tdbiohos.bc
		seliqfos.fehos.tdfoshos.bc
        seliqbio.fedie.tdbiodie.bc
		seliqfos.fedie.tdfosdie.bc
        seliqbio.fepet.tdbiopet.bc
		seliqfos.fepet.tdfospet.bc
        seliqbio.fehos.tdbiohos.oc
		seliqfos.fehos.tdfoshos.oc
        seliqbio.fedie.tdbiodie.oc
		seliqfos.fedie.tdfosdie.oc
        seliqbio.fepet.tdbiopet.oc
		seliqfos.fepet.tdfospet.oc
/
emi2fuel(all_enty,all_enty) "map emissions to fuel extraction"
/
    pecoal.ch4coal
    pegas.ch4gas
    peoil.ch4oil
/
emiMacSector2emiMac(all_enty,all_enty)   "mapping of sub-emissions to their sum"
/
        (co2luc,co2cement_process)                          .co2
        (n2otrans,n2oadac,n2onitac,n2ofertin,n2ofertcr, n2ofertsom, n2oanwstc,n2oanwstm, n2oanwstp,n2oagwaste,n2oforest,n2osavan,n2owaste).n2o
        (ch4coal,ch4gas,ch4oil,ch4rice,ch4animals,ch4anmlwst,ch4agwaste,ch4forest,ch4savan,ch4wstl,ch4wsts).ch4
/
emiMac2mac(all_enty,all_enty)            "mapping of emission sources to MACs - caution: not all MACs exist, in that case they are zero"
/
        ch4coal.ch4coal 
        ch4gas.ch4gas
        ch4oil.ch4oil
        ch4wstl.ch4wstl
        ch4wsts.ch4wsts
        ch4rice.ch4rice
        ch4animals.ch4animals
        ch4anmlwst.ch4anmlwst
        ch4agwaste.ch4agwaste
        ch4forest.ch4forest
        ch4savan.ch4savan
        n2otrans.n2otrans
        n2oadac.n2oadac
        n2onitac.n2onitac
        (n2ofertin, n2ofertcr, n2ofertsom).n2ofert
        (n2oanwstc, n2oanwstm, n2oanwstp).n2oanwst
        n2oagwaste.n2oagwaste
        n2owaste.n2owaste
        n2osavan.n2osavan
        n2oforest.n2oforest
        co2luc.co2luc
        co2cement_process. co2cement   "process emissions are captured by kiln CCS too"
        co2cement    . co2cement
        co2chemicals . co2chemicals
        co2steel     . co2steel
/
*NB*111125 emissions from fossil fuel extraction by grade that is on top of combustion
emi2fuelMine(all_enty,all_enty,rlf)   "missions from fossil fuel extraction"
/
        co2.peoil.(4*8)
/
ccs2te(all_enty,all_enty,all_te)   "chain for ccs"
/
*        cco2.pco2.ccscomp
*        pco2.tco2.ccspipe
        cco2.ico2.ccsinje
*        ico2.sco2.ccsmoni
/

ccs2Leak(all_enty,all_enty,all_te,all_enty)   "leakage along ccs chain"
/
*        cco2.pco2.ccscomp.co2
*        pco2.tco2.ccspipe.co2
        cco2.ico2.ccsinje.co2
*        ico2.sco2.ccsmoni.co2
/

pe2rlf(all_enty,rlf)     "map exhaustible energy to grades for qm_fuel2pe"
/
        peoil.(1*8)
        pegas.(1*6)
        pecoal.(1*6)
        pebiolc.(1*2)
        pebios.(5)
        pebioil.(5)
       (peur,pegeo,pehyd,pewin,pesol).1
/

teReComp2pe(all_enty,all_te,rlf)  "map competing technologies to primary energy carrier and grades"
/
        pesol.spv.(1*9)
        pesol.csp.(1*9)
/

demSeOth2te(all_enty,all_te)      "map other se demands not directly following the sedem-route through technologies"
/
  seh2.csp
  segabio.csp
  segafos.csp
/

prodSeOth2te(all_enty,all_te)      "map other se production not directly following the sedem-route through technologies"
/
  seh2.h2curt
/

teSe2rlf(all_te,rlf)        "mapping for techologies to grades. Currently, the information was shifted to teRe2rlfDetail. Thus, teSe2rlf now only has '1' for the rlf values"
/
      (wind,spv,csp,refliq,hydro,geohe,geohdr,solhe,ngcc,ngccc,ngt,gaschp,gashp,gash2,gash2c,gastr,gasftrec,gasftcrec,dot,
       igcc,igccc,pc,coaltr,coalgas,coalh2,coalh2c,coalchp,coalhp,coalftrec,coalftcrec,
       biotr,biotrmod,biogas,bioftrec,bioftcrec,bioh2,bioh2c,biohp,biochp,bioigcc,bioigccc,
       elh2,h2turb,elh2VRE,h2turbVRE,bioethl,bioeths,biodiesel,tnrs,fnrs
$ifthen setGlobal cm_ccsfosall
       pcc, pco
$endif
       ) . 1
/

teRe2rlfDetail(all_te,rlf)        "mapping for se techologies to grades"
/
        wind.(1*9)
        spv.(1*9)
        csp.(1*9)
        hydro.(1*5)
        geohe.1
        geohdr.1
/

teFe2rlf(all_te,rlf)      "mapping for final energy to grades"
/
      (tdels,tdelt,tdbiogas,tdfosgas,tdbiohos,tdfoshos,tdh2s,tdh2t,tdbiodie,tdfosdie,tdbiopet,tdfospet,tdbiosos,tdfossos,tdhes) . 1
/

teue2rlf(all_te,rlf)     "mapping for ES production technologies to grades"
//

teCCS2rlf(all_te,rlf)     "mapping for CCS technologies to grades"
/
***      (ccscomp,ccspipe,ccsinje,ccsmoni) . 1
      (ccsinje) . 1
/

teNoTransform2rlf(all_te,rlf)         "mapping for no transformation technologies to grades"
/
      (storspv,storwind,storcsp,gridspv,gridwind,gridcsp,h2curt) . 1
/

opTimeYr2te(all_te,opTimeYr)        "mapping for technologies to yearly lifetime - is filled automatically in generisdata.inc from the lifetime values in generisdata_tech.prn"
tsu2opTimeYr(ttot, opTimeYr)     "mapping for opTimeYr to the used time ttot - will be filled automatically in generisdata.inc"

tsu2opTime5(tall,opTimeYr)     "mapping for spinup time index to lifetime index"
/
1910.96
1915.91
1920.86
1925.81
1930.76
1935.71
1940.66
1945.61
1950.56
1955.51
1960.46
1965.41
1970.36
1975.31
1980.26
1985.21
1990.16
1995.11
2000.6
2005.1
/

sectorEndoEmi2te(all_enty,all_enty,all_te,sectorEndoEmi)	 "map sectors to technologies"
/
        pegas.seel.ngcc.power
        pegas.seel.ngt.power
        seh2.seel.h2turb.power
        pegas.seel.gaschp.power
        pegas.sehe.gashp.power
        pegas.segafos.gastr.indst
        pegas.segafos.gastr.res
        pecoal.seel.pc.power
        pecoal.seel.coalchp.power
        pecoal.sehe.coalhp.power
        pecoal.sesofos.coaltr.indst
        pecoal.sesofos.coaltr.res
        peoil.seliqfos.refliq.trans
        peoil.seliqfos.refliq.indst
        peoil.seliqfos.refliq.res
        peoil.seel.dot.power
        pebiolc.seel.biochp.power
        pebiolc.sehe.biohp.power
        pebiolc.sesobio.biotr.indst
        pebiolc.sesobio.biotr.res
        pebiolc.sesobio.biotrmod.indst
        seliqbio.fehos.tdbiohos.indst
		seliqfos.fehos.tdfoshos.indst
        seliqbio.fehos.tdbiohos.res
		seliqfos.fehos.tdfoshos.res
        seliqbio.fedie.tdbiodie.trans
		seliqfos.fedie.tdfosdie.trans
        seliqbio.fepet.tdbiopet.trans
		seliqfos.fepet.tdfospet.trans
/
emiRCP2emiREMIND "mapping between emission types expected by MAGICC and provided by REMIND"
/
    CO    . CO
    NMVOC . VOC
    NOx   . NOx
    SOx   . SO2
    BC    . BC
    OC    . OC
/
emiFgas2emiRCP(all_enty,emiRCP)   "match F-gases to MAGICC emissions"
/
    emiFgasCF4       . CF4 
    emiFgasC2F6      . C2F6
    emiFgasC6F14     . C6F14
    emiFgasHFC23     . HFC23
    emiFgasHFC32     . HFC32
    emiFgasHFC43-10  . HFC43-10
    emiFgasHFC125    . HFC125
    emiFgasHFC134a   . HFC134a
    emiFgasHFC143a   . HFC143a
    emiFgasHFC227ea  . HFC227ea
    emiFgasHFC245fa  . HFC245fa
    emiFgasSF6       . SF6
/
emiRCP2order "order of emission types expected by MAGICC"
/
    FossilCO2 .  1
    OtherCO2  .  2
    CH4       .  3
    N2O       .  4
    SOx       .  5
    CO        .  6
    NMVOC     .  7
    NOx       .  8
    BC        .  9
    OC        . 10
    NH3       . 11
    CF4       . 12
    C2F6      . 13
    C6F14     . 14
    HFC23     . 15
    HFC32     . 16
    HFC43-10  . 17
    HFC125    . 18
    HFC134a   . 19
    HFC143a   . 20
    HFC227ea  . 21
    HFC245fa  . 22
    SF6       . 23
/
  
emiRCP2unitsMagicc(emiRCP,unitsMagicc) "match units to emission types"
/
    (FossilCO2,OtherCO2)  . GtC
    (CH4)                 . MtCH4
    (N2O)                 . MtN2O-N
    (SOx)                 . MtS
    (CO)                  . MtCO
    (NH3,NOx)             . MtN
    (NMVOC,BC,OC)         . Mt
    (CF4,C2F6,C6F14,HFC23,HFC32,HFC43-10,HFC125,HFC134a,HFC143a,HFC227ea,HFC245fa,SF6) . kt
/

cesOut2cesIn(all_in,all_in)              "CES tree structure"
/
    inco  . (lab, kap, en)
/

ue2ppfen(all_enty,all_in)      "matching UE in ESM to ppfEn in MACRO"
//

es2ppfen(all_esty,all_in)      "matching ES in ESM to ppfEn in MACRO"
//

cesLevel2cesIO(counter,all_in)   "CES tree structure by level"
cesRev2cesIO(counter,all_in)   "CES tree structure by level - descending order"
cesOut2cesIn_below(all_in,all_in) "all elements of the CES below located below the first item given"
in_below_putty(all_in)            "all elements of the CES below ppf_putty, excluding ppf_putty. Only meaningful in case putty structures are not intertwined"
;

in_putty(all_in)    = NO;   
ppf_putty(all_in)   = NO; 
ipf_putty(all_in)   = NO; 
ppfIO_putty(all_in) = NO;  

***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------
***                             Helpful constructs: alias
***-----------------------------------------------------------------------------
***-----------------------------------------------------------------------------

alias(cesOut2cesIn,cesOut2cesIn2);
alias(ccs2te,ccs2te2);
alias(pe2se,pe2se2);

*** EOF ./core/sets.gms