Previous: ZFFT1MX, Up: Multi-1D FFT


CFFT1MX Routine Documentation
— SUBROUTINE: CFFT1MX (MODE,SCALE,INPL,NSEQ,N,X,INCX1,INCX2,
Y,INCY1,INCY2,COMM,INFO
)
— Input: INTEGER MODE

The value of MODE on input determines the operation performed by CFFT1MX.
On input:

  • MODE=0 : only initializations (specific to the value of N) are performed using a default plan; this is usually followed by calls to the same routine with MODE=-1 or 1.
  • MODE=-1 : a forward transform is performed. Initializations are assumed to have been performed by a prior call to CFFT1MX.
  • MODE=1 : a backward (reverse) transform is performed. Initializations are assumed to have been performed by a prior call to CFFT1MX.
  • MODE=-2 : (default) initializations and a forward transform are performed.
  • MODE=2 : (default) initializations and a backward transform are performed.
  • MODE=100 : similar to MODE=0; only initializations (specific to the value of N) are performed, but these are based on a plan that is first generated by timing a subset of all possible plans and choosing the quickest (i.e. the FFT computation was timed as fastest based on the chosen plan). The plan generation phase may take a significant amount of time depending on the value of N.

— Input: REAL SCALE

On input: SCALE is the scaling factor to apply to the output sequences

— Input: LOGICAL INPL

On input: if INPL is .TRUE. then X is overwritten by the output sequences; otherwise the output sequences are returned in Y.

— Input: INTEGER NSEQ

On input: NSEQ is the number of sequences to be transformed

— Input: INTEGER N

On input: N is the number of elements in each sequence to be transformed

— Input/Output: COMPLEX X(1+(N-1)*INCX1+(NSEQ-1)*INCX2)

On input: X contains the NSEQ complex sequences of length N to be transformed; the ith element of sequence j is stored in X(1+(i-1)*INCX1+(j-1)*INCX2).
On output: if INPL is .TRUE. then X contains the transformed sequences in the same locations as on input; otherwise X remains unchanged.

— Input: INTEGER INCX1

On input: INCX1 is the increment used to store successive elements of a given sequence in X (INCX1=1 for contiguous data).
Constraint: INCX1 > 0.

— Input: INTEGER INCX2

On input: INCX2 is the increment used to store corresponding elements of successive sequences in X (INCX2=N for contiguous data).
Constraint: INCX2 > 0.

— Output: COMPLEX Y(1+(N-1)*INCY1+(NSEQ-1)*INCY2)

On output: if INPL is .FALSE. then Y contains the transformed sequences with the ith element of sequence j stored in Y(1+(i-1)*INCY1+(j-1)*INCY2); otherwise Y is not referenced.

— Input: INTEGER INCY1

On input: INCY1 is the increment used to store successive elements of a given sequence in Y. If INPL is .TRUE. then INCY1 is not referenced.
Constraint: INCY1 > 0.

— Input: INTEGER INCY2

On input: INCY2 is the increment used to store corresponding elements of successive sequences in Y (INCY2=N for contiguous data). If INPL is .TRUE. then INCY2 is not referenced.
Constraint: INCY2 > 0.

— Input/Output: COMPLEX COMM(5*N+100)

COMM is a communication array. Some portions of the array are used to store initializations for subsequent calls with the same sequence length N. The remainder is used as temporary store.

— Output: INTEGER INFO

On output: INFO is an error indicator. On successful exit, INFO contains 0. If INFO = -i on exit, the i-th argument had an illegal value.

Example:

     C     Forward FFTs are performed unscaled and in-place on two
     C     contiguous vectors stored in the first two columns of X.
     C     Manipulations are stored in 2nd and 3rd columns of X which are
     C     then transformed back.
     C
             COMPLEX X(N,3)
             SCALE = 1.0
             INPL = .TRUE.
             CALL CFFT1MX(0,SCALE,INPL,2,N,X,1,N,DUM,1,N,COMM,INFO)
             CALL CFFT1MX(-1,SCALE,INPL,2,N,X,1,N,DUM,1,N,COMM,INFO)
             DO 10 I = 1, N
                X(I,3) = X(I,1)*CONJG(X(I,2))/REAL(N)
                X(I,2) = CMPLX(0.0D0,1.0D0)*X(I,2)/REAL(N)
        10   CONTINUE
             CALL CFFT1MX(1,SCALE,INPL,2,N,X(1,2),1,N,DUM,1,N,COMM,INFO)