# What's the logic behind the load simulation in Simulink's power_microgrid example?

I'm trying to understand the Simulink example "Simplified Model of a Small Scale Micro-Grid" in order to build something similar. If it's included in your Simulink version you can access it by writing power_microgrid in Matlab.

I get how they simulate the behaviour of the solar panels and the battery using a controlled current source, but my problem comes with the simulation of the houses. The circuit is very similar to the one inside the battery and panels. I understand that this way they can change the power dissipated inside the resistor and simulate the loads of the house, but isn't the current source introducing "free" energy into the system, that can flow into the battery and charge it, or modify the voltage of the system?

Its not free energy to the system.

What the ideal current source does is facilitates forcing current around the loads & from the supply.

If there are loads forcing current to flow, the resultant VA can be measured and the affect on voltage distortion can be seen at the utility

• Thank you! If no energy is introduced in the system then I understand it better. But there's one more detail: in the power_microgrid model the output of the controlled current sources simulating the houses seems to flow against the current coming from the generator, the panels and the batteries. Why opposing the current instead of contributing to it? – Mario F. Palos Aug 28 '17 at 14:07

This is for two possible reasons,

First reason is to include voltage dependent loads. where the load in general can be modeled in 3 ways based on their voltage dependency consumption.The generalized

$P=P_0(\frac{V}{V_0})^\alpha$

$Q=Q_0(\frac{V}{V_0})^\alpha$

where $P_0\, \&\, Q_0$ are the nominal consumption at rated voltage ($V_0$).

1) Constant impedance load (CZL) (electrical heater for example): in this case the load is simply modeled by the equivalent impedance. ($\alpha=2$)

2) Constant current load (CIL) (Fluorescent lamp for example): in this case load is modeled as current source.($\alpha=1$)

3) Constant power load (CPL) (motor drives a pump for example): in this case load is modeled as combination of both aforementioned modelling schemes.($\alpha=0$).

In real life the load is a mix of the three models.

Second reason is to model harmonic injection of the load in case of studying the power quality of the microgrid. This is to ease the computational effort (instead of simulating a group of converters and linear loads you simulate their effects only).

• its not for modeling harmonic injection. The current source for all the loads is configured as an AC source & the RMS value is given. The model has 3 "houses" each with ideal sinus current sources -> pure sinus current draw – JonRB Aug 28 '17 at 10:23
• Ok, actually I did not check the model that's why I've written "possible reasons". Thanks for the correction. – Hazem Aug 28 '17 at 10:37