Research Article
Multisensor Fuzzy Logic Approach for Enhanced Fire Detection in Smart Cities
Algorithm 1
Pseudocode for the multisensor fuzzy logic approach.
| | # Initialize sensor variables | | | smoke_sensor_value = read_smoke_sensor() | | | flame_sensor_value = read_flame_sensor() | | | temperature_sensor_value = read_temperature_sensor() | | | # Fuzzification | | | fuzzy_smoke = fuzzify_smoke(smoke_sensor_value) | | | fuzzy_flame = fuzzify_flame(flame_sensor_value) | | | fuzzy_temperature = fuzzify_temperature(temperature_sensor_value) | | | # Rule Evaluation | | | rule_activation = evaluate_rules(fuzzy_smoke, fuzzy_flame, fuzzy_temperature) | | | # Aggregation | | | aggregated_activation = aggregate_rules(rule_activation) | | | #Defuzzification | | | fire_intensity = defuzzify(aggregated_activation) | | | # Decision-making | | | if fire_intensity is high: | | | activate_alarm() | | | notify_authorities() | | | update_online_portal() | | | # End of algorithm |
|