next up previous contents
Next: Sub-menu PRINT Up: Contents Of Sub-menu {TOP.FILE} Previous: Sub-option OPENGRIDFILE

Sub-option OPENRESULTSFILE

When this option is chosen, the following menu appears:

The contents of the files selected by the first two options are identical; however, the first is written with a formatted write and is read using free format input, and the second is written with an unformatted write . The formatted file format is:

READ (2, *) TET, NP, NDF

DO J=1,NP

READ(2, *) ( VAR(J,K),K=1,NDF )

ENDDO

where TET is the period of a tidal harmonic (0. for a residual component), NP is the number of data points, NDF is the number of degrees of freedom per node (less than or equal to 7), VAR is the values of the data at each node, and any format that leaves spaces or commas between the numbers can be used. Thus, the first record contains TET, NP, NDF. The remaining cards contain NDF fields of real data and there are NP records.

The binary file format is:

READ (2) TET, NP, NDF, ((VAR(J,K),J=1,NP),K=1,NDF)

where the varaibles have the same meaning as above.

An IMPORTANT NOTE is that the interpretation of the data in the program depends on the value of NDF. For scalar data, the interpretation of the data fields is not important. However for vectors the components must be in the correct fields. There are four standard cases recognized by DISPLOT:

  1. NDF = 3, VAR(1) is h (sea level), VAR(2) is U (eastward component of velocity), VAR(3) is V (northward component of velocity).
  2. NDF = 4, VAR(1) is h (sea level), VAR(2) is U (eastward component of velocity), VAR(3) is V (northward component of velocity), and VAR(4) is speed (rms value for velocity).
  3. NDF = 6, VAR(1) is h(real), VAR(2) = h(imaginary), VAR(3) is U(real), VAR(4) is U(imaginary), VAR(5) is V(real), VAR(6) is V(imaginary), where real and imag indicate the real and imaginary part of a complex number, and
  4. NDF = 7, VAR(1) is h (amplitude), VAR(2) is h (phase), VAR(3) is U (amplitude), VAR(4) is U (phase), VAR(5) is V(amplitude), VAR(6) is V (phase), VAR(7) is speed, where phase is in degrees.

For a case where the user has values of sea level, U and V, the NDF equal 3 or 4 option should be used. For the case of tides where data is in terms of amplitude and phase, the NDF equal 7 case should be used. Time-series data can be handled by creating several files with the first options (NDF equals 3 or 4).

Next, a prompt asks if the user wants to convert the data to amplitude and phase. If the answer is N (No), the data remains as it was read. If the answer is Y (Yes) and the data are complex amplitudes, then the data are converted to a real amplitude and a phase in degrees. The program will prompt for f, the nodal modulation factor to use, and E, the equilibrium argument. If in doubt, use f = 1.0 and E = 0. The program will assume that each pair of numbers (1 and 2, 3 and 4, 5 and 6) is a complex pair. Degree of freedom 1 is replaced by the amplitude and degree of freedom 2 is replaced by the phase in degrees. If NDF = 6, u and v are used to construct tidal current ellipses, and sea level and u and v are used to calculate energy flux.

Finally, if NDF = 7, the pairs of numbers are assumed to be amplitude and phase for sea level, u and v, in that order. These values are used to calculate tidal current ellipses and energy flux.

When selecting FESWMS model files, the user is prompted for a definition of the file format. An answer of "f" for formatted or "u" for unformatted is required. The formatted version is read using the format specified in the FESWMS documentation:

READ(18,'(F10.3,I10)') TET,NP

DO N=1,NP

READ(18,'(I10,3F10.3,3G10.3)') (J,(VAR(K,J), K=1,3), (VDOT(K,J),K=1,3) )

ENDDO

where TET = current time, NP = number of node points, VAR(1) is U (eastward component of velocity), VAR(2) is V (northward component of velocity), VAR(3) is h (surface elevation), and VDOT are the time derivatives of these variables.

The unformatted version is read using

READ(18) TET,NP

READ(18) ((VAR(K,J), K=1,3),(VDOT(K,J),K=1,3),J=1,NP)

where the definitions are listed above.


next up previous contents
Next: Sub-menu PRINT Up: Contents Of Sub-menu {TOP.FILE} Previous: Sub-option OPENGRIDFILE

Channel Consulting Ltd.