Benjamin Paris

Julien Eynard

Stéphane Grieu

Monique Polit
email: polit@univ-perp.fr

Hybrid PID-fuzzy control scheme for managing energy resources in buildings

Keywords: energy performance of buildings, multi-energy buildings, thermal comfort, hybrid PID-fuzzy control scheme

both indoor temperature regulation and energy resources management in buildings require the design and the implementation of efficient and readily adaptable control schemes. One can use standard schemes, such as "on/off" and PID, or "advanced" schemes, such as MPC (Model Predictive Control). Another approach would be considering artificial intelligence tools. In this sense, fuzzy logic allows controlling temperature and managing energy sources, taking advantage of the flexibility offered by linguistic reasoning. With this kind of approaches, both the specific use of a building and the specificities of a proposed energy management strategy can be easily taken into account when designing or adjusting the control scheme, without having to model the process to be controlled. PID controllers being commonly used in buildings engineering, the proposed control scheme is built on the basis of a PID controller. This allows implementing the scheme even if a control system based on such a controller is already in use. So, a hybrid PID-fuzzy scheme is proposed for managing energy resources in buildings, as the combination of two usual control structures based on PID and fuzzy controllers: the "parallel" structure (according to the current dynamical state of the considered process, either the PID or the fuzzy controller is selected) and the "fuzzy supervision" of a PID controller. To test the scheme in simulation, a building mock-up has been built, instrumented and modeled. Finally, criteria describing the way energy is used and controlled in real-time have been defined with the aim of evaluating both the proposed strategy and the control scheme performance.

Introduction

Managing energy resources in buildings is fully related to both the development and the in-situ implementation of efficient control schemes. Controlling energy systems and/or actuators allows ensuring indoor comfort and, to a lesser extent, reducing energy consumption. Security and fault detection are also under consideration. Several tools, such as Multi Agent Control Systems (MACS) have already been developed with the aim of responding to the just-mentioned problematic [START_REF] Dounis | Advanced control systems engineering and comfort management in building environment-A review[END_REF]. Unfortunately, these tools are hard to develop and implement.

Parameters to be controlled can be classified into multiple categories. Because people spend about 90% of the time inside buildings, indoor parameters, such as brightness, air quality and movement, humidity or thermal ambience, affect their health, morale or productivity. That is why ensuring thermal comfort (generally defined as follows: "that condition of mind which expresses satisfaction with the thermal environment" and usually referred of whether someone is feeling too cold or too hot) is essential because of its psychological implications. In some cases, people may refuse to live or to work in a particular environment. One speaks of "Sick Building Syndrome" (SBS) [START_REF] Gupta | Sick building syndrome-A case study in a multistory centrally air-conditioned building in the Delhi City[END_REF][START_REF] Wang | Symptom definition for SBS (sick building syndrome) in residential dwellings[END_REF][START_REF] Takigawa | A longitudinal study of environmental risk factors for subjective symptons associated with sick building syndrome in new dwellings[END_REF], as a combination of ailments associated with an individual's place of work (office building) or residence. A key-point, when managing energy resources in buildings, is that ensuring thermal comfort, controlling the above-mentioned indoor parameters, while reducing energy consumption is not an easy task. Both considerations seem to be in opposition.

Whatever the meaning we give to it and because of its subjectivity, thermal comfort is difficult to define as a range of environmental and personal factors. That is why a common approach deals with the "Predicted Mean Vote" (PMV) (on the following thermal sensation scale: +3 is "very hot", +2 is "hot", +1 is "relatively hot", 0 is "neither hot nor cold", -1 is "relatively cold", -2 is "cold" and -3 is "very cold") of a large population of people exposed to a certain environment. PMV is derived from the physics of heat transfer combined with an empirical fit to sensation. The PMV equation uses a steady-state heat balance for the human body and postulates a link between the deviation from the minimum load on heat balance effector mechanisms and thermal comfort vote. The greater the load, the more the comfort vote deviates from zero. PMV is arguably the most widely used thermal comfort index today. PPD is the "Predicted Percent of Dissatisfied" people at each PMV [START_REF] Fanger | Thermal comfort: analysis and applications in environmental engineering[END_REF][START_REF] Raatchen | Demand controlled ventilating systems: state of the art review[END_REF]. However, this index is not always easy to use and focuses on human feeling only. So, it is not well adapted to considerations such as control performance or energy consumption. That is why, usually, the building's Energy Performance Indicator (EPI) (kWh.m -2 .year -1 ) is also calculated [7,8]. Unfortunately, this indicator is only able of expressing the amount of energy consumption, without any explanation. It does not both dissociate the various energy consumptions components and explain how energy is consumed in buildings. As a consequence, proposing new and effective control approaches allowing ensuring indoor comfort, taking into consideration the previouslymentioned and hard-to-handle parameters, while reducing significantly energy consumption, has become mandatory.

