codes:errorbudget
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| codes:errorbudget [2020/12/13 21:46] – fparraro | codes:errorbudget [2024/03/22 13:31] (current) – [Introduction] jlsolano | ||
|---|---|---|---|
| Line 17: | Line 17: | ||
| - | In this document we present the uncertainty estimation of the total ozone measured by the Brewer spectrophotometers focusing on the instrumental parameters. The uncertainty model was developed during the ATMOZ project. This model describe the uncertainty model reference instruments: | + | In this document we present the uncertainty estimation of the total ozone measured by the Brewer spectrophotometers focusing on the instrumental parameters. The uncertainty model was developed during the ATMOZ project. This model describe the uncertainty model reference instruments: |
| On this report we summarize the developments of the first step which is focused on the instrumental parameters that affect the model, considering the Langley calibration and the calibration transfer to the network instruments. | On this report we summarize the developments of the first step which is focused on the instrumental parameters that affect the model, considering the Langley calibration and the calibration transfer to the network instruments. | ||
| Line 410: | Line 410: | ||
| The uncertainties of the due the atmospheric parameters used on this report are calculated for the conditions during IZO16 campaign, the influence of this parameters is the will be detailed on the next working package report. | The uncertainties of the due the atmospheric parameters used on this report are calculated for the conditions during IZO16 campaign, the influence of this parameters is the will be detailed on the next working package report. | ||
| - | The Eubrewnet database has been adapted and an access function provide the instrumental data necessary to obtain the uncertainty of the TOC through of Brewer spectrophotometers has been developed. (for example[[ http://rbcce.aemet.es/ | + | The Eubrewnet database has been adapted and an access function provide the instrumental data necessary to obtain the uncertainty of the TOC through of Brewer spectrophotometers has been developed. (for example[[ http://eubrewnet.aemet.es/ |
| ====== Conclusions ====== | ====== Conclusions ====== | ||
| Line 431: | Line 431: | ||
| ==Bibliography== | ==Bibliography== | ||
| - | Anon: EUBREWNET COST ES1207 website, [online] Available from: http://www.eubrewnet.org/cost1207 (Accessed October 2016a), n.d. | + | Anon: EUBREWNET COST ES1207 website, [online] Available from: http:// |
| - | Anon: EUBREWNET data server, [online] Available from: http://rbcce.aemet.es/ | + | Anon: EUBREWNET data server, [online] Available from: http://eubrewnet.aemet.es/ |
| Line 534: | Line 534: | ||
| ^ Field ^ Description ^ | ^ Field ^ Description ^ | ||
| ^ ’gmt’ | datetime object ^ | ^ ’gmt’ | datetime object ^ | ||
| - | ^ 'raw$\_$count$\_$w0 | + | ^ 'raw_count_w0 |
| - | ^ 'raw$\_$count$\_$w1 | + | ^ 'raw_count_w1 |
| - | ^ 'raw$\_$count$\_$w2 | + | ^ 'raw_count_w2 |
| - | ^ 'raw$\_$count$\_$w3 | + | ^ 'raw_count_w3 |
| - | ^ 'raw$\_$count$\_$w4 | + | ^ 'raw_count_w4 |
| - | ^ 'raw$\_$count$\_$w5 | + | ^ 'raw_count_w5 |
| - | ^ 'dark$\_$count’ | dark count ^ | + | ^ 'dark_count’ | dark count ^ |
| ^ ’cycles’ | # of cycles ^ | ^ ’cycles’ | # of cycles ^ | ||
| ^ ’temp’ | Brewer Temperature ^ | ^ ’temp’ | Brewer Temperature ^ | ||
| - | ^ ’nd$\_$filter$\_$position’ | ND filter position of #2 Filterwheel (in steps) ^ | + | ^ ’nd_filter_position’ | ND filter position of #2 Filterwheel (in steps) ^ |
| ^ ’o3’ | Level 1 ozone ^ | ^ ’o3’ | Level 1 ozone ^ | ||
| ^ ’pre’ | pressure ^ | ^ ’pre’ | pressure ^ | ||
| - | ^ ’u$\_$pre’ | pressure uncertainty ^ | + | ^ ’u_pre’ | pressure uncertainty ^ |
| ==== Config ==== | ==== Config ==== | ||
| Line 553: | Line 553: | ||
| ^ Field ^ Description ^ | ^ Field ^ Description ^ | ||
| - | ^ ’w$\_$o3$\_$0’ | weight for double ratio #2 MS(9) calculation, | + | ^ ’w_o3_0’ | weight for double ratio #2 MS(9) calculation, |
| - | ^ ’w$\_$o3$\_$2’ | weight for double ratio #2 MS(9) calculation, | + | ^ ’w_o3_2’ | weight for double ratio #2 MS(9) calculation, |
| - | ^ ’w$\_$o3$\_$3’ | weight for double ratio #2 MS(9) calculation, | + | ^ ’w_o3_3’ | weight for double ratio #2 MS(9) calculation, |
| - | ^ ’w$\_$o3$\_$4’ | weight for double ratio #2 MS(9) calculation, | + | ^ ’w_o3_4’ | weight for double ratio #2 MS(9) calculation, |
| - | ^ ’w$\_$o3$\_$5’ | weight for double ratio #2 MS(9) calculation, | + | ^ ’w_o3_5’ | weight for double ratio #2 MS(9) calculation, |
| - | ^ ’w$\_$o3$\_$6’ | weight for double ratio #2 MS(9) calculation, | + | ^ ’w_o3_6’ | weight for double ratio #2 MS(9) calculation, |
| ^ ’o3tempcoef’ | ozone temperature coefficient for slit 0 ^ | ^ ’o3tempcoef’ | ozone temperature coefficient for slit 0 ^ | ||
| ^ ’oslit1’ | ozone temperature coefficient for slit 1 ^ | ^ ’oslit1’ | ozone temperature coefficient for slit 1 ^ | ||
| Line 565: | Line 565: | ||
| ^ ’oslit4’ | ozone temperature coefficient for slit 4 ^ | ^ ’oslit4’ | ozone temperature coefficient for slit 4 ^ | ||
| ^ ’oslit5’ | ozone temperature coefficient for slit 5 ^ | ^ ’oslit5’ | ozone temperature coefficient for slit 5 ^ | ||
| - | ^ ’o3tempcoef$\_$unc’ | ozone temperature coefficient uncertainty for slit 0 ^ | + | ^ ’o3tempcoef_unc’ | ozone temperature coefficient uncertainty for slit 0 ^ |
| - | ^ ’oslit1$\_$unc’ | ozone temperature coefficient uncertainty for slit 1 ^ | + | ^ ’oslit1_unc’ | ozone temperature coefficient uncertainty for slit 1 ^ |
| - | ^ ’oslit2$\_$unc’ | ozone temperature coefficient uncertainty for slit 2 ^ | + | ^ ’oslit2_unc’ | ozone temperature coefficient uncertainty for slit 2 ^ |
| - | ^ ’oslit3$\_$unc’ | ozone temperature coefficient uncertainty for slit 3 ^ | + | ^ ’oslit3_unc’ | ozone temperature coefficient uncertainty for slit 3 ^ |
| - | ^ ’oslit4$\_$unc’ | ozone temperature coefficient uncertainty for slit 4 ^ | + | ^ ’oslit4_unc’ | ozone temperature coefficient uncertainty for slit 4 ^ |
| - | ^ ’oslit5$\_$unc’ | ozone temperature coefficient uncertainty for slit 5 ^ | + | ^ ’oslit5_unc’ | ozone temperature coefficient uncertainty for slit 5 ^ |
| ^ 'it’ | slit sampling time ^ | ^ 'it’ | slit sampling time ^ | ||
| ^ ' | ^ ' | ||
| - | ^ ’deadtime$\_$unc’ | dead time uncertainty (seconds) ^ | + | ^ ’deadtime_unc’ | dead time uncertainty (seconds) ^ |
| ^ ’lf0’ | non-linearity filter coefficient of filter 0 ^ | ^ ’lf0’ | non-linearity filter coefficient of filter 0 ^ | ||
| ^ ’lf1’ | non-linearity filter coefficient of filter 1 ^ | ^ ’lf1’ | non-linearity filter coefficient of filter 1 ^ | ||
| Line 580: | Line 580: | ||
| ^ ’lf4’ | non-linearity filter coefficient of filter 4 ^ | ^ ’lf4’ | non-linearity filter coefficient of filter 4 ^ | ||
| ^ ’lf5’ | non-linearity filter coefficient of filter 5 ^ | ^ ’lf5’ | non-linearity filter coefficient of filter 5 ^ | ||
| - | ^ ’lf0$\_$unc’ | non-linearity filter coefficient uncertainty of filter 0 ^ | + | ^ ’lf0_unc’ | non-linearity filter coefficient uncertainty of filter 0 ^ |
| - | ^ ’lf1$\_$unc’ | non-linearity filter coefficient uncertainty of filter 1 ^ | + | ^ ’lf1_unc’ | non-linearity filter coefficient uncertainty of filter 1 ^ |
| - | ^ ’lf2$\_$unc’ | non-linearity filter coefficient uncertainty of filter 2 ^ | + | ^ ’lf2_unc’ | non-linearity filter coefficient uncertainty of filter 2 ^ |
| - | ^ ’lf3$\_$unc’ | non-linearity filter coefficient uncertainty of filter 3 ^ | + | ^ ’lf3_unc’ | non-linearity filter coefficient uncertainty of filter 3 ^ |
| - | ^ ’lf4$\_$unc’ | non-linearity filter coefficient uncertainty of filter 4 ^ | + | ^ ’lf4_unc’ | non-linearity filter coefficient uncertainty of filter 4 ^ |
| - | ^ ’lf5$\_$unc’ | non-linearity filter coefficient uncertainty of filter 5 ^ | + | ^ ’lf5_unc’ | non-linearity filter coefficient uncertainty of filter 5 ^ |
| - | ^ ’slope$\_$wavelength’ | percent variation of double ratio with wavelength ^ | + | ^ ’slope_wavelength’ | percent variation of double ratio with wavelength ^ |
| - | ^ ’slope$\_$wavelength$\_$unc’ | percent variation uncertainty of double ratio with wavelength ^ | + | ^ ’slope_wavelength_unc’ | percent variation uncertainty of double ratio with wavelength ^ |
| ^ ’o3o3rate’ | ozone on ozone ratio ^ | ^ ’o3o3rate’ | ozone on ozone ratio ^ | ||
| - | ^ ’u$\_$A1’ | ozone on ozone ratio uncertainty ^ | + | ^ ’u_A1’ | ozone on ozone ratio uncertainty ^ |
| ^ ’latitude’ | site latitude in decimal degrees ^ | ^ ’latitude’ | site latitude in decimal degrees ^ | ||
| ^ ’longitude’ | site longitude in decimal degrees ^ | ^ ’longitude’ | site longitude in decimal degrees ^ | ||
| Line 598: | Line 598: | ||
| ^ ’be6’ | Rayleigh optical depth (multiplied by 10000*log10(e)) for wavelength #5 ^ | ^ ’be6’ | Rayleigh optical depth (multiplied by 10000*log10(e)) for wavelength #5 ^ | ||
| ^ ’etco3rate’ | ETC on ozone ratio ^ | ^ ’etco3rate’ | ETC on ozone ratio ^ | ||
| - | ^ ’u$\_$etc’ | ETC uncertainty on ozone ratio ^ | + | ^ ’u_etc’ | ETC uncertainty on ozone ratio ^ |
| - | ^ ’rho$\_$A$\_$o3’ | Cross correlation coefficient between o3o3rate and o3 ^ | + | ^ ’rho_A_o3’ | Cross correlation coefficient between o3o3rate and o3 ^ |
| - | ^ ’rho$\_$A$\_$mu’ | Cross correlation coefficient between o3o3rate and ozone optical mass ^ | + | ^ ’rho_A_mu’ | Cross correlation coefficient between o3o3rate and ozone optical mass ^ |
| - | ^ ’rho$\_$A$\_$B’ | Cross correlation coefficient between o3o3rate and weighted Rayleigh depth ^ | + | ^ ’rho_A_B’ | Cross correlation coefficient between o3o3rate and weighted Rayleigh depth ^ |
| - | ^ ’rho$\_$A$\_$m’ | Cross correlation coefficient between o3o3rate and Rayleigh optical mass ^ | + | ^ ’rho_A_m’ | Cross correlation coefficient between o3o3rate and Rayleigh optical mass ^ |
| - | ^ ’rho$\_$A$\_$p’ | Cross correlation coefficient between o3o3rate and pressure ^ | + | ^ ’rho_A_p’ | Cross correlation coefficient between o3o3rate and pressure ^ |
| - | ^ ’rho$\_$A$\_$etc’ | Cross correlation coefficient between o3o3rate and ETC ^ | + | ^ ’rho_A_etc’ | Cross correlation coefficient between o3o3rate and ETC ^ |
| - | ^ ’rho$\_$o3$\_$mu’ | Cross correlation coefficient between o3 and ozone optical mass ^ | + | ^ ’rho_o3_mu’ | Cross correlation coefficient between o3 and ozone optical mass ^ |
| - | ^ ’rho$\_$o3$\_$B’ | Cross correlation coefficient between o3 and weighted Rayleigh depth ^ | + | ^ ’rho_o3_B’ | Cross correlation coefficient between o3 and weighted Rayleigh depth ^ |
| - | ^ ’rho$\_$o3$\_$m’ | Cross correlation coefficient between o3 and Rayleigh optical mass ^ | + | ^ ’rho_o3_m’ | Cross correlation coefficient between o3 and Rayleigh optical mass ^ |
| - | ^ ’rho$\_$o3$\_$p’ | Cross correlation coefficient between o3 and pressure ^ | + | ^ ’rho_o3_p’ | Cross correlation coefficient between o3 and pressure ^ |
| - | ^ ’rho$\_$o3$\_$etc’ | Cross correlation coefficient between o3 and ETC | + | ^ ’rho_o3_etc’ | Cross correlation coefficient between o3 and ETC ^ |
| - | ^ ’rho$\_$mu$\_$B’ | Cross correlation coefficient between ozone optical mass and weighted Rayleigh depth ^ | + | ^ ’rho_mu_B’ | Cross correlation coefficient between ozone optical mass and weighted Rayleigh depth ^ |
| - | ^ ’rho$\_$mu$\_$m’ | Cross correlation coefficient between ozone optical mass and Rayleigh optical mass ^ | + | ^ ’rho_mu_m’ | Cross correlation coefficient between ozone optical mass and Rayleigh optical mass ^ |
| - | ^ ’rho$\_$mu$\_$p’ | Cross correlation coefficient between ozone optical mass and pressure ^ | + | ^ ’rho_mu_p’ | Cross correlation coefficient between ozone optical mass and pressure ^ |
| - | ^ ’rho$\_$mu$\_$etc’ | Cross correlation coefficient between ozone optical mass and ETC | + | ^ ’rho_mu_etc’ | Cross correlation coefficient between ozone optical mass and ETC ^ |
| - | ^ ’rho$\_$B$\_$m’ | Cross correlation coefficient between weighted Rayleigh depth and Rayleigh optical mass ^ | + | ^ ’rho_B_m’ | Cross correlation coefficient between weighted Rayleigh depth and Rayleigh optical mass ^ |
| - | ^ ’rho$\_$B$\_$p’ | Cross correlation coefficient between weighted Rayleigh depth and pressure ^ | + | ^ ’rho_B_p’ | Cross correlation coefficient between weighted Rayleigh depth and pressure ^ |
| - | ^ ’rho$\_$B$\_$etc’ | Cross correlation coefficient between weighted Rayleigh depth and ETC ^ | + | ^ ’rho_B_etc’ | Cross correlation coefficient between weighted Rayleigh depth and ETC ^ |
| - | ^ ’rho$\_$m$\_$p’ | Cross correlation coefficient between Rayleigh optical mass and pressure ^ | + | ^ ’rho_m_p’ | Cross correlation coefficient between Rayleigh optical mass and pressure ^ |
| - | ^ ’rho$\_$m$\_$etc’ | Cross correlation coefficient between Rayleigh optical mass and ETC ^ | + | ^ ’rho_m_etc’ | Cross correlation coefficient between Rayleigh optical mass and ETC ^ |
| - | ^ ’rho$\_$p$\_$etc’ | Cross correlation coefficient between pressure and ETC ^ | + | ^ ’rho_p_etc’ | Cross correlation coefficient between pressure and ETC ^ |
| ===== Functions ===== | ===== Functions ===== | ||
| Line 628: | Line 628: | ||
| ^ Function ^ Short Description ^ | ^ Function ^ Short Description ^ | ||
| - | ^ airmass$\_$unc$\_$calc() | Calculates the air mass uncertainty (rayleigh and ozone) for brewer individual measurements. ^ | + | ^ airmass_unc_calc() | Calculates the air mass uncertainty (rayleigh and ozone) for brewer individual measurements. ^ |
| - | ^ instrumental$\_$unc() | Applies instrumental corrections (darkcount, deadtime, temperature, | + | ^ instrumental_unc() | Applies instrumental corrections (darkcount, deadtime, temperature, |
| ^ combined() | Calculates the combined uncertainty to brewer individual measurements. ^ | ^ combined() | Calculates the combined uncertainty to brewer individual measurements. ^ | ||
| Line 654: | Line 654: | ||
| * // | * // | ||
| + | |||
| * // | * // | ||
| + | |||
| * // | * // | ||
| Line 671: | Line 673: | ||
| print(" | print(" | ||
| - | The fields ’// | + | The fields ’// |
| This function returns the input measure dictionary, adding the following fields: | This function returns the input measure dictionary, adding the following fields: | ||
| Line 681: | Line 684: | ||
| * ’// | * ’// | ||
| - | | + | |
| - | $single\_ratio2 = f_4 - f_2$ | + | * $single\_ratio2 = f_{4} - f_{2}$ |
| - | $single\_ratio3 = f_4 - f_3$ | + | * $single\_ratio3 = f_{4} - f_{3}$ |
| - | $single\_ratio4 = f_5 - f_4$ | + | * $single\_ratio4 = f_{5} - f_{4}$ |
| * ’// | * ’// | ||
| - | | + | |
| - | $double\_ratio2\_unc = double\_ratio2 * \sum_i \frac{u_{fi}}{f_{i}} * w\_o3_{i+1}$ | + | * $double\_ratio2\_unc = double\_ratio2 * \sum_{i} |
| * '// | * '// | ||
| - | | + | |
| - | $measure\_unc = \sqrt{\left(1+\frac{slope\_wavelength}{100}\right)^{2}*double\_ratio2\_unc^{2} + \left(\frac{measure}{100}\right)^{2}*slope\_wavelength\_unc^{2}}$ | + | * $measure\_unc = \sqrt{\left(1+\frac{slope\_wavelength}{100}\right)^{2}*double\_ratio2\_unc^{2} + \left(\frac{measure}{100}\right)^{2}*slope\_wavelength\_unc^{2}}$ |
| === combined() === | === combined() === | ||
| Line 709: | Line 712: | ||
| | | ||
| out = combined( measure, config ) | out = combined( measure, config ) | ||
| - | print("u_o3: & | + | print("u_o3: " |
| - | print("o3 : "+str(out[' | + | print("o3 : " |
| The fields ’// | The fields ’// | ||
| Line 721: | Line 724: | ||
| ^ Function ^ Short Description ^ | ^ Function ^ Short Description ^ | ||
| - | ^ solar$\_$ha$\_$dec$\_$et$\_$unc() | Returns the solar hour angle, declination and equation of time uncertainties. ^ | + | ^ solar_ha_dec_et_unc() | Returns the solar hour angle, declination and equation of time uncertainties. ^ |
| - | ^ sza$\_$unc() | Returns the solar zenith angle uncertainty. ^ | + | ^ sza_unc() | Returns the solar zenith angle uncertainty. ^ |
| === solar_ha_dec_et_unc() === | === solar_ha_dec_et_unc() === | ||
| Line 752: | Line 755: | ||
| ^ Function ^ Short Description ^ | ^ Function ^ Short Description ^ | ||
| ^ rawtocount() | Returns a list with the raw-to-count conversion uncertainty. ^ | ^ rawtocount() | Returns a list with the raw-to-count conversion uncertainty. ^ | ||
| - | ^ darkcount$\_$unc() | Returns a list with the dark count correction uncertainty. ^ | + | ^ darkcount_unc() | Returns a list with the dark count correction uncertainty. ^ |
| - | ^ deadtime$\_$unc() | Returns a list with the dead time correction uncertainty. ^ | + | ^ deadtime_unc() | Returns a list with the dead time correction uncertainty. ^ |
| ^ temp_unc() | Returns a list with the temperature correction uncertainty. ^ | ^ temp_unc() | Returns a list with the temperature correction uncertainty. ^ | ||
| ^ filter_linearity_unc() | Returns a list with the filter linearity correction uncertainty. ^ | ^ filter_linearity_unc() | Returns a list with the filter linearity correction uncertainty. ^ | ||
| Line 768: | Line 771: | ||
| brewer_unc.rawtocount( raw, dark_raw, cycles, it ) | brewer_unc.rawtocount( raw, dark_raw, cycles, it ) | ||
| | | ||
| - | The input parameter | + | The input parameter |
| - | The < | + | The //rawtocount()/ |
| - | === < | + | === darkcount_unc() === |
| This function gets the dark count correction uncertainty: | This function gets the dark count correction uncertainty: | ||
| - | < | + | $u_{out}^{2}[i] = u^{2}[i] + u^{2}[dark]$ |
| - | ''' | + | **Example** |
| - | < | + | |
| - | brewer_unc.darkcount_unc( f, dark_count, u2_f, cycles, it )</ | + | |
| - | The input parameter | + | The input parameter |
| - | The < | + | The // |
| - | === < | + | === deadtime_unc() === |
| This function gets the dead time correction uncertainty. The method iterates 9 times the equation: | This function gets the dead time correction uncertainty. The method iterates 9 times the equation: | ||
| - | < | + | $u_{out}^{2}[i] = \left(\frac{\exp(t1*f[i])}{1-t1*f[i]}\right)^{2}*u^{2}[i] + f^{4}[i]*u_{t1}^{2}$ |
| The deadtime-compensated uncertainty are normalized by computing the base ten logarithm of e, then scaled by 10000, thus allowing integer arithmetic. | The deadtime-compensated uncertainty are normalized by computing the base ten logarithm of e, then scaled by 10000, thus allowing integer arithmetic. | ||
| - | < | + | $u_{out} = \frac{10^{4}u[i]}{f[i]*\log(10)}$ |
| - | ''' | + | **Example** |
| - | < | + | |
| - | brewer_unc.deadtime_unc( f, u2_f, t1, u_t1, norm=1 )</ | + | |
| - | The input parameter | + | The input parameter |
| - | The < | + | The // |
| - | === < | + | === temp_unc() === |
| This function gets the temperature-dependent compensation uncertainty of the spectrometer: | This function gets the temperature-dependent compensation uncertainty of the spectrometer: | ||
| - | < | + | $u_{out}^{2} = u^{2}[i] + tc^{2}[i]*u_{t}^{2} + t^{2}*u_{tc}^{2}[i]$ |
| - | where < | + | where $u_{t}$ is the temperature uncertainty which usially |
| - | ''' | + | **Example** |
| - | < | + | |
| - | brewer_unc.temp_unc( u2_f, t, tc, u_tc )</ | + | |
| - | The input parameter | + | The input parameter // |
| - | The < | + | The //temp_unc()// function returns a list with the temperature corrected uncertainties in counts per second. |
| - | === < | + | === filter_linearity_unc() === |
| This function gets the non-linearity of the neutral-density filters compensation uncertainty used to adjust the light level entering the spectrometer: | This function gets the non-linearity of the neutral-density filters compensation uncertainty used to adjust the light level entering the spectrometer: | ||
| - | < | + | $u_{out}^{2} = u^{2}[i] + u^{2}_{lf}[p]$ |
| - | This function is typically applied after the double ratio.<br /> | + | This function is typically applied after the double ratio. |
| - | ''' | + | |
| - | < | + | **Example** |
| - | brewer_unc.filter_linearity_unc( f, u_f, lf, u_lf, fp )</ | + | |
| - | The input parameter < | + | |
| - | The < | + | brewer_unc.filter_linearity_unc( |
| + | |||
| + | The input parameter | ||
| - | === < | + | The // |
| + | |||
| + | === wavelength_slope() === | ||
| This function gets the uncertainty of the double ratio variation with the wavelength: | This function gets the uncertainty of the double ratio variation with the wavelength: | ||
| - | < | + | $u_{out}^{2} = \left(1+\frac{k_{wv}}{100}\right)^{2}*u_{in}^{2} + \left(\frac{DR}{100}\right)^{2}*u_{wv}^{2}$ |
| - | ''' | + | **Example** |
| - | < | + | |
| - | brewer_unc.wavelength_slope( f, u_f, kwv, u_kwv )</ | + | |
| - | The input parameter | + | The input parameter |
| - | The < | + | The // |
| - | == Auxiliary Functions == | + | ==== Auxiliary Functions |
| - | {| | + | ^ Function |
| - | !align=" | + | ^ rel_unc() | Returns a list with the relative uncertainties. |
| - | ! ''' | + | ^ wsum_unc() | Returns the weighted sum from all uncertainties on a list. ^ |
| - | |- | + | ^ wsum() | Returns the weighted sum from all measurements on a list. ^ |
| - | |align=" | + | ^ B_unc() | Returns the Rayleigh scattering uncertainty. |
| - | | Returns a list with the relative uncertainties. | + | |
| - | |- | + | |
| - | |align=" | + | |
| - | | Returns the weighted sum from all uncertainties on a list. | + | |
| - | |- | + | |
| - | |align=" | + | |
| - | | Returns the weighted sum from all measurements on a list. | + | |
| - | |- | + | |
| - | |align=" | + | |
| - | | Returns the Rayleigh scattering uncertainty. | + | |
| - | |} | + | |
| - | === < | + | === rel_unc() === |
| This function computes the relative uncertainty of a list of measurements or parameters as following: | This function computes the relative uncertainty of a list of measurements or parameters as following: | ||
| - | < | + | $u\_rel = \frac{u\_f}{f}$ |
| - | ''' | + | **Example** |
| - | <pre>import brewer_unc | + | |
| - | + | ||
| - | f=[1,2] | + | f=[1,2] |
| - | u_f=[0.1, | + | u_f=[0.1, |
| - | + | ||
| - | brewer_unc.rel_unc( f, u_f )</ | + | brewer_unc.rel_unc( f, u_f ) |
| - | The input parameter | + | |
| + | The input parameter | ||
| - | The < | + | The //rel_unc()// function returns a float which is the relative uncertainty of //f//. |
| - | === < | + | === wsum() === |
| This function computes the sum of products over two lists. Both input lists should have the same length: | This function computes the sum of products over two lists. Both input lists should have the same length: | ||
| - | < | + | $wsum = \sum_i f[i]*w[i]$ |
| - | ''' | + | **Example** |
| - | <pre>import brewer | + | |
| - | f=[1,2] | + | f=[1,2] |
| - | w=[2,3] | + | w=[2,3] |
| - | brewer.wsum( f, w )</ | + | brewer.wsum( f, w ) |
| - | The input parameter | + | |
| + | The input parameter | ||
| - | The < | + | The //wsum()// function returns a float with the weighted sum value. |
| - | === < | + | === wsum_unc() === |
| This function computes the sum of square products over two lists. Both input lists should have the same length: | This function computes the sum of square products over two lists. Both input lists should have the same length: | ||
| - | < | + | $wsum\_unc = \sum_i (f[i]*w[i])^2$ |
| - | ''' | + | **Example** |
| - | <pre>import brewer | + | |
| - | f=[1,2] | + | f=[1,2] |
| - | w=[0.1, | + | w=[0.1, |
| - | brewer.wsum_unc( f, w )</ | + | brewer.wsum_unc( f, w ) |
| - | The input parameter | + | |
| + | The input parameter | ||
| - | The < | + | The //wsum()// function returns a float with the weighted square sum value. |
| - | === < | + | === B_unc() === |
| This function computes the uncertainty of the Rayleigh scattering coefficients. | This function computes the uncertainty of the Rayleigh scattering coefficients. | ||
| - | ''' | + | **Example** |
| - | <pre>import brewer | + | |
| + | |||
| + | config = {' | ||
| + | unc = 0.01 | ||
| + | |||
| + | out = brewer.wsum_unc( config, unc ) | ||
| + | print(" | ||
| + | print(" | ||
| - | config = {' | + | The fields ’//be2//’, ’//be3//’, ’//be4//', ’//be5//’, ’//be6//’, ’//w_o3_2//’, ’//w_o3_3//’, ’//w_o3_4//’, ’//w_o3_5//’, ’//w_o3_6//’ and ’//w_o3_0//’ are used from config. |
| - | unc = 0.01 | + | |
| - | + | ||
| - | out = brewer.wsum_unc( config, unc ) | + | |
| - | print(& | + | |
| - | print(& | + | |
| - | The fields ’< | + | |
| This function returns the input config dictionary, adding the following fields: | This function returns the input config dictionary, adding the following fields: | ||
| - | * ’< | + | * ’//B//’. This field is the weighted Rayleigh scattering coefficient. |
| - | * ’< | + | |
| + | * ’//u_B//’. This field is the weighted Rayleigh scattering coefficient uncertainty. | ||
codes/errorbudget.1607895996.txt.gz · Last modified: 2020/12/13 21:46 by fparraro