 **********
 **   18 **HESSE 
 **********

 FCN=   15530.33     FROM HESSE     STATUS=OK           207 CALLS     1624 TOTAL
                     EDM=   .19E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     13.336        23.394        .10916E-04   -1.5635    
   2  Prefactor      .0000        8.0412        .84235E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm           .0000        6.0128        .84235E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     101.42        53.226        .19801E-04   -1.5507    
   5  Prefactor     4.2082        15.161        .19525E-04   -1.5667    
   6  norm          18.335        16.824        .93367E-05   -1.5622    
   7  norm          1.6373        1.0185        .95302E-05   -1.5682    
   8  Prefactor     .62172E-08    38.408        .44438E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          1.6303        1.7860        .16633E-04   -1.5682    
  10  norm          12.806        3.2092        .53354E-04   -1.5636    
  11  norm          .44409E-09    5.5158        .84235E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     44.321        50.383        .59944E-05   -1.5575    
  13  Prefactor     28.858        28.338        .74878E-05   -1.5601    
  14  Prefactor     .18929E-07    255.16        .15700E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Normalizat    .71974        .27807        .75276E-03   -1.0312    
  16  Prefactor     1.3608        .10506        .22815E-03   -.81518    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.88899e-09
Minuit parameter uncertainties:
  1  23.3939
  2  1.8394e-05
  3  2.39493e-06
  4  53.2265
  5  15.1611
  6  16.8242
  7  1.01851
  8  0.000975562
  9  1.78599
  10  3.20919
  11  0.000101844
  12  50.3839
  13  28.3377
  14  0.00439327
  15  0.278615
  16  0.105077
/sdf/group/fermi/u/kocevski/software/conda/envs/fermitools_v1.0.5/lib/python2.7/site-packages/pyfits/__init__.py:22: PyFITSDeprecationWarning: PyFITS is deprecated, please use astropy.io.fits
  PyFITSDeprecationWarning)  # noqa

Likelihood Analysis Tool
Support Contact: Daniel Kocevski (daniel.kocevski@nasa.gov)

Importing modules...
This is make3FGLxml version 01r0.
The default diffuse model files and names are for pass 8 and assume you have v10r00p05 of the Fermi Science Tools or higher.
This is make4FGLDR3xml version 01r09.
The default diffuse model files and names are for P8R3, 4FGL DRs, and the default fermitools directory locations.

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

/sdf/group/fermi/u/kocevski/software/conda/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/cbook/deprecation.py:106: MatplotlibDeprecationWarning: The mpl_toolkits.axes_grid module was deprecated in version 2.1. Use mpl_toolkits.axes_grid1 and mpl_toolkits.axisartist provies the same functionality instead.
  warnings.warn(message, mplDeprecation, stacklevel=1)

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 15530.3294065

Extracting fit parameters...

4FGL J0709.1+2241
   Spectrum: PowerLaw
282    Prefactor:  4.208e+00  1.516e+01  0.000e+00  1.000e+06 ( 1.000e-13)
283        Index:  2.064e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
284        Scale:  1.716e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
551    Prefactor:  1.361e+00  1.051e-01  0.000e+00  1.000e+01 ( 1.000e+00)
552        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
553        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
550   Normalization:  7.197e-01  2.786e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.09
Ra Dec: 107.277 22.685
Photon Flux Upper Limit: 1.30691945557e-07 ph cm-2 s-1
Energy Flux Upper Limit: 0.00985332570577 MeV cm-2 s-1

Saving results to:
/lscratch/kocevski/18884193/likelihoodResults_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.txt

Performing a free index iterative likelihood fit...

Freezing all point sources, except source of interest...

Done.

Freeing candidate source...
Done.

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 15530.3222097
delta logL = 0.00719674654465

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 15530.3209354
delta logL = 0.00847110204268

Fit tolerance = 1e-08

