EnergyPlus Co-simulation Toolbox

version (70.8 MB) by Jiri Dostal
Co-simulation of EnergyPlus models in Matlab/Simulink.


Updated 18 Apr 2021

From GitHub

View License on GitHub

The toolbox facilitates simultaneous simulation of EnergyPlus and Matlab (co-simulation). The main component is the mlep class containing all the necessary tools to configure and run EnergyPlus co-simulation within the Matlab environment.

System Requirements
* Windows. The toolbox has only been tested for Windows, but considerable preparations for other OS has already been done.
* EnergyPlus installed. You can obtain the software here If you install the EnergyPlus to the default location ('C:\EnergyPlusVx-x-x') then it might be detected automatically by the toolbox.

Obtain a copy of the toolbox from
* Matlab Add-on Manager
* or Mathworks File Exchange
* or a GitHub repository
and install.

The toolbox contains:

* Parsing of the IDF file to determine co-simulation inputs/outputs.
* Automatic socket communication configuration (on localhost).
* Background start of the EnergyPlus process with an output to the Matlab command line.
* System Object implementation usable in Matlab & Simulink.
* Bus input/output integration for easy Simulink model setup.

See the GettingStarted.mlx guide delivered with the Matlab toolbox or the documentation residing under Help -> Supplemental Software -> EnergyPlus co-simulation toolbox

* Always be sure that EnergyPlus itself is working. To check run "EP-Launch.exe" from the EnergyPlus installation folder and try running one of its examples (located at <EP folder>/ExampleFiles/).
* If you have issues with "EnergyPlus not found." run "setupMlep.m".
* If you have an issue with a "Vector to Bus" block not having its bus types correctly specified, run the model again. Bus objects should now be in the workspace and it should work.

Copyright (C) 2019, Jiri Dostal (
All rights reserved.

This software builds on the free software by Truong Nghiem(, Willy Bernal ( and several other third-party open-source tools.

Cite As

Dostal, Jiri, and Tomas Baumelt. “Model Predictive Control for Buildings with Active One-Pipe Hydronic Heating.” E3S Web of Conferences, edited by S.I Tanabe et al., vol. 111, EDP Sciences, 2019, p. 04050, doi:10.1051/e3sconf/201911104050.

View more styles
MATLAB Release Compatibility
Created with R2019b
Compatible with R2017a and later releases
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!



To view or report issues in this GitHub add-on, visit the GitHub Repository.
To view or report issues in this GitHub add-on, visit the GitHub Repository.