atmoschem/eixport

can we control units in wrf_create?

Closed this issue · 1 comments

library(eixport)
data(emis_opt)

emis_option <- c(emis_opt$ecb05_opt1, "E_CO2")

Generates a wrfchemi with CO2 emissions units ug/m2/s
while
emis_option <- c("E_CO2, emis_opt$ecb05_opt1)

Generates CO2 emissions in wrfchemi as mol/km2/h

Matematically, there are no differences in the numbers, it is the metadata on NetCDF file.

Any idea of how can we control that? Maybe with a postprocess?

Hello Sergio,

For the NetCDF file, the wrf_create uses the same convention of WRF-Chem, that is considering that emissions of aerosol are the last variables of the emission array. If you change the mechanism you must change both variables and n_aero arguments in wrf_create (number of aerosol species) to get the right unit.

To get correct units in metadata (I think the model does not use this metadata) in the emission file you have two options. The first is to use something like:
emis_option <- c(emis_opt$ecb05_opt1[1:25], "E_CO2",emis_opt$ecb05_opt1[26:40])
or
emis_option <- c("E_CO2, emis_opt$ecb05_opt1)
and also use this options:
wrf_create(variables = emis_option, n_aero = 15)

The second alternative is to modify the units with ncdf4 or https://schuch666.github.io/inventory/reference/meta.html

Thanks