Performing likelihood fit...
 **********
 **   14 **SET NOWARN 
 **********

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    5.0004       1.0000          .0000       .10000E+07
     2 'Index     '    1.9071       1.0000          .0000       10.000    
     3 'Normalizat'    .72173       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.3602       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5700E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   15530.32     FROM MIGRAD    STATUS=CONVERGED     90 CALLS      262 TOTAL
                     EDM=   .17E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     4.9970        16.657        .17979E-04   -.26179E-03
   2  Index         1.9064        1.1399        .65855E-02    .35565E-04
   3  Normalizat    .72177        .24928        .75174E-03   -.59156E-03
   4  Prefactor     1.3602        .10145        .22819E-03   -.18917E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 4.99705
  Index      = 1.90643
  Normalizat = 0.721768
  Prefactor  = 1.36019
 **********
 **   18 **HESSE 
 **********

 FCN=   15530.32     FROM HESSE     STATUS=OK            23 CALLS      285 TOTAL
                     EDM=   .17E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     4.9970        16.543        .71916E-06   -1.5663    
   2  Index         1.9064        1.1322        .26342E-03   -.66710    
   3  Normalizat    .72177        .24930        .30070E-04   -1.0304    
   4  Prefactor     1.3602        .10144        .45638E-04   -.81534    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.66393e-09
Minuit parameter uncertainties:
  1  16.5432
  2  1.1485
  3  0.249695
  4  0.101459
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 15530.3209352
delta logL = 0.00847131470437

Extracting fit parameters...

4FGL J0709.1+2241
   Spectrum: PowerLaw
282    Prefactor:  4.997e+00  1.654e+01  0.000e+00  1.000e+06 ( 1.000e-13)
283        Index:  1.906e+00  1.148e+00  0.000e+00  1.000e+01 (-1.000e+00)
284        Scale:  1.716e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
551    Prefactor:  1.360e+00  1.015e-01  0.000e+00  1.000e+01 ( 1.000e+00)
552        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
553        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
550   Normalization:  7.218e-01  2.497e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.09
Ra Dec: 107.277 22.685

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /lscratch/kocevski/18884193/cmap_HighResolution_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.png

Cleaning up...

** Nuclear option initiated! **

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='9.85e-03', job_status='DONE', photon_flux_upper_limit='1.31e-07', time_completed='2023-07-10 10:09:44.460929', job_id='18884193', GAL2='1.36', fit_tolerance='1e-08', EG2='0.72', EG='0.72', time_epoch_completed='1689008984.46', return_code2='0', ts='0.09', comment='SUCCESS', return_code='0', GAL='1.36', dlogl='8.47e-03', ts2='0.11', photon_index_error='0.00', photon_index='2.06' WHERE bin_id='1815' AND source_name='4FGL J0709.1+2241' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Jul 10 10:09:44 PDT 2023

number of points = 7706
number of fields = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J0709.1+2241_daily_bin1815
RA = 107.277, Dec = 22.6847
tmin = 709776001, tmax = 710035201
emin = 100.0, emax = 100000.0
irfs = P8R3_SOURCE_V2
ROI = 12
zmax = 90

Fitting strategies:
Fix sources to their catalog values = True
Leave variable source normalizations free = True
Perform pre-fit where ALL sources are frozen to catalog values = False
Perform secondary fit with a free spectral index = True
Remove all catalog sources = False
Remove weak (TS < 2) catalog sources = False
Freeze Galactic component = False

Likelihood fit parameters:
Statistic: UNBINNED
Optimizer: MINUIT

Catalog: 4FGL

Repository job = True

LAT data source:
Data catalog

Updating database...

UPDATE lightcurve_data_v2 SET job_id='18885726', job_status='RUN', time_executed='2023-07-10 10:08:51.504054', time_epoch_executed='1689008931.5' WHERE source_name='4FGL J0709.1+2241' and cadence='daily' and bin_id='1815'

Database successfully updated.
Done.

Creating custom output directory:
/lscratch/kocevski/18885726

Creating custom pfile directory:
/lscratch/kocevski/18885726/pfiles/

Retrieving the FT1 file...

Issuing command:
datacat find --group FT1 --filter 'nMetStop>=709776001.0 && nMetStart<710035201.0' /Data/Flight/Reprocess/P305

Issuing command:
datacat find --group FT1 --filter 'nMetStart>564945418 && nMetStop>=709776001.0 && nMetStart<710035201.0' /Data/Flight/Level1/LPA

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/lscratch/kocevski/18885726/ft1_4FGL_J0709.1+2241_daily_bin1815.fits


