https://casaguides.nrao.edu/index.php?title=Simulating_Observations_in_CASA_4.4&feed=atom&action=historySimulating Observations in CASA 4.4 - Revision history2024-03-28T19:16:42ZRevision history for this page on the wikiMediaWiki 1.38.6https://casaguides.nrao.edu/index.php?title=Simulating_Observations_in_CASA_4.4&diff=18218&oldid=prevRindebet at 14:17, 20 November 20152015-11-20T14:17:44Z<p></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 10:17, 20 November 2015</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l77">Line 77:</td>
<td colspan="2" class="diff-lineno">Line 77:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div><u>Taskname History</u></div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div><u>Taskname History</u></div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div><del style="font-weight: bold; text-decoration: none;">The simulation tasks have been under significant revision and development.</del></div></td><td colspan="2" class="diff-side-added"></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>* In CASA 3.3 <tt>simobserve</tt> and <tt>simanalyze</tt> were named <tt>sim_observe</tt> and <tt>sim_analyze</tt>, respectively. </div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>* In CASA 3.3 <tt>simobserve</tt> and <tt>simanalyze</tt> were named <tt>sim_observe</tt> and <tt>sim_analyze</tt>, respectively. </div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>* In CASA 3.4 and earlier, the functionality of both tasks was contained in task simdata, which is now obsolete.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>* In CASA 3.4 and earlier, the functionality of both tasks was contained in task simdata, which is now obsolete.</div></td></tr>
</table>Rindebethttps://casaguides.nrao.edu/index.php?title=Simulating_Observations_in_CASA_4.4&diff=18212&oldid=prevRindebet at 13:53, 20 November 20152015-11-20T13:53:03Z<p></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 09:53, 20 November 2015</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l1">Line 1:</td>
<td colspan="2" class="diff-lineno">Line 1:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>[[Category: Simulations]] </div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>[[Category: Simulations]] </div></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div><del style="font-weight: bold; text-decoration: none;"></del></div></td><td colspan="2" class="diff-side-added"></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div><del style="font-weight: bold; text-decoration: none;">[[VLA Hybrid Array Simulation]]</del></div></td><td colspan="2" class="diff-side-added"></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>* This guide describes steps used to simulate interferometric observations in CASA.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>* This guide describes steps used to simulate interferometric observations in CASA.</div></td></tr>
</table>Rindebethttps://casaguides.nrao.edu/index.php?title=Simulating_Observations_in_CASA_4.4&diff=18211&oldid=prevRindebet at 13:52, 20 November 20152015-11-20T13:52:12Z<p></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 09:52, 20 November 2015</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l1">Line 1:</td>
<td colspan="2" class="diff-lineno">Line 1:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>[[Category: Simulations]] </div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>[[Category: Simulations]] </div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;"></ins></div></td></tr>
<tr><td colspan="2" class="diff-side-deleted"></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div><ins style="font-weight: bold; text-decoration: none;">[[VLA Hybrid Array Simulation]]</ins></div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>* This guide describes steps used to simulate interferometric observations in CASA.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>* This guide describes steps used to simulate interferometric observations in CASA.</div></td></tr>
</table>Rindebethttps://casaguides.nrao.edu/index.php?title=Simulating_Observations_in_CASA_4.4&diff=18146&oldid=prevJbraatz at 17:03, 3 November 20152015-11-03T17:03:54Z<p></p>
<table style="background-color: #fff; color: #202122;" data-mw="interface">
<col class="diff-marker" />
<col class="diff-content" />
<col class="diff-marker" />
<col class="diff-content" />
<tr class="diff-title" lang="en">
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">← Older revision</td>
<td colspan="2" style="background-color: #fff; color: #202122; text-align: center;">Revision as of 13:03, 3 November 2015</td>
</tr><tr><td colspan="2" class="diff-lineno" id="mw-diff-left-l16">Line 16:</td>
<td colspan="2" class="diff-lineno">Line 16:</td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div># Image the simulated observation with the <tt>simanalyze</tt> task.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div># Image the simulated observation with the <tt>simanalyze</tt> task.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker" data-marker="−"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;"><div>The [http://casa.nrao.edu/docs/TaskRef/simobserve-task.html <tt>simobserve</tt>] task generates the visibilities that would be measured by observing the specified input model of sky brightness. The user needs to specify a telescope to use for the observation. CASA includes a set of configuration files for ALMA, the VLA, CARMA, the SMA<del style="font-weight: bold; text-decoration: none;">, ATCA</del>, and the Plateau de Bure interferometers. A table of configuration files shipped with CASA is available [http://casaguides.nrao.edu/index.php?title=Antenna_Configurations_Models_in_CASA here]. The <tt>simobserve</tt> task can add thermal noise to the visibilities. The <tt>simobserve</tt> task uses the [http://www.mrao.cam.ac.uk/~bn204/alma/atmomodel.html aatm] atmospheric model (based on Juan Pardo's [http://cab.inta-csic.es/users/jrpardo/class_atm.html ATM] library) to simulate real observing conditions and introduce atmospheric "corruption", i.e. noise and phase delay.</div></td><td class="diff-marker" data-marker="+"></td><td style="color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;"><div>The [http://casa.nrao.edu/docs/TaskRef/simobserve-task.html <tt>simobserve</tt>] task generates the visibilities that would be measured by observing the specified input model of sky brightness. The user needs to specify a telescope to use for the observation. CASA includes a set of configuration files for ALMA, the VLA, CARMA, the SMA, and the Plateau de Bure interferometers. A table of configuration files shipped with CASA is available [http://casaguides.nrao.edu/index.php?title=Antenna_Configurations_Models_in_CASA here]. The <tt>simobserve</tt> task can add thermal noise to the visibilities. The <tt>simobserve</tt> task uses the [http://www.mrao.cam.ac.uk/~bn204/alma/atmomodel.html aatm] atmospheric model (based on Juan Pardo's [http://cab.inta-csic.es/users/jrpardo/class_atm.html ATM] library) to simulate real observing conditions and introduce atmospheric "corruption", i.e. noise and phase delay.</div></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><br/></td></tr>
<tr><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>Next, the [http://casa.nrao.edu/docs/TaskRef/simanalyze-task.html <tt>simanalyze</tt>] task is used to produce a cleaned image based on the generated visibilities. It can compare the simulated image with your input (convolved with the output clean beam) and then calculate a "fidelity image" that indicates how well the simulated output matches the convolved input image.</div></td><td class="diff-marker"></td><td style="background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;"><div>Next, the [http://casa.nrao.edu/docs/TaskRef/simanalyze-task.html <tt>simanalyze</tt>] task is used to produce a cleaned image based on the generated visibilities. It can compare the simulated image with your input (convolved with the output clean beam) and then calculate a "fidelity image" that indicates how well the simulated output matches the convolved input image.</div></td></tr>
</table>Jbraatzhttps://casaguides.nrao.edu/index.php?title=Simulating_Observations_in_CASA_4.4&diff=17370&oldid=prevJbraatz: Created page with "Category: Simulations * This guide describes steps used to simulate interferometric observations in CASA. * The Guide_To_Simulating_ALMA_Data | Guide to Simulating AL..."2015-07-06T22:22:11Z<p>Created page with "<a href="/index.php?title=Category:Simulations" title="Category:Simulations">Category: Simulations</a> * This guide describes steps used to simulate interferometric observations in CASA. * The Guide_To_Simulating_ALMA_Data | Guide to Simulating AL..."</p>
<p><b>New page</b></p><div>[[Category: Simulations]] <br />
<br />
* This guide describes steps used to simulate interferometric observations in CASA.<br />
<br />
* The [[Guide_To_Simulating_ALMA_Data | Guide to Simulating ALMA Data]] gives an introduction to simulations, with examples and a discussion of their relevance to ALMA observing proposals<br />
<br />
* '''This guide is applicable to CASA version 4.4. For older versions of CASA please see [[Simulating Observations in CASA 4.3]].'''<br />
<br />
<br />
== Simulating Interferometric Observations in CASA ==<br />
<br />
Simulating interferometric observations in CASA proceeds in the following steps:<br />
<br />
# Make a model image. The model image is a representation of the sky brightness distribution that you would like to simulate observing, stored initially as a FITS file. There are several paths to making the FITS file, discussed below.<br />
# Generate uv data with the <tt>simobserve</tt> task. <br />
# Image the simulated observation with the <tt>simanalyze</tt> task.<br />
<br />
The [http://casa.nrao.edu/docs/TaskRef/simobserve-task.html <tt>simobserve</tt>] task generates the visibilities that would be measured by observing the specified input model of sky brightness. The user needs to specify a telescope to use for the observation. CASA includes a set of configuration files for ALMA, the VLA, CARMA, the SMA, ATCA, and the Plateau de Bure interferometers. A table of configuration files shipped with CASA is available [http://casaguides.nrao.edu/index.php?title=Antenna_Configurations_Models_in_CASA here]. The <tt>simobserve</tt> task can add thermal noise to the visibilities. The <tt>simobserve</tt> task uses the [http://www.mrao.cam.ac.uk/~bn204/alma/atmomodel.html aatm] atmospheric model (based on Juan Pardo's [http://cab.inta-csic.es/users/jrpardo/class_atm.html ATM] library) to simulate real observing conditions and introduce atmospheric "corruption", i.e. noise and phase delay.<br />
<br />
Next, the [http://casa.nrao.edu/docs/TaskRef/simanalyze-task.html <tt>simanalyze</tt>] task is used to produce a cleaned image based on the generated visibilities. It can compare the simulated image with your input (convolved with the output clean beam) and then calculate a "fidelity image" that indicates how well the simulated output matches the convolved input image.<br />
<br />
The new task <tt>simalma</tt> is available to simplify the process of simulating data that combines the 12-m Main Array and the ACA. The best way to learn <tt>simalma</tt> is to follow the tutorial linked near the bottom of this page.<br />
<br />
=== Generating a Model Image ===<br />
<br />
A "model image" is a FITS file that contains a representation of the sky brightness distribution, and it represents the object to be "observed" in the simulation. The FITS file must contain a realistic set of spatial axes, and a realistic flux density. There are several ways to generate a model image.<br />
<br />
* '''Starting from an existing FITS image'''<br />
<br />
The simplest option is to begin with an existing FITS image of a millimeter or submillimeter observation. The FITS image can be either a single plane (i.e. one observed frequency channel) or a cube. A common simulation exercise is to begin with a FITS file representing an observation of a target, then scale the spatial axes and the flux to shift the data to what would be observed for a similar target at a different distance. The <tt>simobserve</tt> task has parameters to set the peak flux density, coordinates on the sky, pixel size, frequency of the center channel, and channel width. See the discussion below.<br />
<br />
* '''Starting from a component list'''<br />
<br />
It may be useful to simulate observations of an idealized model image consisting, for example, of point sources and Gaussians. The CASA component list tool (<tt>cl</tt>) allows the user to create a FITS file by specifying a set of point sources, Gaussians, disks, and limb-darkened disks. Each of these is a "component" in the FITS image. [http://casaguides.nrao.edu/index.php?title=Simulation_Guide_Component_Lists_%28CASA_4.1%29 This CASA guide] provides an example of creating a FITS file from a component list.<br />
<br />
* '''Starting from a GIF or JPG image'''<br />
<br />
A user may wish to convert a GIF or JPG image to a FITS file for simulation in CASA. The image should be converted to a 32-bit FITS image for use with the CASA sim tools. See [http://casaguides.nrao.edu/index.php?title=Convert_jpg_to_fits this page] for an example of using <tt>gimp</tt> to convert a JPG image to a FITS file. Alternatively, you could use ImageMagik, like so:<br />
<br />
convert myfile.jpg myfile.fits<br />
<br />
Then proceed to trim and convert the file in CASA like so:<br />
<br />
importfits(fitsimage='myfile.fits',imagename='testimage',overwrite=T)<br />
default 'immath'<br />
imagename = 'testimage'<br />
expr = 'IM0'<br />
box = '0,0,299,299'<br />
outfile = 'testimage2'<br />
immath()<br />
exportfits(imagename ='testimage2',fitsimage ='myfile.fits',overwrite=T)<br />
<br />
You could also use the parameters in the <tt>simobserve</tt> task to modify the peak flux density, coordinates on the sky, pixel size, frequency of the center channel, and channel width. See the discussion below.<br />
<br />
=== Generating visibilities with '''simobserve''' ===<br />
<br />
The task [http://casa.nrao.edu/docs/TaskRef/simobserve-task.html <tt>simobserve</tt>] takes several steps to generate observed visibilities. The major steps are:<br />
<br />
* Modify Model. If desired, you can modify the header parameters in your data model to mimic different observing targets. For example, if you start with a model of M100 you might wish to scale the axes to simulate an observation of an M100-like galaxy that is 4X more distant. The settable parameters include:<br />
** '''inbright''': Scaling the model flux densities by setting the peak flux density of the brightest pixel, e.g. "1.2Jy/pixel"<br />
** '''indirection''': Set the center target coordinates, e.g. "J2000 19h00m00 -40d00m00"<br />
** '''incell''': Set the angular size of each pixel, e.g. "0.1arcsec"<br />
** '''incenter''': Set the observed sky frequency. If the model is a spectral cube, this parameter applies to the center channel.<br />
** '''inwidth''': Set the channel width, e.g. "10MHz"<br />
* Set Pointings. If the angular size of your model image is comparable or larger than the 12-m primary beam, you can simulate observing the target as a mosaic. In this step, the individual pointings are determined and saved in a text file. You can also generate such a text file yourself.<br />
* Generate visibilities. The visibilities are determined based on the telescope and configuration specified, and the length in time of the observation. Here is a [[Antenna_Configurations_Models_in_CASA| list of configuration files available in CASA 4.4]].<br />
* Add noise. Finally, noise is added to the visibilities.<br />
<br />
=== Transforming to images with '''simanalyze''' ===<br />
<br />
The task [http://casa.nrao.edu/docs/TaskRef/simanalyze-task.html <tt>simanalyze</tt>] then images the visibility data using CASA's [http://casa.nrao.edu/docs/TaskRef/clean-task.html <tt>clean</tt>] task. It also calculates and displays the difference between the simulates observation and the original model data, and it generates a "fidelity image". Fidelity is defined as I/| I-T |, where I is the observed image intensity and T is the true image intensity, given in this case by the sky model. <br />
# Image - Image the visibility data with CASA's [http://casa.nrao.edu/docs/TaskRef/clean-task.html <tt>clean</tt>] task.<br />
# Analyze - Calculate and display the difference between output and input, and the fidelity image.<br />
<br />
The [http://casaguides.nrao.edu/index.php?title=Simulation_Guide_for_New_Users_(CASA_4.4) Simulation Guide for New Users] tutorial introduces and explains the individual steps in detail. It is possible to run the steps independently and optionally, as long as you follow the <tt>simobserve</tt> and <tt>simanalyze</tt> conventions about filenames. <br />
<br />
<u>Taskname History</u><br />
<br />
The simulation tasks have been under significant revision and development.<br />
* In CASA 3.3 <tt>simobserve</tt> and <tt>simanalyze</tt> were named <tt>sim_observe</tt> and <tt>sim_analyze</tt>, respectively. <br />
* In CASA 3.4 and earlier, the functionality of both tasks was contained in task simdata, which is now obsolete.<br />
* In CASA 4.1, the task [http://casa.nrao.edu/docs/TaskRef/simalma-task.html <tt>simalma</tt>] was introduced. This task simplifies simulation of 12 m interferometric + 7 m interferometric + total power ALMA observations.<br />
<br />
== Tutorials ==<br />
<br />
{| style="width: 100%; valign: top; background-color:#E0FFFF; border:1px solid #3366FF; text-align: center; cellpadding=0"<br />
<br />
! [[Simulation Guide for New Users (CASA 4.4)]]<br />
| rowspan=2 style="border-bottom:1px solid black;" | [[File:30Dor_ES.png|100px]]<br />
|-<br />
| style="border-bottom:1px solid black;" | A fully annotated tutorial that uses a Spitzer SAGE 8 micron continuum image of 30 Doradus and scales it to greater distance. A good place for new users to start.<br />
|- <br />
! [[Protoplanetary Disk Simulation (CASA 4.4)]]<br />
| rowspan=2; stype="border-bottom:1px solid black;" | [[File:Psimthumb.png|100px]]<br />
|-<br />
| style="border-bottom:1px solid black;" | A sky model with a lightly annotated script that simulates a protoplanetary disk. Uses a theoretical model of dust continuum from Sebastian Wolff, scaled to the distance of a nearby star. This is another fairly generic simulation - if you're short on time, you probably don't need to go through this one and the New Users guide, but it can be useful to go through multiple examples.<br />
|-<br />
<br />
<!--<br />
! [[M51 at z = 0.1 and z = 0.3 (CASA 4.4)]]<br />
| rowspan=2; style="border-bottom:1px solid black;" | [[File:M51thumb.png|100px]]<br />
|-<br />
| style="border-bottom:1px solid black;" | A fully annotated tutorial that uses a BIMA-SONG cube of a nearby galaxy and scales it to greater distance.<br />
|- --><br />
<br />
! [[Simulation Guide Component Lists (CASA 4.4)]]<br />
| rowspan=2; style="border-bottom:1px solid black;" | [[File:Analyze_fits_list.jpg|100px]]<br />
|-<br />
| style="border-bottom:1px solid black;" | Tutorial for simulating data based on multiple sources (using both a FITS image and a component list). If you are interested in simulating from a list of simple sources (point, Gaussian, disk), rather than or in addition to a sky model image, then read the considerations here.<br />
|-<br />
<br />
<!--<br />
! [[N891 simdata (CASA 3.4)]]<br />
| rowspan=2; style="border-bottom:1px solid black;" | [[File:N891thumb.png|100px]]<br />
|-<br />
| style="border-bottom:1px solid black;" | A sky model, script, and discussion that simulates a nearby edge-on spiral galaxy. Uses a galactic CO cube from the Galactic Ring Survey and places it at 10Mpc. The data are similar to what NGC891 would look like if it were observable from the southern hemisphere.<br />
|- --><br />
<br />
! [[Einstein-Face (CASA 4.4)]]<br />
| rowspan=2; style="border-bottom:1px solid black;" | [[File:einstein_fs_cfg8_1hr.gif|100px]]<br />
|-<br />
| style="border-bottom:1px solid black;" | A sky model and lightly annotated script that simulates the face of Einstein as seen by ALMA. This simulation is particularly useful for those who wish to better understand spatial filtering by an interferometer, but doesn't demonstrate new capabilities of the simulation tasks beyond those described above.<br />
|-<br />
<br />
! [[ACA Simulation (CASA 4.4)]]<br />
| rowspan=2; style="border-bottom:1px solid black;" | [[File:M51c.ALMA 0.5arcsec.skymodel.png|100px]]<br />
|-<br />
| style="border-bottom:1px solid black;" | A tutorial for simulating ALMA observations that use multiple configurations or use the 12-meter array in combination with the ALMA Compact Array. This tutorial demonstrates combining data from each ALMA component "by hand". This guide is of particular interest to those wishing to explore using the 12-m array in combination with the ACA, and those interested in combining data from multiple 12-m array configurations.<br />
|-<br />
<br />
<!-- ! [http://casaguides.nrao.edu/index.php?title=Simalma_v2 simalma] --><br />
! [[Simalma (CASA 4.4)]]<br />
| rowspan=2; style="border-bottom:1px solid black;" | [[File:M51c.ALMA 0.5arcsec.skymodel.png|100px]]<br />
|-<br />
| style="border-bottom:1px solid black;" | This tutorial demonstrates how to use '''simalma''', a task that simplifies simulations that include the main 12-m array plus the ACA. Like the previous guide, this one is of particular interest to those wishing to explore multi-component ALMA observations.<br />
|}<br />
<br />
=== Example Input Images ===<br />
<br />
Several examples of input model images are showcased here: [[Sim Inputs]]. These may be useful for running your own simulation tests, beyond what are presented in the above tutorials.<br />
<br />
== Advanced CASA Simulation ==<br />
<br />
=== Under the Hood: The sm Tool ===<br />
<br />
<tt>simobserve</tt> calls methods in the '''sm''' (simulation) tool. For advanced CASA users, the <tt>sm </tt> tool has methods that can add to simulated data: phase delay variations, gain fluctuations and drift, cross-polarization, and (coming soon) bandpass and pointing errors. <tt>sm </tt> also has more flexibility than <tt>simobserve</tt> in adding thermal noise. The tutorials linked from this page describe the simulation of data using the task interface only. To learn more about the <tt>sm</tt> tool, see the [http://casa.nrao.edu/docs/CasaRef/CasaRef.html CASA Toolkit Reference Manual].<br />
<br />
The <tt>sm </tt> tool can be used to corrupt your measurement set with thermal noise, phase noise, cross-polarization, etc., in a more advanced way than is done in <tt>simobserve</tt>. To learn advanced techniques for corrupting a simulated measurement set, see [[Corrupt]].<br />
<br />
=== Ephemeris and Geodesy ===<br />
<br />
Generic ephemeris and geodesy calculations can be done using CASA Python module [[simutil.py]].<br />
<br />
== Warning: CLEAN Bias == <br />
<br />
As is the case for real images, cleaning images produced by <tt>simobserve</tt> can lead to a spurious decrease in object fluxes and noise on the image (an effect known as "clean bias"). This is particularly true for observations with poor coverage of the uv-plane, i.e. using telescopes with small numbers of antennas, such as the ALMA Early Science configurations, and/or in short "snapshot" observations. Users should always clean images with care, using a small number of iterations and/or a conservative (3-5sigma) threshold and boxing bright sources.<br />
<br />
== User Feedback ==<br />
<br />
We welcome input on developing the CASA simulator. Contact "rindebet at nrao.edu" if you would like to volunteer your input.</div>Jbraatz