Standard control schemes, such as "on/off" and PID, are widely used in building engineering [START_REF] Bernard | Optimal building energy management. Part II: Control[END_REF][START_REF] Levermore | Building energy management systems: an application to heating and control[END_REF][START_REF] Mathews | Developing cost efficient control strategies to ensure optimal energy use and sufficient indoor comfort[END_REF]. As an example, On/off controllers are used for indoor temperature regulation but, in this case, energy consumption is high because of both significant fluctuations and frequent setpoint overshoots. This kind of control schemes perform poorly in some applications or environments (such as disturbed environments) and do not in general provide optimal control. PID controllers are feedback (or closed-loop) controllers with constant parameters and no direct knowledge of the considered process. When used alone, they usually give poor control performance for large timedelay process, in case of process noise or in the presence of non-linearities [START_REF] Ang | PID control system analysis, design, and technology[END_REF][START_REF] Li | PID control system analysis and design -Problems, remedies, and future directions[END_REF]. Usually, the control system performance is improved by cascading multiple PID controllers [START_REF] Kaya | Improved cascade control structure for enhanced performance[END_REF] or by combining feedback and feed-forward (or open-loop) controllers [START_REF] Thomas | Feed-forward in temperature control in buildings[END_REF]. In the second case, knowledge about the considered system can be fed forward and combined with the PID output to improve the overall system performance. Another valid approach would be considering, instead of (or in addition to) the just-mentioned standard control schemes, "advanced" schemes or artificial intelligence tools [START_REF] Li | Tuning cascade PID controllers using fuzzy logic[END_REF][START_REF] Martins | Application of feedforward artificial neural networks to improve process control of PID-based control algorithms[END_REF][START_REF] Kukolj | Design of a PID-like compound fuzzy logic controller[END_REF]. In this sense, optimal [START_REF] Zaheer-Uddin | Optimal control of time scheduled heating, ventilating and air conditioning processes in buildings[END_REF][START_REF] Kummert | Optimal heating control in a passive solar commercial building[END_REF], predictive [START_REF] Chen | Real-time predictive supervisory operation of building thermal systems with thermal mass[END_REF][START_REF] Henze | Development of a predictive optimal controller for thermal energy storage systems[END_REF] and adaptative [START_REF] Curtis | Neural networks applied to buildings-A tutorial and case studies in prediction and adaptive control[END_REF][START_REF] Nesler | Adaptive control of thermal processes in buildings[END_REF] controllers were used for both ensuring thermal comfort and limiting set-points overshoots, as the only way to save energy. Because these controllers are model-based controllers, one needs to model the considered buildings. However, every building has a specific non-linear thermal behavior related to the construction materials used, its structure, its use and its environmental condition. As a consequence control schemes found in the literature always focus on a specific kind of buildings [START_REF] Mozer | The neurothermostat: predictive optimal control of residential heating systems[END_REF][START_REF] Gouda | Quasi-adaptive fuzzy heating control of solar buildings[END_REF]. As previously-mentioned, artificial intelligence tools can also be used for controlling influential parameters in buildings. In this sense, fuzzy adaptative controllers have been successfully applied to heating [START_REF] Altrock | Adaptive fuzzy control applied to home heating system[END_REF][START_REF] Gouda | Thermal comfort based fuzzy logic controller[END_REF], with the aim of maximizing both energy efficiency and thermal comfort, visual comfort [START_REF] Guillemin | An innovative lighting controller integrated in a self-adaptive building control system[END_REF][START_REF] Dounis | Building visual comfort control with fuzzy reasoning[END_REF] or natural ventilation [START_REF] Eftekhari | Design and performance of a rule-based controller in a naturally ventilated room[END_REF], one of the most interesting ways for improving buildings' energy performance [START_REF] Calvino | The control of indoor thermal comfort conditions: introducing a fuzzy adaptive controller[END_REF][START_REF] Dounis | Design of a fuzzy set environment comfort system[END_REF][START_REF] Kolokotsa | Advanced fuzzy logic controllers design and evaluation for buildings' occupants thermal-visual comfort and indoor air quality satisfaction[END_REF][START_REF] Lah | Fuzzy control for the illumination and temperature comfort in a test chamber[END_REF]. In the same way or as complementary approaches, artificial neural networks and neuro-fuzzy systems were used as control tools [START_REF] Morel | Neurobat, a predictive and adaptive heating control system using artificial neural networks[END_REF][START_REF] Argiriou | Development of a neural network heating controller for solar buildings[END_REF][START_REF] Ben-Nakhi | Energy conservation in buildings through efficient A/C control using neural networks[END_REF][START_REF] Chen | Fuzzy adaptive networks in thermal comfort[END_REF], for forecasting various environmental parameters, such as indoor temperature, illuminance or relative humidity [START_REF] Ruano | Prediction of building's temperature using neural networks models[END_REF][START_REF] Kazanasmaz | Artificial neural networks to predict daylight illuminance in office buildings[END_REF], or for modeling inhabitants' behavior related to energy use [START_REF] Kalogirou | Artificial neural networks for the prediction of the energy consumption of a passive solar building[END_REF][START_REF] Gonzalez | Prediction of hourly energy consumption in buildings based on a feedback artificial neural network[END_REF][START_REF] Karatasou | Modeling and predicting building's energy use with artificial neural networks: Methods and results[END_REF].

The present paper deals with the development of an indoor temperature controller, allowing managing energy resources in buildings. The main objective of the proposed strategy is optimizing energy performance while ensuring thermal comfort, using the developed control scheme. One can highlight, and this is a key point, that we consider, in opposition of what one can find usually in the literature [START_REF] Dounis | Advanced control systems engineering and comfort management in building environment-A review[END_REF], buildings with both fossil and renewable energy resources (one can speak of "multi-energy" buildings) and we want the control scheme to be easily adaptable to different uses of buildings. On another hand and because PID controllers are commonly used in buildings engineering, the proposed control scheme is built on the basis of a PID controller. This allows implementing the scheme even if a control system based on such a controller is already in use and finding ways for improving its performance. With the aim of both taking into account expert knowledge about the just-mentioned considerations and applying the proposed strategy to multienergy buildings, a hybrid PID-fuzzy controller is proposed, as the combination of two usual control structures based on PID and fuzzy controllers: the "parallel" structure (according to the current dynamical state of the considered process, either the PID or the fuzzy controller is selected) and the "fuzzy supervision" of a PID controller [START_REF] Ketata | Fuzzy controller: design, evaluation, parallel and hierarchical combination with a PID controller[END_REF]. A building mock-up has been built, instrumented and modeled to test the proposed controller in simulation. Instrumentation consists of height temperature sensors and two resistors used as heat sources. Finally, and because both the PMV and the EPI are sometimes hard to handle and only provide partial information, criteria describing the way energy is used and controlled in real-time have been defined with the aim of evaluating both the proposed energy management strategy and the hybrid control scheme performance. The present paper mainly focuses on the impact on these criteria and on energy consumption of both the fuzzification of the fuzzy controller's input and output parameters and the design of the rules.

Control criteria

