U.S. Energy Information Administration logo
‹ Analysis & Projections

Annual Energy Outlook 2019

Release date: January 24, 2019   |  Next release date:  January 2020   |  full report

Availability of the National Energy Modeling System (NEMS) Archive

print version

The National Energy Modeling System (NEMS) was developed primarily for the modelers at the U.S. Energy Information Administration (EIA) and is only used by a few organizations outside of EIA. Some non-EIA users have found NEMS to be too difficult or rigid to use. For example, it is not typically used for state-level analysis and is not well-suited to be modified to analyze other countries. However, many users obtain the model for the data in its input files or for the source code. EIA developed NEMS, so most of what constitutes NEMS is in the public domain (and no licenses are required). However, NEMS does contain some proprietary components that are outside of the public domain but can be licensed as discussed below.

NEMS is an integrated model of the U.S. energy system linked to a macroeconomic model. For an overview of NEMS, see Appendix E from the Annual Energy Outlook 2016. (Appendix E has not been included in the Annual Energy Outlook since then.) More detailed documentation of NEMS is available via the Model documentation link in the footer of the AEO webpage.

An archive of NEMS as used for the Reference case for the Annual Energy Outlook 2019 (AEO) is available as is on our website as an encrypted zip file. This archive shows that the published results in the AEO Reference case can be replicated and discloses the source code and inputs EIA used in the model. It does not include executables of the model, which can be generated from the source code with the appropriate software. Please contact Paul Kondis (contact information at the bottom of this document) for the encryption key to the downloaded file. We will send the files for the proprietary IHS Markit macroeconomic model separately once IHS Markit notifies us that you have obtained a license for the model.

The NEMS archive is a 64-bit application with Microsoft Windows Server 2012, but it should be compatible with other 64-bit Windows versions, such as Windows Server 2008 or Windows 8 for PCs. NEMS requires software packages that EIA does not provide and must be obtained from the vendors:

1) Intel Visual Fortran Compiler Professional Edition for Windows, Version 18.0.1.156 Build 20171018 (now called the Intel® Parallel Studio XE 2018 Composer Edition for Fortran Windows) as a 64‐bit application. (If version 18 is not the latest, it may still be available and should be installed for compatibility. Once you purchase Intel Fortran, you can select to download earlier versions by going to their support site and logging in.)

2) The Electricity Market Module of NEMS uses the Optimization and Modeling Library (OML) License from Ketron Optimization with XpressMP barrier interface (optional). The OML libraries are in the archive file. The license key to make them operational must be obtained independently from:

Ketron Optimization Support Services
P.O. Box 71-1601
Oak Hill, VA 20171-1601 USA
Phone: 703-636-4805

Once you obtain the Ketron OML license files, you must copy all of the files to the MPSIII license folder. Typically, for the normal OML install, the license folder is located at C:\MPSIII. Be sure an Environmental Variables path is set up for MPSIII.CFG. To set this Environmental Variable, right-click Computer, select Properties, select Advanced System Settings, and select the Environmental Variables button under the Advanced tab. If no MPS variable is defined under System Variables, select New… and add the Variable name MPS and define the value as C:\MPSIII\.

3) EIA uses the Xpress optimizer from the Fair‐Isaac Corporation (FICO) to solve the Electricity Capacity Planning linear program (LP) of the Electricity Marketing Model (EMM); the Liquid Fuels Market Module LP; and the Carbon Transport, Utilization, and Storage mixed integer program (MIP). EIA uses the OML optimizer to solve the Electricity Fuel Dispatch LP of the EMM. The OML optimizer can be also be used in place of Xpress to solve the Electricity Capacity Planning LP, but the results will differ from EIA's results and the execution time will increase significantly. The other models listed use Xpress as the solver as supplied with GAMS (see below), but other solvers (such as CPlex) may be substituted in GAMS, with slightly different results. EIA has arranged a license of the Xpress solver with Fair-Isaac Corporation to a limited number of organizations who want to use it for NEMS. To obtain the Xpress Optimization license file, you must::

  1. Contact EIA to request a license for Xpress under EIA’s arrangement with FICO.
  2. Contact FICO to download and install Xpress from the FICO web site. (A form is at the bottom of their Contact Us page that you can fill out and submit. In the comments box, explain that you would like to request an online account and obtain Xpress as part of the EIA arrangement with FICO to run NEMS and.) Run the xphostid executable. Copy the results and send to EIA (paul.kondis@eia.gov).

