Observing with a multi-slit mask

How Can We Help?

Observing with a multi-slit mask

Note: The software used at the telescope for aligning IMACS masks requires the existence of two special files per mask (referred to in this cookbook as ".align" and ".sub" files). There are two different ways to generate these files. This cookbook describes a method which uses only IRAF. The second method, which uses the COSMOS data reduction package is described elsewhere.

Afternoon:

  • Make sure that the Instrument Specialist has loaded the multi-slit masks that you will use that night. Remember that observers are required to submit mask files at least 6 weeks before the date of observation in order to insure that the masks will be ready for their run.
  • If the IMACS GUI has not already been started by the Instrument Specialist, open an xterm, type "imacs ", and follow the instructions in the "Getting Started" section of the IMACS Manual.
  • Make sure that flexure control is ON and properly applied (no flexure control error messages in the IMACS message window). Then, take an image of each of the multi-slit masks. To do this, first ask the Instrument Specialist to open the telescope mirror covers. Start the Flat Field Screen gui by typing "ffs " in an xterm. Once the gui appears, click the mouse on the "IN" button to put the screen into the telescope beam. Ambient light in the dome should be sufficient to measure the slit positions. Now, in the IMACS MechGUI, make sure that the Hatch is in the "open" position, the calibration lamps are all turned off, and the CF-Guider is in the "out" position. The Slit Mask must be set to the position with the mask that you intend to use, and Disperser should be set to either "f/2-Imaging" or "f/4-Imaging", depending on which camera is being used. Finally, set the Filter to "Spectroscopic" - or any blocking filter you intend to use. Now, in the IMACS CamGUI, set ExpTime to "10", Loops to "1", and ExpType to "Object". Finally, set Binning X and Binning Y to the binning which you wish to use for the mask alignment process (most observers prefer 1x1 for f/2, and 2x2 for f/4), and then click on the "Start" button to take an exposure.
  • N.B. In f/4, mode and especially on dark nights, we advise 2x2 binning for the acquisition in order to gurantee sufficient light through your alignment boxes at night. You can still use 1x1  binning for your science exposures.
  • Open an IRAF xgterm and the ds9 image display tool, and type "imacs" at the CL prompt to load the imacs package. Next, type "epar icbox" to edit the parameters of the icbox task. These are as follows:


         mask =                 Root name of slit mask image (e.g. ccd0114)
       output =                 Root name of output files (e.g. 3C273)
             (sz = 15.)         Size of alignment boxes (pixels)
  (subraster = 100)        Size of subrasters (pixels)
      (cursor = "")            
          (line = "")            
       (mode = "ql")

For the "mask" parameter, enter the root name of the first of the multi-slit mask image that you took in the previous step. The "output" parameter should be set to the root name (usually the name of the mask or the field) that you want the .align and .sub files to have. Next, make sure that the "sz" parameter is set to the size (in pixels) of the alignment holes as measured on the multi-slit mask image. The "subraster" parameter can be left at its default value of 100.

While still in "epar" mode, type ":go" to execute icbox. One by one, the individual CCD chips of the multi-slit mask image will be displayed, and you will be asked to mark the approximate positions of the alignment boxes. To do this, center the cursor on the box and hit "space bar". If you wish to change the minimum and maximum data values mapped into ds9, hit the "d" key. If you wish to abort, hit the "I" key. Once all the boxes on a chip have been marked (or if there are no boxes on this chip), type "q" to go to the next CCD. The task will end after cycling through all of the chips. Please make certain that each alignment box that you mark is at least one half of the subraster size away from any edge of the CCD in order to be certain that this box can be properly measured and used in the alignment process.

The icbox task produces two files. If the "output" parameter of icbox was set to "3C273", these would be named "3C273.sub" and "3C273.align". The .align file will be needed during the night to carry out the alignment of the mask on the field. The .sub file is used for running the mask alignment process in subraster mode, which cuts down significantly the time required to carry out an alignment.

Run icbox on the remaining multi-slit mask images.

Take a sequence of flat field exposures with the slit that you will be using. With the telescope mirror covers still open, and the Flat Field Screen in the "IN" position (and the HE, Ne, and AR lamps all turned off), you can use the Quartz low or high lamps on the FFS GUI. In the IMACS MechGUI, make sure that Slit Mask is set to the position with the mask that you will use, Disperser to the grating or grism that you will use, and Filter to "Spectroscopic" or any blocking filter that you will use. Now, in the IMACS CamGUI, set ExpTime to "10", Loops to "1", ExpType to "Object", and the Binning X and Binning Y values to whichever values you plan to use at night, and then click on the "Start" button to take an exposure.
Adjust either the exposure time and/or the quartz lamp voltage to achieve the desired count level. Now take a sequence of flats by setting Loops in the IMACS CamGUI to the desired number of exposures, and then click on the "Start" button to begin the sequence.

Turn off the quartz lamp, click the mouse on the "OUT" button to take the flat field screen out of the telescope beam, and take a sequence of bias images. In the IMACS CamGUI, set Loops to the number of exposures you wish to take, ExpType to "Bias", and the Binning X and Binning Y values to whichever values you plan to use at night, and then click on the "Start" button to start the loop sequence. Although IMACS is reasonably light-tight, bias images should be taken with the dome as dark as possible.

Night:

