# gamit **Repository Path**: gnss2020/gamit ## Basic Information - **Project Name**: gamit - **Description**: GNSS 数据处理软件Gamit - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 3 - **Created**: 2024-11-30 - **Last Updated**: 2024-11-30 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README 12345678901234567890123456789012345678901234567890123456789012345678901234567890 File : ftp/pub/gps/updates/README Last updated 9 March 2020 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * This file and the files of source code for GAMIT, GLOBK and FONDA have * * minimal password protection in order that users of the software might have * * convenient access to updates. We ask anyone reading this message to honor * * the spirit of our offering by not copying code without notifying * * rwk@chandler.mit.edu. This notification implies that you will abide by the * * terms of the public license and assures that you will receive notification * * of bugs and updates. Support from the US government for development of the * * software is contingent on our being able to document its widespread use * * through licenses. License of the code is without charge to universities and * * governmental institutions for research and educational purposes; commercial * * licenses are also available at a fee. * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Please read this document carefully before installing the software, as there are important system-dependent caveats that you need to know about to avoid wasting time. Before copying source files, you should copy and read carefully the release notes (source/relnote.10.71) to see whether you need to update and what changes have been made from the last release. This directory contains GAMIT/GLOBK release 10.71 created on 9 March 2020. To install the complete software from source code you should copy the tar-files described below, including incremental_updates if available, into your top-level directory then execute "install_software", answering "y" to the question about installing the incremental updates if available. If you are installing incrementals alone (10.71 is already installed), see the note below regarding libraries/Makefile.config. We recommend performing all of the installation steps as a user other than "root" since the directory and file permissions for "root" are often restrictive and may prevent other users (or you, if you run under a different user name) from writing files during your processing. There is nothing in the GAMIT installation that requires root access. We are not currently providing executables since these have proven too system- dependent to be useful in most cases. The recommended free compiler for Linux is gfortran (GCC 4.2 or higher, except for gfortran 4.3 and 7, which have some bugs). You may not use the gfortran compilers distributed with gcc 4.0 or 4.1.1, which have an incomplete set of libraries. If you are using g77 (gcc < 4.0), see "installing_g77" in the documentation/ directory. If you are using gcc 4.6, you must add "-fno-whole-file" to FFLAGS to avoid a bug with the optimization (a GAMIT workaround is in progress). You may use either bash or csh for your terminal shell, but csh and tcsh must be installed because many scripts explictly invoke one or the other. The environment variable for numeric preferences in .cshrc or .bashrc must be set to ensure the decimal separator is a dot, not a comma (e.g. LC_NUMERIC=C). EOP and the MIT station.info files are kept up-to-date daily in incremental_updates/tables/. The dcb.dat file for differential code biases (needed for lc_autcln and clock estimates) is updated on the 8th day of each month. The large grid files for ocean tidal loading (OTL), tidal (atl.grid) and non-tidal (atmdisp or atmfilt) atmospheric loading (ATML), and VMF1 mapping functions are now stored separately from the GAMIT/GLOBK distribution, in the (public) anonymous FTP site on everest.mit.edu (cd pub/GRIDS/). The VMF1 and ATML files for the current year are updated daily. Note that atl.list, atml.list, map.list, met.grid and met.list files do not currently exist and hence will create broken but harmless links in the experiment tables directory and the day directories. Platforms supported ------------------- The current version of this code has been compliled and tested successfully on: - Ubuntu 18.04 LTS with GNU gcc/gfortran 8.3.0 or 6.5.0, but compilation with the default gcc/gfortran 7.4.0 fails at arbitrary points with a message including "See for instructions."; - Ubuntu 16.04 LTS with the default GNU gcc/gfortran 5.4.0; - CentOS 6.10 with GNU gcc/gfortran 4.8.4; - Debian 9 with the default GNU gcc/gfortran 6.3.0; - openSUSE Leap 15.1 with GNU gcc/gfortran 8.2.1, but compilation with the default GNU gcc/gfortran 7.4.0 fails at arbitrary points with a message including "See for instructions."; - openSUSE Leap 42.3 with the default GNU gcc/gfortran 4.8.5; - macOS 10.14.6 (Mojave) with native clang 11.0.0 and gfortran 8.2.0 from https://gcc.gnu.org/wiki/GFortranBinaries#MacOS; - macOS 10.13.6 (High Sierra) with native clang 10.0.0 and gfortran 8.2.0 from https://gcc.gnu.org/wiki/GFortranBinaries#MacOS. Former versions of this code had been tested on Solaris 2.5-8, HP-UX 9, 10 and 11, Digital Unix (OSF1 V4.0) and IRIX 6.4 with native compilers; on Linux (Ubuntu, RedHat 5.1 to 7.3, Fedora Core 3 to 8, Mandrake, CentOS and Gentoo) with GNU gcc/gfortran 4.2 and Intel ifort/ifc 8, 9 and 10 compilers; for Mac OS X 10.2 and higher with the gcc/g77 or gcc/gfortran 4.2 and Intel icc/ifort compilers; and for Cygwin on Windows with the gfortran compiler. See the notes on gfortran in the documentation/ directory and do NOT try to compile with any version of gfortran earlier than 4.2. See the important notes under "System- specific irregularies" below regarding older Linux installations and older versions of gcc/g77. For a macOS installation, see documentation/MacOSX/ and the instructions by Gilles Celli of ECGS at http://www.ecgs.lu/gilles/blog/install-gamit-10-4-x-on-mac-os-x-lion-10-7-x/. Note that if you mix workstations with little-endian (Intel, AMD, DEC) and big- endian (Sun, HP) binary representation in your network, you will need to be careful keep c- and t-files separate, and to use the kf/ utility "swaph" to convert binary H-files. You do not need to worry about the binary ocean tide, atmospheric loading, or VMF mapping function grid files since program "grdtab" does the byte-swap for this file automatically when it reads the file. Directory name restriction -------------------------- You may not use a "." (dot) in the names of directories accessed by sh_gamit or sh_glred. Additional software required ---------------------------- To include translation of raw data in your processing, you will need to copy onto your system and add to your search path the UNAVCO teqc program, available on the web at http://www.unavco.org/facility/software/teqc/teqc.html (note that teqc is now no longer maintained and the 2019-02-25 release is the final version). To use the interactive program "cview" to view residuals, you will need to have included X11 in your Linux installation. To generate plots of your results, you will need the Generic Mapping Tools (GMT) developed by Wessel and Smith at the University of Hawaii. These are available on the web at https://www.generic-mapping-tools.org/ or https://github.com/GenericMappingTools/gmt/releases/. The plotting scripts in the com/ directory for release 10.6 and beyond use GMT 5 syntax but if you wish to continue using GMT 4 temporarily you may prepend com_preGMT5/ ahead of com/ in your path so that its scripts will be invoked for plotting. The MATLAB interactive plotting programs "tsview" and "velview" are not included in the updates/source/ directory but can be downloaded as instructed at http://geoweb.mit.edu/~tah/GGMatlab/. For details of other required or suggested third-party software for various operating systems, see http://geoweb.mit.edu/gg/pre.php or GAMIT_prerequisites.pdf in the documentation/ directory. Installation ------------ We recommend creating a top-level directory for all the software (e.g. gamit_globk/) and transfer into it (e.g. using "ftp" in binary mode) into it the following from the updates/source/ directory: install_software (installation shell script) install_updates (shell script for updates only) com.10.71.tar.gz 767 kB com_preGMT5.10.71.tar.gz 195 kB (not required if using GMT 5 or above) libraries.10.71.tar.gz 121 kB gamit.10.71.tar.gz 4.3 MB kf.10.71.tar.gz 2.6 MB tables.10.71.tar.gz 45 MB test_install.10.71.tar.gz 665 kB help.10.71.tar.gz 465 kB maps.10.71.tar.gz 9.8 MB TOTAL = 64 MB For trackRT you will also need the small files trackRT_pbo.cmd and cron.sp3u. The instructions for installing trackRT may be found in help/trackRT.hlp. Before continuing, make sure you are at the top level of the GAMIT/GLOBK directories; that you have in that directory the current versions of "install_software" and "install_updates" and that they are marked exectuable after the ftp; and that "." and the new com/ directories are in your path ahead of a directory containing older versions of the scripts. Also, inspect and edit libraries/Makefile.config, setting the GAMIT dimensions, the correct name and path for the compiler you plan to use and for your X11 libraries. The current Makefile.config assumes that you have a 64-bit machine; if not, then remove the -m64 and -DADD64BIT options from FFLAGS and CFLAGS, respectively. Since gamit/solve/Makefile.generic has special entries for FFLAGS, you need to change these also. In incremental_updates/, the Makefile.config is named Makefile.config.new so that you will not inadvertently overwrite an older version that has your local X11 paths. It is highly recommended that you edit X11LIBPATH and X11INCPATH to something appropriate for your system before running install_software. The install scripts no longer initially search the entire system for the appropriate libX11 and Xlib.h files because this can be a very slow step. Instead, the search occurs only in the X11LIBPATH and X11INCPATH specified by the user in libraries/Makefile.config (/usr/lib/X11 and /usr/include/X11, respectively, by default). When you run install_software or install_updates, you will be asked to confirm that the paths are correct. If you answer "no" the script will undertake a system-wide search to provide suggestions for X11LIBPATH and X11INCPATH. If more than one path is found, you must manually edit libraries/Makefile.config and re-run install_software or install_updates. An alternative approach to handling X11 is to use the generic paths in Makefile.config and create aliases on your system; e.g., for Solaris 2 with Openwindows, ln -s /usr/openwin/lib /usr/lib/X11 ln -s /usr/openwin/share/include /usr/include/X11 For the 64bit Redhat Enterprise system, there may be a link missing, which you should add: /usr/X11R6/lib64/libX11.so -> /usr/X11R6/lib64/libX11.so.6.2 There may also be some other local variations that are not accounted for. For example, we have assumed "fort77" and "f77" as the Fortran compilers for HP and Sun, respectively, and "cc" as the C compiler on both systems. If you are using another compiler or want to adjust the compiler flags, you will need to edit Makefile.config for your local configuration. In particular, if you are using gfortran with Solaris (on Sun hardware), you should replace the four lines of the # ASSIGNMENTS block for OS_ID Sun OS 5200 5800 with those for PC Solaris; viz: # ----- for SunOS from 5.2 to 5.8 (Solaris 2.2 to 2.8) -- # OS_ID SunOS 5200 5800 # ASSIGMENTS FFLAGS = -O3 -Wuninitialized -Wunused -Wimplicit -fno-f2c -ffast-math -fno-automatic -fno-backslash -Wno-globals -fno-globals FTN = gfortran CFLAGS = -g -c CC = gcc Then, to compile the source, type at the top level: install_software or, if you are overriding the default compiler (gftn) for your system, type install_software -c which will execute the following steps: - uncompress and extract the source files - prompt you to set your search paths - prompt you to check files (and edit if necessary) for system-dependent settings (X11 path, GAMIT dimension); if there is a unique path to X11 on your system, the script will find it automatically - make the Makefiles and programs in the libraries/, gamit/ and kf/ directories removing any existing Makefiles or archive (.a) files in the module directories. The install script will set temporarily the appropriate paths to allow the software to be compiled and linked, but before you can use it you will need to put additional paths into your .cshrc or .login files. If [mypath] is the absolute path to the directory for the GNSS software, then you should add to the path variable in .cshrc or .login [mypath]/com [mypath]/gamit/bin [mypath]/kf/bin To allow the software to find tables from your processing directories, you need to put into your home directory the alias or link gg --> [mypath], and set the environment variable in .cshrc or .login setenv HELP_DIR [mypath]/help The install_software script is (we think) fail-safe in the sense that it will run correctly even if some of the steps have already been accomplished. Following are the individual steps followed by the install script so that you can execute them individually: Untar at the top level (e.g., gamit_globk, aliased to gg) EACH of the compressed tarfiles using, e.g. gzip -d -c gamit.10.71.tar.Z | tar -xfv - The result will be the following directory structure under gg: com/ gamit/ kf/ libraries/ tables/ example/ maps/ help/ bin/ arc/ etc. bin/ globk/ etc. comlib/ matrix/ Next you need to set or check the X11 library path, GAMIT dimensions, and possibly the compiler flags appropriate for your operating system. These are recorded in the "Makefile.config" files for the libraries/, gamit/ and kf/ directories. In the current release, there is a single original of this in libraries/, to which there are symbolic links in gamit/ and kf/. There are default values for the compiler switches recorded for Solaris 2, and HP systems. Dimensioning of the GAMIT modules is a function of the size of the networks and data files you wish to analyze, and the size of the swap space on your workstations. The largest modules are solve, cview and scandd, which require about 300 MB for 60 stations and 2880 epochs (24 h at 30 s sampling). You set the sizes at installation by editing the MAXSAT, MAXSIT, MAXATM, and MAXEPC entries in libraries/Makefile.config. The internal logic limits the maximum number of sites to 99, but above about 50 it is much more efficient to process subnetworks in parallel and combine them in GLOBK. The maximum number of total zenith-delay parameters (maxsit x maxatm) is limited to 2500. When the GAMIT installation script is run, the dimensions of the appropriate arrays in include files (in gamit/includes/) will be updated. (The gamit/clean/ dimension NCVSIT is set equal to MAXSIT; to change this you must edit gamit/includes/cview.h manually). See the comments in libraries/Makefile.config for a more complete explanation of the compiler switches. Make sure that you have put [mypath]/com/ into your search path, and type rmfresh -p [mypath] -d libraries -M -ao rmfresh -p [mypath] -d gamit -M -ao make_gamit [mypath] rmfresh -p [mypath] -d kf -M -ao make_globk [mypath] The "rmfresh" steps can be omitted if there are no archive or Makefiles in the module directories. The make scripts will invoke script "unimake" to convert the generic makefiles in each module directory ("Makefile.generic") to a form appropriate for your operating system ("Makefile") using Makefile.config, and then compiles and links each program. If a "Makefile" exists, unimake look to see if "Makefile.generic" has been modified more recently than "Makefile", and if not, will skip this step. The rmfresh command removes the MIT Makefiles tar'd with the source, and also any archive (.a) or object (.o) files (though none should exist in a clean installation). Although there is a "make_libraries" script, it is not necessary to use it since make_gamit and make_globk will each remake the libraries if they do not exist. Note that the installation shell scripts (as well as most GAMIT/GLOBK shell scripts and GLOBK programs) are self-documenting: Typing the name without any arguments will usually tell you how to run it. If you are installing incremental_updates into an existing 10.71 installation, note that the current version of libraries/Makefile.config in the incremental tar-file is named Makefile.config.new to avoid overwriting a local version that may have been edited for X11 paths. If you want the new version of Makefile.config, you should rename it before recompiling the software. In order to keep the tables and maps tar-files of manageable size, we have stored the large files for ocean tidal loading, atmospheric (non-tidal) loading, and the VMF1 mapping function separately in pub/GRIDS/ on ftp://everest.mit.edu (login anonymous). If you want any of these files, you should make a GRIDS/ directory at the top-level of your GAMIT/GLOBK installation (e.g. "mkdir ~/gg/GRIDS") and download them there; symbolic links in gg/tables/ expect to find OTL, ATML and VMF1 files in this directory. otl_FES2004.grid 731 MB otl_FES99.grid 183 MB otl_CSR4.grid 46 MB otl_GOT00.grid 46 MB otl_NAO99b.grid 88 MB ATML files 185 MB per year VMF1 mapping functions 232 MB per year FES2004 is the current IGS standard for ocean tidal loading and is much larger than the older files because the grid spacing is finer (0.25 deg vs 1 deg for CSR4 and GOT00). There are six sets of ATML files for each year: for GAMIT processing you would normally use the atmdisp_cm.YYYY file. If you cannot successfully ftp the large ocean or atmospheric loading, or VMF1 grid files, you may still use the software successfully since for horizontal measurements these effects are small, and for height measurements they vary little across networks less than 500 km (except for ocean effects near the coast). Before downloading an OTL grid, you should decide if your analysis needs a loading model and, if so, whether the differences in accuracy for your region between the finely spaced FES2004 model and one of the coarser, smaller file- size models are important. An alternative to the grids is to construct a station-list file using the automatic OTL provider on the OSO web page (http://www/oso.chalmers.se/~loading). The file format produced by OSO is the same as GAMIT's otl.list except that you need to add a one-line header to identify the OTLl model. This approach would be quite efficient if you have a constant set of stations for all of your processing. Use of the atmospheric loading corrections is experimental but could be important for some applications. The VMF1 mapping function, while clearly important for applications requiring observations below 10 degrees, will probably offer little improvement with the standard processing scenario of a 10-degree cutoff and elevation-dependent weighting. On the other hand, the VMF1 files have included in them values of the zenith hydrostatic (dry) delay, which could reduce errors in estimates of zenith delay and height under variable conditions (see the Tregoning and Herring reference in the release notes). Documentation ------------- Documentation for the software comes in printed, on-line, and interactive forms. All users should start with the "Introduction to GAMIT/GLOBK" (47pp, Intro_GG_10.7.pdf). Complete guides to the programs are found in GAMIT_Ref_10.7.pdf (167pp) and GLOBK_Ref_10.6.pdf (91pp). All of these are found in the documentation/ directory here and are also accessible via the website. On the web page you will also find an on-line tutorials based on one or more short courses we have conducted. Finally,for all of the programs and scripts run using command-line arguments, typing the name of the program with no arguments will display a short, or in some cases long "help" to guide you in its use. System-specific irregularities ------------------------------ The shell scripts in com/ used by GAMIT and GLOBK assume the POSIX-compliant versions of "awk" and "tail". On some systems (Ubuntu and Mandrake Linux, Solaris) there are non-POSIX versions in the primary path. On Solaris, for example, awk and tail in /usr/bin/ may not be POSIX-compliant, so you must force use of either /usr/bin/nawk or /usr/xpg4/bin/awk, and /usr/xpg4/bin/tail. This can be done by putting the link into gamit/bin/ and making sure that gamit/bin/ precedes /usr/bin/ in your path. You must use a link rather than an alias in .cshrc because when you execute a script with the -f option your .cshrc is not sourced, so the script is run in a default shell. Your path is passed from the shell that started the shell script, but your aliases are not passed. We have used the -f option for shell scripts so that your personal aliases don't interfere with the GAMIT scripts. On LINUX, link awk to gawk, but note that the gawk included in the 3.1.3 rpm for Mandrake is not POSIX-compliant and must be replaced by the gawk from 3.1.2-2. Additionally, the locale that is passed to the shell may influence the output of certain commands such as awk. If, for instance, your regional settings will use commas (,) instead of points (.) for the decimal separator, you may need to check that the "LANG" or any "LC_..." environment variables are not causing undesired effects. We know of one example, for instance, where LANG was set to fr_FR.UTF-8 and formatted prints in awk were done with commas for decimal separators, crashing the rest of the script. With Mac OS X Terminal, uncheck the "Set locale environment variables on startup" box under Terminal -> Preferences -> Advanced. For other systems, check the environment variables using "env" or "printenv". The sh_gamit scripts now use gzip and gunzip rather than compress and uncompress for file compression, conforming to current Linux practice. This compression is supported on other systems as well, but with some HP-UX systems gunzip does not exist and you must alias gunzip to gzip -d. Since some operating systems no longer distribute ftp in their standard package, we are migrating away from its use. The download scripts for EOP and RINEX observation and navigation files still include an ftp option if specified in gg/tables/ftp_info but also support wget. The 10.71 version of sh_get_orbits includes only wget for most systems and curl for macOS. Some Linux distributions use the KERBEROS version of ftp, which is incompatible with the GAMIT shell scripts. If typing "which ftp" yields"/usr/kerberos/ftp", you should put a link in gamit/bin/ to /usr/bin/ftp, and make sure that gamit/bin/ precedes the path directory pointing to the KERBEROS version. Note also that GAMIT routines use the UNIX "ls" command to generate file lists. Don't alias it in your .cshrc or .login file to produce output besides the filename (e.g., time, size, directory demarcation). SOPAC has changed its protocol for ftp'ing data, requiring that the email address used as password include the full domain name. Since the GAMIT shell scripts used to transfer data (sh_get_nav, sh_get_rinex, sh_get_orbits, and sh_get_hfiles) construct the password using the Unix "hostname" command, which may on some systems not return the full domain, to use these scripts (invoked by sh_gamit), you may need to make the following change to your .cshrc file: set host = `\hostname | \awk -v FS='.' '{print $1}'` set dom = `\hostname | \awk -v FS='.' '{print $2}'` if ( "$dom" == '' ) then alias hostname 'echo $host.mit.edu' endif The GAMIT/GLOBK installations on PCs running Linux or PC Solaris are straightforward once Linux or PC Solaris themselves and Fortran and C compilers are installed. Earlier problems with the Linux installation being hardware dependent have diminished considerably, as almost all hardware that's been around for more than a few months is now supported by the various Linux distributions. The need to recompile the gcc/g77 compiler to increase the maximum of Fortran unit numbers has also gone away with the gfortran (4.2) compiler. If you have only an earlier version of gcc/g77, you must either download gfortran from the GNU website or recompile g77 after editing libf2c/libI77/fio.h to set MXUNIT=10000. If you fail to do this, AUTCLN will stop with an I/O error reading each of its files (IOSTAT=101). The procedure for downloading and compiling gcc/g77 is detailed in the text file "installing_g77" in the GAMIT/GLOBK documentation/ directory. There are problems with RedHat Linux 6.2, 7.0, and 7.1, and with gcc/g77 3.0.x and 3.1.x described in the README file under source/RedHat_fixes below. We recommend RedHat 7.2 or above, and gcc/g77 3.4.4 (though gcc/g77 2.95.3 or 3.2.1 or above should work). If you are planning to use the shell scripts in com/ to create plots using GMT, note that they assume English, not SI units, so you should select "inches" as the measure unit when you install GMT. We realize that this is a reprehensible restriction and will soon modify our scripts to work with GMT built with either set of units. Testing the installation ------------------------ You can test the installation by following the instructions in the README file in the test_install/ directory. Note that the sestbl. used, copied from ~/gg/tables/, has ocean tidal loading turned on but there is no otl.grid file in the directory. You must either set "Tides applied = 23" in your test_install//tables/sestbl. and accept the fact that your results will differ slightly from those in the check_files directory, or download otl_FES2004.grid from pub/GRIDS/ on ftp://everest.mit.edu into gg/GRIDS. The test_install example does not use a VMF1 grid file for a priori hydrostatic zenith delay and mapping functions or an ATML grid file for loading corrections, so you do not have to download those grid files from everest to run the install test. 12345678901234567890123456789012345678901234567890123456789012345678901234567890