The motivation
I frequently convert between reporting units, e.g. Tg N, Tg NO and Tg NO2, Gt C and Gt CO2 when comparing datasets and running fair. I believe the conversions in OpenSCM units based on mass number are too imprecise; for example, Global Carbon Budget use 3.664 to convert C to CO2, which is 44.009 / 12.011; OpenSCM uses 44 / 12 = 3.667. I know the difference is well within emissions uncertainty, but affects harmonization and modelling runs (for instance fair uses PubChem weights).
|
"CO2": ["12/44 * C", "carbon_dioxide"], |
|
"CH4": "methane", |
|
"HC50": ["CH4"], |
|
"N2O": "nitrous_oxide", |
|
"N2ON": ["44/28 * N2O", "nitrous_oxide_farming_style"], |
|
"N": "nitrogen", |
|
"NO2": ["14/46 * N", "nitrogen_dioxide"], |
|
# aerosol precursors |
|
"NOx": "NOx", |
|
"NO": ["46/30 * NOx", "nox_cmip_style"], |
|
"nox": ["NOx"], |
|
"NH3": "NH3", |
|
"ammonia": ["NH3"], |
|
"S": "sulfur", |
|
"SO2": ["32/64 * S", "sulfur_dioxide"], |
The proposed solution
Use PubChem or Wikipedia values for molecular weights, usually to three decimal places for these compounds.
Alternatives
Allow a user to override the default value.
The motivation
I frequently convert between reporting units, e.g. Tg N, Tg NO and Tg NO2, Gt C and Gt CO2 when comparing datasets and running fair. I believe the conversions in OpenSCM units based on mass number are too imprecise; for example, Global Carbon Budget use 3.664 to convert C to CO2, which is 44.009 / 12.011; OpenSCM uses 44 / 12 = 3.667. I know the difference is well within emissions uncertainty, but affects harmonization and modelling runs (for instance fair uses PubChem weights).
openscm-units/src/openscm_units/_unit_registry.py
Lines 26 to 40 in 14a4e60
The proposed solution
Use PubChem or Wikipedia values for molecular weights, usually to three decimal places for these compounds.
Alternatives
Allow a user to override the default value.