Chandra X-Ray Observatory
	(CXC)
Skip to the navigation links
Last modified: March 2017

URL: http://cxc.harvard.edu/ciao/ahelp/install_marx.html
AHELP for CIAO 4.9

install_marx

Context: tools

Synopsis

Automatically download and install MARX

Syntax

install_marx  [installdir]

Description

This script can be used to download and install the latest version of MARX. From the MARX website:

marx is a suite of programs created and maintained by the MIT/CXC/HETG group group and is designed to enable the user to simulate the on-orbit performance of the Chandra X-ray Observatory. marx provides a detailed ray-trace simulation of how Chandra responds to a variety of astrophysical sources and can generate standard FITS event files and images as output. It contains detailed models for Chandra's High Resolution Mirror Assembly (HRMA), the HETG and LETG gratings, and all the focal plane detectors.

marx can also use the SAOTrace ray files generated by ChaRT.

If users experience problems during the installation, please contact the MARX support team at marx-help@space.mit.edu. Users can find instructions for how to run MARX on the MARX home page.

Mac OSX users are encouraged to use a version of the GCC compilers instead of the default 'clang' compiler that Apple provides.

This script only works with the latest version of MARX. Users who require the a different version must install it manually.

Example

unix% install_marx /soft/marx

The script will automatically download the version of MARX via FTP from the MIT site and the will build and install it from source. Users need to have standard compilers (ie gcc) installed along with either wget or the lwp-download.

--2015-12-14 12:54:03--  ftp://space.mit.edu/pub/cxc/marx/v5.2/marx-dist-5.2.0.tar.gz
           => `marx-dist-5.2.0.tar.gz'
Resolving space.mit.edu... 18.75.0.10
Connecting to space.mit.edu|18.75.0.10|:21... connected.
Logging in as anonymous ... Logged in!
==> SYST ... done.    ==> PWD ... done.
==> TYPE I ... done.  ==> CWD (1) /pub/cxc/marx/v5.2 ... done.
==> SIZE marx-dist-5.2.0.tar.gz ... 12018160
==> PASV ... done.    ==> RETR marx-dist-5.2.0.tar.gz ... done.
Length: 12018160 (11M) (unauthoritative)

2015-12-14 12:54:06 (4.87 MB/s) - `marx-dist-5.2.0.tar.gz' saved [12018160]

checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
...

Some users, especially Mac OSX, may need to set special environment variables depending on their setup (CC, CFLAGS, LDFLAGS, etc). Please consult the MARX installation page for assistance.

After successfully building and installing MARX users will be provided instructions on how to setup the package:

...
Builds are complete.  

For MARX documentation and support please visit 
http://space.mit.edu/ASC/MARX/


To setup for this installation:

setenv MARX_ROOT /soft/marx/marx-5.2.0
setenv MARX_DATA_DIR ${MARX_ROOT}/share/marx/data
setenv PATH ${PATH}:${MARX_ROOT}/bin
setenv PFILES ${PFILES}:$MARX_ROOT/share/marx/pfiles

These commands are scripted in 

(t)csh: source /soft/marx/setup_marx.csh
bash: source /soft/marx/setup_marx.sh

Parameters

name type ftype reqd
installdir file output no

Detailed Parameter Descriptions

Parameter=installdir (file not required filetype=output)

Installation directory

The top level directory to install MARX. The actual installation will be in a version-numbered sub-directory.

If no directory is specified, the script will attempt to install marx into CIAO's $ASCDS_INSTALL root directory.

Changes in scripts CIAO 4.8.4 (September 2016) release

Corrects the export of the MARX_DATA_DIR environment varialbe in the bash setup script.

Changes in scripts CIAO 4.8.3 (April 2016) release

The script will now try to install the latest version of MARX available on the MARX FTP site.

If no installation directory is supplied, the script will try to install MARX into CIAO root directory, $ASCDS_INSTALL.

Users are now prompted to continue before the installation occurs.

Changes in the scripts 4.9.2 (April 2017) release

Fix for a problem when using Python 3.

About Contributed Software

This script is not an official part of the CIAO release but is made available as "contributed" software via the CIAO scripts page. Please see the installation instructions page for help on installing the package.

Bugs

Installing MARX with the default OSX C compiler

The default C compiler in OSX is clang, which is aliased to gcc. While MARX compiles successfully with clang, several problematic issues have been seen in the resulting MARX build. The MARX developers suggest using a true gcc compiler, obtainable at http://hpc.sourceforge.net/ for Max OS X, as noted in Known Bugs and Limitations -- Max OS X. The real gcc needs to be manually installed and put early in the PATH environment variable, otherwise the broken Mac OS X version will be picked up. Prior to installing MARX, it may also be worthwhile to set the CC environment variable to the gcc

For example, if the new gcc is installed in /usr/local/bin/, then set the C compiler variable CC:

(t)csh% setenv CC /usr/local/bin/gcc

or

bash% export CC=/usr/local/bin/gcc

See Also

tools
aconvolve, acrosscorr, arestore, arfcorr, dmcoords, dmfilth, dmregrid, make_psf_asymmetry_region, psf_project_ray, psfsize_srcs, simulate_psf, src_psffrac

Last modified: March 2017
Smithsonian Institute Smithsonian Institute

The Chandra X-Ray Center (CXC) is operated for NASA by the Smithsonian Astrophysical Observatory. 60 Garden Street, Cambridge, MA 02138 USA.   Email:   cxchelp@head.cfa.harvard.edu Smithsonian Institution, Copyright © 1998-2017. All rights reserved.