Sign In to Follow Application
View All Documents & Correspondence

Real Time Iot Application In Monitoring Air Pollutant Quality System Through Ml Approach

Abstract: Air pollution in urban areas poses significant risks to human health and the environment, primarily due to vehicle exhaust emissions. To raise awareness and address this issue, air pollution monitoring systems are used to measure harmful gases such as CO2, smoke, alcohol, benzene, and NH3. However, most mobile applications fail to provide users with real-time, location-specific data. This work proposes a portable air quality detection device that offers real-time monitoring anywhere. The device employs two sensors, MQ135 and MQ3, to detect harmful gases and measure air quality in parts per million (PPM). The collected data is stored and visualized using the cloud-based platform ThinkSpeak, enabling remote access and real-time analysis. Additionally, machine learning techniques will be applied to the data to enhance the detection and prediction of air pollution levels, making the system more responsive and informative for users.

Get Free WhatsApp Updates!
Notices, Deadlines & Correspondence

Patent Information

Application #
Filing Date
21 September 2024
Publication Number
40/2024
Publication Type
INA
Invention Field
COMPUTER SCIENCE
Status
Email
Parent Application

Applicants

DREAM INSTITUTE OF TECHNOLOGY
Thakupukur Bakhrahat Road, Samali, Kolkata -700104, West Bengal, India
Dr. Dipankar Sarkar
Professor and Principal, Department of Electrical Engineering, Dream Institute of Technology, Thakupukur Bakhrahat Road, Samali, Kolkata - 700104, West Bengal, India

Inventors

1. Dr. Dipankar Sarkar
Professor and Principal, Department of Electrical Engineering, Dream Institute of Technology, Thakupukur Bakhrahat Road, Samali, Kolkata - 700104, West Bengal, India

Specification