As just-mentioned, clear and easy-to-handle criteria are needed for evaluating the controller's performance. The proposed criteria allow evaluating thermal comfort, energy consumption and managing fossil and renewable energy resources in real time. First, the criterion is defined as the percentage of the fossil energy consumed ( ) compared with the total energy used (

). Let us note that energy is expressed in Wh.m -2 . Then, the comfort criterion , based on temperature set-point tracking, specifies the mean relative error between (°C) and (°C), with the temperature set-point and the building's indoor mean temperature. Finally, the criterion focuses on both the performance of the proposed controller, comparing the two just-mentioned criteria, and the way the control scheme impacts energy consumption (Equation 1). As a keypoint, one can highlight that the three proposed criteria allow adapting the proposed strategy, especially when designing the fuzzy rules, to the specific use of a building. Usually, one will try to optimize the performance criterion while reducing fossil energy consumption and ensuring thermal comfort. However, in some cases, one can choose to focus on energy consumption or on thermal comfort. As an example, when considering a school, one can favor energy savings during holidays (minimizing ) and favor thermal comfort during course periods (maximizing ). As another example, when considering a hospital, one can favor thermal comfort all the time, taking into consideration the health and wellness of patients. In all the cases and whatever the use of a building, managing energy resources is a compromise between energy consumption and thermal comfort (set-point tracking).

Because both the use and occupancy of a building impact on temperature set-point profiles, specific temperature instructions (for offices and residential buildings respectively), recommended by the French "Règlementation Thermique 2005" [7], were used. This allows testing in several ways the robustness of the proposed hybrid control scheme. For example, when considering an office building, the temperature set-point varies between 7°C and 19°C, according to both the hour of the day and the day of the week. Taking a quick look at Figure 1, one can note that the daily temperature profile proposed is related to the following heating scenario: the heating system is turned on when offices are occupied (intensity is high) or unoccupied for a short period of time (intensity is low) while it is turned off when offices are unoccupied for significant periods of time.

Design and modeling of a building mock-up

Design and thermal losses calculation

Being able to instrument real buildings with a set of sensors for testing heating controller is rare. That is why a building mock-up has been built, instrumented and modeled. Instrumentation consists of height temperature sensors (one outdoor sensor and seven indoor sensors) and two resistors used as heat sources. Designing a mock-up allow testing the proposed hybrid controller in condition that can be considered to be closed to real condition. Moreover, working with a mockup gives flexibility about both sensors and heat sources localization. The lack of thermal inertia favors reactivity and avoids energy waste. The mock-up was built, taking as a reference a real onefloor building of 128 m 2 , with a bay window, in the following way: first, its scale was defined, secondly, materials were chosen and, finally, energy resources and losses were calculated. The respective thickness of both the concrete flagstone found in the just-mentioned real building (20 cm) and the tiled floor, which homogeneity is closed to concrete's homogeneity, used in the mockup (6 mm) allowed calculating its scale (1:27). Length, width and height are about 60 cm, 30 cm and 15 cm respectively. Common building materials were used: gypsum plaster for walls, polyane for glasses (because of its low thickness) and polystyrene for insulation purposes. Figure 2 presents the mock-up. It was in a room at the ELIAUS laboratory (University of Perpignan Via Domitia, south of France) and indirectly exposed to outdoor elements, because of a window. Thermal losses were estimated calculating surface transmission coefficients [7]. Table 1 summarizes all the losses, according to the respective thermal conductivities of the materials used. With the aim of modeling the thermal behavior of the mock-up, data describing how indoor temperature evolves during heating periods were collected. As previously-mentioned, the mock-up was instrumented using temperature sensors placed on the roof (sensors SW and SE), on the floor (sensors NW and NE), at half height (sensors MW and ME) and at the center of the volume (sensor MC). A last temperature sensor measured the temperature inside the room (sensor OUT). Instrumentation was also composed of two resistors (which powers are 80W and 34W respectively, according to the just-mentioned mock-up thermal losses, considering an outdoor temperature of -5°C and a temperature set-point fixed to 21°C) used as primary and secondary heat sources. With the aim of understanding the thermal behavior of the mock-up, various tests were carried out according to the localization of the two heat sources and both the intensity and duration of heating periods. Figure 3 presents an example of temperatures acquisition during a period of about thirty days (from September 9, 2008 to October 6, 2008), with a sampling time of 60s, while Figure 4 shows the spatial distribution of the heat generated inside the mock-up, when only the main heating system is turned on. Taking a look at Figure 3, one can note that all the temperature profiles are similar; only the amplitude varies according to the localization of the sensors. Whatever the sensor, a sudden power increase is reflected in temperatures, which tend to stabilize after a few hours. This behavior is typical of first-order systems. One can also note that amplitude changes are non-linear with respect to the heating power: power changes have a greater impact on indoor temperatures when heating is weak than when it is high. Taking a look at Figure 4, one can remark that a unique convection cell is visible. As a consequence, both Figures 3 and4 highlight the mock-up limitations in terms of thermal behavior, when considering the thermal behavior of a real building. Working with a mock-up doesn't allow studying heat transfers between adjacent thermal zones. Moreover, because of a low thermal inertia characteristic, transitory phenomena are not fully representative of what happens in real buildings.

Mock-up modeling

The study of the mock-up thermal behavior allowed proposing the model structure described by Equation 2, with (°C) the indoor temperature measured by the sensor, (°C) the outdoor temperature, the time index (such as and 60s), (W) the power of the first heat source, (W) the power of the second heat source, the inertia of temperature , and two parameters characterizing the influence of the first heat source on temperature , and two parameters characterizing the influence of the second heat source on temperature and, finally, the influence of outdoor temperature on temperature . Using an iterative process of error minimization depicted by Equation 3 ( (°C) and (°C) are experimental and modeled temperatures respectively), all the parameters of Equation 2 are identified for each of the seven temperature sensors ( ):

with: , , , , and . Table 2 presents the result of the model parameters identification. For each of the seven indoor temperatures, the fit between measured and modeled data is computed using Equation 4. The results of the identification process highlight a mean similarity higher than 90%. All the parameters of the mock-up model are listed by Table 2.

Table 2. Parameters of the mock-up model.

The seven equations obtained were then used in simulation for estimating the average indoor temperature of the mock-up and testing the developed control scheme when applying the proposed energy management strategy. About disturbances, only outdoor temperature is taken into account.

Hybrid PID-fuzzy control scheme

The present section of the paper deals with the design of the hybrid PID-fuzzy control scheme used for managing energy resources, ensuring thermal comfort and reducing energy consumption in multi-energy buildings. First, the different ways, found in the literature, fuzzy techniques are included into existing control tools with the aim of improving the closed loop performances are discussed shortly. This allow to study both the design and properties of fuzzy controllers and combined control structures [START_REF] Dounis | Advanced control systems engineering and comfort management in building environment-A review[END_REF][START_REF] Ketata | Fuzzy controller: design, evaluation, parallel and hierarchical combination with a PID controller[END_REF] such as the well-known "commutation between fuzzy and PID controllers" or "fuzzy supervision of a PID controller". Next, the particularities of the hybrid control scheme proposed for managing energy resources are highlighted.