EIA will forward the result from the xphostid tool to FICO, who will then send a license file.

4) EIA uses the General Algebraic Modeling System (GAMS) for the Carbon Transport, Utilization, and Storage routine and for the Liquid Fuels Market Module. EIA used GAMS version 24.7.3 for the AEO2019. EIA’s GAMS implementation uses the Xpress solver mentioned above. Links to the commercial and academic price schedules for GAMS are available on their website. EIA purchased the development license (rather than the run-time license), which allows changes to the linear program matrix during execution of a NEMS run.

5) EIA uses the Advanced Integrated Multidimensional Modeling Software (AIMMS) for the Coal Market Module, the Natural Gas Market Module, and the Renewable and Electricity Storage submodule within the Electricity Market Module. EIA used AIMMS version 4 (release 4.37.4.1024) for AEO2019, licensed with the CPLEX solver. The AIMMS System Development Kit, with a programming interface known as the AIMMSLINK library, has been installed at EIA and is also used with the NEMS Coal Market Module. The AIMMSLINK library invokes the AIMMS SDK and is linked in for NEMS runs. The AIMMS SDK is no longer supported by AIMMS.

6) (Optional) For macroeconomic feedback cases only, the IHS Markit Macroeconomic Model, as implemented with the EViews8 software package, is used. EIA is using the EViews8 standard edition, version 8.1, Sep 8, 2015 build. The IHS Markit macro module is called directly from NEMS if the macro feedback switch in NEMS is turned on. Users can elect to run NEMS without macro feedback, in which case the run uses a static macroeconomic inputs taken as is. When the Macro feedback switch is on, NEMS will attempt to call the macro model by executing EViews using the IHS Markit model's work files as the input to Eviews. These Eviews work files are not included in the archive, but they can be obtained from EIA after licensing the IHS Markit model. A copy of Eviews must also be obtained to run the IHS Markit model. An IHS Markit representative is Matt Weiler (Matt.Weiler@iksmarkit.com).

NEMS is computationally intensive and requires a memory address space of about 2 gigabytes (GB) with some additional memory, about 1 GB, allocated dynamically. Some modules, those run as separate subprocesses, are not included in this total. EIA is now running NEMS as a 64-bit application on 64-bit Windows PCs with the 64-bit Windows Server 2012. The EIA servers running NEMS have 128 GB of random access memory (RAM) to accommodate multiple runs and users simultaneously, but a single copy of NEMS may execute on a single-user system with 4 GB of RAM. NEMS also can be run on a desktop/laptop using Windows 8 with sufficient RAM and processing speed. EIA runs the integrated NEMS run in two parts simultaneously (in parallel) to speed run time, so two processor cores per integrated run are used. If a (non-integrated) run is done with modules off (e.g., turning off coal, electricity, and renewables) then only one processor core per run is needed. With a quad core processor, you can run two integrated parallel runs or four non-integrated runs with little speed loss, provided sufficient memory is available. To run two integrated runs or four non-integrated runs in parallel, 16 GB of RAM is suggested.

Runs of NEMS take about 3-4 hours on the EIA servers purchased in 2014 (with dual Intel XEON E5-2690 v2 processors, 3.6 gigahertz), but most scenarios are solved by making a series of complete runs, known as cycles, that are used to resolve convergence and foresight issues. Such multi-run scenarios are usually planned to run overnight, for about 12-8 hours total, so that they will be completed by mid-morning. Runs of some individual parts of NEMS, if run separately, such as the energy demand models, can take only a few minutes. All files of a completed run, input and output, take up about 30 gigabytes of storage, but they compress to about 15 gigabytes once the run finishes.

Brief instructions for compiling the code, setting up a run, and replicating the AEO Reference case are included in a readme.txt file included with the archive. EIA does not have a budget to support the outside use of NEMS.

If you have technical questions about the NEMS archive and requests for the zip file encryption key, contact Paul Kondis at 202-586-1469 (paul.kondis@eia.gov). Email is the best method for acquiring the encryption key.

Link to the model: https://www.eia.gov/outlooks/archive/aeozipfiles/aeo/aeo2019.zip