Description:FIELD OF INVENTION
Field of interest revolves around the development and implementation of real-time iot applications for monitoring air pollutant quality, integrated with machine learning (ml) techniques. This includes designing systems that utilize iot sensors to continuously collect air quality data, such as particulate matter (pm2.5 and pm10), co2, nox, so2, and other pollutants. The data is processed and analyzed in real-time using machine learning algorithms to identify patterns, predict pollutant levels, and provide actionable insights for environmental monitoring and management. Key objectives include enhancing accuracy, improving prediction models, and ensuring scalability and real-time responsiveness for better decision-making in smart cities and pollution control initiatives.
BACKGROUND OF INVENTION
The background of the invention of a real-time IoT application for monitoring air pollutant quality through machine learning (ML) stems from the growing need to address air pollution, which poses significant risks to public health and the environment. Traditional air quality monitoring methods, often dependent on stationary and expensive equipment, provide limited spatial and temporal coverage. This creates gaps in data collection, which impairs timely decision-making for pollution control. Advances in IoT technology have enabled the development of low-cost, portable, and connected sensors that can be deployed across wide areas to monitor air quality in real-time. These IoT sensors collect continuous data on pollutants such as PM2.5, PM10, CO2, NOx, and volatile organic compounds (VOCs), offering a more comprehensive view of air quality trends. The integration of machine learning into this system brings the ability to process and analyze vast amounts of real-time data more efficiently. Machine learning algorithms can identify patterns, predict future pollution levels, detect anomalies, and provide insights into the sources and impacts of pollutants. These predictive models enhance the effectiveness of environmental monitoring and enable proactive measures to control air pollution. The invention builds on the convergence of IoT, data analytics, and AI technologies to deliver more accurate, scalable, and intelligent air quality monitoring systems that support real-time decision-making and promote sustainable environmental practices.
The patent application number 201921022722 discloses a system for dynamic monitoring of air quality.
The patent application number 202117021546 discloses a air pollutants capturing technique through smart inventive framework for downstream chemical processing.
The patent application number 202241014209 discloses a system and method for assessing the air quality and pollutant ratio at pre-determined altitude of the atmosphere.
The patent application number 202221063499 discloses a plant-based sensing device for detecting air pollutants.
The patent application number 202321058430 discloses a IOT based real time air quality monitoring system and method thereof.
SUMMARY
The invention of a real-time IoT-based air pollutant monitoring system integrated with machine learning (ML) addresses the critical need for continuous, accurate, and scalable air quality monitoring. Traditional air quality systems are often limited by their high cost, fixed locations, and lack of real-time data processing capabilities. This invention leverages the power of IoT to deploy a network of low-cost, portable sensors that monitor key pollutants such as PM2.5, PM10, CO2, NOx, and SO2 in real-time, across large areas. These sensors collect vast amounts of data, which are transmitted wirelessly to a central system for analysis. Here, machine learning algorithms process the data to identify trends, detect anomalies, and predict future air quality conditions. The system provides real-time alerts and actionable insights to users, helping authorities take immediate action when pollutant levels exceed safe limits. Machine learning enhances the accuracy of pollutant detection by analyzing historical and current data, optimizing the system’s predictive capabilities. The real-time aspect ensures timely interventions, while the scalability of IoT makes it adaptable for use in urban, industrial, and rural settings. This invention promises to improve environmental monitoring, promote public health, and support smart city initiatives by providing a comprehensive solution to managing air quality.
DETAILED DESCRIPTION OF INVENTION
Air quality is essential for human health and environmental well-being, but air pollution continues to rise due to factors such as vehicle emissions, industrial activities, energy production, and natural disasters like wildfires. Monitoring and evaluating the quality of the air we breathe is crucial. Air Quality Monitoring (AQM) systems, equipped with sensors and advanced technologies, measure particulate matter and pollutants like ozone, nitrogen oxides, and sulfur dioxide. The data from these systems helps shape environmental policies, track pollution reduction efforts, and allow the public to make informed health decisions.
Currently, AQM stations are primarily used to calculate the Air Quality Index (AQI) and monitor pollution levels. However, the high infrastructure requirements, operational complexities, and ongoing expenses limit the expansion of these networks and the availability of air pollution data. To address these challenges, low-cost, efficient, and real-time data-sensing devices are needed. The Internet of Things (IoT) technology offers a promising solution for creating user-friendly air pollution monitoring systems.
Key features of such a system include:
• Real-time data collection within the AQM framework.
• The use of Blynk for instant data visualization.
• The adoption of ThingSpeak, an open-source platform, for daily pollution tracking.
This proposal emphasizes the importance of air quality monitoring, highlighting the limitations of current AQM stations and advocating for cost-effective and efficient IoT solutions. The system leverages IoT sensors, Arduino, cloud platforms, and machine learning algorithms for real-time air quality analysis. It integrates a low-cost AQM system capable of gathering data in real-time, displaying the AQI on a website, and utilizing Blynk and ThingSpeak for data access and visualization.
Proposed Solution
The proposed system framework integrates the MQ3 and MQ135 sensors with a NodeMCU processor, the Arduino IDE, and platforms like ThingSpeak and Blynk. It includes a comprehensive hardware and software architecture, as well as machine learning components for data analysis and visualization.
• Hardware Architecture: The device consists of sensors, a NodeMCU processor, a WiFi module, a power source, and other necessary components. The MQ3 and MQ135 sensors measure air quality and alcohol levels, respectively. The NodeMCU processor manages the collected data and device behavior. The WiFi module enables the device to transfer data to the ThingSpeak platform, while the power source ensures continuous operation.
• Software Architecture: This includes multiple layers such as data acquisition, processing, internet connectivity, cloud storage, and a user interface. Firmware on the NodeMCU controls the device and transmits data to ThingSpeak for storage and analysis. The Blynk app allows users to view the collected data in real-time.
• Machine Learning Analysis and Visualization: Data gathered from ThingSpeak is further analyzed using machine learning algorithms. This process includes feature selection, algorithm selection, model building, evaluation, and data visualization, providing actionable insights for environmental monitoring and public health decisions.

Figure 1: Flow diagram
• The input from the MQ3 and MQ135 sensors is taken in analog format and sent to the ESP8266 microcontroller.
• The Wi-Fi module in the ESP8266 connects to a nearby Wi-Fi network to transmit the sensor data to the ThingSpeak and Blynk IoT platforms.
• Raw sensor data is sent to the ThingSpeak platform for storage and analysis.
• The processed data, including calculated PPM (parts per million) values, is displayed on the Blynk IoT mobile application for real-time monitoring.
• The data collected on ThingSpeak is exported as a CSV file and further processed through machine learning algorithms for deeper analysis and insights.
Circuit Design
The system utilized the MQ135 gas sensor to detect volatile organic compounds (VOCs) and the MQ3 gas sensor for alcohol detection. These sensors were calibrated by exposing them to specific pollutant levels and adjusting their output to match expected values. The hardware setup included an ESP8266 module for wireless communication, an Arduino microcontroller, MQ135 and MQ3 sensors, and a power source.

Figure 2: Circuit Design
The sensors were connected to the Arduino microcontroller, while the ESP8266 module facilitated Wi-Fi connectivity for data transmission. The software development involved writing code in the Arduino IDE to read data from the sensors, process it, and transmit it wirelessly to a cloud server.
The system collected data at regular intervals and stored it for further analysis. Machine learning algorithms were applied to the collected data to predict future pollution levels based on historical patterns and trends.