Fuzzy controllers and combined control structures 4.1.1. Fuzzy P, PI, PD and PID controllers

Many different approaches exist to use fuzzy logic in closed-loop control [START_REF] Ketata | Méthodologies de régulation numérique incluant la logique floue[END_REF]. The simplest way deals with the use of both the signals measured from the considered process as the inputs of the fuzzy controller and its outputs to drive the actuators of the process. This controller is called "fuzzy P" controller [START_REF] Ketata | Fuzzy controller: design, evaluation, parallel and hierarchical combination with a PID controller[END_REF]. Depending on the fuzzy controller output, one can also use "fuzzy PI" or "fuzzy PD" controllers [START_REF] Dounis | Advanced control systems engineering and comfort management in building environment-A review[END_REF][START_REF] Ketata | Fuzzy controller: design, evaluation, parallel and hierarchical combination with a PID controller[END_REF]. In most cases, the fuzzy PI controller is an incremental controller. It computes the values of the control increment from both the process output error and the error increment. It is used off-line to generate the numerical look-up tables with the inference mechanism.

Proportional and integral actions are combined to take advantage of both the inherent stability of the proportional controllers and the offset elimination ability of the integral controllers. The fuzzy PD controller computes the values of the control signal (instead of the control increment) from both the process output error and the error increment. This kind of controllers is suitable for a limited class of systems: it is not suitable when measurement noise and sudden load disturbances exist [START_REF] Dounis | Advanced control systems engineering and comfort management in building environment-A review[END_REF]. Finally, one can use a "fuzzy PID" controller which is composed of a conventional PID controller in conjunction with a set of fuzzy rules and a fuzzy reasoning mechanism to tune the PID gains online [START_REF] Zhao | Fuzzy gain scheduling of PID controllers[END_REF]. Such a controller can adapt to varying environments but it is mainly modeldependent and requires human knowledge about the controlled system to define the range of the proportional gain.

Parallel structure: commutation between fuzzy and PID controllers

Combining PID and fuzzy controllers, one can build a "parallel structure". As a consequence and according to the current dynamical state of the considered process, either the PID or the fuzzy controller is selected [START_REF] Ketata | Fuzzy controller: design, evaluation, parallel and hierarchical combination with a PID controller[END_REF]. A key-point when using such a structure is the communication logic which needs to be designed to ensure an efficient transmission of information between the two controllers, while respecting the inherent and various limitations of the process. Usually, the switching strategy is based on the state of an additional variable (depending on both the error between the process output and the reference signal and its increment sign), named commutation variable, allowing selecting one of the two controllers: a value of 0 activates the PID controller while a value of 1 activates the fuzzy controller. Although such a parallel control structure can be implemented in multi-energy buildings (for example, each controller can manage one of the available energy resources), avoiding useless communications between the two controllers and, as a consequence, ensuring thermal comfort while reducing energy consumption is not an easy task. Moreover, one needs at times to use all the resources simultaneously and this can be in opposition to the way the control structure was designed.

Fuzzy supervision of a PID controller

As another approach, a hierarchical structure can be adopted, the PID parameters being tuned with the aim of improving the dynamical response of the process on-line. One speaks of "fuzzy supervision of a PID controller" [START_REF] Ketata | Fuzzy controller: design, evaluation, parallel and hierarchical combination with a PID controller[END_REF]. The main reason for supervising a PID controller is that such a controller is widely used in control engineering. However, many well-known tuning methods can lead to unacceptable results (for example in terms of overshoot). Moreover, this controller is only robust in low disturbed environments and tends to become under-optimal in case of large variations of control loop parameters, if the operating conditions change, or when facing to nonlinear systems. As a consequence, a fuzzy module can be used with the aim of improving the abilities of a PID controller to control optimally systems in highly disturbed context [START_REF] Oliveira | Fuzzy supervision on intelligent control systems[END_REF]. Because they don't need extensive knowledge about the system, PID supervisors are easy to implement. As a key-point, let us note that they allow increasing significantly the robustness of the control system. Their structure is similar to that of fuzzy controllers: while the outputs are the PID parameter increments, the inputs can be both the process output error and its increment [START_REF] He | PID self-tuning control using a fuzzy adaptative mechanism[END_REF][START_REF] Tzafestas | Incremental fuzzy expert PID control[END_REF] or the performance values [START_REF] Oliveira | Fuzzy supervision on intelligent control systems[END_REF][START_REF] He | PID self-tuning control using a fuzzy adaptative mechanism[END_REF][START_REF] Tzafestas | Incremental fuzzy expert PID control[END_REF][START_REF] Litt | An expert system to perform on-line controller tuning[END_REF]. Although supervising a PID controller (already implemented and used in a building) can be useful for improving its performance, this kind of approaches is not the best way to manage energy resources in multi-energy buildings. Indeed, the way one takes advantage of expert knowledge and fuzzy reasoning, using this approach, is too restrictive.

Design of the proposed hybrid PID-fuzzy control scheme

Let us remember that the present paper deals with the development of an indoor temperature controller, allowing managing energy resources in buildings. The main objective of the proposed strategy is optimizing energy performance while ensuring thermal comfort, using the developed control scheme. Let also remember that because PID controllers are commonly used in buildings engineering, this control scheme is built on the basis of a PID controller. With the aim of both taking into account expert knowledge about the just-mentioned considerations and applying the strategy to multi-energy buildings, a hybrid PID-fuzzy controller is proposed, as the combination of the two just-mentioned control structures based on PID and fuzzy controllers: the "parallel" structure (section 4.1.2) and the fuzzy supervision of a PID controller (section 4. 1.3). With this combination one can take advantage of the properties of the two structures, filling in their respective gaps: the PID controller will be in charge of the main heat source (the renewable energy warmer) while the fuzzy controller will both manage the secondary heat source (the fossil energy warmer) and supervise the PID controller. Respective powers are about 80W and 34W. Whatever the situation, is used until power saturation is reached. Only at this point, starts working. The hybrid PID-fuzzy control scheme proposed, which structure is described by Figure 5, allow easily taking into account the specific use of a building, thanks to the design of fuzzy rules [START_REF] Bouslama | Fuzzy control rules and their natural control laws[END_REF]. From the difference between the set-point temperature ( ) and the indoor mean temperature ( ), the PID controller estimates the power of ( ) while a 1 st fuzzy module determines if this power needs to be corrected (

). From and , a 2 nd fuzzy module evaluates the power of ( ).

