CXML

sfft_apply_grp, dfft_apply_grp, cfft_apply_grp, zfft_apply_grp 


FORMAT

  Real transform: status = {S,D}FFT_APPLY_GRP (input_format, output_format,
  direction, in, out, grp_size, lda, fft_struct, stride, grp_stride)

  Complex transform of real data format: status = {C,Z}FFT_APPLY_GRP
  (input_format, output_format, direction, in, out, grp_size, lda,
  fft_struct, stride, grp_stride)

  Complex transform of real data to real data: status = {C,Z}FFT_APPLY_GRP
  (input_format, output_format, direction, in_real, in_imag, out_real,
  out_imag, grp_size, lda, fft_struct, stride, grp_stride)

Arguments

  input_format, output_format
                      character*(*)
                      Identifies the data type of the input and the format to
                      be used to store the data, regardless of the data type.
                      For example, a complex sequence can be stored in real
                      format.

                      The character 'R' specifies the format as real; the
                      character 'C' specifies the format as complex. As
                      convenient, use either upper- or lowercase characters,
                      and either spell out or abbreviate the word.

                      The following table shows the valid values:

  Subprogram   Input Format   Output Format   Direction

  {S,D}        'R'            'C'             'F'

               'C'            'R'             'B'

               'R'            'R'             'F' or 'B'

  {C,Z}        'R'            'R'             'F' or 'B'

               'C'            'C'             'F' or 'B'

       For complex transforms, the type of data determines what other
       arguments are needed. When both the input and output data are real,
       the complex functions store the data as separate arrays for imaginary
       and real data so additional arguments are needed.

  direction           character*(*)
                      Specifies the operation as either the forward or
                      inverse transform. Use 'F' or 'f' tp specify the
                      forward transform. Use 'B' or 'b' to specify the the
                      inverse transform.

  in, out             real*4 | real*8 | complex*8 | complex*16
                      Both arguments are two-dimensional arrays. The IN array
                      contains the data to be transformed. The OUT array
                      contains the transformed data. The IN and OUT arrays
                      can be the same array.

  in_real, in_imag, out_real, out_imag
                      real*4 | real*8
                      Use these arguments when performing a complex transform
                      on real data format and storing the result in a real
                      data format.

  grp_size            integer*4
                      Specifies the number of one-dimensional data arrays;
                      grp_size > 0.

  lda                 integer*4
                      Specifies the number of rows in two-dimensional data
                      arrays; lda >= grp_size. Using lda = grp_size + {3 or
                      5} can sometimes achieve better performance by avoiding
                      cache thrashing.

  fft_struct          record /dxml_s_grp_fft_structure/ for single-precision
                      real operations
                      record /dxml_d_grp_fft_structure/ for double-precision
                      real operations
                      record /dxml_c_grp_fft_structure/ for single-precision
                      complex operations
                      record /dxml_z_grp_fft_structure/ for double-precision
                      complex operations
                      The argument refers to the structure created by the
                      _INIT routine.

  stride              integer*4
                      Specifies the distance between columns of active data
                      arrays; stride >= 1. stride permits columns of IN and
                      OUT arrays to be skipped when they are not part of the
                      group.

  grp_stride          integer*4
                      Specifies the distance between consecutive elements in
                      a row in the IN and OUT arrays; grp_stride >= 1.
                      grp_stride permits rows of IN and OUT arrays to be
                      skipped when they are not part of the group.

Description

  The _FFT_APPLY_GRP computes the fast forward or inverse Fourier transform
  on a group of one-dimensional data arrays. The transform is performed on
  the first row of elements of one-dimensional data arrays within the group.
  Data array can be skipped by setting the stride parameter. The transform
  then goes to the next row of elements. Similarly, rows of elements can be
  skipped by setting the grp_stride parameter. _FFT_APPLY_GRP contrasts with
  _FFT_APPLY in that _FFT_APPLY perform a transform on each element of a data
  array before going to the next data array.  Although _FFT_APPLY_GRP gives
  the same result as _FFT_APPLY, _FFT_APPLY_GRP is more efficient at
  completing the transform.

Return Values

  0                  DXML_SUCCESS()

  12                 DXML_INS_RES()

  13                 DXML_BAD_STRIDE()

  15                 DXML_BAD_DIRECTION_STRING()

  16                 DXML_BAD_FORMAT_STRING()

  18 (real transform only)
                     DXML_BAD_FORMAT_FOR_DIRECTION()

Example

  INCLUDE CXMLDEF.FOR
  INTEGER*4 GRP_SIZE,N,STATUS
  REAL*8 A(100,514),B(100,514)
  RECORD /CXML_D_GRP_FFT_STRUCTURE/FFT_STRUCT
  GRP_SIZE=100
  N=512
  LDA=100
  STATUS = DFFT_INIT_GRP(N,FFT_STRUCT,.TRUE.,100)
  STATUS = DFFT_APPLY_GRP('R','C','F',A,B,GRP_SIZE,LDA,FFT_STRUCT,1,1)
  STATUS = DFFT_EXIT_GRP(FFT_STRUCT)

  This FORTRAN code computes a set of 100 FFT of size 512. The results of the
  transforms are stored in B in complex format. Note that the second
  dimension is 514 to hold the extra complex values.

CXML Home Page

Index of CXML Routines