ALGORITHM
• Define the necessary credentials for Blynk and WiFi, along with other required variables.
• Initialize serial communication and establish the Blynk connection using Blynk.begin().
• Set up a timer to trigger a function that sends data to ThingSpeak every second.
• Connect to the WiFi network using WiFi.begin() and wait until the connection is successful.
• Define the changeMUX function and set the MUX_A pin as an output.
• In the main loop, continuously run the Blynk and timer functions, and read sensor data from the analog pin A0.
• Calculate the first sensor value (in ppm, parts per million) using a specific formula.
• Read the sensor data from A0 six times, average the readings, and store this as sensor value 0.
• Set the MUX_A pin to HIGH, read the sensor data from A0 another six times, and average the readings to obtain sensor value 1.
• Establish a connection to ThingSpeak using a WiFiClient object.
• Construct a request string that includes the ThingSpeak API key and field values (sensorValue0 and sensorValue1), and send the GET request via an HTTPClient object.
• Introduce a one-second delay before repeating the loop.
• Define the function to be called by the timer for sending data to ThingSpeak.
• Set the MUX_A pin to LOW and read sensor data from A0.
• Calculate the ppm value based on the sensor data using a given formula.
• Set the MUX_A pin to HIGH, read the sensor data from A0 six more times, and average these readings to compute sensor value 2.
• Use Blynk.virtualWrite() to send sensor values 1 and 2 to virtual pins V1 and V2, respectively.
The figures presented illustrate data interpretation in BLYNK and ThingSpeak, connected through a unique key. In Figure 3, the green meter represents sensor readings from the MQ135 sensor, while the blue meter shows readings from the MQ3 sensor. The dataset used, "city_day.csv," contains daily air quality data for multiple cities in India from 2015 to 2020, sourced from the Central Pollution Control Board (CPCB). This dataset includes 15 columns, featuring attributes such as City, Date, PM2.5, PM10, NO, NO2, NOx, NH3, CO, SO2, O3, Benzene, Toluene, Xylene, and AQI.

Figure 3: Sensor Data Visualization in Blynk Application
The target variable in this analysis is AQI (Air Quality Index), which quantifies air quality based on pollutant concentrations. The dataset spans daily air quality readings from various cities, resulting in a large number of records. Missing values have been removed in the code, and some features exhibit skewness, which may affect the performance of machine learning models.
Three regression models—Random Forest, Linear Regression, and Decision Tree—are used to predict AQI based on pollutant concentrations. The models are evaluated using metrics like Mean Absolute Error (MAE), Root Mean Squared Error (RMSE), Root Mean Squared Logarithmic Error (RMSLE), and R-squared (R²) score.

Figure 4: Data Storage and Visualization on ThingSpeak Platform
Figure 5 highlights gaps in the correlation heatmap, which indicate missing data for some variables, particularly Xylene. It can also be observed that Toluene and PM10, as well as NH3 and Xylene, are inversely proportional to each other.