Figure 5. Framework of the hybrid PID-fuzzy control scheme.

The values of and are normalized between -1 and +1 ( ) and 0 and + 1 (

) respectively then denormalized using the gains and . One needs, first, to characterize all the above-mentioned parameters and their respective "universes of discourse" using fuzzy sets and membership functions and, secondly, to define appropriate fuzzy rules that map inputs to outputs, with the aim of maximizing (thanks to the fuzzification process and the design of the fuzzy rules, one can easily take into account the specific use of a multi-energy building, favoring thermal comfort or minimizing the fossil energy consumption). Equation 5describes the way this indicator can be maximized, jointly optimizing all the controllers' gains ( , , , and ), according to the system model: with: , , , and

Results and discussion

This section focuses on the results obtained about indoor temperature regulation when applying the proposed strategy, allowing managing energy resources in a multi-energy building, using both the mock-up model and the hybrid PID-fuzzy controller developed. The previously-mentioned criteria ( , and ), describing the way energy is used and controlled in real-time, allow evaluating the performance of the control scheme and adapting to the specific use of a building.

PID controller

Heating system

Disturbance

Fuzzy module FLCRE

Fuzzy module FLCFE

This section also deals with the impact on these criteria and on energy consumption of both the fuzzification of the fuzzy modules' input and output parameters and the design of the rule bases.

Let us note that the performance of a PID control scheme with anti-windup system was considered as "reference" performance. From , this controller computes and (Figure 6) [START_REF] Eynard | Control strategies for managing energy in a building mock-up[END_REF].

Figure 6. Framework of the PID control scheme.

Universe of discourses

Let us remember that one needs, first, to characterize the fuzzy modules' input and output parameters and their "universes of discourse" using fuzzy sets, triangular or trapezoidal-shaped membership functions and linguistic labels and, secondly, to define appropriate fuzzy rules that map inputs to outputs, with the aim of implementing the proposed energy management strategy. Because of the thermal inertia, heat transfers between adjacent thermal zones and the heating system dimensioning, temperatures in buildings may be in the range 0°C-30°C. Moreover, and according to the French "Règlementation thermique 2005", temperature set-points ( ) may be in the range 7°C-22°C. As a result, values for the difference between the set-point temperature and the (current) mean indoor temperature range between -24°C and +24°C (

). As previously mentioned, the values of and are normalized between -1 and +1 and 0 and +1 respectively then denormalized using the gains and . So, and . Finally, being saturated at 80W, the universe of discourse of is defined as follows: . To be concise and because, whatever the set-point, similar results are obtained, only results for offices will be presented in the following sections of the paper.

Impact on the control criteria and on energy consumption of both the fuzzification of the fuzzy modules' input and output parameters and the design of the rule bases: overall considerations

Let us note that, because of measurement error due to the data acquisition tool used, control accuracy is ± 0.5°C. Usually, one considers that energy consumption increases by 7% over a year if the regulated indoor temperature rises above the set-point by 1°C. Both factors were considered during the fuzzification phase of the parameters. Let us also note that the control tool was designed without any consideration about control speed which is, however, a significant criterion in control engineering. Nevertheless, and with the aim of avoiding both the saturation of the renewable energy resource and set-point overflow, a progressive relaunch of the control process has been promoted. Table 3 summarizes all the significant results, obtained when using the hybrid PID-fuzzy control scheme for implementing the proposed energy management strategy, according to the fuzzification of the modules' input and output parameters and both the number and the design of the fuzzy rules. Nine configurations are proposed (from A to I). Table 3 highlights how the just-mentioned considerations are related with both the previously-defined criteria , and and (fossil and renewable) energy consumption, when implementing the proposed control scheme in an office while taking into account its use and specific constraints. Increasing, from a starting configuration (A), the number of both the fuzzy sets (common triangular or trapezoidal membership functions and linguistic labels have been associated to the sets) used to split the respective universes of discourse of the modules' input and output parameters and the fuzzy rules led to the optimal configuration (E) which maximizes the performance criterion ( ). Let us also note, first, that the shape of the triangular membership functions used for characterizing around zero has been adjusted (the length of their respective bases has been reduced) from configuration B (this configuration allows minimizing ) to configuration C (this configuration leads to very

PID controller Heating system

Disturbance good performance, rather close to the performance of the optimal configuration E, but using less fuzzy rules) then from configuration D to configuration E (in this case, the number of fuzzy sets has also increased from 5 to 7) (Figure 7), secondly, that the design of the fuzzy rules has been modified from configuration E to configuration F then from configuration F to configuration G and, finally, that the shape of the triangular membership functions used for characterizing has been adjusted (the length of their respective bases has been extended) from configuration H to configuration I. Taking a look at configurations A to I, one can first highlight the two following key-points: [START_REF] Dounis | Advanced control systems engineering and comfort management in building environment-A review[END_REF] the difference between the set-point temperature and the current temperature (used as fuzzy modules input) has to be characterized by splitting its chosen universe of discourse into enough fuzzy sets, notably around zero, to obtain a good comfort criterion ( ) and to avoid oscillations of the controlled temperature around the set-point; (2) splitting the universe of discourse of into enough fuzzy sets allows limiting the use of fossil energy and improves consequently the criterion . Both key-points impact the performance criterion ( ) and define the way the hybrid PID-fuzzy scheme can be implemented according to the use of a building.

Table 3. Impact on the control criteria and on energy consumption of both the fuzzification of the fuzzy modules' input and output parameters and the design of the rule bases (offices).

and are the renewable energy and the fossil energy consumed, respectively.

Optimal configuration E

