• Nem Talált Eredményt

Consumer side Management and Control Algorithms

2.4 Indoor Temperature Control

2.4.4 MPC Strategy For Thermostat’s Setpoint Control

factor choice represents a trade-off between the inconvenience factor and the compensation.

Another consequence of the increment of the weighting factor that can be seen in Fig 2.12, is that the indoor temperature curve gets smoother. That is due to the increase of the weight penalty exercised on the inconvenience.

Figure 2.13: Thermostat behavior.

where qmax is the maximum heat flowing out of the heating system when it is actuated by its maximum nominal power P OWmax.

Thus, the goal is to control the thermostat by changing the setpoint Td (i.e., the desired temperature) at each time sample. This implies changing the comfort level range (i.e., TdϵTinTd+ϵ) to achieve thermal comfort while minimizing the energy consumption of the heating system in the temperature control time horizon.

Figure 2.14 shows the block diagram of the proposed setup. The MPC receives the consumer’s desired temperature Td and starts the prediction of the suitable temperatures, denoted by TM P Ck , using the thermal dynamics of the household and the heating system that includes the thermostat represented in Figure 2.13. Then the MPC generates optimal setpoints over a finite prediction horizonNprd. The thermostat receives the MPC’s outputs that will be the new temperature setpoints. The optimal setpoints may include the desired temperature specified by the consumer. Sequentially, the thermostat generates actuation signals uT T to actuate the heating system.

The heating system, by its turn, injects a heat flow that will circulate the household for the time when it is switched on. This control loop is represented in Figure 2.14 by L1. The primary objective is to minimize the energy consumed in actuating the heating system by regulating the thermostat setpoint and the duration of the heating operation. However, the MPC should minimize the temperature error between the measured indoor temperature Tin and the optimal setpoint obtained TM P C. This control loop is referred to by L2. The optimal setpoint obtained by the MPC is also regulated based on the outdoor temperature variation. Hence, the manipulated variable, in this case, is the setpoint of the thermostat TM P C.

The MPC performs an optimization at every sample time Ts in our case to get the minimum sufficient heat to bring the actual temperatureTinto the range around the desired temperature Td along the prediction horizon Nprd. The process is carried out by measuring at each time slot k the current indoor and outdoor temperatures. Thus the inputs of the MPC are updated to prepare for the new optimization at the next time slot k+1.

The cost function for the MPC optimization problem, to minimize the energy

consump-Figure 2.14: Control loops setup L1 and L2. tion and the temperature error, reads

min

TM P Ck

Nprd

X k=1

qkhvac+

Nprd X k=1

(TM P CkTdk)2

, (2.31)

where TM P C is the manipulated variable.

The output of the MPC which is the optimal set point should not deviate from the desired temperature given by the consumer with a certain range as follow

TdkθTM P CkTdk+θ, (2.32) where θ is a pre-defined range by the consumer that indicates the width of the acceptable thermal comfort, which could be less or equal to ϵ (θϵ). The changes of the optimal setpoints are also bounded to keep the energy consumption minimal

TM P Ck ,min≤∆TM P Ck ≤∆TM P Ck ,max. (2.33) The indoor temperature should be inside of the thermal comfort range at each time slot, hence

TdkθϵTinkTdk+θ+ϵ, (2.34) where ∆TM P C is the rate of control changes that we seek to keep small at each time slot.

The advantage of the MPC scheme is the minimization of energy consumption. However, the thermal comfort can also be improved since the MPC employs a new width specified by the user that will force, by the constraint (2.32), the thermostat to switch on and off the heater to keep the indoor temperature in the range of ±θ around the desired temperature set by the consumer. Hence, if θϵ, the consumer can achieve an optimal thermal comfort with smaller deviations around the desired temperature.

Simulation 4 In this section, the presented MPC algorithm is evaluated by running sim-ulations in Matlab/Simulink environment. The simulation of the models is done in a time horizon of 24 hours; however, the framework efficiency is demonstrated by considering smaller time intervals. The time slot is considered to be∆t=1ssince the changes of the thermostat control are fast, and its variation may not be captured correctly. The outdoor temperature Text is considered to be available at every time slot k, where the value of k increases by ∆t. For this example, the desired temperature is set to beTd=21°C, and the switching range of the thermostat is ϵ=C. The thermal comfort range resulting from this case study is bounded byθ=0.5°C as well. The maximum power of the electric heating system is similar to previous simulations (i.e., 2kW).

Firstly, the operation of the thermostat controlling the heating system without imple-menting the MPC strategy is simulated where the setpoint Td is constant throughout the time horizon. As an example, we consider a time window of 10 hours for simulation, and Figure 2.15 illustrates the measured indoor temperature changes according to the changes of the outdoor temperature. The thermostat keeps the indoor temperature in the speci-fied range of ±ϵ, where the measured temperature exhibits a limit cycle around the desired temperature.

Figure 2.15: Indoor temperature changes using thermostat control only (top) and the outdoor temperature changes (bottom).

Figure 2.16 illustrates the consumption of the heating system to maintain the desired comfort range when the MPC does not regulate the setpoint. It can be seen that each time the heating system is on, it consumes 2kW for the average duration of 12.5 minutes. The duration when the heating system is in off mode changes according to the disturbances (i.e., changes of the outdoor temperature). The total time when the heater is on throughout the

chosen time horizon window is 1.67 hours. Hence, the total electric energy consumed in this case is 3.34kWh.

Figure 2.16: Power consumed by the heating system controlled by the thermostat only.

As discussed before, the MPC is used to optimize the thermostat’s setpoint, and for this case scenario, the MPC strategy is implemented for simulation. Figure 2.17 shows the results of the simulation. The MPC controls the heating system (i.e., heater with a thermostat) to keep the indoor temperature inside the thermal comfort in the range of θ. The thermostat turns on the heating system repeatedly thanks to the MPC’s output so that the limit cycles have small amplitudes around the desired temperature.

Figure 2.17: Indoor temperature changes with the MPC strategy to control the thermostat control.

The setpoint of the thermostat TM P C (i.e., the manipulated variable) is changed contin-uously by the MPC, where the new setpoints values and their variation pattern are shown in Figure 2.18.

As it can be seen from Figure 2.18, the resulting setpoints are not always equal to the desired temperature (i.e., the setpoint specified by the user) throughout the time, but it is less or similar. However, the thermal comfort is kept optimal where the limit cycle has a smaller amplitude around the desired temperature.

Consequently, the power consumed by the heating system is kept minimal to produce sufficient heat due to the smaller temperature setpoints. From Figure 2.19, the heating

Figure 2.18: Optimal temperature setpoints resulting from the MPC strategy optimization.

system indicates the on state, in the time window of 10 hours, for 1.46 hours. The total energy consumption of the heating system in this case scenario is 2.92kWh, which is significantly less than the amount of energy consumed by the heating system when controlled solely by the thermostat. In this example, the amount of energy savings after implementing the MPC strategy is approximately 12,57%. We can also note that the indoor temperature changes rapidly when the outdoor temperature is low since the controller aims to keep the temperature at the comfort level as long as possible.

Figure 2.19: Power consumed by the heating system when implementing the MPC strategy.

Remark 1 The MPC strategies proposed in Sections 2.4.2 and 2.4.4 can both be imple-mented for a population of residential consumers that have different types of heating systems.

Both strategies are verified to have significant energy cost reduction and energy savings.