S5P CH4 | Column ppb to column number density mol/m2 conversion

Dear Sander,

This question refers to S5P CH4 data. I went through the Map Sentinel 5p CH4, SO2 and CO Data (Visan) post but couldn’t find what I was looking for.

The CH4 file contains the CH4_column_volume_mixing_ratio_dry_air in ppb. Can this be transformed into a CH4_column_number density in mol/m2? I tried the operation, using derive, but it didn’t work and something tells me that harp is expecting to read CH4_column_volume_mixing_ratio and not CH4_column_volume_mixing_ratio_dry_air.

Can I use the dry_air_column_number_density to convert? I’ll just have to sum it first, since this is a profile, right?

And then it is simple multiplication, as per equation 1 from
http://stcorp.github.io/harp/doc/html/algorithms/derivations/column_volume_mixing_ratio.html

Or maybe not?

Many thanks!

MariLiza

This is an omission in HARP.

Note that the Algorithms documentation of HARP shows you how variables can be derived from inputs (it works only one-way). We did have algorithms that can derive column vmr from column number density but we didn’t have ones that produced column nd from column vmr.

We just committed a change that introduces these missing conversions (and these will be included in the next official HARP release). The online documentation already shows these new derivations.

What is also useful to know is that running harpdump --list-derivations on a product will show you which variables HARP is able to generate based on the content of the product itself (and how it will do this).
If you expect that some variable should be able to be derived, but isn’t in the list, then please raise a request on this forum and we will see whether we can have this added.

1 Like

Dear Sander,

I am updating my old IDL ingestion routines for S5P CH4. I note that now the derivation for CH4_column_number_density from CH4_volume_mixing_ratio_dry_air is included in harp 1.14, which is excellent.

CH4_column_number_density {time} [molec/m2] (double) from
CH4_volume_mixing_ratio_dry_air {time} [ppv] (double)
dry_air_column_number_density {time} [molec/m2] (double)

However, in the S5P CH4 files, the dry_air_column_number_density has an extra dimension, the altitude, and is naturally delivered in mol/m2.

dry_air_column_number_density float {time, vertical} [mol/m2] column number density profile of dry air

For this reason, I tried to first derive the dry_air_column_number_density in [molec/m2].

IDL responds with an error.

product2 = harp_import(file,‘CH4_column_volume_mixing_ratio_dry_air_validity>50;derive(dry_air_column_number_density[molec/m2]);derive(CH4_column_number_density[molec/m2]);keep(CH4_colu
mn_volume_mixing_ratio_dry_air,dry_air_column_number_density)’)

% HARP-IDL ERROR -310: “variable ‘CH4_column_number_density’ does not exist”

Any ideas on how to overcome this issue?
:slight_smile:

Actually, now that I notice the dry_air_column_number_density still has vertical dimensions, i.e., is a profile. I am guessing that I can integrate. in which case, I can apply eq 2 from
column volume mixing ratio derivations — HARP 1.14 documentation (stcorp.github.io)
outside of harp.

All ideas welcome!
MariLiza

See also the documentation on the derive operation. You will need to add the dimensions that you want in order for HARP to calculate the variable from other inputs. When you use derive(CH4_column_number_density {time,vertical} [molec/m2]) you will get a partial column density profile and if you use derive(CH4_column_number_density {time} [molec/m2]) you will get total (=integrated) columns. So there is no need to do integration yourself.

Absolutely! This did the trick! Many thanks @sander.niemeijer !
MariLiza

Dear Mariliza, Sander,

I found this post by chance and it happens that I find very useful to transform CH4 ppbv from L2 S5P data into CH4 mol/m2. Reading your answers, I need the dry_air_column_number_density, but this variable is not provided in the CH4 L2 files, as far as I could check. Is that correct?

I’m new using S5P L2 data and also new in the HARP package.

Thank you in advance for your help,
Best

The dry air column is available and HARP already ingests it. You can find the mapping for the L2 CH4 product in the documentation.
You can immediately get the column number density by using e.g. product = harp.import_product("S5P_OFFL_L2__CH4____20181128T122504_20181128T140634_05833_01_010202_20181205T132750.nc", "derive(CH4_column_number_density {time} [mol/m2])")

It is quite straightforward. Thank you. Although the output has different arrangement for dimensions. It seems that “time” dimension “absorbs” scanline/ground_pixel dimensions. Is this something than can be handled with HARP by any chance? preserve input dataset dimensions, I mean.

Thank you very much for your help,
Best,

When you perform per-pixel filtering (which you should if you apply the recommended quality filtering) then you won’t have a grid anymore. You can however still figure out the position of each pixel in the satellite viewing grid based on the datetime_start and scan_subindex variable values. All pixels with the same datetime_start are in the same row, and all pixels with the same scan_subindex are in the same column.