Figure 5: Correlation heat map of AQI with other pollutants.
Vehicular pollution in major cities like Delhi and Mumbai is a significant concern, with particulate matter (PM) levels being notably high, followed by PM2.5. Industrial pollutants also contribute substantially to air pollution, where ozone (O3) levels are exceptionally high, followed by toluene. It's important to note that ozone is a secondary pollutant, meaning it isn't emitted directly but forms through chemical reactions involving other pollutants such as volatile organic compounds (VOCs) and nitrogen oxides.
Air Quality Index (AQI) trends across different cities reveal that there is no consistent pattern. External factors often influence AQI levels, with the highest AQI recorded in Ahmedabad in 2018, and the lowest in Shillong. Several cities show elevated industrial pollution, including Patna, Delhi, Kolkata, Amritsar, Visakhapatnam, Amaravati, Hyderabad, Gurugram, and Chandigarh. Similarly, high vehicular pollution was observed in Delhi, Patna, Amritsar, Visakhapatnam, Gurugram, Kolkata, Hyderabad, Chandigarh, and Amaravati.
To address air pollution issues, various regression models were employed, including Random Forest Regression, Linear Regression, and Decision Tree Regression. The performance of these models was evaluated using metrics such as Mean Absolute Error (MAE), Root Mean Squared Error (RMSE), Root Mean Squared Logarithmic Error (RMSLE), and R-squared (R²). The Random Forest Regression model demonstrated the best performance in predicting AQI, with the lowest MAE, RMSE, RMSLE, and the highest R². It was also observed that adding SMOTE (Synthetic Minority Over-sampling Technique) did not improve the performance of the regression models, particularly for AQI prediction.
When predicting AQI categories (AQI_Bucket), Random Forest and Decision Tree classifiers were compared with and without SMOTE. Random Forest consistently provided better results, with accuracy and F1 scores remaining stable around 81%. However, the Decision Tree classifier showed improved performance with SMOTE due to the balanced representation of AQI categories such as moderate, satisfactory, poor, good, very poor, and severe. Among different machine learning models like Support Vector Machines (SVM), K-Nearest Neighbors (KNN), Naïve Bayes, and Deep Neural Networks (DNN), KNN performed the best in predicting AQI_Bucket.
To mitigate air pollution, several scientific and general methods were proposed:
Scientific Methods:
1. Catalytic Converters: Used in vehicles to reduce harmful pollutants such as CO, NO, and NO2 by transforming them into less harmful substances through chemical reactions.
2. Scrubbers: Applied in factories and power plants to remove pollutants like SO2, PM2.5, and PM10 from exhaust gases before they are released into the environment.
3. Flue Gas Desulfurization: A technique that removes sulfur dioxide from exhaust gases, converting it into a less harmful compound.
4. Selective Catalytic Reduction: Reduces nitrogen oxide emissions in power plants by injecting a reductant, such as ammonia or urea, into exhaust gases, transforming NOx into nitrogen and water vapor.
5. Biofiltration: A natural air purification method that uses microorganisms in a biofilter to convert pollutants into harmless compounds.
6. Carbon Capture and Storage: Captures carbon dioxide from industrial processes and stores it in secure locations, such as underground reservoirs, to reduce CO2 emissions.
General Methods:
1. Reducing Emissions: Implementing stricter emission regulations for industries and vehicles, encouraging renewable energy sources, and controlling industrial processes that produce harmful gases.
2. Promoting Public Transportation: Encouraging the use of buses, walking, or cycling can help reduce vehicular emissions, a major contributor to air pollution.
3. Improving Energy Efficiency: Reducing emissions from power plants by making buildings and appliances more energy-efficient.
4. Tree Planting: Trees can absorb pollutants like CO2, and urban tree planting can help reduce airborne pollutant concentrations.
5. Installing Air Filters: Air filters in homes, offices, and public spaces can improve indoor air quality by removing pollutants from the air.
DETAILED DESCRIPTION OF DIAGRAM
Figure 1: Flow diagram
Figure 2: Circuit Design
Figure 3: Sensor Data Visualization in Blynk Application
Figure 4: Data Storage and Visualization on ThingSpeak Platform
Figure 5: Correlation heat map of AQI with other pollutants. , Claims:1. Real-Time Iot Application in Monitoring Air Pollutant Quality System through Ml Approach claim that the use of Arduino, a multiplexer, and a few sensors offers an affordable solution for air quality monitoring by reducing the hardware cost and overall system complexity.
2. The system is easily customizable and expandable by adding more sensors based on specific requirements, making it flexible for various applications.
3. Connecting multiple sensors through a single Arduino board using a multiplexer reduces the need for additional hardware, optimizing resource usage.
4. The collected air quality data can be effectively visualized and analyzed using software tools, allowing users to track air quality trends over time.
5. The system can be applied to a wide range of environmental monitoring tasks, such as indoor air quality in homes and offices or outdoor pollution levels in urban environments.
6. The system can support health management and pollution control by identifying air quality issues and enabling preventive measures to improve overall air quality.
7. The integration of SMOTE (Synthetic Minority Over-sampling Technique) in regression models enhances the data analysis process, especially when dealing with imbalanced datasets, leading to better predictive performance.
8. Sensor calibration can be optimized for specific environments, improving the accuracy and reliability of the system in different settings.
9. By incorporating machine learning algorithms, the system could detect patterns in air quality data and predict potential deterioration, enabling preventive actions before the situation worsens.
10. Improving the user interface and data visualization would make the system more accessible to non-experts, broadening its usability and application in various fields.

Documents

Application Documents

# Name Date
1 202431071519-REQUEST FOR EARLY PUBLICATION(FORM-9) [21-09-2024(online)].pdf 2024-09-21
2 202431071519-POWER OF AUTHORITY [21-09-2024(online)].pdf 2024-09-21
3 202431071519-FORM-9 [21-09-2024(online)].pdf 2024-09-21
4 202431071519-FORM 1 [21-09-2024(online)].pdf 2024-09-21
5 202431071519-DRAWINGS [21-09-2024(online)].pdf 2024-09-21
6 202431071519-COMPLETE SPECIFICATION [21-09-2024(online)].pdf 2024-09-21