Retrieving the FT1 file...

Issuing command:
datacat find --group FT2 --filter 'nMetStop>=709776001.0 && nMetStart<710035201.0' /Data/Flight/Level1/LPA

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits


Selecting the photons:
time -p gtselect infile=/lscratch/kocevski/18885726/ft1_4FGL_J0709.1+2241_daily_bin1815.fits outfile=/lscratch/kocevski/18885726/ft1_filteredMKT_4FGL_J0709.1+2241_daily_bin1815.fits ra=107.277 dec=22.6847 rad=12.0 tmin=709776001.0 tmax=710035201.0 emin=100.0 emax=100000.0 zmin=0.0 zmax=90.0 evclass=128 evtype="INDEF" convtype=-1 phasemin=0.0 phasemax=1.0 evtable="EVENTS" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

Done.
real 2.97
user 2.64
sys 0.18

Adding sun position to ft2 file:
/sdf/group/fermi/g/LCRepository/Repository/bin/sunpos /lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits

Selecting the good time intervals:
time -p gtmktime scfile=/lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits sctable="SC_DATA" filter="IN_SAA!=T && LIVETIME>0 && gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))" roicut=no evfile=/lscratch/kocevski/18885726/ft1_filteredMKT_4FGL_J0709.1+2241_daily_bin1815.fits evtable="EVENTS" outfile="/lscratch/kocevski/18885726/ft1_filtered_4FGL_J0709.1+2241_daily_bin1815.fits" apply_filter=yes overwrite=yes header_obstimes=yes tstart=0.0 tstop=0.0 gtifile="default" chatter=3 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtmktime version HEAD
Applying GTI filter:
IN_SAA!=T && LIVETIME>0 && gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))
real 0.49
user 0.20
sys 0.13

Number of photons that the gtmktime cut: 1596

Generating the livetime cube:
time -p gtltcube evfile="/lscratch/kocevski/18885726/ft1_filtered_4FGL_J0709.1+2241_daily_bin1815.fits" evtable="EVENTS" scfile=/lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits sctable="SC_DATA" outfile=/lscratch/kocevski/18885726/ltcube_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits dcostheta=0.025 binsz=1.0 phibins=0 tmin=0.0 tmax=0.0 file_version="1" zmin=0.0 zmax=90.0 chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

Working on file /lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits
.....................!
real 8.39
user 7.96
sys 0.24

Generating the exposure map:
time -p gtexpmap evfile=/lscratch/kocevski/18885726/ft1_filtered_4FGL_J0709.1+2241_daily_bin1815.fits evtable="EVENTS" scfile=/lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits sctable="SC_DATA" expcube=/lscratch/kocevski/18885726/ltcube_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits outfile=/lscratch/kocevski/18885726/expmap_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits irfs="P8R3_SOURCE_V2" evtype="INDEF" srcrad=30.0 nlong=88 nlat=88 nenergies=10 submap=no nlongmin=0 nlongmax=0 nlatmin=0 nlatmax=0 chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

The exposure maps generated by this tool are meant
to be used for *unbinned* likelihood analysis only.
Do not use them for binned analyses.
Computing the ExposureMap using /lscratch/kocevski/18885726/ltcube_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits
.....................!
real 70.07
user 65.80
sys 3.68

Generating the xml model:
radLim = 0.001
maxRad = 12
normsOnly = True
freeVariableSources = True
Fixing all sources to their catalog values, except variable sources
Creating file and adding sources from 4FGL
Extended source IC 443 in ROI with RadialGaussian spatial model.
Extended source Monoceros in ROI with RadialGaussian spatial model.
Extended source S 147 in ROI, make sure /sdf/group/fermi/g/LCRepository/Likelihood/ExtendedSources/Extended_8years/Templates/S147.fits is the correct path to the extended template.
Extended source Rosette in ROI, make sure /sdf/group/fermi/g/LCRepository/Likelihood/ExtendedSources/Extended_8years/Templates/Rosette.fits is the correct path to the extended template.
Added 166 point sources and 4 extended sources
If using unbinned likelihood you will need to rerun gtdiffrsp for the extended sources or rerun the makeModel function with optional argument psForce=True

