Changeset 4800 for trunk/Ohana/src/addstar
- Timestamp:
- Aug 16, 2005, 3:04:36 PM (21 years ago)
- Location:
- trunk/Ohana/src/addstar
- Files:
-
- 5 edited
-
doc/Changes.txt (modified) (2 diffs)
-
src/find_matches.c (modified) (8 diffs)
-
src/find_matches_refstars.c (modified) (4 diffs)
-
src/replace_match.c (modified) (1 diff)
-
src/update_coords.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/addstar/doc/Changes.txt
r4772 r4800 1 2 2005.08.15:3 cleanup of the minor Wall,Werror messages4 1 5 2 2005.02.24 : I am adding the mosaic two-level astrometry information to the Image table. 6 3 7 4 2005.07.06 : current release is addstar-1.1 5 8 6 I have made a variety of fairly substantial changes since 9 7 v1.0. I have added autocode for the basic DVO data types. I … … 23 21 need to know about the mysql backend interface. 24 22 25 23 2005.08.15: 24 cleanup of the minor Wall,Werror messages -
trunk/Ohana/src/addstar/src/find_matches.c
r3389 r4800 74 74 75 75 for (i = 0; i < Nave; i++) { 76 fRD_to_XY (&X2[i], &Y2[i], catalog[0].average[i].R , catalog[0].average[i].D, &tcoords);76 fRD_to_XY (&X2[i], &Y2[i], catalog[0].average[i].R_PS, catalog[0].average[i].D_PS, &tcoords); 77 77 N2[i] = i; 78 78 catalog[0].found[N2[i]] = -1; … … 146 146 147 147 /** add measurements for this star **/ 148 catalog[0].measure[Nmeas].dR = 360000.0*(catalog[0].average[n].R - stars[N].R); 149 catalog[0].measure[Nmeas].dD = 360000.0*(catalog[0].average[n].D - stars[N].D); 148 /** dR,dD now represent arcsec **/ 149 catalog[0].measure[Nmeas].dR_PS = 3600.0*(catalog[0].average[n].R_PS - stars[N].R); 150 catalog[0].measure[Nmeas].dD_PS = 3600.0*(catalog[0].average[n].D_PS - stars[N].D); 150 151 catalog[0].measure[Nmeas].M = MIN (1000*stars[N].M + MTIME, NO_MAG); 151 152 catalog[0].measure[Nmeas].dM = MIN (1000*stars[N].dM, NO_ERR); /* error in input files stored in thousandths of mag */ … … 216 217 if (catalog[0].found[n] < 0) { 217 218 /* should the catalog star be on this image? project into image coords */ 218 if (!in_image (catalog[0].average[n].R , catalog[0].average[n].D, image)) continue;219 if (!in_image (catalog[0].average[n].R_PS, catalog[0].average[n].D_PS, image)) continue; 219 220 /* find last missing meas */ 220 221 if (catalog[0].average[n].Nn < 1) { /* no previous missing obs */ … … 234 235 } 235 236 /* calculate time of exposure for this coordinate in the image */ 236 RD_to_XY (&X, &Y, catalog[0].average[n].R , catalog[0].average[n].D, &image[0].coords);237 RD_to_XY (&X, &Y, catalog[0].average[n].R_PS, catalog[0].average[n].D_PS, &image[0].coords); 237 238 catalog[0].missing[Nmiss].t = image[0].tzero + 1e-4*Y*image[0].trate; /* trate is in 0.1 msec / row */ 238 239 catalog[0].average[n].Nn ++; … … 254 255 secz = airmass (image[0].secz, stars[N].R, stars[N].D, SiderealTime, Latitude); 255 256 256 catalog[0].average[Nave].R = stars[N].R;257 catalog[0].average[Nave].D = stars[N].D;257 catalog[0].average[Nave].R_PS = stars[N].R; 258 catalog[0].average[Nave].D_PS = stars[N].D; 258 259 catalog[0].average[Nave].M = NO_MAG; 259 260 catalog[0].average[Nave].dM = NO_MAG; … … 273 274 } 274 275 275 catalog[0].measure[Nmeas].dR = 0.0;276 catalog[0].measure[Nmeas].dD = 0.0;276 catalog[0].measure[Nmeas].dR_PS = 0.0; 277 catalog[0].measure[Nmeas].dD_PS = 0.0; 277 278 catalog[0].measure[Nmeas].M = MIN (1000*stars[N].M + MTIME, NO_MAG); 278 279 catalog[0].measure[Nmeas].dM = MIN (1000*stars[N].dM, NO_ERR); … … 298 299 for (j = 0; (j < Noverlap) && !SKIP_MISSED; j++) { 299 300 if (!FindMosaicForImage (overlap, Noverlap, j)) continue; 300 if (!in_image (catalog[0].average[Nave].R , catalog[0].average[Nave].D, &overlap[j])) continue;301 if (!in_image (catalog[0].average[Nave].R_PS, catalog[0].average[Nave].D_PS, &overlap[j])) continue; 301 302 if (catalog[0].average[Nave].Nn < 1) { 302 303 catalog[0].average[Nave].missing = Nmiss; … … 306 307 last_miss = Nmiss; 307 308 /* get time of exposure of this portion of the image */ 308 RD_to_XY (&X, &Y, catalog[0].average[Nave].R , catalog[0].average[Nave].D, &overlap[j].coords);309 RD_to_XY (&X, &Y, catalog[0].average[Nave].R_PS, catalog[0].average[Nave].D_PS, &overlap[j].coords); 309 310 catalog[0].missing[Nmiss].t = overlap[j].tzero + 1e-4*Y*overlap[j].trate; /* rough guess at time */ 310 311 catalog[0].average[Nave].Nn ++; -
trunk/Ohana/src/addstar/src/find_matches_refstars.c
r3361 r4800 62 62 63 63 for (i = 0; i < Nave; i++) { 64 fRD_to_XY (&X2[i], &Y2[i], catalog[0].average[i].R , catalog[0].average[i].D, &tcoords);64 fRD_to_XY (&X2[i], &Y2[i], catalog[0].average[i].R_PS, catalog[0].average[i].D_PS, &tcoords); 65 65 N2[i] = i; 66 66 catalog[0].found[N2[i]] = -1; … … 127 127 128 128 /** add measurements for this star **/ 129 catalog[0].measure[Nmeas].dR = 360000.0*(catalog[0].average[n].R - stars[N][0].R); 130 catalog[0].measure[Nmeas].dD = 360000.0*(catalog[0].average[n].D - stars[N][0].D); 129 /** *** dR,dD now in arcsec *** **/ 130 catalog[0].measure[Nmeas].dR_PS = 3600.0*(catalog[0].average[n].R_PS - stars[N][0].R); 131 catalog[0].measure[Nmeas].dD_PS = 3600.0*(catalog[0].average[n].D_PS - stars[N][0].D); 131 132 catalog[0].measure[Nmeas].M = MIN (1000*stars[N][0].M, NO_MAG); 132 133 catalog[0].measure[Nmeas].dM = MIN (1000*stars[N][0].dM, NO_ERR); … … 192 193 if (stars[N][0].found >= 0) continue; 193 194 194 catalog[0].average[Nave].R = stars[N][0].R;195 catalog[0].average[Nave].D = stars[N][0].D;195 catalog[0].average[Nave].R_PS = stars[N][0].R; 196 catalog[0].average[Nave].D_PS = stars[N][0].D; 196 197 catalog[0].average[Nave].M = NO_MAG; 197 198 catalog[0].average[Nave].dM = NO_MAG; … … 211 212 } 212 213 213 catalog[0].measure[Nmeas].dR = 0.0;214 catalog[0].measure[Nmeas].dD = 0.0;214 catalog[0].measure[Nmeas].dR_PS = 0.0; 215 catalog[0].measure[Nmeas].dD_PS = 0.0; 215 216 catalog[0].measure[Nmeas].M = MIN (1000*stars[N][0].M, NO_MAG); 216 217 catalog[0].measure[Nmeas].dM = MIN (1000*stars[N][0].dM, NO_ERR); -
trunk/Ohana/src/addstar/src/replace_match.c
r3376 r4800 10 10 for (i = 0; i < average[0].Nm; i++) { 11 11 if (measure[i].source != thiscode[0].code) continue; 12 measure[i].dR = 360000.0*(average[0].R- star[0].R);13 measure[i].dD = 360000.0*(average[0].D- star[0].D);12 measure[i].dR_PS = 3600.0*(average[0].R_PS - star[0].R); 13 measure[i].dD_PS = 3600.0*(average[0].D_PS - star[0].D); 14 14 measure[i].M = MIN (1000*star[0].M, NO_MAG); 15 15 measure[i].dM = MIN (1000*star[0].dM, NO_ERR); -
trunk/Ohana/src/addstar/src/update_coords.c
r3376 r4800 19 19 continue; 20 20 } 21 R = measure[m].dR ;22 D = measure[m].dD ;21 R = measure[m].dR_PS; 22 D = measure[m].dD_PS; 23 23 r += R; 24 24 d += D; … … 33 33 r = r / Npt; /* these are corrections in 1/100 arcsec to RA and DEC */ 34 34 d = d / Npt; 35 average[0].R -= r / 360000.0;36 average[0].D -= d / 360000.0;35 average[0].R_PS -= r / 3600.0; 36 average[0].D_PS -= d / 3600.0; 37 37 m = average[0].offset; /* first measurement of this star */ 38 38 for (i = 0; i < average[0].Nm; i++) { 39 measure[m].dR -= r;40 measure[m].dD -= d;39 measure[m].dR_PS -= r; 40 measure[m].dD_PS -= d; 41 41 m = next[m]; 42 42 }
Note:
See TracChangeset
for help on using the changeset viewer.
