Changeset 4143
- Timestamp:
- Jun 7, 2005, 2:26:01 PM (21 years ago)
- Location:
- trunk/psLib
- Files:
-
- 19 deleted
- 4 edited
-
src/astronomy/Makefile.am (modified) (2 diffs)
-
src/astronomy/airmas.f (deleted)
-
src/astronomy/aoppa.f (deleted)
-
src/astronomy/aoppat.f (deleted)
-
src/astronomy/aopqk.f (deleted)
-
src/astronomy/atms.f (deleted)
-
src/astronomy/atmt.f (deleted)
-
src/astronomy/dcc2s.f (deleted)
-
src/astronomy/dcs2c.f (deleted)
-
src/astronomy/drange.f (deleted)
-
src/astronomy/dranrm.f (deleted)
-
src/astronomy/eqeqx.f (deleted)
-
src/astronomy/geoc.f (deleted)
-
src/astronomy/gmst.f (deleted)
-
src/astronomy/nutc.f (deleted)
-
src/astronomy/oapqk.f (deleted)
-
src/astronomy/psAstrometry.c (modified) (7 diffs)
-
src/astronomy/psAstrometry.h (modified) (2 diffs)
-
src/astronomy/refco.f (deleted)
-
src/astronomy/refro.f (deleted)
-
src/astronomy/refz.f (deleted)
-
src/astronomy/slalib.h (deleted)
-
test/astronomy/tst_psAstrometry01.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/astronomy/Makefile.am
r3938 r4143 15 15 psTime.c \ 16 16 psCoord.c \ 17 psAstrometry.c \ 18 aoppa.f aopqk.f oapqk.f airmas.f eqeqx.f geoc.f refco.f aoppat.f \ 19 dranrm.f dcs2c.f refz.f refro.f dcc2s.f gmst.f atms.f atmt.f nutc.f drange.f 17 psAstrometry.c 20 18 21 19 BUILT_SOURCES = psAstronomyErrors.h … … 31 29 psCoord.h \ 32 30 psAstrometry.h \ 33 psPhotometry.h \ 34 slalib.h 31 psPhotometry.h 35 32 -
trunk/psLib/src/astronomy/psAstrometry.c
r4051 r4143 8 8 * @author GLG, MHPCC 9 9 * 10 * @version $Revision: 1.6 7$ $Name: not supported by cvs2svn $11 * @date $Date: 2005-0 5-31 21:47:46$10 * @version $Revision: 1.68 $ $Name: not supported by cvs2svn $ 11 * @date $Date: 2005-06-08 00:26:01 $ 12 12 * 13 13 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 29 29 #include "psTrace.h" 30 30 #include "psLogMsg.h" 31 32 #include "slalib.h"33 31 34 32 /***************************************************************************** … … 233 231 *(float *)&exp->positionAngle = 0.0f; // XXX: need input, see Bug #207 234 232 *(float *)&exp->parallacticAngle = 0.0f; // XXX: need input, see Bug #207 235 *(float *)&exp->airmass = slaAirmas(zenithDistance);233 *(float *)&exp->airmass = 0.0f; // XXX: needs calculation! = slaAirmas(zenithDistance); 236 234 *(float *)&exp->parallacticFactor = 0.0f; 237 235 exp->cameraName = NULL; … … 408 406 PS_ASSERT_PTR_NON_NULL(exp, NULL); 409 407 410 double date = psTimeToMJD(exp->time);411 double dut = psTimeGetUT1Delta(exp->time,PS_IERS_A);412 double elongm = exp->observatory->longitude;413 double phim = exp->observatory->latitude;414 double hm = exp->observatory->height;415 416 408 psSphere* polarMotion = p_psTimeGetPoleCoords(exp->time); 417 double xp = polarMotion->r; 418 double yp = polarMotion->d; 409 410 psGrommit* grommit = (psGrommit* ) psAlloc(sizeof(psGrommit)); 411 412 *(double*)&grommit->latitude = exp->observatory->latitude; 413 *(double*)&grommit->longitude = exp->observatory->longitude; 414 *(double*)&grommit->height = exp->observatory->height; 415 *(double*)&grommit->abberationMag = 0.0; // XXX: need to figure out what to set here. 416 *(double*)&grommit->temperature = exp->temperature; 417 *(double*)&grommit->pressure = exp->pressure; 418 *(double*)&grommit->humidity = exp->humidity; 419 *(double*)&grommit->wavelength = exp->wavelength; 420 *(double*)&grommit->lapseRate = exp->observatory->tlr; 421 *(double*)&grommit->refractA = polarMotion->r; // XXX: need to figure out what to set here too. 422 *(double*)&grommit->refractB = polarMotion->d; // XXX: need to figure out what to set here too. 423 *(double*)&grommit->siderealTime = psTimeToMJD(exp->time); // XXX: this is probably not correct 424 419 425 psFree(polarMotion); 420 421 double tdk = exp->temperature;422 double pmb = exp->pressure;423 double rh = exp->humidity;424 double wl = exp->wavelength;425 double tlr = exp->observatory->tlr;426 427 psGrommit* grommit = (psGrommit* ) psAlloc(sizeof(psGrommit));428 429 slaAoppa(date, dut, elongm, phim, hm, xp, yp,430 tdk, pmb, rh, wl, tlr, (double*)grommit);431 426 432 427 return (grommit); … … 579 574 PS_ASSERT_PTR_NON_NULL(grommit, NULL); 580 575 581 double AOB = 0.0;582 double ZOB = 0.0;583 double HOB = 0.0;584 576 if (outSphere == NULL) { 585 577 outSphere = (psSphere* ) psAlloc(sizeof(psSphere)); 586 578 } 587 579 588 slaAopqk(tpCoord->x, tpCoord->y, (double*)grommit, 589 &AOB, &ZOB, &HOB, &outSphere->r, &outSphere->d); 580 // XXX: this was done by a SLALIB call -- needs to be reimplemented 581 psWarning("Warning! psCoordTPToSky functionality is no longer implemented"); 582 /* slaAopqk(tpCoord->x, tpCoord->y, (double*)grommit, 583 &AOB, &ZOB, &HOB, &outSphere->r, &outSphere->d); */ 590 584 591 585 return (outSphere); … … 693 687 PS_ASSERT_PTR_NON_NULL(grommit, NULL); 694 688 695 char* type = "RA";689 // char* type = "RA"; 696 690 697 691 if (tpCoord == NULL) { … … 699 693 } 700 694 701 slaOapqk(type, in->r, in->d, (double*)grommit, &tpCoord->x, &tpCoord->y); 695 // XXX: this was done by a SLALIB call -- needs to be reimplemented 696 psWarning("Warning! psCoordSkyToTP functionality is no longer implemented"); 697 /* slaOapqk(type, in->r, in->d, (double*)grommit, &tpCoord->x, &tpCoord->y); */ 702 698 703 699 return(tpCoord); -
trunk/psLib/src/astronomy/psAstrometry.h
r3598 r4143 8 8 * @author GLG, MHPCC 9 9 * 10 * @version $Revision: 1. 39$ $Name: not supported by cvs2svn $11 * @date $Date: 2005-0 3-31 23:01:46$10 * @version $Revision: 1.40 $ $Name: not supported by cvs2svn $ 11 * @date $Date: 2005-06-08 00:26:01 $ 12 12 * 13 13 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 44 44 typedef struct 45 45 { 46 const double latitude; ///< geodetic latitude (radians) 47 const double sinLat; ///< sine of geodetic latitude 48 const double cosLat; ///< cosine of geodetic latitude 49 const double abberationMag; ///< magnitude of diurnal aberration vector 50 const double height; ///< height (HM) 51 const double temperature; ///< ambient temperature (TDK) 52 const double pressure; ///< pressure (PMB) 53 const double humidity; ///< relative humidity (RH) 54 const double wavelength; ///< wavelength (WL) 55 const double lapseRate; ///< lapse rate (TLR) 56 const double refractA; ///< refraction constant A (radians) 57 const double refractB; ///< refraction constant B (radians) 58 const double longitudeOffset; ///< longitude + ... (radians) 59 const double siderealTime; ///< local apparent sidereal time (radians) 46 const double latitude; ///< geodetic latitude (radians) 47 const double longitude; ///< longitude + ... (radians) 48 const double height; ///< height (HM) 49 const double abberationMag; ///< magnitude of diurnal aberration vector 50 const double temperature; ///< ambient temperature (TDK) 51 const double pressure; ///< pressure (PMB) 52 const double humidity; ///< relative humidity (RH) 53 const double wavelength; ///< wavelength (WL) 54 const double lapseRate; ///< lapse rate (TLR) 55 const double refractA, refractB; ///< refraction constants A and B (radians) 56 const double siderealTime; ///< local apparent sidereal time (radians) 60 57 } 61 58 psGrommit; -
trunk/psLib/test/astronomy/tst_psAstrometry01.c
r3993 r4143 5 5 * @author GLG, MHPCC 6 6 * 7 * @version $Revision: 1. 29$ $Name: not supported by cvs2svn $8 * @date $Date: 2005-0 5-20 00:44:12$7 * @version $Revision: 1.30 $ $Name: not supported by cvs2svn $ 8 * @date $Date: 2005-06-08 00:26:01 $ 9 9 * 10 10 * XXX: Must test … … 381 381 382 382 printf("grom->latitude is %.2f\n", grom->latitude); 383 printf("grom-> sinLat is %.2f\n", grom->sinLat);384 printf("grom-> cosLat is %.2f\n", grom->cosLat);383 printf("grom->longitude is %.2f\n", grom->longitude); 384 printf("grom->height is %.2f\n", grom->height); 385 385 printf("grom->abberationMag is %.2f\n", grom->abberationMag); 386 printf("grom->height is %.2f\n", grom->height);387 386 printf("grom->temperature is %.2f\n", grom->temperature); 388 387 printf("grom->pressure is %.2f\n", grom->pressure); … … 392 391 printf("grom->refractA is %.2f\n", grom->refractA); 393 392 printf("grom->refractB is %.2f\n", grom->refractB); 394 printf("grom->longitudeOffset is %.2f\n", grom->longitudeOffset); 393 395 394 // printf("grom->siderealTime is %.2f\n", grom->siderealTime); 396 395
Note:
See TracChangeset
for help on using the changeset viewer.
