ybsc_skyhex

Query the Yale Bright Star Catalog (YBSC) for stars that can be observed at a fixed HET structure azimuth (AZ). This is actually a faily general problem. I used this code (slightly cleaned up and debugged) in Dec2105 to conduct some "Box Test" observations with the HET. The ability to easily select appropriate stars for this exercise was fulfilled with ybsc_skyhex. Below I describe how this was done (including the use of some other unrelated scripts).


To generate track files:
%  ybsc_skyhex.sh 180 

**** NOTE: A few straight-forward interactive queries must be answered. 

To impose helpful star selection rules, and 
to specify the UT Date/Time for when you want to make the observations:
*** Use skyhex.in    (or edit slightly)

Sample skyhex.in file:
% cat skyhex.in 
48.0 59.0              ALT(min,max)    
150.0  210.0           AZ(min,max)     
0.0                    Tel_AZ offset   
-1800.0 1800.0         X_STRT(min,max) 
-1800.0 +1800.0        Y_STRT(min,max) 
10:00:00 20151220      UT,UTdate       
                       Desired mirror  
In 5-10 seconds you will have generated a set of track files (track*.xypdat) and a summary file named YBSC.list1 that lists the properties of the stars you have gathered:
 
% ls -1 
track_BSC5-3741_180.0_.xypdat
track_BSC5-3750_180.0_.xypdat
track_BSC5-3758_180.0_.xypdat
track_BSC5-3759_180.0_.xypdat
track_BSC5-3760_180.0_.xypdat
track_BSC5-3762_180.0_.xypdat
track_BSC5-3787_180.0_.xypdat
track_BSC5-3814_180.0_.xypdat
track_BSC5-3845_180.0_.xypdat   *** The one we choose!
track_BSC5-3899_180.0_.xypdat
track_BSC5-3901_180.0_.xypdat
track_BSC5-3981_180.0_.xypdat
track_BSC5-4059_180.0_.xypdat
track_BSC5-4082_180.0_.xypdat
track_BSC5-4109_180.0_.xypdat
track_BSC5-4116_180.0_.xypdat
track_BSC5-4119_180.0_.xypdat
YBSC.list1

% cat track_BSC5-3845_180.0_.xypdat 
# data 
9
Xstrt
Ystrt
Xhet
Yhet
UT_real
UT
point_color
point_type
point_size
-1471.6   540.0  -0.6792  0.2289     9.85000  09:51  green   circle       1.0000
 -924.9   466.2  -0.4277  0.1994    10.01667  10:01  red     solid-star   2.3000
 -435.3   428.1  -0.2025  0.1842    10.16667  10:10  red     solid-star   2.3000
  107.2   417.8   0.0471  0.1801    10.33333  10:20  red     solid-star   2.3000
  596.1   437.6   0.2720  0.1880    10.48333  10:29  red     solid-star   2.3000
 1140.9   491.4   0.5226  0.2095    10.65000  10:39  red     solid-star   2.3000


% cat YBSC.list1

Selection Rules: 
ALT(min,max) in degrees:         48.00    59.00
AZ(min,max) in degrees:         150.00   210.00
Tel_AZ offset in degrees:         0.00
X_STRT min,max:                -1800.0   1800.0
Y_STRT min,max:                -1800.0   1800.0

YBSC Stars selected for UT=11:00:00  20151220
Desired mirror =      

Nmirr = total number of ANY mirrors visible AFTER UT 
Nwant = number of times DESIRED MIRROR is visible (1)
Ns    = number of track points from START to UT   (2)
Ne    = number of track points from UT to END        


Special Notes:  
(1) Nwant tallies "requested mirror" hits ONLY for times
    after the request UT (i.e. not the entire track).   
(2) Ns/Ne just tells you how much track remains after UT
name         RA_2000     DEC_2000        AZ       ALT       Xmm    Ymm   U_mag    col   Tel_AZ  Nmirr  Nwant  Ns    Ne

