for grb in allEA_1.grib allEA_2.grib allEA_3.grib;do
ncl_convert2nc $grb-nc4cdone
for nc in allEA_1.nc allEA_2.nc allEA_3.nc;do
ncks -d forecast_time0,0 $nc${nc}_0
done
specname.json: 預報grib 檔中ID與grab.name的對照關係
2022以後,氨氣、paraffins、olefins等不在快速下載之項目範圍。
{"1":"Ozone mass mixing ratio (full chemistry scheme)","2":"Sulphur dioxide mass mixing ratio","3":"Propane","4":"Nitrogen monoxide mass mixing ratio","5":"Nitrogen dioxide mass mixing ratio","6":"Isoprene","7":"Formaldehyde","8":"Ethane","9":"Carbon monoxide mass mixing ratio","10":"Hydrophilic Black Carbon Aerosol Mixing Ratio","11":"Dust Aerosol (0.9 - 20 um) Mixing Ratio","12":"Dust Aerosol (0.55 - 0.9 um) Mixing Ratio","13":"Dust Aerosol (0.03 - 0.55 um) Mixing Ratio","14":"Paraffins","15":"Organic nitrates","16":"Olefins","17":"Nitrate","18":"Ammonium","19":"Sulphate Aerosol Mixing Ratio","20":"Sea Salt Aerosol (5 - 20 um) Mixing Ratio","21":"Sea Salt Aerosol (0.5 - 5 um) Mixing Ratio","22":"Sea Salt Aerosol (0.03 - 0.5 um) Mixing Ratio","23":"Peroxyacetyl nitrate","24":"Nitric acid","25":"Hydrophobic Organic Matter Aerosol Mixing Ratio","26":"Hydrophobic Black Carbon Aerosol Mixing Ratio","27":"Hydrophilic Organic Matter Aerosol Mixing Ratio"}
graph TD
A((AllEA.nc)) --> B(latlon, bdate, 5d array var)
C((BCON)) --> D(rate)
E((METCRO3D)) --> F(dens)
G((CCTM_CGRID)) --> H(grid def.)
G --> I{time flags}
B --> I
H --> J{horizontal interp.}
B --> J
J --> K(5d new array var1)
K --> L{pollutant mapping and expansions}
D --> L
F --> L
L --> M((save and quit))
I --> M
#iv in (gas+par) transfer to V1[3]
forvinlist(nms_gas)+list(nms_part):print(v)iv=(gas+par).index(dic[v])ifvinnms_gas:nm=nms_gas[v]ifnmnotinV1[3]:continuenc1[nm][:]=var1[iv,:,:,:,:]*28.E6/mws[dic[v]]#mixing ratio to ppm
continueskip=0nms=nms_part[v]fornminnms:ifnmnotinV1[3]:skip=1ifskip==1:continue# unit=dens[:] (kg/kg) to microgram/M3
fornminnms:im=nms.index(nm)nc1[nm][:]+=var1[iv,:,:,:,:]*rate[v][im]*dens[None,:,:,:]