Changeset 29295 for trunk/ippToPsps/src/ippToPspsBatchDetection.c
- Timestamp:
- Oct 1, 2010, 2:10:00 PM (16 years ago)
- File:
-
- 1 edited
-
trunk/ippToPsps/src/ippToPspsBatchDetection.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippToPsps/src/ippToPspsBatchDetection.c
r29198 r29295 11 11 #include "ippToPspsConfig.h" 12 12 #include "ippToPspsDetEnums.h" 13 #include "fitsio.h"14 15 // Gets uncalibrated instrumental flux from magnitude16 static __inline bool ippToPsps_getFlux(const float exposureTime, const float magnitude, float* flux, const float magnitudeErr, float* fluxErr) {17 18 *flux = powf(10.0, -0.4*magnitude) / exposureTime;19 if (!isfinite(*flux) || *flux < 0.000001) return false;20 if (fluxErr) *fluxErr = fabsf((magnitudeErr * *flux)/1.085736);21 // if (fluxErr) printf("Mag = %03.03f, Flux = %03.03f, Mag err = %03.03f, Flux Err = %03.03f\n", magnitude, *flux, magnitudeErr, *fluxErr);22 23 return true;24 }25 13 26 14 /** … … 37 25 int status = 0; 38 26 fitsfile *fitsIn; 39 int nKeys;40 27 41 28 if (fits_open_file(&fitsIn, this->inputFiles[0], READONLY, &status)) { … … 46 33 47 34 // get primary header and pull stuff out for later 35 int nKeys; 48 36 fits_get_hdrspace(fitsIn, &nKeys, NULL, &status); 49 37
Note:
See TracChangeset
for help on using the changeset viewer.
