Commit a14a002f78e64231bd51b34e51a68191fe4f4015

Authored by Annie Hughes
1 parent 2926480f
Exists in master

fixed final plot for wraptest mode

Showing 1 changed file with 28 additions and 21 deletions   Show diff stats
src/idl/dustem_init.pro
... ... @@ -11,20 +11,28 @@ PRO dustem_init,model=model $
11 11 ;+
12 12 ; NAME:
13 13 ; dustem_init
  14 +;
14 15 ; PURPOSE:
15 16 ; Defines system variables to run the DUSTEM code
  17 +;
16 18 ; CATEGORY:
17 19 ; DustEMWrap, Distributed, High-Level, Initialization
  20 +;
18 21 ; CALLING SEQUENCE:
19 22 ; dustem_init,model=model,
  23 +;
20 24 ; INPUTS:
21 25 ; None
  26 +;
22 27 ; OPTIONAL INPUT PARAMETERS:
23 28 ; None
  29 +;
24 30 ; OUTPUTS:
25 31 ; None
  32 +;
26 33 ; OPTIONAL OUTPUT PARAMETERS:
27   -; ; st_model *** COMMENT AH -- what is this? END COMMENT AH ***
  34 +; ; st_model
  35 +;
28 36 ; ACCEPTED KEY-WORDS:
29 37 ; model = specifies the interstellar dust mixture used by DustEM
30 38 ; 'MC10' model from Compiegne et al 2010 (default)
... ... @@ -46,8 +54,10 @@ PRO dustem_init,model=model $
46 54 ; polarization = set this variables for runs taking polarization into account
47 55 ; noerase : set this keyword to not erase the temporary memory used by dustemwrap
48 56 ; grain_keywords : Fortran grain keywords. Must be an array of Ngrains strings. Use '?' to keep default values.
  57 +;
49 58 ; COMMON BLOCKS:
50 59 ; None
  60 +;
51 61 ; SIDE EFFECTS:
52 62 ; 1/ The following system variables are initialized to null values
53 63 ; or empty pointers:
... ... @@ -63,13 +73,17 @@ PRO dustem_init,model=model $
63 73 ; 2/ optionally runs the fortran code (if wraptest)
64 74 ; This step calls the Fortran code to run a standard model
65 75 ; 3/ !dustem_filters is initialized calling dustem_filter_init.pro.
  76 +;
66 77 ; RESTRICTIONS:
67   -; The dustem fortran code must be installed
68   -; The dustem idl wrapper must be installed
  78 +; The DustEM fortran code must be installed
  79 +; The DustEMWrap idl code must be installed
  80 +;
69 81 ; PROCEDURES AND SUBROUTINES USED:
70 82 ; *** COMMENT AH --> is this really NONE? ****
  83 +;
71 84 ; EXAMPLES
72 85 ; dustem_init,model="MC10",/wrap,/plot_it
  86 +;
73 87 ; MODIFICATION HISTORY:
74 88 ; Written by JPB,NF,DP Jan-2007
75 89 ; Evolution details on the DustEMWrap gitlab.
... ... @@ -321,21 +335,7 @@ defsysv,'!dustem_filters',ptr_new() ;filter information (filled by dustem_fi
321 335 ;; ** Structure <1b95608>, 17 tags, length=8232, data length=8118, refs=1:
322 336 ;; IRAC STRUCT -> <Anonymous> Array[1]
323 337 ;; MIPS STRUCT -> <Anonymous> Array[1]
324   -;; MSX STRUCT -> <Anonymous> Array[1]
325   -;; IRAS STRUCT -> <Anonymous> Array[1]
326   -;; DIRBE STRUCT -> <Anonymous> Array[1]
327   -;; SPM STRUCT -> <Anonymous> Array[1]
328   -;; ISOCAM STRUCT -> <Anonymous> Array[1]
329   -;; ISOPHOTP STRUCT -> <Anonymous> Array[1]
330   -;; ISOPHOTC STRUCT -> <Anonymous> Array[1]
331   -;; EFIRAS STRUCT -> <Anonymous> Array[1]
332   -;; ARCHEOPS STRUCT -> <Anonymous> Array[1]
333   -;; HFI STRUCT -> <Anonymous> Array[1]
334   -;; LFI STRUCT -> <Anonymous> Array[1]
335   -;; WMAP STRUCT -> <Anonymous> Array[1]
336   -;; SPIRE STRUCT -> <Anonymous> Array[1]
337   -;; PACS STRUCT -> <Anonymous> Array[1]
338   -;; AKARI STRUCT -> <Anonymous> Array[1]
  338 +;; ... etc
339 339  
340 340 defsysv,'!dustem_verbose',0 ;1=verbose
341 341 defsysv,'!dustem_show_plot',1 ;0=show no plot
... ... @@ -534,9 +534,16 @@ IF keyword_set(wraptest) THEN BEGIN
534 534 dustem_write_all,st_model,dir_out
535 535 st=dustem_run()
536 536 IF keyword_set(plot_it) THEN BEGIN
537   - loadct,13
538   - dustem_plot_nuinu_em,st,yr=[1e-14,1.e-6],/ysty,xr=[1,5e3],/xsty
539   - ENDIF
  537 + window,0 & loadct,13
  538 + yr=[1e-14,1.e-6]
  539 + xr=[1,5e3]
  540 + tit='dustem_init wrapper test '+!dustem_model
  541 + xtit=textoidl('\lambda (\mum)')
  542 + ytit=textoidl('\nuI_\nu^{em} (W/m^2/sr for N_H=1.e20 H/cm^2)')
  543 + yr=[1e-11,6.e-7]
  544 + xr=[1,5e3]
  545 + dustem_plot_nuinu_em,st,yr=yr,/ysty,xr=xr,/xsty,/xlog,/ylog,title=tit,xtit=xtit,ytit=ytit
  546 + ENDIF
540 547 ENDIF
541 548  
542 549 ;Initialize filters
... ...