; DTSIM ;--------------------------------------------------------------- ;! Generate fake UV data ;# Task Calibration VLBI ;----------------------------------------------------------------------- ;; Copyright (C) 1995-1998 ;; Associated Universities, Inc. Washington DC, USA. ;; ;; This program is free software; you can redistribute it and/or ;; modify it under the terms of the GNU General Public License as ;; published by the Free Software Foundation; either version 2 of ;; the License, or (at your option) any later version. ;; ;; This program is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHDTSIMILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU General Public License for more details. ;; ;; You should have received a copy of the GNU General Public ;; License along with this program; if not, write to the Free ;; Software Foundation, Inc., 675 Massachusetts Ave, Cambridge, ;; MA 02139, USA. ;; ;; Correspondence concerning AIPS should be addressed as follows: ;; Internet email: aipsmail@nrao.edu. ;; Postal address: AIPS Project Office ;; National Radio Astronomy Observatory ;; 520 Edgemont Road ;; Charlottesville, VA 22903-2475 USA ;----------------------------------------------------------------------- ;--------------------------------------------------------------- DTSIM LLLLLLLLLLLLUUUUUUUUUUUU CCCCCCCCCCCCCCCCCCCCCCCCCCCCC DTSIM Task to generate fake UV data OUTNAME Output UV file name (name) OUTCLASS Output UV file name (class) OUTSEQ 0.0 9999.0 Output UV file name (seq. #) OUTDISK 0.0 9.0 Output UV file disk unit # INFILE Parameter file name. IN2FILE Directory PRTLEV Print level (0=>none; 1=> echo text file) ---------------------------------------------------------------- DTSIM Task: This task will generate fake uv-data for the primary purpose of testing AIPS tasks. It is used in conjunction with task DTCHK, which measures the degree of compliance with the expected test result. Adverbs: OUTNAME....Output UV file name (name). Standard defaults. OUTCLASS...Output UV file name (class). Standard defaults. OUTSEQ.....Output UV file name (seq. #). 0 => highest. OUTDISK....Disk drive # of output UV file. 0 => any. INFILE.....External text file containing data simulation parameters in KEYIN format. IN2FILE....Not used as yet. PRTLEV.....Print level (>0: echo external parameter file on input. ----------------------------------------------------------------- DTSIM: Task to generate fake uv-data Documentor: A. Kemball Related Programs: DTCHK OVERVIEW This task will generate fake uv-data for the primary purpose of testing AIPS tasks. It is used in conjunction with task DTCHK, which measures the degree of compliance with the expected test result. The input parameters defining the simulated dataset are provided in the form of an external text file in KEYIN format. This file is used by DTCHK in checking test compliance. DTSIM can be used alone, however, to generate datasets containing simulated data for other purposes. PARAMETER FILE The format of the parameter file consists of several different groups, which are defined below: ANTENNA TABLES ============== The attached antenna tables are defined in the following format: AN_TABLE VER = n / (* defines AN table version number *) KEY CAL_ERR (* copy feed cal. err. to the AN table *) POLTYPE = 'VLBI' (* set polzn. POLTYPE keyword *) ARRNAM = 'array' / (* defines AN keyword ARRNAM; eg 'VLBA' *) STATION = 'name' (* station name (up to 8 characters) *) LONG = hh:mm:ss (* station longitude and latitude *) LAT = dd:mm:ss MNT = 'AZEL' or 'HADC' or 'ORB' (* az-el, equatorial or orbiting *) NO = n (* antenna number in AN table *) ELEV = x (* station elevation in (m) *) ORBPARM = 6*x / (* orbital parameters (six) *) CARTPOS= X, Y, Z (* XYZ earth-centered coordinates in a right-handed system with Z towards North, X through Greenwich, and Y through Europe, ***THIS MAY BE SPECIFIED IN PLACE OF LONG, LAT, ELEV*** *) Multiple STATION records can be defined for any given AN table. END / (* end of station records *) STATION = 'SPEC_NAM' / (* alternate format for specifying station information, SPEC_NAM is chosen from the following list: VLBA_xx : xx = PT, LA, SC, MK, HN, OV, KP, FD, BR, NL ALL_VLBA : all 10 VLBA antennas VLA_Yx : x = A, B, C, D arrays VLA_na : n = 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 16, 18, 20, 24, 28, 32, 36, 40, 48, 56, 64, 72 pad pos. a = N, W, E arms *** NOTE that specifying VLA_YA and VLA_YB will specify some common antennas -this could cause problems- it would be advisable to specify the antennas individually in this case. Other alternate formats can be added by request *) SOURCE TABLE ============ The source table is defined as follows: SU_TABLE / SU_ID = n (* source ID *) NAME = 'name' (* source name (16 characters) *) REST_FQ = Nif * x (* rest freq. for each IF in MHz *) LSR_VEL = Nif * x (* LSR vel. for each IF in km/s *) RAEPO = hh:mm:ss (* RA at epoch *) DECEPO = dd:mm:ss (* DEC at epoch *) EPOCH = nnnn / (* epoch, e.g. 2000 *) Multiple source records can be specified for the SU table. END / (* end of source records *) FREQUENCY TABLE =============== The frequency table is defined as follows: FQ_TABLE / FQID = n (* frequency ID *) FREQ = Nif * x (* freq. for each IF in MHz *) TOTBW = Nif * x (* bandwidth for each IF in MHz *) CHANBW = Nif * x (* channel BW for each IF in MHz *) SIDE = Nif * {0|1} / (* sideband (0=LSB; 1=USB) per IF *) Multiple FQ ID records can be specified for the FQ table. END / (* end of FQ ID records *) CATALOG HEADER ============== The catalog header, which defines the overall structure of the AIPS uv-data file, is specified as follows: CAT_HDR REF_FREQ = x (* reference freq. in MHz *) REST_FQ = x (* rest frequency in MHz *) NO_IF = n (* number of AIPS IF channels *) NO_CHAN = n (* number of freq. channels per IF *) STOKES = 4*{'RR'|'LL'|'RL'|'LR'} (* Stokes parameters defined in the file *) REF_DATE = dd/mm/yy (* reference date *) COMPRESS (* if present, then compress output data; this option not yet implemented *) / (* end of catalog header parameters *) CALIBRATION ERRORS ================== Calibration errors for each antenna, IF=n and polarization p = {R,L} are specified as follows: CAL_ERR LINPOL / (* LINPOL selects linearized polzn. errors; else second order is used *) STATION = 'name' FQID = n (* define antenna/FQID for this calibration error record *) BP_np = {1, bwth, cheb, phs, norm, v_1, v_2, v_3, v_4 } (* bandpass error (type 1), where bwth = Butterworth order for ampl. response cheb = Chebyshev order for phase response phs = Phase response ampl. (deg.) norm = {0 => no normalization; 1 => normalize} v_j = variability parameters (set to zero for no variability) or, *) {2, frac, time} (* bandpass error (type 2), where phs = phase/ampl. slope across band (0..1) time = phase/ampl. slope in time (0..1) *) DELA_np = 1, cheb, range, delay, offset (* delay errors, where cheb = Chebyshev order for delay error poly. range = Period in days for delay poly. from UT 0 delay = Delay error poly. ampl. (ns) offset = Polynomial offset (ns) *) PHAS_np = 1, cheb, range, phs, offset (* phase errors where, cheb = Chebyshev order of phase error poly. range = Period in days for phase poly. from UT 0 phs = Phase error poly. ampl. (deg) offset = Polynomial offset (deg) *) FEED_np = 1, ampl, phas (* polarization D-terms, where: ampl = D-term amplitude phas = D-term phase (deg.) *) GAIN_np = 1, gval (* gain, where gval = point source sensitivity *) TSYS_np = 1, cheb, range, tval, offset (* Tsys, where cheb = Chebyshev order of Tsys poly. range = Period in days of Tsys poly from UT 0 tval = Amplitude of Tsys polynomial offset = Polynomial offset *) GERR_np = 1, cheb, range, amperr, offset (* multiplicative gain error, where cheb = Chebyshev order of gain error poly. range = Period in days for err. poly. from UT 0 amperr = Gain error poly. ampl. offset = Gain error offset *) / (* end of calibration record for this STATION and FQID *) Multiple records can be defined for each STATION and FQID combination. END / (* end of the calibration error group *) SOURCE MODEL ============ The source model data are specified as follows: SU_MODEL / SOURCE = 'name' (* source name *) TYPE = {1, ra, dec, I, Q, U, V} (* point source, where ra = RA offset (asec) dec = DEC offset (asec) I, Q, U, V = flux density (Jy) *) {2, ra, dec, pa, maj, min, I, Q, U, V} (* Gaussian component, where ra = RA offset (asec) dec = DEC offset (asec) pa = position angle (deg) maj = major axis (asec) min = minor axis (asec) I, Q, U, V = flux density (Jy) *) / (* end of this source model *) Multiple source models can be defined. END / (* end of the source model data *) SCHEDULE RECORDS ================ The fake data are specified via schedule records not unlike those accepted by SCHED. The format is given below: SCHEDULE / DAY = n MONTH = n YEAR = nnnn (* day, month and year *) START = hh:mm:ss (* start of scan *) STOP = hh:mm:ss (* end of scan *) SOURCE = 'name' (* source name *) SUBA = n (* subarray number *) FQID = n (* frequency ID *) SELECT = +stat or -stat (* select (+) or de-select all baselines to a given station *) TINT = x / (* integration time (sec) *) Multiple schedule records can be defined. END / (* end of schedule *) EXAMPLE INPUT FILE ================== An example input file is given below: !---------------------------------------------------------------------- ! ! Fringe-fit test (no model, no noise) ! AN_TABLE VER=1 / STATION = 'ANT_1' LONG = 10:23:45.5 LAT = 23:45:46 MNT='AZEL' NO=1 / STATION = 'ANT_2' LONG = 9:12:12.9 LAT = 45:45:34 MNT='AZEL' NO=2 / STATION = 'ANT_3' LONG = 8:47:13.4 LAT = 12:50:32 MNT='AZEL' NO=3 / STATION = 'ANT_4' LONG = 6:50:00.0 LAT = 10:00:00 MNT='AZEL' NO=4 / END / ! ! FQ table data ! FQ_TABLE / FQID = 1 FREQ = 43000.0, 43001.0 TOTBW = 8.0, 8.0 CHANBW = 0.5, 0.5 SIDE = 1, 1 / END / ! ! SU table data ! SU_TABLE / SU_ID = 1 NAME = 'SRC_1' RAEPO = 12:00:00 DECEPO = 80:00:00 EPOCH = 2000 / END / ! ! Catalog header ! CAT_HDR / REF_FREQ = 43000.0 NO_IF = 2 NO_CHAN = 16 STOKES = 'RR', 'LL', 'RL', 'LR' REF_DATE = '01/02/96'/ ! ! Calibration errors: Delay and phase only ! CAL_ERR / STATION = 'ANT_1' FQID = 1 DELA_1R = 1, 1, 1.0, 30.0, 60.0 DELA_2L = 1, 9, 1.0, -5.0, 0 PHAS_1R = 1, 4, 1.0, 145.6, 40.0 / STATION = 'ANT_2' FQID = 1 DELA_1R = 1, 6, 1.0, -50.0, 0 DELA_2L = 1, 2, 1.0, 140.0, 0 PHAS_2L = 1, 8, 1, -56.0, 20.0 / STATION = 'ANT_3' FQID = 1 DELA_1R = 1, 1, 1, 88.0, 0 PHAS_2R = 1, 2, 1, -34.5, 10 / END / ! ! Source model data: point source unit flux density ! SU_MODEL / SOURCE = 'SRC_1' TYPE = 1,0,0,1,0,0,0,0,0,0,0,0 SPEC = 0,0,0,0,0 VEL = 0,0 / END / ! ! Schedule records ! SCHEDULE / ! ! All antennas ! START = 00:00:00 STOP = 01:00:00 DAY = 1 MONTH = 2 YEAR = 1996 SOURCE = 'SRC_1' SUBA = 1 FQID = 1 TINT = 2 / ! ! Exclude baselines to ANT_1 ! START = 03:00:00 STOP = 04:00:00 DAY = 1 MONTH = 2 YEAR = 1996 SOURCE = 'SRC_1' SUBA = 1 FQID = 1 TINT = 2 SELECT = '-ANT_1' / END / ! -----------------------------------------------------------------------