## 5 Case Study: Experimental Validation in a Representative Smart Building Scenario
### Design of the Fuzzy Rule-Based System  
The design of the FRBS in this study was guided by a structured expert knowledge elicitation process, aiming to capture domain-specific control strategies for lighting, ventilation, and HVAC management in dynamic indoor environments. The rule base was deliberately constructed from the perspective of qualified domain experts--such as HVAC engineers and building automation specialists--rather than end-users. This choice aligns with the system's focus on technical subsystems requiring operational reliability, safety compliance, and context-aware reasoning, which are best addressed through expert-driven design. The methodology followed a multi-stage protocol:  
1. **Domain Expert Panel:** A panel of five domain experts was convened, including two senior HVAC engineers, one building automation specialist, and two academic researchers in fuzzy systems. All experts had over 10 years of experience in their respective domains. 2. **Variable Selection and Definition:** Experts reviewed the list of sensor and actuator variables (Section 5.1) and jointly selected the subset most relevant for energy optimization and comfort regulation. Each variable was associated with predefined linguistic labels (e.g., _Low_, _Medium_, _High_) standardized using triangular/trapezoidal membership functions. 3. **Initial Rule Drafting:** An initial set of 40 fuzzy rules was proposed by the system developers based on commonly accepted HVAC and lighting strategies. These rules followed an IF-THEN structure with 2-3 antecedents and 1 consequent. 4. **Expert Evaluation and Feedback Quantification:** Each expert independently reviewed the proposed rules using a standardized feedback form. For each rule, the expert rated the following: \begin{table}
\begin{tabular}{c l l l} \hline \hline
**Input Variables** & **Description** & **Domain** & **Sensors** \\ \hline Room Temperature 1 & Temperature in °C (zone 1) & [0–40] & DHT22 Sensor \\ Room Temperature 2 & Temperature in °C (zone 2) & [0–40] & DHT22 Sensor \\ Room Humidity 1 & Relative humidity in \% (zone 1) & [0–100] & DHT22 Sensor \\ Room Humidity 2 & Relative humidity in \% (zone 2) & [0–100] & DHT22 Sensor \\ Illuminance 1 & Light level in lux (zone 1) & [0–1000] & BH1750 Light Sensor \\ Illuminance 2 & Light level in lux (zone 2) & [0–1000] & BH1750 Light Sensor \\ Occupancy 1 & Motion detection (binary, zone 1) & [0–1] & HC-SR501 PIR Sensor \\ Occupancy 2 & Motion detection (binary, zone 2) & [0–1] & HC-SR501 PIR Sensor \\ CO\({}_{2}\) Level & Air quality in ppm & [400–2000] & MH-Z19 CO\({}_{2}\) Sensor \\ \hline
**Output Variables** & **Description** & **Domain** & **Actuators** \\ \hline Lighting Control 1 & Light dimming level (zone 1) & [0–1] & PWM-controlled LED Driver \\ Lighting Control 2 & Light dimming level (zone 2) & [0–1] & PWM-controlled LED Driver \\ Ventilation Control & Ventilation system state & [0–1] & Relay-based Fan Switch \\ HVAC Control & HVAC on/off or power level & [0–1] & Relay-based HVAC Interface \\ \hline \hline \end{tabular}
\end{table} 
Table 2: Defined variables and associated devices. * Clarity (Scale: 1-5). * Relevance (Scale: 1-5). * Redundancy (Yes/No). * Suggested Edits (Free-Text Comments). These responses were consolidated into a matrix representing expert-rule evaluations. Rules scoring below a threshold average (e.g., relevance \(<\) 3.5 or clarity \(<\) 3) were flagged for revision. * **Consensus Building:** Discrepancies were resolved through moderated online sessions following a Delphi-inspired process. Experts discussed flagged rules and iteratively refined their structure. In cases of persistent disagreement (three instances), a weighted voting system was used to reach a final decision. * **AI-Assisted Rule Review:*
* To complement expert feedback, a generative AI tool (OpenAI GPT-4) was used to
* Detect syntactic redundancy and inconsistent phrasing;
* Suggest rule clustering or merging based on similarity;
* Provide alternative formulations for ambiguous rules.