Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
C-CARGO
Contents
Step 1-Installation steps for MiniDOAS ....................................................................................... 3
Step 2-Ocean Optics and DOASIS Configuration ......................................................................... 4
Step 3-Spectral Calibration using WINDOAS ............................................................................... 8
Step 4-Convolution using WINDOAS ......................................................................................... 17
Step 5-Ring spectrum determination using DOASIS.................................................................. 19
Step 6-DOAS analysis using WINDOAS ...................................................................................... 21
Step 7- VCD Extraction .............................................................................................................. 36
Step 8-Querries for SQL Database ............................................................................................. 39
Step 9-Using QGIS and pg-Admin III .......................................................................................... 40
Step 10- Interpolation using IDW Tool in ArcGIS ...................................................................... 53
Page 2 of 64
5. Connect the USB cables to the computer (ocean optics and HMT), install both
drivers like follows:
Page 3 of 64
Page 5 of 64
If that would not work select Open Configuration in Spectrometer menu and select
Default.spec and click open. Repeat the previous step once again
-after a few seconds, the instrument has turned into the horizontal position. Move the
motor up or down until the true horizontal position is reached. This has to be tested
using the water level.
-press OK
(if the instrument position was not changed, this step can be omitted for restart of
measurements)
Manual acquisition of spectra
Manual spectra are needed to characterise the electronic offset and dark current.
Manual operations are performed by selecting fixed (acquisition) in the main menu.
Press Acquire; the spectrum is displayed and automatically saved to
Disk.
For offset spectra, chose a small integration time (per scan), e.g. 3 msec and a high
scan number, e.g. 1000.
For dark current spectra, chose a moderate integration time (per scan), e.g. 10000
msec and a small scan number, e.g. 1. If saturation is reached, select a smaller
integration time.
Attention:
a) always close the telescope with a black paper or something similar
b) the dark current and offset spectra are only useful if the set detector temperature
was actually reached. This might take some minutes. The best option is to measure
several subsequent offset and dark current spectra
Page 7 of 64
In the Project Window your measured spectra will be opened entitled as Raw Spectra
Page 8 of 64
Right Click Calibra properties and input Offset and Dark Current measured by
DOASIS in Instrumental Tab
Page 9 of 64
Calibration 1
Browse to a noon spectrum by next button on the toolbar
Page 10 of 64
Page 11 of 64
-Offset (const, order 1/2): allows to fit an intensity offset (polynomial of different
degree)
-sol: allows a fit coefficient of the solar spectrum to vary freely
-the spectra included here will be shifted (and squeezed). In our case, the own
measurement is shifted until it matches the wavelength calibration of the solar
spectrum
Page 12 of 64
-The first window shows the result of the fit (in red the measured spectrum; in black
the convoluted solar spectrum)
Page 13 of 64
-The second window shows the residual of the fit (the difference between the
measured spectrum and the fit result)
-the third window shows the determined shift (individual points for the different subwindows) with respect to the pre-calibration.
-the fourth window shows the determined spectral resolution (FWHM) for the
different sub-windows.
All small figures can be enlarged by clicking on them. Then, they can be saved as
figures or as ascii files.
It is recommended to save the following results:
A) first window as ascii-file. This is used as calibration file for the convolution of
reference spectra
B) fourth window as bmp-file. The FWHM is also used as input for the convolution.
Page 14 of 64
Calibration 2
Repeat all the steps from calibration 1 expect replacing the high resolution spectrum
with your saved calibrated spectrum from calibration 1
Page 15 of 64
Page 16 of 64
Page 17 of 64
Here a slit function has to be selected, e.g. a Gaussian shape. Then a line with
(FWHM) has to be defined. Here the value determined from the calibration (see
calibration.doc) has to be used. In the case of NO2, which is analysed around 440nm,
a FWHM of 0.5 nm is chosen.
Alternatively to a Gaussian function, also a Voigt function, or a measured slit function
(provided from an ascii-file) can be used.
The result of the spectral convolution is mapped to the wavelength calibration of the
own measurement (as provided in calibration.txt).
Note:
Usually all literature cross sections are convoluted with the instrument function.
However, in some cases (e.g. for O4), the original measurement was taken at a broad
spectral resolution, usually broader than the own measurement. Then, instead of a
convolution (standard), an interpolation (none) has to be selected.
Page 18 of 64
Page 19 of 64
Note: if instead of wavelength, the pixel number is displayed, you must load the
correct file.
Without correct wavelength, no Ring spectrum can be calculated
-select in the top menu math, Ring spectrum. The following spectrum will appear:
-Save the Ring spectrum by selecting file, save as in the top menu. Make sure that
you save the file as ascii file, and chose the directory, where you want to store the file.
-The Ring spectrum calculated in this way has the correct file format to be used in the
DOAS analysis.
-you must, however, change the file name to match the naming convention required
by WINDOAS. A useful file name would e.g. be: Ring_date_time.txt
Page 20 of 64
Page 21 of 64
-use the button calibration file and load the file with the wavelength calibration (e.g.
calibration_260708.txt)
-in addition, make sure that as Format it is selected MFC (Heidelberg). If this
format is chosen, then the binary data format (MFC format) of the measured spectra
can be used.
-insert the offset and dark current spectra using the buttons Dark current and
Offset. Also these files have to be in the MFC format.
-the 1st wavelength must be the same as for the measured spectrum (this is not
necessarily the true first wavelength, but is the wavelength stored together with the
spectra).
Page 22 of 64
-If the calibration file was not loaded correctly, then the spectra are displayed as
function of the pixel number (see below):
In that case, make sure that the correct calibration file is loaded.
Define the fitting parameters:
-click right mouse button on the item below analysis window (in our case, the item
is NO2); select properties. The following menu appears:
Page 23 of 64
Page 24 of 64
Page 25 of 64
-click the right mouse button at the location marked by the red oval, select insert.
The following menu appears:
In the left window, all cross sections inserted, as well as Ref and spectrum
appears. Ref indicates the Fraunhofer reference spectrum, Spectrum indicates the
measured spectrum.
-by marking a cross section in the left window and pressing the arrow button, the
cross section is transferred in the right window. For a typical DOAS analysis, all
items, except Spectrum are transferred into the right window. Then the menu looks
like below:
Page 26 of 64
-after pressing OK, the shift and stretch menu looks like:
-now, the selected cross sections and spectra are shifted during the fit procedure until
they match the wavelength calibration of the measured spectrum (Spectrum). All
selected cross sections and spectra are shifted together by the same amount.
-in addition to shift fit also a stretch fit of order 1 or 2 can be selected. For typical
analyses, however, a shift fit is sufficient.
-Usually, the Gaps and Output menu is not changed.
-After pressing OK, the fit parameters are stored.
Page 27 of 64
You might check if all cross sections are correctly loaded, by clicking with the right
mouse button at NO2 (below analysis) and selecting view cross sections. Then
the cross sections are displayed:
menu. If you find a spectrum of good quality (as shown in the graphs window) and
with elevation angle 90 (as in the data window), then click with the right mouse
button at the spectrum and select save as ascii file.
Save the spectrum at a file name and path of your choice. The file will be stored as
needed for the DOAS fit.
Page 29 of 64
Here you can chose which information should be displayed at the screen after the
DOAS fit of the each individual spectrum.
Normally you should select Spectra, Fits, and Data. You should also select
pause; then the analysis automatically stops after each spectrum and the results can
be looked at.
Chose ASCII results, and the following menu appears:
Page 30 of 64
Here you should select a path and file name (Output path or file) for the file
containing the fit results.
After pressing OK the program is ready for the analysis.
To start the DOAS fit, click with the right mouse button at the folder which contains
your spectra, select run analysis.
A screen with the first spectrum appears:
Page 31 of 64
-to start the DOAS fit, press the arrow button in the top menu. The fit results are then
displayed. Typical fit results are like the following example:
Page 32 of 64
-The first window shows the measured spectrum and the Fraunhofer reference
spectrum.
-the second window shows the fit residual
-the following windows show the results for the different cross sections (and Ring
spectrum)
-the last window shows the fitted polynomial
All small windows can be enlarged by clicking on them.
The above example shows a typical result for a NO2 analysis. Besides the NO2
absorption features (center plot), also the H2Oabsorptions are clearly visible.
Processing large data sets:
After it is checked that the fit works well (looking at individual fit results, like above),
large quantities of spectra (e.g. a whole day, or week) can be processed automatically.
For that purpose, the following parameters should be selected:
-click right mouse button at Calibra, select properties, select spectra. The
following menu will appear:
Page 33 of 64
Here the markers at spectra, fits, pause, and data are removed (see above).
This enables a higher processing speed of the data analysis.
Result files:
The data are stored in result files in the structure shown below. After loading the
result file into EXCEL, the following entries appear:
Page 34 of 64
Page 35 of 64
T. Wagner, 02.12.2012
The different steps are described for the example of the car MAX-DOAS
measurements made in Islamabad and Rawalpindi on 16.11.2012 (see xls-file:
Description_16Nov2012.xls).
Page 36 of 64
For the selected elevation angles, and using the geometric approximation, the AMFs
become:
AMF(30) = 2
AMF(90) = 1
Thus the above equation reduces to:
offset = DSCD(30) 2 * DSCD(90)
These values are calculated in column D in sheet 30_90_all.
2) The stratospheric AMF is estimated: The stratospheric AMF is calculated from the
SZA according to the geometric approximation:
AMFstrat = 1 / cos(SZA)
The stratospheric AMF is calculated in column L in sheet 30_90_all.
3) The stratospheric SCD is estimated assuming a typical stratospheric VCD (for mid
latitudes in autumn a typical value is 2e15 molec/cm).
The stratospheric SCD is calculated in column m in sheet 30_90_all.
4) The stratospheric SCD is added to the offset (from step 1, see above).
According to equation 12 in Wagner et al., 2010, this yields the DSCDref.
The sum of offset and stratospheric SCD is calculated in column E in the sheet
30_90_all.
This value is plotted in the sheet offset.
5) Unrealistic values have to be removed. Especially close to strong emission sources,
usually not the same air masses are observed at both elevation angles. This leads to
strong negative or positive deviations. (see sheet offset).
These outliers have to be removed. The remaining good values are copied into the
table in sheet 30_90.
Now the average of all values in column E is calculated. This is then our best
estimate for the DSCDref. In our case it is 1.07e16 molec/cm, see bottom of column
E).
C) Calculation sequence of the tropospheric NO2 VCDs from all 30 elevation
spectra
From the sheet RMS_below_3.5e-3, all 30 elevation spectra are selected and
copied into new table (sheet 30).
The tropospheric VCD is calculated according to:
VCDtrop = SCD(30) / AMF(30)
with
Page 37 of 64
Remark: For car MAX-DOAS measurements made at rather low SZA (as for 16. Nov.
2012), the variation of the SCDstrat with time is small. Thus this variation can be
neglected and the offset could be determined in a simplified way (without adding the
SCDstrat, see column D in sheet 30_90). The respective average value for 16. Nov.
2012 is 6.4e15 molec/cm, see bottom of column D in sheet 30_90.
This (new) offset has to be added to the DSCD(30) (but without subtracting the
SCDstrat). This simplified determination of the VCDtrop is shown in column M in
sheet 30. It is very similar to the one calculated before (column L).
For days with measurements made at high SZA (>75) the simplified method can
not be used.
Reference:
Wagner, T., Ibrahim, O., Shaiganfar, R., and Platt, U.: Mobile MAX-DOAS
observations of tropospheric trace gases, Atmos. Meas. Tech., 3, 129-140,
doi:10.5194/amt-3-129-2010, 2010.
Page 38 of 64
Update no2 time_id from time class table using this query
update no2 n
set time_id= t.id
from time_class t
where n."time (hh_m"::time>= t.t1 and n."time (hh_m"::time<= t.t2
Update the lat log of no2 table from gps table based on time_class
update no2 n
set longitude= g.longitude
from gps g
where n.time_id=g.time_id
update no2 n
set latitude= g.latitude
from gps g
where n.time_id=g.time_id
Copy no2 table into csv
COPY (SELECT * FROM no2)
Page 39 of 64
Page 40 of 64
Page 41 of 64
Page 42 of 64
Page 43 of 64
Now go to pgadmin III and from plugin icon add a postGIS shapefile
and DBF loader (add the saved shape file here)
Page 44 of 64
Execute query
Page 45 of 64
Page 46 of 64
Page 47 of 64
Page 48 of 64
Page 49 of 64
Page 50 of 64
Page 51 of 64
Page 52 of 64
For interpolation it is better to crop data from the satellite swath over Pakistan.
Page 53 of 64
Page 54 of 64
Copy the selection and paste in a new excel sheet and save as csv file for satellite data
over Pakistan only
Page 55 of 64
Page 56 of 64
Page 57 of 64
Your point data of no2 VCDs via satellite data will be displayed as following:
Page 58 of 64
Save it as a shapefile, by right clicking at the file in TOC, go to Data, and then Export
Data
Page 59 of 64
ArcGIS will ask you add exported to the map as layer, click yes.
Page 60 of 64
Page 61 of 64
Page 62 of 64
Input your shapefile, specify Z-value as no2 and output path, Input cell size as
0.0090440444966989, click OK
The interpolated raster image will be prepared in a while; you should give a suitable
color ramp to present your pollution levels more conveniently
Page 63 of 64
You can add you project area shapefile to represent your pollution levels at different
locations
Page 64 of 64