Alfalfa: Standardizing Runtime Interaction with Building Energy Simulation

Project website: https://github.com/NREL/alfalfa
Performer: National Renewable Energy Laboratory (NREL) - Golden, CO
Performance period: FY22 -
DOE funding: $250,000 in FY24; $500,000 in total
Funding vehicle: Emerging Technologies - Building Energy Modeling and Controls core funding
Related Projects: EnergyPlus, Spawn, BOPTEST, Smart Thermostat Benchmarking

Project Objective

Many of the traditional uses of whole-building energy simulation are non-interactive; a model is configured, the simulation is run a preset time-period like a design day or a year, the results are harvested and analyzed. However, a growing number of use cases use energy simulation interactively; here the simulation can exchange data with an external actor—another program, a physical device, or a human—at different points in the simulation time-step. Applications of interactive simulation include:

  • Hardware-in-the-loop (HIL) testing of physical HVAC or refrigeration equipment where simulation is used to drive conditions to the input of the equipment.
  • Testing and benchmarking of control algorithms using a virtual building in lieu of a real building.
  • Building operator training, again using a virtual building in lieu of a real building.

EnergyPlus has an external runtime interface for this purpose, but that interface is bespoke and using it requires programming to the EnergyPlus runtime application programming interface (API). Enter Alfalfa. Alfalfa standardizes runtime interaction with energy simulation by placing it behind an interface that is familiar to many developers, specifically the same interface that building automation systems (BAS) provide for remote access over the web. To outside actors—humans, physical devices, or software—Alfalfa makes a simulated building look like a remote physical building. Alfalfa makes it easy to automate interaction with one or hundreds of simulations as they run by providing an open-source web service that robustly solves the common tasks required for runtime interaction with simulation. 

Contacts

DOE technology manager: Amir Roth
Principal investigator: Anya Petersen, NREL