Skip to main content
. 2011 Nov 28;11(12):11235–11250. doi: 10.3390/s111211235

Algorithm 1.

Global air pollution prediction with Gaussian air spread plume.

Algorithm predict_air_pollution (class pollution_area *current_pollution_area, class wind_info *wind)
input: current_pollution_area  // the properties of global pollution area such as max() and min().
       wind  // the properties of a wind such as direction, speed.
output: predicted pollution level // the predicted value in 10, 30, 60 minutes
method:
 // check the progress direction and get predicted pollution level
for each time // 10, 30 60 minutes
  // get the moving position in each time
  distance = wind.speed * time
  for each position of current pollution area such as max(), min(), boundary
    target.x = current_pollution_area.position.x + distance * cos(wind.direction * pi / 180)
    target.y = current_pollution_area.position.y + distance * sin(wind.direction * pi / 180)
    target.value = current_pollution_area.position.value
    // pollution value prediction at each position in each time
    pollution_level[time][position] = Gaussian_air_pollution_dispersion(time, current_pollution_area, target)
    dangerous_rate[time][position]= pollution_level[time][position] / AQI(level_5) * 100 * gradient
  endfor
endfor
return pollution_level[time][position], dangerous_rate[time][position]
end