# uvot_fluxes_wget.pl vrs. 2018-01-16 fem at 180925d06h45m11s551213usUT
# /Home/eud/uvot_tdrss/perl/uvot_fluxes_wget.pl -seq=00020844001 -use_uvot -rebin -plot_mag -sens_corr -search_src_reg -wrk_dir=/local/home/khamseen/khamseen10/uvot_tdrss/uvot_lc -web -useprev -zp_2011 -gamma=1.0 -use_filter_wtd=white v b u
# Current directory: /local/home/khamseen/khamseen10/uvot_tdrss/uvot_lc
# ========= GRB180914 ===================
Could not find/read custom source region custom_020844_src.reg
Used archived uvot source position of 332.35640 25.06220 3.00
Reference: GCN_Circulars-23241
The position is (22:09:25.54, +25:03:43.9)
Using source region:
# Region file format: DS9 version 3.0
# uvot_fluxes.pl uvot
global font="helvetica 12 bold" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source=1
fk5;circle(332.3564,25.0622,3") # color=red dash=0
Source region spec. is: 332.3564 25.0622 3"
Region file centered at (332.3564,25.0622), which is (22:09:25.54, +25:03:43.9)
Could not find/read custom background region custom_020844_bkg.reg
Made source region file with 5" aper with name uvot_flux_src5.reg
Coincidence losses are calculated using a 5" aperture.
Exposure times (t_exp) have NOT been corrected for coinc. loss, but rates and mags have been.
The no. of background pixels has been corrected by the ratio of coincidence loss corrections in the source and background regions.
The errors have been adjusted to account for the binomial distribution of counts at large rates.
A table entry starting with # is an exposure with no aspect solution.
A table entry starting with ! has no pixels in either source or background region.
A table entry starting with % is unreliable because it is not well inside the image.
Upper limits in tables give the 0.9987 confidence limit using Bayesian analysis for detection taking the observed counts into account.
Upper limits in plots give the 0.9772 confidence limit using Bayesian analysis.
Weighted rates in tables (wtd_rate) combine rates from different exposures weighted by the expected source rate divided by the background rate
The source is assumed to produce the same magnitude in all filters.
The source is assumed to decay as t**(-1.0), and the rate is normalized so that the white filter produces 1 cps at 1000 sec.
The Rebinned Data for All_files combine rates from different exposures weighted by the expected rate divided by the observed sigma squared.
A plot of these data is stored in uvot_fluxes_wtd_date.ps and .gif.
A zero point of 20.29 is adopted for weighting rates.
Subtract UTCF of -21.59504 from uncorrected trigger time of 558642182.22 in BAT summary file
# ============ Reading file sw00020844001uuu_sk.img ================
Long-term sensitivity correction to zero point is -0.156 at 558725744
The processing date in extension 0 is: 2018-09-25T06:35:57
The trigger time is: 558642203.81504. The reference is BAT GRB summary file
Using zero point of 18.184 for filter U
Use aperture correction of 1.100 based on aperture of 3.00
Calculate distance from target to edge of image.
Ext Dist.(") RA_cent  DEC_cent width  PA
  1  -20.5 332.26319  25.19146 0.286 329.7
Using background region based on sources found in extension 2:
# Region file format: DS9 version 3.0
global color=red font="helvetica 10 normal" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source
fk5;circle(332.3564,25.0622,25")
fk5;-circle(332.3564,25.0622,12.5")
fk5;-circle(332.362422,25.058909,6")
 Ext   Exposure      t-trig coinc  t_exp   src  pix    bkg   pix net_rate +/-   mag   UL sum_rate  +/-    mag  UL sumexp wtd_rate  +/-   mag  wt/t
%  1 uu558725744I   83540.6  0.99   76.5   54.0 116    890  5587 
   2 uu558729136I   86933.1  0.99  372.9  285.9 116   4935  5532  0.542 0.050 18.85 18.6  0.5422 0.0504 18.85 18.6   373 328.691 30.584 14.00 0.006 
   3 uu558734907I   92703.4  0.99  193.8  135.7 116   2664  5581  0.459 0.067 19.03 18.6  0.5138 0.0403 18.91 18.7   567 318.791 24.994 14.03 0.006 
    Sum (T+ 86933 to  92900):             421.6        158.9 (est. in src region)   SNR_unwtd_sum:  12.75 0.9987 signif. UL:  18.68
  0   567 558731268   89064.5   3835.7  -2131.4    0.5138   0.0403 18.907  0.088  -0.082
Total wtd_rate (for all exposures so far): 318.791 +/-24.897 snr: 12.8 mag: 14.03 UL: 11.70
Rebinned Data for sw00020844001uuu_sk.img using a zero point of 18.184:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      562   89065.9   3834.4  -2132.7    0.5138   0.0403 18.91  0.08   89065.9    0.5138   0.0403 18.91  0.08 18.68
The data range from T+86933.1 s (1.01 d) to T+92900.3 s (1.08 d)
Wrote uvot_fluxes_180925d06h45m11s551213usUT.qdp
Wrote uvot_fluxes_180925d06h45m11s551213usUT.gif
Wrote uvot_fluxes_180925d06h45m11s551213usUT.ps
Wrote uvot_fluxes_180925d06h45m11s551213usUT_vis.qdp
Wrote uvot_fluxes_180925d06h45m11s551213usUT_uv.qdp
Wrote uvot_fluxes_180925d06h45m11s551213usUT_vis.gif
Wrote uvot_fluxes_180925d06h45m11s551213usUT_vis.ps
# ================ Make Light Curve for Weighted Filters ==========
Use the following filters with indicated color corrections (mags):
  u (0)  , white (0)  , b (0)  , v (0)  , 
Rebinned Data for All_files using a zero point of 20.290:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0 0.000231   89020.2   3880.1  -2087.0    3.5718   0.2804 18.91  0.08   89020.2    3.5718   0.2804 18.91  0.08 18.68
The data range from T+86933.1 s (1.01 d) to T+92900.3 s (1.08 d)
Wrote uvot_fluxes_wtd_180925d06h45m11s551213usUT.qdp
Wrote uvot_fluxes_wtd_180925d06h45m11s551213usUT.gif
Wrote uvot_fluxes_wtd_180925d06h45m11s551213usUT.ps
Normal end of uvot_fluxes_wget.pl vrs. 2018-01-16 fem