zd
Location of executable: /home/hgs/bin/zd
Location of source: /home/hgs/Oload/p/*.f (subroutines) and
/home/hgs/Oload/p/mpp/zd.f (main)
zd can be executed in interactive mode. However, it is
easier to
use an instruction file. If the file is called
myzd.ins you would call
prompt> zd myzd
> *.ins file (myzd)> $
Contents of this page
Graphic window and prompter
Instruction file
Display setup parameters
Symbols on a map
Sampling and numerical output
Using a script together with an instruction file
Table: Responses at the graphic prompter
S or Q | Stop or Quit |
r or R | Repeat drawing, R with refresh and prompter to redefine pixel size |
C | In two-window mode: continue with the phase plot |
i or I | Toggle on/off: Interpolate (i,I) and draw phase isolines (I) |
A | Prompt for Amplitude range |
H | Prompt for Phase range |
X and Y | Prompt for subarea to view (reply with array index range) |
l or L | Draw coastline and, optionally, "cities". L includes a prompt for GMT options. |
N | Prompt for amplitude or phase numerical formats |
O | Order switch, north-south toggle up-side-down |
U | Prompt for the comment concerning measurement units |
v or V |
Draw "cities"
but no coastlines |
t or T | change title. T to change permanently. |
g or G | process a sample file (tide gauges). Use G to inquire whether some are outside the area |
P | change palette |
M | swap parts of prompt message (more) |
1 or 2 | One-page resp. Two-page view of amplitudes and phases |
D | Dump viewed array to ascii file. System prompts for a file name and options |
1) The names
and comments in the open-file block can reference environment
variables (${TIDE});
openf
will take care of resolving them.
2) Grid range is
specified Xlow Xwidth Ylow Yhigh in grid
units
]
G>
A
section
for R. Ray model
19 R /geo/hgs/OTEQ/GOMSL/tide_gauge.loc
Q
/Bifrost/hgs/Otide/GOT99.2/rray M2
3.0 [m]
560 80 220 300
2 N=2 F=1 Pix=4,4 GMT=-Dc -I1 -A1000/1]
]
The tide gauges are activated using the l option (command lower case
L) at the display
prompter
The grid window zooms into the Gulf of Maine
and Saint Laurence.
A number {1| 2} must appear first: One window with both amplitude and phase, or two windows.
The other parameters may appear in any order. Use blanks to
separate them on one line.
Continue with the next line provided the first column is nonblank.
The first line with a blank first column will be taken as beyond
the input scope.
Table: Display setup parameters
P=filename | File name of a palette, e.g. P=/home/hgs/util/standard.pal |
N=npal | Integer number of the colour set in the palette file |
T=ncolor | The colour blob number in the palette used for text |
Grey= or Gray= | Use a grayscale |
Pix=nx,ny |
Number of pixels per array
cell |
FMTA=formatcode | Format amplitude numbers, like FMTPA=F10.2 |
FMTP=formatcode | Format phase numbers, like FMTP=F7.1 |
GMT=coastline options] | Coastline
options, routine
pscoast. If 'NO' a simple, less accurate coastline will be drawn. Example: GMT=-A1000/0.5/4 -Df -I1 -I2 -I3 ] 3) |
P+ | I+ |
Interpolate and display
phase | Interpolate |
Cyl={ H
| m } |
Rotate (cylindrically
connected) array half turn or by m cells |
GRAD={ E
| N } |
Compute gradient of array
(assume global, spherical, cyl. conn.) |
3) Right-bracket as the string delimiter, since the
string may contain blanks.
Symbols on a map - using a "city"-file
Optionally, an ASCII file can be opened on unit 19. It is assumed
to be a city-file organized as follows
xx yy ncsy ntsy ixo
iyo 'text'
in free format. The parameters have the following meaning:
xx - longitude (degrees)
yy - latitude (degrees)
ncsy - color number for symbol (0..15)
ntsy - type number for symbol (1 - George's cross; 2- square,
3 -diamond,
4 - triangle up, 5 -
triangle down, 6 -Andrew's cross)
ixo - horizontal and ...
iyo - ... vertical offset for the text
text - some text in single quotes.
Sampling of the field and numerical output
Optionally, ASCII-files containing locations can be opened on
available file unit numers. With the
G command at the graphic prompter the file will be read and the
CMPX array will be sampled at
the locations (incl. interpolation between grid nodes).
The result will be written to the protocol unit.
The file must contain longitude and latitude in degrees in the
first two columns. A bad longitude
(magnitude greater than 360 degrees) will stop file reading.
If an ASCII file is opened for output on unit 61, the entire
array will be dumped into it showing the
geographic position of each grid node.
Help text is obtained by
prompt> zd-sol -hUSAGE: zd-sol subdir tide code #version
PURPOSE: run CMPX-array graphic display
OPTIONS:
subdir - name of the directory containing the file. Oftentimes
needs to have a trailing slash, e.g. GOMSL/
tide - the tag symbol and file name substring
code - abutted substring in file name after tide
#version - the version number of the array. Use 99999 for the last
array on that file.The file name will be composed as follows:
${subdir}${tide}${code}.datThus, to display array version number 4 on file GOMSL/M2qf.dat
issuezd-sol GOMSL/ M2 qf 4
FILES: Needs ${subdir}zd_sol.ins (instruction file)
If you need to specify the version number and don't know it, use
program otecat
and specify the file name, e.g. GOMSL/M2qf.dat
Dump at the display
prompter - Options for WRIZM
procedure
( OTEQ/s/oteuw60.f )
Under zd/zds, the Dump command will output the visible area of
the array Z using WRIZM.
Some options of wrizm cannot be used (grey color).
subroutine wrizm
(iun,opt,z,flz,m,n,typ,mb,me,nb,ne,scc,zn)
c
c FLZ(N,M) - integer - flag array
c FLZ(1,1)=17 - all cells z(i,j) will be printed and other
elements of
c FLZ will
never be addressed.
(qrf=.false.)
c
c OPT = 'flags] options F=formatstring$'
c
c (F=formatstring$ is optional)
c options = '+string' or '+a+b+c+d'
c Format is for one complex pair, default '(1p,e12.4,0p,f8.2)'
c
c Flags designate a
target string (e.g. 'SAaO'
for a selection of wet nodes).
c
c OPT=']'
-
cell distinction is by .eq.0 |
.ne.0 (qq=.true.)
c
c OPTIONS:
c +P
- array is packed; output will scan the entire array
c (mb,me,nb,ne are ignored);
flags and target will be matched though.
c +I - print
array index
c +S - print location
on sphere [deg]
c +F - print location
on flat plane [km]
c +B - inverse
projection
c +N - print node
type (flag symbol)
c +V - print node
type (flag value)
c +C - print values
in polar representation (call set_phacut(cut) prior to wrizm)
c +J - take complex
conjugate of z(i,j)
c +U
- use scc as the scale value for the grid (scc is not set in
zd/zds!)
c +G
- circularly connected; ME specifies width (probably not
usefuls under zd/zds).
c
c mb,me,nb,ne - rectangular printing interval
c
if nb>ne, printing will be north-to-south in ordinarily
ordered
c
matrices.
c
(Under zd/zds, the parameters for the visible area are
submitted.)
c scc - together with option '+U': use value as the grid
constant
c zn - divide output values by zn
.bye