Commit 537113757fa91a5923874730b49cac5492cd3306
1 parent
0979f90a
Exists in
master
First commit
Showing
1 changed file
with
45 additions
and
0 deletions
Show diff stats
src/idl_misc/JPBLib_for_Dustemwrap/General/convert_mk_mjy.pro
0 → 100644
... | ... | @@ -0,0 +1,45 @@ |
1 | +; Copyright 2007 IAS | |
2 | + | |
3 | +; This file is part of the Planck Sky Model. | |
4 | +; | |
5 | +; The Planck Sky Model is free software; you can redistribute it and/or modify | |
6 | +; it under the terms of the GNU General Public License as published by | |
7 | +; the Free Software Foundation; version 2 of the License. | |
8 | +; | |
9 | +; The Planck Sky Model is distributed in the hope that it will be useful, | |
10 | +; but WITHOUT ANY WARRANTY, without even the implied warranty of | |
11 | +; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
12 | +; GNU General Public License for more details. | |
13 | +; | |
14 | +; You should have received a copy of the GNU General Public License | |
15 | +; along with the Planck Sky Model. If not, write to the Free Software | |
16 | +; Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA | |
17 | + | |
18 | +;+ | |
19 | +; Convert mK, either themodynamic or Rayleigh-Jeans in MJy/sr | |
20 | +; | |
21 | +; | |
22 | +; @param lam {in}{required}{type=float} wavelength in micron | |
23 | +; @keyword sig_mK{in}{required}{type=float} signal in mK | |
24 | +; @keyword sig_Mjy{in}{optional}{type=float} ... | |
25 | +; @keyword RJ{in}{optional}{type=boolean} ... | |
26 | +; @keyword CMB_TH{in}{optional}{type=boolean} ... | |
27 | +; | |
28 | +; @history <p> Written Guilaine Lagache, 2001</p> | |
29 | +;- | |
30 | + | |
31 | +pro convert_mk_mjy, lam, sig_mk, sig_Mjy, RJ=RJ, CMB_TH = CMB_TH | |
32 | +k=1.3806503e-23 | |
33 | + | |
34 | +IF KEYWORD_SET(RJ) THEN $ | |
35 | + ; mK Rayleigh-Jeans | |
36 | + sig_Mjy=sig_mk*1.e-3*2*k*1e20/(lam*1.e-6)^2. | |
37 | + | |
38 | +IF KEYWORD_SET(CMB_TH) THEN BEGIN | |
39 | + ; mK thermodynamique | |
40 | + PLANCK_VALUES= planck_function(2.726,lam,dBdT_VALUES,units='micron',/MJY) | |
41 | + sig_Mjy=sig_mk*dbdt_values*1.e-3 | |
42 | +ENDIF | |
43 | + | |
44 | +END | |
45 | + | ... | ... |