Blame view

src/idl/dustem_cut_off.pro 447 Bytes
a38807fc   Annie Hughes   first commit of f...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
FUNCTION DUSTEM_CUT_OFF, x, par
; generates the large size cut-off 
; from Weingartner & Draine 2001
; x : grain size 
; par(0) : threshold for cut-off (At)
; par(1) : shape As (roughly the size where cut_off=0.5)

 y = 0.d0*x + 1.d0
 ix = WHERE( x GT par(0), cnt )
 if CNT GT 0 then begin 
     y(ix) = exp( -( (x(ix)-par(0)) / par(1))^3. )
 endif else begin 
     print,'(W)  DUSTEM_CUT_OFF: no size larger than At found'
 endelse
RETURN, y
END