BSC5-3741  09:26:22.30 -01:27:50.0     194.98    56.96     1778   -448    8.77   10.7    180.0    0      0      0    0
BSC5-3750  09:27:46.80 -06:04:16.0     192.73    52.52     1687    517    6.15   10.5    180.0    0      0      0    0
BSC5-3758  09:29:02.20 -01:15:25.0     193.86    57.30     1630   -523    6.65   10.4    180.0    0      0      0    0
BSC5-3759  09:29:08.90 -02:46:08.0     193.26    55.83     1621   -202    5.06   10.4    180.0    0      0      0    0
BSC5-3760  09:29:24.50 -02:12:19.0     193.34    56.39     1608   -325    6.52   10.3    180.0    0      0      0    0
BSC5-3762  09:29:32.40 -04:14:50.0     192.59    54.39     1596    109    7.50   10.3    180.0    0      0      0    0
BSC5-3787  09:31:58.90 -01:11:06.0     192.54    57.52     1467   -570    4.76   10.0    180.0    0      0     54    0
BSC5-3814  09:34:32.70 -05:54:54.0     190.04    52.96     1317    421    7.85    9.6    180.0    0      3     51    3
BSC5-3845  09:39:51.40 -01:08:34.0     188.92    57.87     1033   -648    6.69    9.0    180.0    0      8     46    8
BSC5-3899  09:51:14.00 -04:14:36.0     183.29    55.04      410    -31    6.29    7.5    180.0    0     19     34   19
BSC5-3901  09:51:21.60 -06:10:54.0     183.07    53.11      402    389    7.11    7.4    180.0    0     20     34   20
BSC5-3981  10:07:56.30 -00:22:18.0     175.57    58.89     -498   -868    4.38    5.3    180.0    0     36     18   36
BSC5-4059  10:19:32.20 -05:06:21.0     171.21    53.88    -1127    220    7.87    3.8    180.0    0     48      6   48
BSC5-4082  10:23:26.50 -04:04:27.0     169.30    54.76    -1343     28    5.70    3.3    180.0    0     52      2   52
BSC5-4109  10:28:44.00 -03:44:33.0     166.94    54.86    -1636      8    6.14    2.6    180.0    0      0      0    0
BSC5-4116  10:29:28.70 -02:44:21.0     166.27    55.80    -1679   -197    5.03    2.5    180.0    0      0      0    0
BSC5-4119  10:30:17.50 -00:38:13.0     165.09    57.81    -1728   -634    4.43    2.4    180.0    0      0      0    0
To view plots for the selected stars:
 
For a single file:
% pht.py track_BSC5-3845_180.0_.xypdat 10

The code pht.py is currently maintained in: sco/codes/python/virusP/pht.py

To view and print plots:
% ls -1 trac*data >Tlist
% pht_list Tlist

Once a source is selected for use, get the Ra,Dec from the file 
YBSC.list1, and send it to the TO with:

Recall, with negative decs:
[sco@mcs]$ newtarg 09:39:51.40 -01:08:34.0 180.0

As an aside, when we take our observations with the acm, we can always 
learn the last image taken with:
% lastim 20151220  



The HET tracker positions (X_tracker, Y_tracker in mm units) for the BSC5-3845 on 20151220 when this star is being observed at AZ=180 around 10:00UT. Each point is accompanied with a text label that gives the UT time that the star will be at this position.



Some results from my AZ=180 box test of 20151220.. I did two stars through the clouds. The green stars are the Observed tracker X,Y positions taken from the "d" dump we usually do. The red stars are the Predicted positions made with the tool "ybsc_skyhex". This tool extracted sets of track predictions for Yale Bright Star catalog targets that could be obsereved at AZ=180 aroun 10:00UT. For each star I had a plot of X,Y that gave the UT time for each point. The attached plot shows that this scheme works quite well. The predicted points agree quite well with the obsrved points. I could use the predicted UT times to estimat when i should observe each star in the box test. This procedure seemed to be smooth and easy to manage.




Back to SCO CODES page