# This data file describes what is known about the HRC-S geometry, and
# the UV/Ion Shields.
#
# The format of the file is very simple.  Comment lines start with a
# `#' chracter.  Blank lines are ignored.  All other lines are
# meaningful.  They contain a keyword name followed by 1 or more whitespace
# separated numbers.
#
#---------------------------------------------------------------------------
# HRC-S MCP Geometry
#---------------------------------------------------------------------------
# The HRC-S geometry is represented by the following figure:
#
#   1  \                        / 6
#       \ Left          Right  /
#        \                    /         ---- V Axis---->
#         \       Middle     /
#       2  \________*_______/ 5
#            3            4
#
# Each of the points 1-6 has two V coordinates associated with it: a
# physical V value and and active V value.  We need to specifiy a mapping
# from (u,v) coordinates to AXAF (x,y,z) coordinates.  To do this,
# we require a fiducial point to be selected from each of the MCPs.  Each 
# fiducial point will be given a (u,v) coordinate and an AXAF (x,y,z) 
# coordinate measured from the LSI coordinate origin (the nominal
# aimpoint) 

# Fiducial Points for (u,v) --> (x,y,z) --> (chipx, chipy) mappings
# The following numbers came from
# http://cxc.harvard.edu/cal/Hrc/Documents/hrcs_map.html
# (was: http://asc.harvard.edu/cal/Links/Hrc/CIP/hrcs_map.html).
# Also note that according to the JCM's coordinate memo, paper 1 table
# 5 from May 2001:
#  Left_CY = Left_V + 12.5
#  Middle_CY = Middle_V - 16459.5
#  Right_CY =  Right_V - 32929.5
# Left MCP (Chip 1)
Left_UV		560		1616
Left_XYZ	2.386		151.486		-9.567
Left_CXCY	561.0		1628.5

# Middle MCP (Chip 2)
Middle_UV	560		17060
Middle_XYZ	0		52.322		-9.567
Middle_CXCY	561.0		600.5

# Right MCP (Chip 3)
Right_UV	560		32960
Right_XYZ	0.041		-49.818		-9.567
Right_CXCY	561.0		30.5

# This value may be used to tweak the aimpoint
#Aimpoint_Offset		0.1	0.0	0.0
Aimpoint_Offset		0.0	0.0	0.0

# The angles of the left and right MCPs are given in degrees:
Left_Angle		1.4321
Right_Angle 		1.2202
Detector_Angle		-0.06987

# The following numbers come from a memo by Steve Murray regarding the 
# location of the active and physical regions:
# (These number have been updated to reflect new information from
# Steve Murray ---JED 07/12/1999)
V_Pixel_Size	0.0064294 (mm/pixel)
V_Physical	1196 16444 16884 32234 32901 48088
V_Active	1665 16404 17044 32149 32946 47036
#V_Physical	1196 16444 16900 32250 32930 48117
#V_Active	1665 16404 17060 32165 32975 47605

U_Pixel_Size	0.0064294 (mm/pixel)
U_Physical	0	4096
U_Active	560	3536


#---------------------------------------------------------------------------
#  UV/Ion Shield Geometry
#---------------------------------------------------------------------------
#
#  The UV/Ion Shield Geometry is specified by the following figure:
#
#   +-----------------+ +-------------------+ +-------------------+
#   |      2          | |         0         | |      2            |
#   +-----------------+ +-----+        +----+ +-------------------+  ^
#   |                 | |     |        |    | |                   |  +- T
#   |        +        | |     |   @    |    | |         +         |  v
#   |                 | |     |        |    | |                   |
#   |     3           | | 1   |        | 1  | |       3           |
#   |                 | |     |        |    | |                   |
#   +-----------------+ +-----+--------+----+ +-------------------+
#                             <-L-><-R->
#                       <---SL----><---SR-->
#                   --> <-- GapL          -->  <-- GapR
#
# In this figure, `@' marks the centerline of the detector.  The AXAF +Y
# axis runs to the right and the +Z coordinate runs up.
#
# In the following, `Ion_Shield_' will be used as a prefix for the
# above dimensions.  All units are mm.

# Question: How accurate are these numbers??

Ion_Shield_T		 4.0000
Ion_Shield_L		19.7000
Ion_Shield_R		11.7000
Ion_Shield_SL		50.2158
Ion_Shield_SR		50.2158
Ion_Shield_GapL		 1.4732
Ion_Shield_GapR		 1.4732

# The center of the Ion Shield offset from MCP (mm)

Ion_Shield_X		12.33

#---------------------------------------------------------------------------
#
#From jcm@urania.harvard.edu  Tue Feb  9 15:30:48 1999
#Date: Tue, 9 Feb 1999 15:30:41 -0500 (EST)
#From: Jonathan McDowell <jcm@head-cfa.harvard.edu>
#To: davis
#Subject: HRC revised
#
#
#HRC-S ISSUES FOR MARX  (Updated 1999 Feb 1)
#
#Here's our new plan for Level 1 coordinates:
#
#
#Reference positions on the chips, for J. Davis to match with MARX:
#
#Reference positions for Mike Juda's U and V values:
#
#CHIP    U,V          CHIPX, CHIPY       LSIX, LSIY, LSIZ
#
#1       560, 1616     561.0,  1628.5     2.382, 151.485, -9.567
#1      3536, 1616    3537.0,  1628.5     2.382, 151.485,  9.567
#1      3536, 16384   3537.0, 16396.5     0.010,  56.566,  9.567
#1       560, 16384    561.0, 16396.5     0.010,  56.566, -9.567
#
#2       560, 17060    561.0,   600.1   0.0,  52.325, -9.567
#2      3536, 17060   3537.0,   600.1   0.0,  52.325,  9.567
#2      2048, 25197.5 2048.5,  8738.0   0.0,    0.0,    0.0
#2      3536, 32165   3537.0, 15705.1   0.0,  -44.791,  9.567
#2       560, 32165    561.0, 15705.1   0.0,  -44.791, -9.567
#
#3       560, 32960    561.0,    30.5    0.004, -49.815, -9.567
#3      3536, 32960   3537.0,    30.5    0.004, -49.815,  9.567
#3      3536, 47632   3537.0, 14702.5    2.013, -144.126,  9.567
#3       560, 47632    561.0, 14702.5    2.013, -144.126, -9.567

