USGS InfoBank banner.  USGS, Coastal and Marine Geology, InfoBank banner.
 USGS Coastal and Marine Geology banner.    Search InfoBank.
USGS InfoBank program -- magredgeomag Skip navigational links
    ________   ________   ______________   ________   _________   _______________   ________  
  tab edge  Home  tab edge  Data  tab edge  Activities  tab edge  FACS  tab edge  Atlas  tab edge  Definitions  tab edge  More  tab edge  
   
InfoBank Programs: by Name   by Data Type   General Tools   GIS   Plotting   Web   USGS Disclaimer   InfoBank Programs
   
Expanded description
Topic Description
Name
magredgeomag
Synopsis
/infobank/programs/mag/geomag/magredgeomag.for
Description
  Program to calculate IGRF regional magnetic field and residual.
    
Prompts
  First  input file is magnetics  (.200 or .240).

  Second input file is navigation (.050 or .070).
  Enter name of input file #1:
  Enter name of input file #2:
  Enter output file name:
  Enter last 2 digits of year:
    
Include_files
  drsvt

    
Subroutines
  vescinit            (shared PMG external)         

  getsymbol           (shared PMG external)         
  percentage          (shared PMG external)         
  openem              (shared PMG external)         
  converttime         (shared PMG external)         
  field               (internal)                    
  forerror            (shared PMG external)         
    
Functions
  abs                 (FORTRAN intrinsic function)  

    
Files_used
  unit=*(write)

  unit=(p)iinunit(read)
  unit=(p)ifilmag(read,bcksp,close)
  unit=(p)ifilnav(read,close)
  unit=(p)ifilout(write,close)
    
Author
  Clint Steele               12/26/83          .for

    based on program MRMFR.
    used subroutine named GMRF75 to calculate regional field
  modified by Carolyn Degnan, 09/14/84
    to accept ida,ihr,imin,isec,itens
  modified by Carolyn Degnan, 10/20/84
    to check for values with sensitivity to tenths of a gamma
  modified by Carolyn Degnan, 02/28/85
    to only accept new times of ida,ihr,imin,isec,itens
    to output new standard formats without navigation
    ran it thru MAT
  modified by Carolyn Degnan, 04/15/85
    to use GEOMAG subroutines and IGRF80 data
  modified by Carolyn Degnan, 11/06/85
    to use IGRFDEMO subroutines and
    IGRF45, IGRF50, IGRF55, IGRF60, DGRF65, DGRF70, DGRF75,
    DGRF80, IGRF85, & IGRF85S data
  converted to subroutine, CDegnan, 2/17/87
  converted for and ran MAT, CDegnan, 3/4/87
  added calls to PERCENTAGE, CDegnan, 6/10/87
  modified to read new gradiometer format (...,t20,f7.1,...), CDegnan, 9/15/87
  changed reference from DRS$ to PMG$, CDegnan, 2/19/92
  modified by Carolyn Degnan, 07/30/92
    to use subroutine FIELD to calculate regional value.
    FIELD is from NGDC and has all IGRF models.

    
Reads
 read ( iinunit, cfmtiyr ) iyr
 read ( ifilmag, cfmtmag2, iostat = ierr, err = 100,
*    end = 290 ) ida, ihr, imin, isec, iten, rmstobs, rslvobs

         read ( ifilmag, cfmtmag1, iostat = ierr, err = 290,
*            end = 800 ) ida, ihr, imin, isec, iten, observed
             read ( ifilmag, cfmtmag2, iostat = ierr, err = 290,
*                end = 800 ) ida, ihr, imin, isec, iten,
*                rmstobs, rslvobs
         read ( ifilnav, cfmtnav, iostat = ierr, err = 291,
*            end = 700 ) ida, ihr, imin, isec, iten,
*            rlatnew, rlonnew
    
Writes
                 write ( ifilout, cfmtout2, iostat = ierr,
*                    err = 92 ) ida, ihr, imin, isec, iten,
                 write ( ifilout, cfmtout1, iostat = ierr,
*                    err = 92 ) ida, ihr, imin, isec, iten,
*                    observed, regional, residual
    
Calls
 call getcentury (iyr, Century)
         call converttime ('COMPRESS', ida, ihr, imin, isec, 
*                          iten, itmmag, ErrorFlag)

             call converttime ('COMPRESS', ida, ihr, imin, isec, 
*                              iten, itmmag, ErrorFlag)

     call percentage ( ifilmag )
         call converttime ('COMPRESS', ida, ihr, imin, isec, 
*                          iten, itmnavnew, ErrorFlag)
         call field (flat, flon, elev, date,
*                    d, i, h, x, y, z, f,
*                    ddot, idot, hdot, xdot, ydot, zdot, fdot,
*                    jerr)
                 call converttime ('EXPAND', ida, ihr, imin, 
*                          isec, iten, itmmag, ErrorFlag)
                 call converttime ('EXPAND', ida, ihr, imin, 
*                             isec, iten, itmmag, ErrorFlag)
 call forerror ( ierr )
 call forerror ( ierr )
    

Skip footer navigational links

InfoBank   Menlo Park Center   Santa Cruz Center   St. Petersburg Center   Woods Hole Center   Coastal and Marine Geology Program  
 
U. S. Department of the Interior   U. S. Geological Survey   Geologic Information   Ask-A-Geologist   USGS privacy statement   Disclaimer  

URL: /infobank/programs/mag/geomag/magredgeomag.doc.html
Maintainer: Clint Steele
Last modified: Fri Oct 11 03:10:22 PDT 2002  (wcs)