Taking as a reference the performance of the PID scheme, one can observe that the hybrid PIDfuzzy scheme, with optimal configuration E, allows reducing the percentage of the fossil energy consumed compared with the total energy used by 11.7%, from 6.50% to 5.74%, and increasing both the comfort and the performance criteria by 0.5%, from 72.03% to 72.38%, and 1.7%, from 65.53% to 66.64%, respectively. Looking at Table 3, one can remark that configuration E provides the highest comfort criteria among all of the configurations we studied and that fossil energy consumption is significantly reduced while renewable energy consumption increases moderately:

is reduced by 9.7%, from 521.02 Wh.m -2 to 470.66 Wh.m -2 , while is increased by 3.2%, from 7494.29 Wh.m -2 to 7731.35 Wh.m -2 . Similar results are obtained for houses. Figures 8,9

Configuration B for the minimization of

Taking again as a reference the performance of the PID controller, one can observe that the hybrid PID-fuzzy scheme, with configuration B, allows reducing the percentage of the fossil energy consumed compared with the total energy used by 36.3%, from 6.50% to 4.17% (this is the lowest value of among all of the configurations we studied). However, both the comfort and the performance criteria are notably decreased by 13.82%, from 72.03% to 62.07%, and 11.64%, from 65.53% to 57.90%, respectively. Because implementing the proposed strategy in multi-energy buildings is always a compromise between comfort and energy consumption, one won't be surprised by such a result. Looking at Table 3, one can also remark that choosing configuration B leads to the lowest consumption of fossil energy (338.76 Wh.m -2 ), reduced by 34.98%, from 521.02 Wh.m -2 to 338.76 Wh.m -2 , while the renewable energy consumed increases by 3.8% only, from 7494.29 Wh.m -2 to 7779.79 Wh.m -2 , with respect to the PID controller's performance. Again, similar results are obtained for houses. The respective fuzzifications of , and remain the same as for configuration E (Figures 9 to 11). As a consequence, only the fuzzification of ε is presented (Figure 12) while Tables 6 and7 depict the two sets of fuzzy rules used (modules and ). As mentioned in section 5.2 and taking a look at configuration E, less fuzzy sets split the universe of discourse of ε (one can highlight that extending the base of the triangularshaped membership functions used allow minimizing ) and, as a consequence, two simplified rule bases (of 5 and 10 rules respectively) were designed. Configuration B is useful when, according to the specific use of a building, one want, as a primary objective, to reduce the consumption of fossil energy. In this case, thermal comfort is considered as less relevant.

Sub-optimal configuration C

Figure 13. Fuzzification of (configuration C).

Configuration C is another remarkable configuration, leading to very good performance, rather close to the performance of the optimal configuration E (Table 3), but using less fuzzy rules, as a consequence of only five fuzzy sets being used to split the universe of discourse of ε. With respect to the performance of the PID controller, one can observe that the hybrid PID-fuzzy scheme, with sub-optimal configuration C, allows reducing the percentage of the fossil energy consumed compared with the total energy used by 7.4%, from 6.50% to 6.02%, and increasing slightly both the comfort and the performance criteria by 0.2%, from 72.03% to 72.14%, and 0.9%, from 65.53% to 66.12%, respectively. Looking at Table 3, one can remark that, with configuration C, fossil energy consumption is significantly reduced while renewable energy consumption increases moderately, again with respect to the PID controller's performance: is reduced by 7.7%, from 521.02 Wh.m -2 to 480.95 Wh.m -2 , while is increased by only 0.1%, from 7494.29 Wh.m -2 to 7504.92 Wh.m -2 . Similar results are obtained for houses. Again, the respective fuzzifications of , and remain the same as for configuration E (Figures 9 to 11). As a consequence, only the fuzzification of ε is presented (Figure 13): it is similar to that leading to configuration B (in terms of both the number of fuzzy sets and the membership functions used) but with triangular-shaped membership functions, whose bases have been reduced, grouped around ε = 0. The two sets of fuzzy rules used (modules and ) are unchanged with respect to configuration B (Tables 6 and7).

Design of new rules for improving the control quickness: configurations E' and E"

As just-highlighted, the way the fuzzy rules are designed, related not only to the proposed control strategy but also to the fuzzification of the fuzzy modules' input and output parameters, directly impacts both the evaluation criteria and the closed-loop performance. Let us talk about some highlights from the proposed fuzzy rules for module (configuration E) (Table 4). First, the rule "IF ε is NM THEN is NH" (rule #2) was designed with the aim of both making faster the control and limiting the power of : when it is too hot, heating has to be significantly reduced. About the rule "IF ε is PM THEN is PL" (rule #6), it was designed to limit the power of during heating times: when it is too cold, heating as to be slightly increased. With the aim of giving flexibility to the proposed control strategy and thanks to some specific adjustments of the two just-mentioned rules (rules #2 and #6), one can try to improve the control quickness. The first way (this leads to configuration E') is designing the rule #6 as follows: "IF ε is PM THEN is PH" (when it is too cold, heating has to be significantly increased). The second way (this leads to configuration E") is designing the rule #2 as follows: "IF ε is NM THEN is NL" (when it is too hot, heating has to be slightly reduced). While the control quickness is improved, these two adjustments also lead to increasing the criterion and decreasing both the comfort and performance criteria and (Figure 14). In all cases, the design of the fuzzy rules reflects a compromise between thermal comfort and energy consumption, taking into account a given situation and the specific use of a building. Finally, let us note that, to avoid incoherent behaviors and to be in agreement with the proposed strategy, some potential rules were obviously not taken into account, such as the following ones: "IF ε is NL THEN is PM" (when it is slightly too hot, heating has to be significantly increased) or "IF ε is PL THEN is NL" (when it is slightly too cold, heating has to be slightly reduced). Moreover, one can remark (Table 3) that, with configuration E' and E'', is increased by 45.7% (from 470.66 Wh.m -2 to 685.81 Wh.m -2 ) and 37.3% (from 470.66 Wh.m -2 to 646.37 Wh.m -2 ) while is decreased by 0.4% (from 7731.35 Wh.m -2 to 7698.23 Wh.m -2 and from 7731.35 Wh.m -2 to 7683.12 Wh.m -2 ) respectively, with respect to the performance of optimal configuration E.

and 's power profiles