Setting source of interest to:
4FGL J0709.1+2241 @ 107.277 22.6847

Creating the counts map:
time -p gtbin evfile=/lscratch/kocevski/18885726/ft1_filtered_4FGL_J0709.1+2241_daily_bin1815.fits scfile=/lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits outfile=/lscratch/kocevski/18885726/cmap_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits algorithm="CMAP" ebinalg="LOG" emin=30.0 emax=200000.0 ebinfile=NONE tbinalg="LIN" tbinfile=NONE nxpix=160 nypix=160 binsz=0.25 coordsys="CEL" xref=107.277 yref=22.6847 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 0.42
user 0.22
sys 0.13

Creating the high resolution counts map:
time -p gtbin evfile=/lscratch/kocevski/18885726/ft1_filtered_4FGL_J0709.1+2241_daily_bin1815.fits scfile=/lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits outfile=/lscratch/kocevski/18885726/cmap_HighResolution_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits algorithm="CMAP" ebinalg="LOG" emin=30.0 emax=200000.0 ebinfile=NONE tbinalg="LIN" tbinfile=NONE nxpix=500 nypix=500 binsz=0.1 coordsys="CEL" xref=107.277 yref=22.6847 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 0.43
user 0.23
sys 0.13

Computing the diffuse response:
time -p gtdiffrsp evfile=/lscratch/kocevski/18885726/ft1_filtered_4FGL_J0709.1+2241_daily_bin1815.fits evtable="EVENTS" scfile=/lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits sctable="SC_DATA" srcmdl=/lscratch/kocevski/18885726/Model_4FGL_J0709.1+2241_daily_bin1815.xml irfs="P8R3_SOURCE_V2" evclsmin=0 evclass="INDEF" evtype="INDEF" convert=yes chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

adding source EG_v02
adding source GAL_V02
adding source IC 443
adding source Monoceros
adding source Rosette
adding source S 147
Working on...
/lscratch/kocevski/18885726/ft1_filtered_4FGL_J0709.1+2241_daily_bin1815.fits.....................!
real 132.19
user 129.74
sys 1.31

