Go to main content
Oracle Developer Studio 12.5 Man Pages

Exit Print View

Updated: June 2017
 
 

zfftopt (3p)

Name

zfftopt - compute the length of the closest fast FFT

Synopsis

INTEGER FUNCTION ZFFTOPT(LEN)

INTEGER LEN

INTEGER*8 FUNCTION ZFFTOPT_64(LEN)

INTEGER*8 LEN




F95 INTERFACE
INTEGER FUNCTION ZFFTOPT(LEN)

INTEGER :: LEN

INTEGER(8) FUNCTION ZFFTOPT_64(LEN)

INTEGER(8) :: LEN




C INTERFACE
#include <sunperf.h>

int zfftopt(int len);

long zfftopt_64(long len);

Description

Oracle Solaris Studio Performance Library                          zfftopt(3P)



NAME
       zfftopt - compute the length of the closest fast FFT


SYNOPSIS
       INTEGER FUNCTION ZFFTOPT(LEN)

       INTEGER LEN

       INTEGER*8 FUNCTION ZFFTOPT_64(LEN)

       INTEGER*8 LEN




   F95 INTERFACE
       INTEGER FUNCTION ZFFTOPT(LEN)

       INTEGER :: LEN

       INTEGER(8) FUNCTION ZFFTOPT_64(LEN)

       INTEGER(8) :: LEN




   C INTERFACE
       #include <sunperf.h>

       int zfftopt(int len);

       long zfftopt_64(long len);



PURPOSE
       zfftopt  computes  the  length  of  the closest fast FFT.  Fast Fourier
       transform algorithms, including those used in Performance Library, work
       best  with vector lengths that are products of small primes.  For exam-
       ple, an FFT of length 32=2**5 will run faster  than  an  FFT  of  prime
       length  31  because  32 is a product of small primes and 31 is not.  If
       your application is such that you can taper or zero pad your vector  to
       a  larger length then this function may help you select a better length
       and run your FFT faster.

       ZFFTOPT will return an integer no smaller than  the  input  argument  N
       that  is  the  closest  number  that  is  the  product of small primes.
       ZFFTOPT will return 16 for an input of N=16 and return 18=2*3*3 for  an
       input of N=17.

       Note  that  the  length  computed here is not guaranteed to be optimal,
       only to be a
        product of small primes.  Also, the value returned may change  as  the
       underlying
        FFTs  become  capable of handling larger primes.  For example, passing
       in N=51 to day will return 52=2*2*13 rather than  51=3*17  because  the
       FFTs  in  Performance  Li brary do not have fast radix 17 code.  In the
       future, radix 17 code may be added
        and then N=51 will return 51.




                                  7 Nov 2015                       zfftopt(3P)