Figures 15 to 19 deal with the power profiles of the main and secondary heat sources ( and ), when applying the energy management strategy proposed to a multi-energy building which thermal behavior is described by equation 2 (section 3.2), according to both the temperature setpoint used and the hybrid controller configuration (section 5.2). Taking a look at these figures, one can note that the chosen configuration impacts significantly on the profiles. First, let us talk about 's power profile. Choosing optimal configuration E (which maximizes the performance criterion) allows limiting both power variations (as well as their amplitudes) and shutdown and restart sequences. As a consequence, this leads to the more "stable" behavior. That is why sizing correctly the renewable energy warmer ( ) to operate most often at nominal power allows saving energy and preserving it. When choosing configuration B (which minimizes the percentage of the fossil energy consumed compared with the total energy used), the behavior observed is quite similar to that obtained when choosing configuration E. However, one can remark that, with configuration C (which presents very good performance, rather close to the performance of configuration E), power variations (as well as their amplitudes) are significantly larger than when using configurations E or configuration B: the renewable resource is not managed optimally. As expected, this phenomenon is amplified and the number of shutdown and restart sequences is increased while choosing either configuration E' or configuration E" (both configurations were defined with the aim of improving the control quickness). As a consequence, this will impact negatively on the life span of . One can note that, whatever the hybrid controller configuration, the saturation ( ) of is clearly visible on the power profiles. Moreover, with configuration E or configuration B, the mean power supplied by is larger (about 60-80W) than it is with the other configurations and, consequently, this favors the use of the renewable resource. Of course, one needs a main heating system able to provide such a power, what represents a substantial investment. Finally, when the indoor temperature set-point is low (at the end of the 24-hour period), one can remark that the power supplied by is lower (and unsaturated) using configurations E, E' or E" than using configurations B or C. Now, let us talk about 's power profile. In this case, choosing configuration B leads to the more "stable" behavior, limiting both power variations and the number of shutdown and restart sequences. One can highlight that the power supplied by is the lowest (< 5W) using this configuration, among all of the remarkable configurations tested. As a result, one can size the fossil energy warmer (

) to provide such a (low) power with the aim of both operating most often at nominal power and limiting the investment. When using configurations E or C, the power supplied by reaches 5W and at times more but power variations are significantly larger with configuration C. This phenomenon is amplified choosing either configuration E' or configuration E", leading to the saturation ( ) of the fossil resource. Finally, when the indoor temperature set-point is low (at the end of the 24-hour period), configurations E, E' and E" don't use this secondary resource. and 's power profiles (configuration E").

Set-point tracking

Using configuration E, set-point tracking is pretty good (Figure 19). The maximum deviation between and is about 0.25°C. The time response is about 30 minutes. However, taking a look at Figure 20, one can remark that during the 24-hour period, disturbances cannot be rejected completely (for example, at 10h30-11h). When the set-point is 19°C, only one significant overshoot (of about 1.3%) can be noted, at 5h. If outdoor temperature decreases, indoor temperature is hard to stabilize and reaches the set-point with difficulty. When the set-point is 16°C, variations and overshoots ( can exceed the set-point by up to 1°C (6%)) are larger than when the set-point is 19°C. However, indoor temperature stabilizes after about 15 minutes. At the end of the 24-hour period, when the set-point changes suddenly (from 19°C to 7°C), both control quickness and the stabilization of are satisfactory. Using configuration B, in particular when outdoor temperature is cold, oscillates with an amplitude of up to 1.3°C (Figure 21). Although disturbances are well rejected, the controller lacks reactivity and precision. Indeed, when the set-point is 19°C, the time response is about 30 minutes (which is relatively long). Overshoots are weak (about 0.2°C) but one can note that doesn't reach the set-point temperature when outdoor temperature tends to decrease. Let us remember that because configuration B was designed with the aim of minimizing the percentage of the fossil energy consumed compared with the total energy used, one won't be surprised that thermal comfort is not optimal. As a consequence and whatever the hybrid controller configuration, implementing the proposed strategy for managing energy resources in buildings is a compromise between thermal comfort and energy consumption. When the set-point is 16°C, both exhibits significant overshoots (up to 1.3°C) and oscillates with a growing amplitude (from about 0.2°C to about 1°C). At the end of the 24-hour period, when the set-point changes suddenly (from 19°C to 7°C), continues to oscillate with an amplitude of about 1°C. Using configuration C, one can note that the controller is precise during steady-state phases and pretty reactive during transitory phases (Figure 22). When the set-point is 19°C, overshoots are weak (about 0.1°C) and the time response is about 20 minutes. However, when outdoor temperature decreases, the time response increases to about 1h and precision becomes bad. When the set-point is 16°C, precision is very good and the time response is roughly 15 minutes.

oscillates with an amplitude of about 0.2°C and overshoots are weak (about 0.4°C). At the end of the 24-hour period, when the set-point changes suddenly (from 19°C to 7°C), the time response increases up to about 40 minutes and oscillates with the same amplitude (about 0.2°C). Finally, using configuration E' or configuration E" leads to the best set-point tracking (Figures 23 and24). Precision, stability and reactivity are very good. Let us remember that both configurations were designed with the aim of improving the control quickness. Whatever the set-point, no overshoots are observed. The time response is about 20 minutes. In opposition to what can be observed when using configurations B, C or E, precision and stability are not affected by outdoor temperature changes (whether these changes are increases or decreases).

Conclusion