Creating the likelihood object...
obs = UnbinnedObs('/lscratch/kocevski/18885726/ft1_filtered_4FGL_J0709.1+2241_daily_bin1815.fits', '/lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits', expMap='/lscratch/kocevski/18885726/expmap_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits', expCube='/lscratch/kocevski/18885726/ltcube_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/lscratch/kocevski/18885726/Model_4FGL_J0709.1+2241_daily_bin1815.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0709.1+2241'

4FGL J0709.1+2241
   Spectrum: PowerLaw
282    Prefactor:  3.306e+00  0.000e+00  0.000e+00  1.000e+06 ( 1.000e-13)
283        Index:  2.064e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
284        Scale:  1.716e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /lscratch/kocevski/18885726/ft1_filtered_4FGL_J0709.1+2241_daily_bin1815.fits
Spacecraft file(s): /lscratch/kocevski/18885726/ft2_4FGL_J0709.1+2241_daily_bin1815.fits
Exposure map: /lscratch/kocevski/18885726/expmap_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits
Exposure cube: /lscratch/kocevski/18885726/ltcube_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.fits
IRFs: P8R3_SOURCE_V2
Source model file: /lscratch/kocevski/18885726/Model_4FGL_J0709.1+2241_daily_bin1815.xml
Optimizer: MINUIT
Statistic: UNBINNED

Performing an iterative likelihood fit...

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 15530.3326167

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 15530.334279

Fit tolerance = 1e-08

Performing likelihood fit...
 **********
 **   14 **SET NOWARN 
 **********

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    13.445       1.0000          .0000       .10000E+07
     2 'Prefactor '    .12943E-02   1.0000          .0000       .10000E+07
     3 'norm      '    .31219E-02   1.0000          .0000       .10000E+07
     4 'Prefactor '    102.03       1.0000          .0000       .10000E+07
     5 'Prefactor '    4.2564       1.0000          .0000       .10000E+07
     6 'norm      '    18.368       1.0000          .0000       .10000E+07
     7 'norm      '    1.6368       1.0000          .0000       .10000E+07
     8 'Prefactor '    .22950       1.0000          .0000       .10000E+07
     9 'norm      '    1.6336       1.0000          .0000       .10000E+07
    10 'norm      '    12.808       1.0000          .0000       .10000E+07
    11 'norm      '    .14093E-02   1.0000          .0000       .10000E+07
    12 'Prefactor '    44.535       1.0000          .0000       .10000E+07
    13 'Prefactor '    28.547       1.0000          .0000       .10000E+07
    14 'Prefactor '    .50209       1.0000          .0000       .10000E+07
    15 'Normalizat'    .71729       1.0000         .10000E-01   10.000    
    16 'Prefactor '    1.3608       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5700E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   15530.33     FROM MIGRAD    STATUS=CONVERGED    362 CALLS     1417 TOTAL
                     EDM=   .84E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     13.336        23.386        .54783E-05   -.48477E-03
   2  Prefactor      .0000        8.0406       -.31251E-07** at limit **
   3  norm           .0000        6.0105       -.62201E-08** at limit **
   4  Prefactor     101.42        53.385       -.43724E-05   -.98333E-03
   5  Prefactor     4.2082        15.237        .13530E-05   -.84459E-03
   6  norm          18.335        16.878       -.33456E-06   -.12641E-02
   7  norm          1.6373        1.0315       -.65983E-08   -.10713E-01
   8  Prefactor     .62172E-08    3.7778       -.68294E-07** at limit **
   9  norm          1.6303        1.8121        .29910E-07   -.17963E-01
  10  norm          12.806        3.2188       -.11945E-07   -.14325E-01
  11  norm          .44409E-09    5.5001       -.53267E-07** at limit **
  12  Prefactor     44.321        50.387       -.16428E-05    .94153E-04
  13  Prefactor     28.858        28.419        .21792E-05   -.46025E-03
  14  Prefactor     .18929E-07    251.10        .96574E-05** at limit **
  15  Normalizat    .71974        .28736        .10350E-04   -.24643E-03
  16  Prefactor     1.3608        .10175       -.44992E-05    .21395E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 13.3362
  Prefactor  = 0
  norm       = 0
  Prefactor  = 101.422
  Prefactor  = 4.20821
  norm       = 18.3349
  norm       = 1.63733
  Prefactor  = 6.21725e-09
  norm       = 1.63028
  norm       = 12.8064
  norm       = 4.44089e-10
  Prefactor  = 44.3206
  Prefactor  = 28.8585
  Prefactor  = 1.89293e-08
  Normalizat = 0.719738
  Prefactor  = 1.36076
 **********
 **   18 **HESSE 
 **********

 FCN=   15530.33     FROM HESSE     STATUS=OK           207 CALLS     1624 TOTAL
                     EDM=   .19E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     13.336        23.394        .10916E-04   -1.5635    
   2  Prefactor      .0000        8.0412        .84235E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm           .0000        6.0128        .84235E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     101.42        53.226        .19801E-04   -1.5507    
   5  Prefactor     4.2082        15.161        .19525E-04   -1.5667    
   6  norm          18.335        16.824        .93367E-05   -1.5622    
   7  norm          1.6373        1.0185        .95302E-05   -1.5682    
   8  Prefactor     .62172E-08    38.408        .44438E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          1.6303        1.7860        .16633E-04   -1.5682    
  10  norm          12.806        3.2092        .53354E-04   -1.5636    
  11  norm          .44409E-09    5.5158        .84235E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     44.321        50.383        .59944E-05   -1.5575    
  13  Prefactor     28.858        28.338        .74878E-05   -1.5601    
  14  Prefactor     .18929E-07    255.16        .15700E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Normalizat    .71974        .27807        .75276E-03   -1.0312    
  16  Prefactor     1.3608        .10506        .22815E-03   -.81518    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.88899e-09
Minuit parameter uncertainties:
  1  23.3939
  2  1.8394e-05
  3  2.39493e-06
  4  53.2265
  5  15.1611
  6  16.8242
  7  1.01851
  8  0.000975562
  9  1.78599
  10  3.20919
  11  0.000101844
  12  50.3839
  13  28.3377
  14  0.00439327
  15  0.278615
  16  0.105077
Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 15530.3294065

Extracting fit parameters...

4FGL J0709.1+2241
   Spectrum: PowerLaw
282    Prefactor:  4.208e+00  1.516e+01  0.000e+00  1.000e+06 ( 1.000e-13)
283        Index:  2.064e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
284        Scale:  1.716e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
551    Prefactor:  1.361e+00  1.051e-01  0.000e+00  1.000e+01 ( 1.000e+00)
552        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
553        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
550   Normalization:  7.197e-01  2.786e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.09
Ra Dec: 107.277 22.685
Photon Flux Upper Limit: 1.30691945557e-07 ph cm-2 s-1
Energy Flux Upper Limit: 0.00985332570577 MeV cm-2 s-1

Saving results to:
/lscratch/kocevski/18885726/likelihoodResults_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.txt

Performing a free index iterative likelihood fit...

Freezing all point sources, except source of interest...

Done.

Freeing candidate source...
Done.

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 15530.3222097
delta logL = 0.00719674654465

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 15530.3209354
delta logL = 0.00847110204268

Fit tolerance = 1e-08

Performing likelihood fit...
 **********
 **   14 **SET NOWARN 
 **********

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    5.0004       1.0000          .0000       .10000E+07
     2 'Index     '    1.9071       1.0000          .0000       10.000    
     3 'Normalizat'    .72173       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.3602       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5700E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   15530.32     FROM MIGRAD    STATUS=CONVERGED     90 CALLS      262 TOTAL
                     EDM=   .17E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     4.9970        16.657        .17979E-04   -.26179E-03
   2  Index         1.9064        1.1399        .65855E-02    .35565E-04
   3  Normalizat    .72177        .24928        .75174E-03   -.59156E-03
   4  Prefactor     1.3602        .10145        .22819E-03   -.18917E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 4.99705
  Index      = 1.90643
  Normalizat = 0.721768
  Prefactor  = 1.36019
 **********
 **   18 **HESSE 
 **********

 FCN=   15530.32     FROM HESSE     STATUS=OK            23 CALLS      285 TOTAL
                     EDM=   .17E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     4.9970        16.543        .71916E-06   -1.5663    
   2  Index         1.9064        1.1322        .26342E-03   -.66710    
   3  Normalizat    .72177        .24930        .30070E-04   -1.0304    
   4  Prefactor     1.3602        .10144        .45638E-04   -.81534    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.66393e-09
Minuit parameter uncertainties:
  1  16.5432
  2  1.1485
  3  0.249695
  4  0.101459
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 15530.3209352
delta logL = 0.00847131470437

Extracting fit parameters...

4FGL J0709.1+2241
   Spectrum: PowerLaw
282    Prefactor:  4.997e+00  1.654e+01  0.000e+00  1.000e+06 ( 1.000e-13)
283        Index:  1.906e+00  1.148e+00  0.000e+00  1.000e+01 (-1.000e+00)
284        Scale:  1.716e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
551    Prefactor:  1.360e+00  1.015e-01  0.000e+00  1.000e+01 ( 1.000e+00)
552        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
553        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
550   Normalization:  7.218e-01  2.497e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.09
Ra Dec: 107.277 22.685

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /lscratch/kocevski/18885726/cmap_HighResolution_709776001_710035201_4FGL_J0709.1+2241_daily_bin1815.png

Cleaning up...

** Nuclear option initiated! **

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='9.85e-03', job_status='DONE', photon_flux_upper_limit='1.31e-07', time_completed='2023-07-10 10:17:42.096590', job_id='18885726', GAL2='1.36', fit_tolerance='1e-08', EG2='0.72', EG='0.72', time_epoch_completed='1689009462.1', return_code2='0', ts='0.09', comment='SUCCESS', return_code='0', GAL='1.36', dlogl='8.47e-03', ts2='0.11', photon_index_error='0.00', photon_index='2.06' WHERE bin_id='1815' AND source_name='4FGL J0709.1+2241' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Jul 10 10:17:42 PDT 2023

