Air Quality Index
The Bettair® platform allows configuring the Air Quality Index for each organization. Currently, the platform supports two indices, the AQI (Air Quality Index) developed by the United States of America Environmental Protection Agency (USEPA) and the CAQI (Common Air Quality Index) with more widespread use in Europe.
AQI
To estimate the AQI, it starts by calculating the mean concentrations of each pollutant (using an hourly moving average) for the periods indicated in Figure 1, In some cases, such as O₃, there may be several periods, so the concentration is calculated for each one of them, in this particular case, it has been calculated for 1 hour and 8 hours periods.
Figure 1 AQI breakpoints table (source wikipedia.org)

The concentration averages must focus on the current time. For a 24-hour average, it should be considered the last 12 hours of data and the future 12 hours. Since the future data is unknown, the platform estimates the average using a particular case of the weighted average proposed by the USEPA called NowCast described later in this document.
Once the averages have been calculated for each pollutant and period, the Air Quality Index is calculated using the equation shown in Figure 2
Figure 2 AQI Air Quality Index Equation (source wikipedia.org)

Where:
I = Air Quality Index
C = Pollutant concentration,
Clow = the concentration breakpoint that is ≤ C,
Chigh = the concentration breakpoint that is ≥ C,
Ilow = the index breakpoint corresponding to Clow.
Ihigh = the index breakpoint corresponding to Chigh.
Finally, from all indices calculated during a day, the highest one is chosen. The pollutant used to calculate this index is considered the predominant one, and its value represents the AQI value of that day.
NowCast
The NowCast is an algorithm developed by the USEPA to calculate the weighted average of a concentration giving more weight to recent measures. The steps of the algorithm are described below.
- Calculate the W * variable using the equation described in Figure 3, where Cmax and Cmin are the maximum and minimum hourly concentrations of the period.
Figure 3 W* Equation (source wikipedia.org)

- If W * is greater than 1/2, W * is used as the basis for the calculation, if not, the 1/2 value is used instead (see Figure 4).
Figure 4 W variable value (source wikipedia.org)

3.- The weighted average concentration is calculated using the following equation (see Figura 5).
Figure 5 NowCast Equation (source wikipedia.org)

CAQI
To estimate the Common Air Quality Index (CAQI), it is calculated the average concentration for NO₂, PM₁₀, O₃, PM₂.₅, CO, and SO₂ using the NowCast algorithm described above. For NO₂, O₃, and SO₂ it is used an hourly average, for PM a daily averages, and for CO an 8-hour average (hourly moving average).
These concentrations are compared with the table shown in Figure 6, specifically with the City Background section.
Figura 6 CAQI values table (source airqualitynow.eu)

Finally, the highest index is chosen as the CAQI value of the day. That is, in one single day 24 indices are calculated for NO₂, O₃, and SO₂, 1 index for PM₁₀ and for PM₂.₅ and 17 indices for CO. The greatest of these 91 indices is chosen as the CAQI value and the pollutant that generated this index is considered the predominant one.