View Javadoc
1   package nom.tam.fits.header;
2   
3   /*-
4    * #%L
5    * nom.tam.fits
6    * %%
7    * Copyright (C) 1996 - 2024 nom-tam-fits
8    * %%
9    * This is free and unencumbered software released into the public domain.
10   * 
11   * Anyone is free to copy, modify, publish, use, compile, sell, or
12   * distribute this software, either in source code form or as a compiled
13   * binary, for any purpose, commercial or non-commercial, and by any
14   * means.
15   * 
16   * In jurisdictions that recognize copyright laws, the author or authors
17   * of this software dedicate any and all copyright interest in the
18   * software to the public domain. We make this dedication for the benefit
19   * of the public at large and to the detriment of our heirs and
20   * successors. We intend this dedication to be an overt act of
21   * relinquishment in perpetuity of all present and future rights to this
22   * software under copyright law.
23   * 
24   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
25   * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
26   * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
27   * IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
28   * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
29   * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
30   * OTHER DEALINGS IN THE SOFTWARE.
31   * #L%
32   */
33  
34  /**
35   * Standard FITS keywords for defining world coordinate systems (WCS). Many (but not all) keywords listed here support
36   * alternative coordinate systems. These have a lower case 'a' at the end of their enum names, e.g.
37   * <code>WCSNAMEa</code>. The alternative coordinate system for these can be set via the {@link #alt(char)} method.
38   * 
39   * @author Attila Kovacs
40   * 
41   * @see    DateTime
42   * 
43   * @since  1.19
44   */
45  public enum WCS implements IFitsHeader {
46  
47      /**
48       * World coordinate system name
49       * 
50       * @since 1.19
51       */
52      WCSNAMEa(SOURCE.RESERVED, HDU.IMAGE, VALUE.STRING, "coordinate system name"),
53  
54      /**
55       * Dimensionality of image coordinate system
56       * 
57       * @since 1.19
58       */
59      WCSAXESa(SOURCE.RESERVED, HDU.IMAGE, VALUE.INTEGER, "coordinate dimensions"),
60  
61      /**
62       * Coordinate reference frame of major/minor axes.If absent the default value is 'FK5'.
63       * 
64       * @since 1.19
65       */
66      RADESYSa(SOURCE.RESERVED, HDU.IMAGE, VALUE.STRING, "celestial coordinate reference frame."),
67  
68      /**
69       * Coordinate reference frame of major/minor axes (generic).
70       *
71       * @deprecated Deprecated in the current FITS standard, use {@link #RADESYSa} instead.
72       */
73      @Deprecated
74      RADECSYS(SOURCE.RESERVED, HDU.ANY, VALUE.STRING, "celestial coordinate reference frame."),
75  
76      /**
77       * [deg] The longitude of the celestial pole (for spherical coordinates).
78       * 
79       * @since 1.19
80       */
81      LONPOLEa(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "[deg] celestial pole longitude"),
82  
83      /**
84       * [deg] The latitude of the celestial pole (for spherical coordinates).
85       * 
86       * @since 1.19
87       */
88      LATPOLEa(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "[deg] celestial pole latitude"),
89  
90      /**
91       * The value field shall contain a floating point number giving the equinox in years for the celestial coordinate
92       * system in which positions are expressed. Starting with Version 1, the Standard has deprecated the use of the
93       * EPOCH keyword and thus it shall not be used in FITS files created after the adoption of the standard; rather, the
94       * EQUINOX keyword shall be used.
95       *
96       * @deprecated Deprecated in the current FITS standard, use {@link #EQUINOXa} instead.
97       */
98      @Deprecated
99      EPOCH(SOURCE.RESERVED, HDU.ANY, VALUE.REAL, "[yr] equinox of celestial coordinate system"),
100 
101     /**
102      * The value field shall contain a floating point number giving the equinox in years for the celestial coordinate
103      * system in which positions are expressed.
104      * 
105      * @since 1.19
106      */
107     EQUINOXa(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "[yr] equinox of celestial coordinate system"),
108 
109     /**
110      * Coordinate axis name.
111      * 
112      * @since 1.19
113      */
114     CNAMEna(SOURCE.RESERVED, HDU.IMAGE, VALUE.STRING, "coordinate system display name"),
115 
116     /**
117      * The value field shall contain a floating point number, identifying the location of a reference point along axis
118      * n, in units of the axis index. This value is based upon a counter that runs from 1 to NAXISn with an increment of
119      * 1 per pixel. The reference point value need not be that for the center of a pixel nor lie within the actual data
120      * array. Use comments to indicate the location of the index point relative to the pixel.
121      * 
122      * @since 1.19
123      */
124     CRPIXna(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "coordinate axis reference pixel"),
125 
126     /**
127      * The value field shall contain a floating point number, giving the value of the coordinate specified by the CTYPEn
128      * keyword at the reference point CRPIXn. Units must follow the prescriptions of section 5.3 of the FITS Standard.
129      * 
130      * @since 1.19
131      */
132     CRVALna(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "coordinate axis value at reference pixel"),
133 
134     /**
135      * The value field shall contain a character string, giving the name of the coordinate represented by axis n.
136      * 
137      * @since 1.19
138      */
139     CTYPEna(SOURCE.RESERVED, HDU.IMAGE, VALUE.STRING, "name of the coordinate axis"),
140 
141     /**
142      * The value field shall contain a floating point number giving the partial derivative of the coordinate specified
143      * by the CTYPEn keywords with respect to the pixel index, evaluated at the reference point CRPIXn, in units of the
144      * coordinate specified by the CTYPEn keyword. These units must follow the prescriptions of section 5.3 of the FITS
145      * Standard.
146      * 
147      * @since 1.19
148      */
149     CDELTna(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "coordinate spacing along axis"),
150 
151     /**
152      * Random coordinate error on axis <i>n</i> in the physical coordinate unit (if defined).
153      * 
154      * @since 1.19
155      */
156     CRDERna(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "random error in coordinate"),
157 
158     /**
159      * Systematic coordinate error on axis <i>n</i> in the physical coordinate unit (if defined).
160      * 
161      * @since 1.19
162      */
163     CSYERna(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "systematic error in coordinate"),
164 
165     /**
166      * Phase axis zero point
167      * 
168      * @since 1.19
169      */
170     CZPHSna(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "phase axis zero point"),
171 
172     /**
173      * Phase axis period
174      */
175     CPERIna(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "phase axis period"),
176 
177     /**
178      * [Hz] Rest frequency of observed spectral line.
179      * 
180      * @since 1.19
181      */
182     RESTFRQa(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "[Hz] line rest frequency"),
183 
184     /**
185      * [Hz] Rest frequeny of observed spectral line (generic).
186      *
187      * @deprecated Deprecated in the current FITS standard, use {@link #RESTFRQa} instead.
188      */
189     @Deprecated
190     RESTFREQ(SOURCE.RESERVED, HDU.ANY, VALUE.REAL, "[Hz] observed line rest frequency"),
191 
192     /**
193      * [m] Rest wavelength of observed spectral line in image.
194      * 
195      * @since 1.19
196      */
197     RESTWAVa(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "[m] line rest wavelength"),
198 
199     /**
200      * Image spectral reference system name.
201      * 
202      * @since 1.19
203      */
204     SPECSYSa(SOURCE.RESERVED, HDU.IMAGE, VALUE.STRING, "spectral reference frame"),
205 
206     /**
207      * Image spectral reference system name of observer.
208      * 
209      * @since 1.19
210      */
211     SSYSOBSa(SOURCE.RESERVED, HDU.IMAGE, VALUE.STRING, "spectral reference frame of observer"),
212 
213     /**
214      * Spectral reference system name of source.
215      * 
216      * @since 1.19
217      */
218     SSYSSRCa(SOURCE.RESERVED, HDU.IMAGE, VALUE.STRING, "spectral reference frame of source"),
219 
220     /**
221      * [m/s] Radial velocity of source in the spectral reference frame.
222      * 
223      * @since 1.19
224      */
225     VELOSYSa(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "[m/s] source radial velocity"),
226 
227     /**
228      * Redshift value of source in the spectral reference frame.
229      * 
230      * @since 1.19
231      */
232     ZSOURCEa(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "source redshift value"),
233 
234     /**
235      * [deg] True velocity angle of source
236      * 
237      * @since 1.19
238      */
239     VELANGLa(SOURCE.RESERVED, HDU.IMAGE, VALUE.REAL, "[deg] true velocity angle"),
240 
241     /**
242      * [m] Geodetic location of observer (<i>x</i> coordinate).
243      * 
244      * @since 1.19
245      */
246     OBSGEO_X("OBSGEO-X", SOURCE.RESERVED, HDU.ANY, VALUE.REAL, "[m] geodetic location x of observer"),
247 
248     /**
249      * [m] Geodetic location of observer (<i>y</i> coordinate).
250      * 
251      * @since 1.19
252      */
253     OBSGEO_Y("OBSGEO-Y", SOURCE.RESERVED, HDU.ANY, VALUE.REAL, "[m] geodetic location y of observer"),
254 
255     /**
256      * [m] Geodetic location of observer (<i>z</i> coordinate).
257      * 
258      * @since 1.19
259      */
260     OBSGEO_Z("OBSGEO-Z", SOURCE.RESERVED, HDU.ANY, VALUE.REAL, "[m] geodetic location z of observer"),
261 
262     /**
263      * WCS name for the array entries in the given column index.
264      * 
265      * @since 1.19
266      */
267     WCSNna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column coordinate syste name"),
268 
269     /**
270      * [deg] The longitude of the celestial pole for the entries in the given column index (for spherical coordinates).
271      * 
272      * @since 1.19
273      */
274     LONPna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[deg] column celestial pole longitude"),
275 
276     /**
277      * [deg] The latitude of the celestial pole for the entries in the given column index (for spherical coordinates).
278      * 
279      * @since 1.19
280      */
281     LATPna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[deg] column celestial pole latitude"),
282 
283     /**
284      * [yr] Coordinate epoch for which the celestial coorinate system is defined for the given column index.
285      * 
286      * @since 1.19
287      */
288     EQUIna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[yr] column coordinate epoch"),
289 
290     /**
291      * The equatorial coordinate frame used for the given column index, e.g. 'FK4', 'FK5', or 'ICRS'.
292      * 
293      * @since 1.19
294      */
295     RADEna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column equatorial coordinate frame"),
296 
297     /**
298      * [Hz] The rest frequency of the line in the given column index.
299      * 
300      * @since 1.19
301      */
302     RFRQna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[Hz] line rest frequency in column"),
303 
304     /**
305      * [Hz] The rest wavelength of the line in the given column index.
306      * 
307      * @since 1.19
308      */
309     RWAVna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[m] line rest wavelength in column"),
310 
311     /**
312      * Spectral reference frame for the given column index.
313      * 
314      * @since 1.19
315      */
316     SPECna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column spectral reference frame"),
317 
318     /**
319      * Spectral reference system of observer for the given column index.
320      * 
321      * @since 1.19
322      */
323     SOBSna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column observer spectral frame"),
324 
325     /**
326      * Spectral reference system of source for the given column index.
327      * 
328      * @since 1.19
329      */
330     SSRCna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column source spectral frame"),
331 
332     /**
333      * [m/s] Source radial velocity for the given column index.
334      * 
335      * @since 1.19
336      */
337     VSYSna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[m/s] column radial velocity"),
338 
339     /**
340      * [deg] Angle of true velocity for the given column index.
341      * 
342      * @since 1.19
343      */
344     VANGna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[deg] angle of velocity in column"),
345 
346     /**
347      * Source redshift value for the given column index.
348      * 
349      * @since 1.19
350      */
351     ZSOUna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column redshift value"),
352 
353     /**
354      * [m] Geodetic location (<i>x</i> coordinate) of observer for he given column index.
355      * 
356      * @since 1.19
357      */
358     OBSGXn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[m] column geodetic location x"),
359 
360     /**
361      * [m] Geodetic location (<i>y</i> coordinate) of observer for he given column index.
362      * 
363      * @since 1.19
364      */
365     OBSGYn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[m] column geodetic location y"),
366 
367     /**
368      * [m] Geodetic location (<i>z</i> coordinate) of observer for he given column index.
369      * 
370      * @since 1.19
371      */
372     OBSGZn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[m] column geodetic location z"),
373 
374     /**
375      * The coordinate axis type for array entries in this column (trailing index). The number of coordinate axes
376      * (leading index) defined this way should match the dimensionality of the array elements in the column. This
377      * version does not support alternative coordinates systems.
378      * 
379      * @see   #nCTYna
380      * 
381      * @since 1.19
382      */
383     nCTYPn(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column coordinate axis type"),
384 
385     /**
386      * The coordinate axis type for array entries in this column (trailing index). The number of coordinate axes
387      * (leading index) defined this way should match the dimensionality of the array elements in the column. This
388      * version supports alternative coordinates systems.
389      * 
390      * @see   #nCTYPn
391      * 
392      * @since 1.19
393      */
394     nCTYna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column coordinate axis type"),
395 
396     /**
397      * The coordinate axis name for array entries in this column (trailing index). The number of coordinate axes
398      * (leading index) defined this way should match the dimensionality of the array elements in the column.
399      * 
400      * @since 1.19
401      */
402     nCNAna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column coordinate axis type"),
403 
404     /**
405      * The physical coordinate unit for array entries in this column (trailing index). The number of coordinate axes
406      * (leading index) defined this way should match the dimensionality of the array elements in the column. This
407      * version does not support alternative coordinates systems.
408      * 
409      * @see   #nCUNna
410      * 
411      * @since 1.19
412      */
413     nCUNIn(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column coordinate axis unit"),
414 
415     /**
416      * The physical coordinate unit for array entries in this column (trailing index). The number of coordinate axes
417      * (leading index) defined this way should match the dimensionality of the array elements in the column. This
418      * version supports alternative coordinates systems.
419      * 
420      * @see   #nCUNIn
421      * 
422      * @since 1.19
423      */
424     nCUNna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column coordinate axis unit"),
425 
426     /**
427      * The coordinate reference value in the physical unit of the axis (if defined) for array entries in this column
428      * (trailing index). The number of coordinate axes (leading index) defined this way should match the dimensionality
429      * of the array elements in the column. This version does not support alternative coordinates systems.
430      * 
431      * @see   #nCRVna
432      * 
433      * @since 1.19
434      */
435     nCRVLn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coordinate axis reference value"),
436 
437     /**
438      * The coordinate reference value in the physical unit of the axis (if defined) for array entries in this column
439      * (trailing index). The number of coordinate axes (leading index) defined this way should match the dimensionality
440      * of the array elements in the column. This version supports alternative coordinates systems.
441      * 
442      * @see   #nCRVLn
443      * 
444      * @since 1.19
445      */
446     nCRVna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coordinate axis reference value"),
447 
448     /**
449      * The coordinate axis random error in the physical unit of the axis (if defined) for array entries in this column
450      * (trailing index). The number of coordinate axes (leading index) defined this way should match the dimensionality
451      * of the array elements in the column.
452      * 
453      * @since 1.19
454      */
455     nCRDna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coordinate axis random error"),
456 
457     /**
458      * The coordinate axis systematic error in the physical unit of the axis (if defined) for array entries in this
459      * column (trailing index). The number of coordinate axes (leading index) defined this way should match the
460      * dimensionality of the array elements in the column.
461      * 
462      * @since 1.19
463      */
464     nCSYna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coordinate axis systematic error"),
465 
466     /**
467      * Phase axis zero point on axis (leading index) for array entries in this column (trailing index)
468      * 
469      * @since 1.19
470      */
471     nCZPna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "phase axis zero point"),
472 
473     /**
474      * Phase axis period on axis (leading index) for array entries in this column (trailing index)
475      * 
476      * @since 1.19
477      */
478     nCPRna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "phase axis period"),
479 
480     /**
481      * The coordinate axis spacing in the physical unit of the axis (if defined) for array entries in this column
482      * (trailing index). The number of coordinate axes (leading index) defined this way should match the dimensionality
483      * of the array elements in the column. This version does not support alternative coordinates systems.
484      * 
485      * @see   #nCDEna
486      * 
487      * @since 1.19
488      */
489     nCDLTn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coordinate axis spacing"),
490 
491     /**
492      * The coordinate axis spacing in the physical unit of the axis (if defined) for array entries in this column
493      * (trailing index). The number of coordinate axes (leading index) defined this way should match the dimensionality
494      * of the array elements in the column. This version supports alternative coordinates systems.
495      * 
496      * @see   #nCDLTn
497      * 
498      * @since 1.19
499      */
500     nCDEna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coordinate axis spacing"),
501 
502     /**
503      * The 1-based coordinate reference pixel index in the physical unit of the axis (if defined) for array entries in
504      * this column (trailing index). The number of coordinate axes (leading index) defined this way should match the
505      * dimensionality of the array elements in the column. This version does not support alternative coordinates
506      * systems.
507      * 
508      * @see   #nCRPna
509      * 
510      * @since 1.19
511      */
512     nCRPXn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coordinate axis reference pixel"),
513 
514     /**
515      * The 1-based coordinate reference pixel index in the physical unit of the axis (if defined) for array entries in
516      * this column (trailing index). The number of coordinate axes (leading index) defined this way should match the
517      * dimensionality of the array elements in the column. This version supports alternative coordinates systems.
518      * 
519      * @see   #nCRPXn
520      * 
521      * @since 1.19
522      */
523     nCRPna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coordinate axis reference pixel"),
524 
525     /**
526      * @deprecated The FITS standard deprecated this keyword. Use {@link WCS#nnPCna} and {@link WCS#nnCDna}instead.
527      *                 [deg] The coordinate axis rotation in the physical unit of the axis (if defined) for array
528      *                 entries in this column (trailing index). The number of coordinate axes (leading index) defined
529      *                 this way should match the dimensionality of the array elements in the column.
530      * 
531      * @since      1.19
532      */
533     @Deprecated
534     nCROTn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[deg] column coordinate axis rotation"),
535 
536     /**
537      * Coordinate transformation matrix in the PC convention. from rectilinear coordinate index <i>i</i> (leading index)
538      * to coordinate index <i>j</i> (second index) for the for array entries in this column (trailing index). The number
539      * of coordinate axes (leading index) defined this way should match the dimensionality of the array elements in the
540      * column.
541      * 
542      * @since 1.19
543      */
544     nnPCna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coord. trans. matrix element"),
545 
546     /**
547      * Coordinate transformation matrix in the CD convention. from rectilinear coordinate index <i>i</i> (leading index)
548      * to coordinate index <i>j</i> (second index) for the for array entries in this column (trailing index). The number
549      * of coordinate axes (leading index) defined this way should match the dimensionality of the array elements in the
550      * column.
551      * 
552      * @since 1.19
553      */
554     nnCDna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column coord. trans. matrix element"),
555 
556     /**
557      * The coordinate string parameter <i>m</i> (trailing index) for axis <i>i</i> (leading index) for array entries in
558      * this column (middle index). The number of coordinate axes (leading index) defined this way should match the
559      * dimensionality of the array elements in the column. The shorter {@link #nSn_na} form may be required for column
560      * indices &gt;99 with alternate coordinate systems.
561      * 
562      * @since 1.19
563      */
564     nPSn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column axis parameter name"),
565 
566     /**
567      * The coordinate string parameter <i>m</i> (trailing index) for axis <i>i</i> (leading index) for array entries in
568      * this column (middle index). The number of coordinate axes (leading index) defined this way should match the
569      * dimensionality of the array elements in the column. Same as {@link #nPSn_na}. This shorter form may be required
570      * for column indices &gt;99 with alternate coordinate systems.
571      * 
572      * @since 1.19
573      */
574     nSn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column axis parameter name"),
575 
576     /**
577      * The coordinate parameter value <i>m</i> (trailing index) for axis <i>i</i> (leading index) for array entries in
578      * this column (middle index). The number of coordinateaxes defined this way should match the dimensionality of the
579      * array elements in the column. The shorter {@link #nVn_na} form may be required for column indices &gt;99 with
580      * alternate coordinate systems.
581      * 
582      * @since 1.19
583      */
584     nPVn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column axis parameter value"),
585 
586     /**
587      * The coordinate parameter value <i>m</i> (trailing index) for axis <i>i</i> (leading index) for array entries in
588      * this column (middle index). The number of coordinateaxes defined this way should match the dimensionality of the
589      * array elements in the column. Same as {@link #nPVn_na}. This shorter form may be required for column indices
590      * &gt;99 with alternate coordinate systems.
591      * 
592      * @since 1.19
593      */
594     nVn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column axis parameter value"),
595 
596     /**
597      * The coordinate parameter array for axis <i>i</i> (leading index) in this column (middle index). The number of
598      * coordinate axes defined this way should match the dimensionality of the array elements in the column.
599      * 
600      * @since 1.19
601      */
602     nVn_Xa(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column parameter array"),
603 
604     /**
605      * WCS name for the pixe list entries in the given column index. Same as {@link #TWCSna}. This shorter form may be
606      * required for column indices &gt;99 with alternate coordinate systems.
607      * 
608      * @since 1.19
609      */
610     WCSna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column WCS name"),
611 
612     /**
613      * WCS name for the pixe list entries in the given column index. The shorter form {@link #WCSna} may be required for
614      * column indices &gt;99 with alternate coordinate systems.
615      * 
616      * @since 1.19
617      */
618     TWCSna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column WCS name"),
619 
620     /**
621      * WCS dimensions for given column index.
622      * 
623      * @since 1.19
624      */
625     WCAXna(SOURCE.RESERVED, HDU.TABLE, VALUE.INTEGER, "column coordinate dimensions"),
626 
627     /**
628      * The coordinate axis type for (1D) pixel lists in this column (trailing index). This version does not support
629      * alternative coordinates systems.
630      * 
631      * @see   #TCTYna
632      * 
633      * @since 1.19
634      */
635     TCTYPn(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column pixel axis type"),
636 
637     /**
638      * The coordinate axis type for (1D) pixel lists in this column (trailing index). This version supports alternative
639      * coordinates systems.
640      * 
641      * @see   #TCTYPn
642      * 
643      * @since 1.19
644      */
645     TCTYna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column pixel axis type"),
646 
647     /**
648      * The coordinate axis name for (1D) pixel lists in this column (trailing index).
649      * 
650      * @since 1.19
651      */
652     TCNAna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column pixel axis name"),
653 
654     /**
655      * The physical coordinate unit for (1D) pixel lists in this column (trailing index). This version does not support
656      * alternative coordinates systems.
657      * 
658      * @see   #TCUNna
659      * 
660      * @since 1.19
661      */
662     TCUNIn(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column pixel axis unit"),
663 
664     /**
665      * The physical coordinate unit for (1D) pixel lists in this column (trailing index). This version supports
666      * alternative coordinates systems.
667      * 
668      * @see   #TCUNIn
669      * 
670      * @since 1.19
671      */
672     TCUNna(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column pixel axis unit"),
673 
674     /**
675      * The coordinate reference value in the physical unit of the axis (if defined) for the (1D) pixel lists in this
676      * column (trailing index). This version does not support alternative coordinates systems.
677      * 
678      * @see   #TCRVna
679      * 
680      * @since 1.19
681      */
682     TCRVLn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis reference value"),
683 
684     /**
685      * The coordinate reference value in the physical unit of the axis (if defined) for the (1D) pixel lists in this
686      * column (trailing index). This version supports alternative coordinates systems.
687      * 
688      * @see   #TCRVLn
689      * 
690      * @since 1.19
691      */
692     TCRVna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis reference value"),
693 
694     /**
695      * The coordinate axis spacing in the physical unit of the axis (if defined) for the (1D_) pixel lists in this
696      * column (trailing index). This version does not support alternative coordinates systems.
697      * 
698      * @see   #TCDEna
699      * 
700      * @since 1.19
701      */
702     TCDLTn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis spacing"),
703 
704     /**
705      * The coordinate axis spacing in the physical unit of the axis (if defined) for the (1D_) pixel lists in this
706      * column (trailing index). This version supports alternative coordinates systems.
707      * 
708      * @see   #TCDLTn
709      * 
710      * @since 1.19
711      */
712     TCDEna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis spacing"),
713 
714     /**
715      * The coordinate axis random error in the physical unit of the axis (if defined) for the (1D_) pixel lists in this
716      * column (trailing index).
717      * 
718      * @since 1.19
719      */
720     TCRDna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis random error"),
721 
722     /**
723      * The coordinate axis systematics error in the physical unit of the axis (if defined) for the (1D_) pixel lists in
724      * this column (trailing index).
725      * 
726      * @since 1.19
727      */
728     TCSYna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis random error"),
729 
730     /**
731      * Phase axis zero point on axis (leading index) for array entries in this column (trailing index)
732      * 
733      * @since 1.19
734      */
735     TCZPna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "phase axis zero point"),
736 
737     /**
738      * Phase axis period on axis (leading index) for array entries in this column (trailing index)
739      * 
740      * @since 1.19
741      */
742     TCPRna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "phase axis period"),
743 
744     /**
745      * The 1-based coordinate reference pixel index in the physical unit of the axis (if defined) for the (1D) pixel
746      * lists in this column (trailing index). This version does not support alternative coordinates systems.
747      * 
748      * @see   #TCRPna
749      * 
750      * @since 1.19
751      */
752     TCRPXn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis reference pixel"),
753 
754     /**
755      * The 1-based coordinate reference pixel index in the physical unit of the axis (if defined) for the (1D) pixel
756      * lists in this column (trailing index). This version supports alternative coordinates systems.
757      * 
758      * @see   #TCRPXn
759      * 
760      * @since 1.19
761      */
762     TCRPna(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis reference pixel"),
763 
764     /**
765      * Coordinate transformation matrix in the PC convention. from column index <i>n</i> (leading index) to column index
766      * <i>k</i> (second index) for the for the (1D) pixel lists in this column. The shorter form {@link #TPn_na} may be
767      * required for column indices &gt;99 with alternate coordinate systems.
768      * 
769      * @see   #TPn_na
770      * 
771      * @since 1.19
772      */
773     TPCn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pix trans. matrix element"),
774 
775     /**
776      * Coordinate transformation matrix in the PC convention. from column index <i>n</i> (leading index) to column index
777      * <i>k</i> (second index) for the for the (1D) pixel lists in this column. Same as {@link #TPCn_na}. This shorter
778      * form may be required for column indices &gt;99 with alternate coordinate systems.
779      * 
780      * @see   #TPCn_na
781      * 
782      * @since 1.19
783      */
784     TPn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pix trans. matrix element"),
785 
786     /**
787      * @deprecated The FITS standard deprecated this keyword. Use {@link WCS#TPCn_na} and {@link WCS#TCDn_na}instead.
788      *                 [deg] The coordinate axis rotation in the physical unit of the axis (if defined) for the (1D)
789      *                 pixel lists in this column (trailing index).
790      * 
791      * @since      1.19
792      */
793     @Deprecated
794     TCROTn(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "[deg] column pixel axis rotation"),
795 
796     /**
797      * Coordinate transformation matrix in the CD convention. from column index <i>n</i> (leading index) to column index
798      * <i>k</i> (second index) for the for the (1D) pixel lists in this column. The shorter form {@link #TCn_na} may be
799      * required for column indices &gt;99 with alternate coordinate systems.
800      * 
801      * @since 1.19
802      */
803     TCDn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pix trans. matrix element"),
804 
805     /**
806      * Coordinate transformation matrix in the CD convention. from column index <i>n</i> (leading index) to column index
807      * <i>k</i> (second index) for the for the (1D) pixel lists in this column. Same as {@link #TCDn_na}. This shorter
808      * form may be required for column indices &gt;99 with alternate coordinate systems.
809      * 
810      * @since 1.19
811      */
812     TCn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pix trans. matrix element"),
813 
814     /**
815      * The coordinate string parameter <i>m</i> (trailing index) for the (1D) pixel list entries in this column (leading
816      * index). This shorter form {@link #TSn_na} may be required for column indices &gt;99 with alternate coordinate
817      * systems.
818      * 
819      * @since 1.19
820      */
821     TPSn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column axis parameter name"),
822 
823     /**
824      * The coordinate string parameter <i>m</i> (trailing index) for the (1D) pixel list entries in this column (leading
825      * index). Same as {@link #TPSn_na}. This shorter form may be required for column indices &gt;99 with alternate
826      * coordinate systems.
827      * 
828      * @since 1.19
829      */
830     TSn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.STRING, "column axis parameter name"),
831 
832     /**
833      * The coordinate parameter value <i>m</i> (trailing index) for the (1D) pixel list entries in this column (leading
834      * index). The shorter form {@link #TVn_na} may be required for column indices &gt;99 with alternate coordinate
835      * systems.
836      * 
837      * @since 1.19
838      */
839     TPVn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis parameter value"),
840 
841     /**
842      * The coordinate parameter value <i>m</i> (trailing index) for the (1D) pixel list entries in this column (leading
843      * index). Same as {@link #TPVn_na}. This shorter form may be required for column indices &gt;99 with alternate
844      * coordinate systems.
845      * 
846      * @since 1.19
847      */
848     TVn_na(SOURCE.RESERVED, HDU.TABLE, VALUE.REAL, "column pixel axis parameter value");
849 
850     /** ICRS coordinate reference frame */
851     public static final int WCSAXES_MAX_VALUE = 9;
852 
853     /** ICRS coordinate reference frame */
854     public static final String RADESYS_ICRS = "ICRS";
855 
856     /** IAU 1984 FK5 coordinate reference frame */
857     public static final String RADESYS_FK5 = "FK5";
858 
859     /** Bessel-Newcomb FK4 coordinate reference frame */
860     public static final String RADESYS_FK4 = "FK4";
861 
862     /** Bessel-Newcomb FK4 coordinate reference frame, without eccentricity terms */
863     public static final String RADESYS_FK4_NO_E = "FK4-NO-E";
864 
865     /** Geocentric apparent place (IAU 1984) */
866     public static final String RADESYS_GAPPT = "GAPPT";
867 
868     /** Logarithmically sampled algorithm code for {@link #CTYPEna} keywords */
869     public static final String ALGO_LOG = "LOG";
870 
871     /** Detector sampling algorithm code for {@link #CTYPEna} keywords */
872     public static final String ALGO_GRI = "GRI";
873 
874     /** Detector sampling algorithm code for {@link #CTYPEna} keywords */
875     public static final String ALGO_GRA = "GRA";
876 
877     /** Irregular sampling algorithm code for {@link #CTYPEna} keywords */
878     public static final String ALGO_TAB = "TAB";
879 
880     /** Spectral frequency coordinate value for {@link #CTYPEna} keywords */
881     public static final String SPECTRAL_TYPE_FREQ = "FREQ";
882 
883     /** Spectral energy coordinate value for {@link #CTYPEna} keywords */
884     public static final String SPECTRAL_TYPE_ENER = "ENER";
885 
886     /** Spectral wavenumber coordinate value for {@link #CTYPEna} keywords */
887     public static final String SPECTRAL_TYPE_WAVN = "WAVN";
888 
889     /** Spectral radial velocity coordinate value for {@link #CTYPEna} keywords */
890     public static final String SPECTRAL_TYPE_VRAD = "VRAD";
891 
892     /** Spectral vacuum wavenlength coordinate value for {@link #CTYPEna} keywords */
893     public static final String SPECTRAL_TYPE_WAVE = "WAVE";
894 
895     /** Spectral optical velocity coordinate value for {@link #CTYPEna} keywords */
896     public static final String SPECTRAL_TYPE_VOPT = "VOPT";
897 
898     /** Spectral redshift coordinate value for {@link #CTYPEna} keywords */
899     public static final String SPECTRAL_TYPE_ZOPT = "ZOPT";
900 
901     /** Spectral wavelength in air coordinate value for {@link #CTYPEna} keywords */
902     public static final String SPECTRAL_TYPE_AWAV = "AWAV";
903 
904     /** Spectral apparent radial velocity coordinate value for {@link #CTYPEna} keywords */
905     public static final String SPECTRAL_TYPE_VELO = "VELO";
906 
907     /** Spectral beta factor (<i>v/c</i>) coordinate value for {@link #CTYPEna} keywords */
908     public static final String SPECTRAL_TYPE_BETA = "BETA";
909 
910     /** Spectral frequency expressed as wavelength transformation code for {@link #CTYPEna} keywords */
911     public static final String SPECTRAL_ALGO_F2W = "F2W";
912 
913     /** Spectral frequency expressed as apparent radial velocity transformation code for {@link #CTYPEna} keywords */
914     public static final String SPECTRAL_ALGO_F2V = "F2V";
915 
916     /** Spectral frequency expressed as air wavelength transformation code for {@link #CTYPEna} keywords */
917     public static final String SPECTRAL_ALGO_F2A = "F2A";
918 
919     /** Spectral wavelength expressed as frequency transformation code for {@link #CTYPEna} keywords */
920     public static final String SPECTRAL_ALGO_W2F = "W2F";
921 
922     /** Spectral wavelength expressed as apparent radial velocity transformation code for {@link #CTYPEna} keywords */
923     public static final String SPECTRAL_ALGO_W2V = "W2V";
924 
925     /** Spectral wavelength expressed as air wavelength transformation code for {@link #CTYPEna} keywords */
926     public static final String SPECTRAL_ALGO_W2A = "W2A";
927 
928     /** Spectral radial velocity expressed as frequency transformation code for {@link #CTYPEna} keywords */
929     public static final String SPECTRAL_ALGO_V2F = "V2F";
930 
931     /** Spectral radial velocity expressed as wavelength transformation code for {@link #CTYPEna} keywords */
932     public static final String SPECTRAL_ALGO_V2W = "V2W";
933 
934     /** Spectral radial velocity expressed as air wavelength transformation code for {@link #CTYPEna} keywords */
935     public static final String SPECTRAL_ALGO_V2A = "V2A";
936 
937     /** Spectral air wavelength expressed as frequency transformation code for {@link #CTYPEna} keywords */
938     public static final String SPECTRAL_ALGO_A2F = "A2F";
939 
940     /** Spectral air wavelength expressed as vacuum wavelength transformation code for {@link #CTYPEna} keywords */
941     public static final String SPECTRAL_ALGO_A2W = "A2W";
942 
943     /**
944      * Spectral air wavelength expressed as apparent radial velocity transformation code for {@link #CTYPEna} keywords
945      */
946     public static final String SPECTRAL_ALGO_A2V = "A2V";
947 
948     private final FitsKey key;
949 
950     WCS(SOURCE status, HDU hdu, VALUE valueType, String comment) {
951         this(null, status, hdu, valueType, comment);
952     }
953 
954     WCS(String headerName, SOURCE status, HDU hdu, VALUE valueType, String comment) {
955         key = new FitsKey(headerName == null ? name() : headerName, status, hdu, valueType, comment);
956         FitsKey.registerStandard(this);
957     }
958 
959     @Override
960     public final FitsKey impl() {
961         return key;
962     }
963 
964     /**
965      * Specifying an alternative coordinate system. Alternative systems are labelled 'A' through 'Z'. This call is
966      * available only for the enums, which have a lower-case 'a' at the end of their Java names (such as
967      * {@link #WCSNAMEa}). Attempting to call this on WCS keywords that do not end with lower-case 'a' in their Java
968      * names (such as {@link #OBSGEO_X} will throw and {@link UnsupportedOperationException}. You will want to call this
969      * before chaining other calls to {@link IFitsHeader}.
970      * 
971      * @param  c                             The alternative coordinate system marker 'A' through 'Z' (case
972      *                                           insensitive).
973      * 
974      * @return                               The standard FITS keyword with the alternate coordinate system marker
975      *                                           attached.
976      * 
977      * @throws IllegalArgumentException      if the marker is outside of the legal range of 'A' through 'Z' (case
978      *                                           insensitive).
979      * @throws UnsupportedOperationException if the keyword does not support alternative coordinate systems
980      * 
981      * @since                                1.19
982      */
983     public IFitsHeader alt(char c) throws IllegalArgumentException, UnsupportedOperationException {
984         if (!name().endsWith("a")) {
985             throw new UnsupportedOperationException("WCS keyword " + key.key() + " does not support alternatives.");
986         }
987 
988         c = Character.toUpperCase(c);
989         if (c < 'A' || c > 'Z') {
990             throw new IllegalArgumentException("Expected 'A' through 'Z': Got '%c'");
991         }
992 
993         return new FitsKey(key() + Character.toUpperCase(c), status(), hdu(), valueType(), comment());
994     }
995 
996 }