This paper deals with the development of an indoor temperature controller, allowing managing energy resources in buildings. A strategy for optimizing energy performance and ensuring thermal comfort, using the developed control scheme, is proposed. Because PID controllers are commonly used in buildings engineering, this scheme is built on the basis of a PID controller. Consequently, it can be implemented in buildings even if a control system based on such a controller is already in use, as a way to improve its performance. With the aim of both taking into account expert knowledge about energy performance, thermal comfort as well as the use of a building and applying the proposed strategy to multi-energy buildings, a hybrid PID-fuzzy controller is proposed, as the combination of two usual control structures based on PID and fuzzy controllers. These are known as "parallel" structure (according to the current dynamical state of the considered process, either the PID or the fuzzy controller is selected) and "fuzzy supervision" of a PID controller respectively. With this combination one can take advantage of the properties of the two structures, filling in their respective gaps: the PID controller will be in charge of the main heat source (the renewable energy warmer

) while the fuzzy controller will both manage the secondary heat source (the fossil energy warmer

) and supervise the PID controller. A building mock-up has been built, instrumented and modeled to test the proposed hybrid controller in simulation. Instrumentation consists of temperature sensors and resistors used as heat sources. Finally, and because both the Predicted Mean Vote (PMV) and the Energy Performance Indicator (EPI) are sometimes hard to handle and only provide partial information, criteria ( , and ) describing the way energy is used and controlled in real-time have been defined with the aim of evaluating both the proposed energy management strategy and the hybrid control scheme performance. The main conclusion of the work is that the proposed approach is useful for managing fossil and renewable resources in multi-energy buildings. Thanks to the flexibility offered by both the fuzzification of the fuzzy modules' input and output parameters and the design of the fuzzy rules, the proposed hybrid control scheme allows favoring one of the defined criteria or adapting to the specific use of a building. As a consequence, it can affect, in one way or another, the behavior of the considered system. Five remarkable configurations have been studied in detail (including and 's power profiles) with the aim of highlighting the way the controller can adapt to both the specificities and the use of a building. Thanks to the linguistic approach proposed, one can easily promote the set-point tracking (i.e. the comfort criterion ) while increasing the consumption of fossil energy or promote energy savings while decreasing comfort. Promoting the performance criterion is a compromise. Because the hybrid control scheme proposed has been developed in simulation, it needs now to be tested using more complex models and/or situations, with the aim of being finally implemented in real buildings.

Nomenclature

Figure 1 .

 1 Figure 1. Daily temperature set-point profile for offices.

Figure 2 .

 2 Figure 2. The building mock-up used for testing the proposed hybrid control scheme.

Figure 3 .

 3 Figure 3. Mock-up temperatures acquisition.

Figure 4 .

 4 Figure 4. Spatial distribution of the heat generated inside the mock-up.

Figure 7 .

 7 Figure 7. Remarkable configurations.

  , 10 and 11 present the respective fuzzifications of , , and while Tables 4 and 5 depict the two sets of fuzzy rules (modules FLCFE and FLCRE), characterizing configuration E. The following linguistic labels were associated to the fuzzy sets: NH (Negative High), NM (Negative Medium), NL (Negative Low), AZ (Approximately Zero), PL (Positive Low), PM (Positive Medium) and PH (Positive High) for , and for , NH (Negative High), NL (Negative Low), AZ (Approximately Zero), PL (Positive Low) and PH (Positive High) for and, finally, null, weak, medium, strong and full for .

Figure 8 .

 8 Figure 8. Fuzzification of (configurations E, E' and E").

Figure 9 .

 9 Figure 9. Fuzzification of (configurations E, B, C, E' and E").

Figure 10 .

 10 Figure 10. Fuzzification of (configurations E, B, C, E' and E").

Figure 11 .

 11 Figure 11. Fuzzification of

Figure 12 .

 12 Figure 12. Fuzzification of (configuration B).

Figure 14 .

 14 Figure 14. New configurations for improving the control quickness.

Figure 15

 15 Figure 15. and 's power profiles (configuration E).

Figure 16 .

 16 Figure 16.

Figure 17

 17 Figure 17. and 's power profiles (configuration C).

Figure 18

 18 Figure 18. and 's power profiles (configuration E').

Figure 19 .

 19 Figure 19.

Figure 20 .

 20 Figure 20. Set-point tracking (configuration E).

Figure 21 .

 21 Figure 21. Set-point tracking (configuration B).

Figure 22 .

 22 Figure 22. Set-point tracking (configuration C).

Figure 23 .

 23 Figure 23. Set-point tracking (configuration E').

Figure 24 .

 24 Figure 24. Set-point tracking (configuration E").

  Percentage of the fossil energy consumed compared with the total energy used Comfort criterion Performance criterion Renewable energy consumed ( ) Fossil energy consumed ( ) Total energy consumed ( ) Temperature set-point (°C) Building's indoor mean temperature (°C) Thermal losses due to walls ( ) Thermal losses due to the roof ( ) Thermal losses due to doors ( ) Thermal losses due to windows ( ) Thermal losses due to the floor (

Table 1 .

 1 Mock-up thermal losses with and the surface transmission coefficient and the surface of component x respectively.

	3.255	3.482	7.784	5.814
			Thermal bridges	Total losses
	3.248	2.051	0.255	2.256

Table 4 .

 4 Fuzzy rules for module (configuration ).

	Rule	1	2	3	4	5	6	7
	Module FLCRE	NH	NM	NL	AZ	PL	PM	PH
		NH	NH	NL	AZ	PL	PL	PH

Table 5 .

 5 Fuzzy rules for module (configuration ).

		Rule	1	2	3	4	5	6	7
			NH	NM	NL	AZ	PL	PM	PH
	Module		Null	Null	Null	Null	Null	Null	Null
	FLCFE	Rule	8	9	10	11	12	13	14
			NH	NM	NL	AZ	PL	PM	PH
			Null	Null	Null	Weak	Medium	Strong	Full

Table 6 .

 6 Fuzzy rules for module (configurations B and C).

	Module FLCRE	Rule	1 NH NH	2 NL NL	3 AZ AZ	4 PL PL	5 PH PH

Table 7 .

 7 Fuzzy rules for module (configurations B and C).

		Rule	1	2	3	4	5
			NH	NL	AZ	PL	PH
	Module		Null	Null	Null	Null	Null
	FLCFE	Rule	6	7	8	9	10
			NH	NL	AZ	PL	PH
			Null	Weak	Medium	Strong	Full

(W) (°C) Denormalization gain applied to Denormalization gain applied to

Proportional gain

Integral gain Derivative gain

) Indoor temperature measured by the sensor (°C) Outdoor temperature (°C) Power of the first heat source (W) Power of the second heat source (W) Inertia of temperature Influence of the first heat source on temperature (first parameter) Influence of the first heat source on temperature (second parameter) Influence of the second heat source on temperature (first parameter) Influence of the second heat source on temperature (second parameter) Influence of outdoor temperature on temperature Experimental temperature (°C) Modeled temperature (°C) Renewable energy warmer Fossil energy warmer Power of estimated by the PID controller (W) Power of estimated by the PID controller (W) Correction to be applied to (estimated by the by the first fuzzy module) (W) Power of estimated by the second fuzzy module (W)