**Why the energy detective?**

The question today is **how to measure the energy consumption of a production building with only one counter**. And when we have several overlapping process. We want to know the consumption for each process. To solve this problem we will act as an energy detective which uses **one clue to go to the next step**. For us every step is one of the different energies. **We will use ****regressions****, a formula and data filtering**.

**Only one counter! **

Let’s specify the starting point. One production building which has an air conditioning system (HVAC). The batch production has these activities: mixing, heating and cooling. We can measure material produced and know which activity is occurring. The external atmospheric conditions are known. **But we only have one counter!**

ETotal = EHVAC + EMixing + EHeating + ECooling.

**Data collected: production, external conditions and process activities.**

We always have the HVAC system connected. In other cases we can be in the mixing, heating or cooling phase. As you see there are moments when overlapping of several processes occurs. We have the limitation of having a single counter. **We are going to calculate the theoretical energies of each process**.

**First step, HVAC consumption.**

The first step is to determine the HVAC consumption. So, we take the days of no production, by filtering.

ETotal = EHVAC when EMixing = EHeating = ECooling = 0.

Once data is filtered, we will perform a linear regression. **The ****dependent variable**** is the energy consumed and the independent variables are external ****temperature and humidity**. We can use any spreadsheet tool to calculate the linear regression. In this case the result is:

EHVAC = 24.96 -1.24 * T + 0.047 * H where T is external temperature and H is external humidity.

**Verifying the model.**

**To verify the validity of the model we can check the ****R square**** and the ****residual graphs**. We control that the points are distributed homogeneously around the average at a reasonable distance. We also have to check that they are distributed in a random way without a distribution pattern.

**Next step: Energy for mixing.**

Now we have the energy from the air conditioning system. The next one to estimate is mixing.

EMixing = ETotal – EHVAC when EHeating = ECooling = 0.

So, once again we filter the points where we know that mixing is taking place and where other activities do not overlap. This consumption relates to the amount of product processed. Therefore we will do the regression taking as independent variable the energy measured minus the energy for the HVAC and as an independent variable the processed material. The result is:

EMixing = -1.47 + 10.98 * Pu where Pu are the processed units.

**Energy for heating**

Fine for the *energy detective!* With the same logic previously used, we will now calculate the energy needed for heating the product. **We filter the points where heating occurs**. If we want the model to be very exact, we avoid overlapping with another activities, as long as we have enough points for the regression. But if this is not the case, we can take also take overlapping points.

EHeating = ETotal – EHVAC when EMixing = ECooling = 0.

We filter the data when heating occurs. The dependent variable will be the energy measured minus the energy for the HVAC and the independent variable is the processed material.

EHeating = -7.43 + 19.51 * Pu

**Finally, the energy detective finds out the cooling energy. **

We filter the points where cooling occurs. The dependent variable will be the total energy minus the energy for the HVAC and the independent variable will be the processed units.

ECooling = ETotal – EHVAC when EHeating = EMixing = 0.

The result is:

ECooling = -29.50 + 27.38 * Pu

**Lastly, we have all the energies. We can make a graph to compare these theoretical energies versus the real energy measured.**

I hope that today’s information is useful. I leave the file with the data used by the energy detective and the different steps below.