program s2_gcmb ! Uses use s2_types_mod use s2_cmb_mod use s2_sky_mod use s2_pl_mod use s2_error_mod use s2_vect_mod ! Calls call parse_options call s2_cmb_free call s2_error call s2_pl_conv call s2_pl_free call s2_sky_free call s2_sky_write_file call system_clock ! Variables type (s2_cmb) :: cmb integer :: nside integer :: lmin integer :: lmax integer :: ncomment integer :: seed integer :: fail = 0 character (len=S2_STRING_LEN) :: filename_cl character (len=S2_STRING_LEN) :: filename_out = 'out.fits' logical :: scale_cl = .true. logical :: seed_set = .false. real (kind=s2_sp) :: noise_var = 0.0e0 real (kind=s2_sp) :: beam_fwhm = 0.0e0 real (kind=s2_sp), allocatable, dimension (:) :: npl logical :: beam_present = .false. logical :: noise_present = .false. type (s2_pl) :: beam_pl type (s2_pl) :: noise_pl type (s2_pl) :: background_pl type (s2_pl) :: background_pl_tmp type (s2_sky) :: cmb_sky character (len=*), parameter :: MAP_FILE = 'map' character (len=*), parameter :: ALM_FILE = 'alm' character (len=*), parameter :: SKY_FILE = 'sky' integer :: file_type_out = S2_SKY_FILE_TYPE_MAP character (len=S2_STRING_LEN) :: file_type_out_str = MAP_FILE logical :: compute_map = .false. ! Subroutines and functions subroutine parse_options () end program s2_gcmbGenerate a Gaussian CMB realisation from an input power spectrum.
Usage:
Author: J. D. McEwen (mcewen@mrao.cam.ac.uk)
Version: 0.1 - July 2005
type (s2_cmb) :: cmb
integer :: nside
integer :: lmin
integer :: lmax
integer :: ncomment
integer :: seed
integer :: fail = 0
character (len=S2_STRING_LEN) :: filename_cl
character (len=S2_STRING_LEN) :: filename_out = 'out.fits'
logical :: scale_cl = .true.
logical :: seed_set = .false.
real (kind=s2_sp) :: noise_var = 0.0e0
real (kind=s2_sp) :: beam_fwhm = 0.0e0
real (kind=s2_sp), allocatable, dimension (:) :: npl
logical :: beam_present = .false.
logical :: noise_present = .false.
type (s2_pl) :: beam_pl
type (s2_pl) :: noise_pl
type (s2_pl) :: background_pl
type (s2_pl) :: background_pl_tmp
type (s2_sky) :: cmb_sky
character (len=*), parameter :: MAP_FILE = 'map'
character (len=*), parameter :: ALM_FILE = 'alm'
character (len=*), parameter :: SKY_FILE = 'sky'
integer :: file_type_out = S2_SKY_FILE_TYPE_MAP
character (len=S2_STRING_LEN) :: file_type_out_str = MAP_FILE
logical :: compute_map = .false.
subroutine parse_options () ! Calls: getArgument end subroutine parse_optionsParse the options passed when program called.
Author: J. D. McEwen (mcewen@mrao.cam.ac.uk)
Version: 0.1 - November 2004