**SPGRADX**
The **SPGRADX** routine computes the x-gradient of fields
in complex Fourier space.
The x-gradient of a vector field W is:
WX=CONJG(W)*L/RERTH
where l is the wavenumber and rerth is the earth radius,
So that the result is the x-gradient of the pseudo-vector.
The x-gradient of a scalar field W is:
WX=CONJG(W)*L/(RERTH*CLAT)
Where clat is the cosine of latitude.
At the pole this is undefined, so the way to get
The x-gradient at the pole is by passing both
The weighted wavenumber 0 and the unweighted wavenumber 1
amplitudes at the pole and setting MP=10.
In this case, the wavenumber 1 amplitudes are used
to compute the x-gradient and then zeroed out.
Input argument list:
M - INTEGER FOURIER WAVENUMBER TRUNCATION
INCW - INTEGER FIRST DIMENSION OF THE COMPLEX AMPLITUDE ARRAY
(INCW >= M+1)
KMAX - INTEGER NUMBER OF FOURIER FIELDS
MP - INTEGER (KM) IDENTIFIERS
(0 OR 10 FOR SCALAR, 1 FOR VECTOR)
CLAT - REAL COSINE OF LATITUDE
W - COMPLEX(INCW,KMAX) FOURIER AMPLITUDES
Output argument list:
W - COMPLEX(INCW,KMAX) FOURIER AMPLITUDES
CORRECTED WHEN MP=10 AND CLAT=0
WX - COMPLEX(INCW,KMAX) COMPLEX AMPLITUDES OF X-GRADIENTS
SPLIB.tar |
Library contains routines to be
be used for a variety of spectral transform functions. (Fortran90)
Date posted: 2/23/2007 |