Note: Follow this sequence completely for every mask that you wish to align
Have the Telescope Operator (TO) slew to the object that you wish to observe. Make sure that the TO has the rotator mode set to the "OFF" mode with an offset which will depend on the orientation of the slits in the mask. This will be equal to X + PA(slit) - 180 (+ 180 if the target is between the zenith and the pole), where X is the IMACS rotator offset angle which is a number like -46.15 (the Instrument Specialist can give you the latest value), and PA(slit) is the intended position angle on the sky of the mask slits. Note that the observer can (and should, if possible) prepare his/her Observing Catalog in advance with the desired rotator mode and offsets.  An appropriate catalog entry is also created for you during the mask making process and is written to the SMF file.  Given the appropriate catalog file position to slew to (including a guide star and SH star), the TO will first center your field using the two outer field probes and the star positions.

As soon as the telescope has slewed to the position of the object, have the TO set up on a guide star and an off-axis S-H star.

Next take an image of the field. To do this, go to the IMACS MechGUI and make sure that the Hatch is in the "open" position, and the calibration lamps are all turned off. The Slit Mask and the Disperser must both be set to "f/2-Imaging" or "f/4-Imaging", depending on which camera is being used. Next, set the Filter to "Spectroscopic" (for maximum throughput) or use the blocking filter that you intend to use for your observations and that you already used for afternoon mask images and icbox. Now, in the IMACS CamGUI, set ExpTime to an appropriate value so that the reference stars will be visible (probably about 10 seconds will be sufficient), Loops to "1", ExpType to "Object", and make sure that Binning X and Binning Y are set to the same values that you used to take the mask images in the afternoon.

N.B: If observing in f/4 mode make sure you have sufficient background counts that you can clearly see your alignment boxes picked out within your subrasters -- ifalign needs to be able to detect the edges of the alignment boxes.

Next, click on the "Full" button and select the "Subraster" readout mode, which will then cause the Subraster-Definition box to appear. Click on the "File" button to browse for the .sub file which you produced in tha afternoon. Once the file has been selected, hit "Load". Make sure that SaveMode is set to "Full", and then click on "Done" to close the dialog box. Finally, click on the "Start" button to begin an exposure.
Note that the orientation of N and E will be indicated in the QL-Tool when the exposure has read out. Make sure that this is consistent with your expectations for the mask.

  • Edit the parameters for the IRAF imacs task ialign, the parameters of which are:


          mask =                 Image root name of slitlets (e.g. ift0114)
            field =                 Image root name of field (e.g. ift0115)
     align_ro = ""             Alignment file ROOTNAME (e.g. mask21)
          inter = no              Run 'geomap' interactively?
          axis = xy              Minimize which residuals? ('xy' or 'x' or 'y')
              sz =                  Size of alignment boxes in (pixels)
       drange = yes            Set the Display range to specific values
                z1= 1              Minimum grey level to be displayed
                z2= 10000       Maximum grey level to be displayed
       query0 = no              Delete stars from alignment solution?
       query1 = no              Send RA/DEC offset to TCS?
       query2 = no              Send rotation offset to TCS?
       query3 = yes             Do coordinated offset?
        (cursor = "")            
         (falign = "")            
         (mode = "ql")

Set the "mask" parameter to the root name of the mask image taken in the afternoon; the "field" parameters should be set to the root name of image of the field just taken. Set the "align_file" parameter to the name of the .align file that you produced in that afternoon. The "inter" parameter is normally set to "no", but if you wish to interact with the alignment solution (which is performed with the iraf task "geomap"), set this parameter to "yes".

Now run ialign. One by one, the expected position of the reference stars will be displayed in the "ds9" tool.  The routine will display a green circle around the automatic selection of the brightest nearby source.  If you want to accept the circled target, hit the "a" key for accept.  Otherwise, you will need to place the cursor on the star and use the "space bar" to calculate the centroid, or use the "m" key to mark the position manually. If you wish to change the minimum and maximum data values mapped into ds9, hit the "d" key. If you wish to abort, hit the "I" key. Once you've marked each of the reference stars, a solution is calculated and you will be offered the chance to eliminate discrepant stars. A final solution for both a rotation offset and an offset in RA and DEC is then calculated, and you will be asked if you wish to apply these offsets. Usually it is o.k. to reply "yes". Make sure you also reply "yes" to the question of whether you want to do a coordinated offset (which moves both the telescope and the guide probes), but let the TO know before actually executing it.


Now take another image of the object -- but this time with the mask inserted in the beam. Run the IRAF IMACS task ifalign on the new image. (Note the "f" in ifalign which distinguishes this task from the ialign task discussed in the previous bullet!). The parameters for ifalign are identical to those of ialign except that only one image, "mask", is requested. The ifalign task will step through each of the alignment stars showing you x and y cuts looking something like the following:

The dashed line in these plots shows the level determined for the sky. The rectangle shows the position measured for the alignment box, and the solid line displays the calculated centroid of the star. You can change any of these values (type "?" to see how to change them), but usually this is totally unnecessary. Once you are happy with the xy fits, type "q" to move on to the next alignment star. After marking all the stars, you will be offered the opportunity again to eliminate discrepant stars. Finally, new offsets are calculated and you are asked whether or not you wish to execute them. These offsets should be small, but it is usually worth executing them.


You should now be ready to observe your object. In the IMACS MechGUI, set the Disperser to the grating or grism that you will use, and set the Filter to "Spectroscopic" or your desired blocking filter. In the IMACS CamGUI, set ExpTime, Loops, Binning X, and Binning Y to the desired values, and click on "Subraster" to select the "Full" readout mode. To begin the exposure, click on the "Start" button.

Table of Contents