;+ ; NAME: ; RELTRANS.PRO ; PURPOSE: ; Get the relative transmission of a Polar Camera interference ; filter as a function of filter (wheel) temperature. ; CATEGORY: ; Secondary data processing, image brightness calibration. ; CALLING SEQUENCE: ; RELTRANS, FILENAME, FILTEMPS, FILTRANS ; INPUTS: ; FILENAME: The file name (only, no pathname) of the file of ; processed images. The suffix must be .ray or .bgs. ; OPTIONAL INPUTS: ; None. ; KEYWORD PARAMETERS: ; None. ; OUTPUTS: ; FILTEMPS: The filter (wheel) temperatures at which the ; relative transmission is tabulated. Defaults to ; 10.0, 12.0, ..., 32.0 deg C. ; FILTRANS: The transmission of the filter at the wavelength ; of the line emission imaged in the filters, relative ; to the peak transmission of the filter. ; OPTIONAL OUTPUTS: ; None. ; COMMON BLOCKS: ; None. ; SIDE EFFECTS: ; The file '~cnsr3/passband/cwl.rpb' is read to determine ; the center wavelength of the camera/filter combination ; providing the images. If the filter involved is 558 nm or ; 630 nm the 'thruput' file for the appropriate filter is ; read to get the relative transmissions. ; RESTRICTIONS: ; None known yet. ; PROCEDURE: ; Straightforward. ; EXAMPLE: ; reltrans,'93120202.bgs',filtemps,filtrans ; cam 0, filt 2 ; SEE ALSO: ; FILTERPLBS.PRO ; MODIFICATION HISTORY: ; Written by: D P Steele, April 1995 ;- PRO reltrans,filename,filtemp,filtrans ; Load OS-dependent quantities @isitdos ; Isolate the camera and filter numbers, and the filename suffix. cam=FIX(STRMID(filename,6,1)) filt=FIX(STRMID(filename,7,1)) suffix=STRMID(filename,9,3) ; If the image file ends with .bgs, assume that all continuum ; background has been removed, and try to account for reduced ; transmission at the wavelength of the emission line. Otherwise, ; return dummy values that will have no net effect. IF suffix EQ 'bgs' THEN BEGIN ; Get center wavelengths so we know which thruput file to read cwl=FLTARR(10) OPENR,lun,tproot+dd+'cwl.rpb',/GET_LUN READF,lun,cwl FREE_LUN,lun ; Convert center wavelength to STRING cwl=STRTRIM(ROUND(cwl(5*cam+filt)),2) ; Read feature transmission versus filter temperature tmp=ddread(tproot+dd+cwl+'c'+dd+'thruput',/formatted) tmpsize=SIZE(tmp) IF tmpsize(1) EQ 3 THEN BEGIN ; relative transmissions nent=tmpsize(2) ; are in 3rd column filtemp=TRANSPOSE(tmp(0,*)) filtrans=TRANSPOSE(tmp(2,*)) ENDIF ELSE BEGIN ; no 3rd column => broad- ; band filter, assume 1.0 filtemp=FINDGEN(12)*2+10 filtrans=REPLICATE(1.,12) ENDELSE ENDIF ELSE BEGIN ; not .bgs file => back- filtemp=FINDGEN(12)*2+10 ; ground not subtracted. filtrans=REPLICATE(1.,12) ENDELSE RETURN END