Viewing contents of file '../idllib/ghrs/pro/a_b.pro'
function A_b,l,b
;+
; NAME:
; A_b
; PURPOSE:
; Compute interstellar extinction in the B bandpass as a function
; of galactic position using the 21 parameter function given by
; deVaucoulers in the 2nd Reference Catalog of Galaxies
; CALLING SEQUENCE:
; result = A_b(l2,b2)
; INPUT PARAMETERS
; l2 = galactic longitude (degrees), scalar
; b2 = galactic latitude (degrees), scalar
; OUTPUT PARAMETERS
; RESULT - Interstellar extinction Ab in magnitudes
; NOTES:
; The controversial aspect of the deVaucoulers reddening curve
; is that it predicts an extinction of about 0.2 at the poles
;
; The parameters used here differ from the ones printed in the RC2
; but are the ones actually used for entries in the catalog
; (see Rowan-Robinson 1985)
; REVISION HISTORY
; Written by R. Cornett and W. Landsman, STX 10/16/1987
;-
lr = l/!radeg & br = b/!radeg
; compute the RC2 'C'
c = 1./sin(br+(0.25/!radeg)-(1.7/!radeg)*sin(lr)-(1./!radeg)*cos(3.*lr))
if (b ge 0) then begin
sn = 0.1948*cos(lr) + 0.0725*sin(lr) $
+ 0.0953*cos(2.*lr) - 0.0751*sin(2.*lr) $
+ 0.0936*cos(3.*lr) + 0.0639*sin(3.*lr) $
+ 0.0391*cos(4.*lr) + 0.0691*sin(4.*lr)
ab = 0.19*( 1.+ sn * cos(br))*abs(c)
endif else begin
ss = 0.1749*cos(lr) - 0.01112*sin(lr) $
+ 0.1438*cos(2.*lr) - 0.0180*sin(2.*lr) $
- 0.0897*cos(3.*lr) - 0.0013*sin(3.*lr) $
+ 0.0568*cos(4.*lr) + 0.0433*sin(4.*lr)
ab = 0.21*( 1.+ ss * cos(br) )*abs(c)
endelse
return,ab
end