Main Page | Class List | Directories | File List | Class Members | File Members

ObitFFT.h

Go to the documentation of this file.
00001 /* $Id: ObitFFT.h,v 1.7 2007/08/31 17:24:48 bcotton Exp $         */
00002 /*--------------------------------------------------------------------*/
00003 /*;  Copyright (C) 2003-2007                                          */
00004 /*;  Associated Universities, Inc. Washington DC, USA.                */
00005 /*;                                                                   */
00006 /*;  This program is free software; you can redistribute it and/or    */
00007 /*;  modify it under the terms of the GNU General Public License as   */
00008 /*;  published by the Free Software Foundation; either version 2 of   */
00009 /*;  the License, or (at your option) any later version.              */
00010 /*;                                                                   */
00011 /*;  This program is distributed in the hope that it will be useful,  */
00012 /*;  but WITHOUT ANY WARRANTY; without even the implied warranty of   */
00013 /*;  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the    */
00014 /*;  GNU General Public License for more details.                     */
00015 /*;                                                                   */
00016 /*;  You should have received a copy of the GNU General Public        */
00017 /*;  License along with this program; if not, write to the Free       */
00018 /*;  Software Foundation, Inc., 675 Massachusetts Ave, Cambridge,     */
00019 /*;  MA 02139, USA.                                                   */
00020 /*;                                                                   */
00021 /*;Correspondence about this software should be addressed as follows: */
00022 /*;         Internet email: bcotton@nrao.edu.                         */
00023 /*;         Postal address: William Cotton                            */
00024 /*;                         National Radio Astronomy Observatory      */
00025 /*;                         520 Edgemont Road                         */
00026 /*;                         Charlottesville, VA 22903-2475 USA        */
00027 /*--------------------------------------------------------------------*/
00028 #ifndef OBITFFT_H 
00029 #define OBITFFT_H 
00030 
00031 /* Disable FFTW if not needed */
00032 #if HAVE_FFTW==1
00033 #include <fftw.h>
00034 #include <rfftw.h>
00035 #elif HAVE_GSL==1  /* Else try GSL version */
00036 #include <gsl/gsl_fft_complex_float.h>
00037 #include <gsl/gsl_fft_halfcomplex_float.h>
00038 #include <gsl/gsl_fft_real_float.h>
00039 #endif /* HAVE_GSL */
00040 #include "Obit.h"
00041 #include "ObitThread.h"
00042 #include "ObitFArray.h"
00043 #include "ObitCArray.h"
00044 
00045 /*-------- Obit: Software for the recently deceased ------------------*/
00077 /*-------------- enumerations -------------------------------------*/
00083 enum obitFFTdir {
00085   OBIT_FFT_Forward,
00087   OBIT_FFT_Reverse
00088 }; /* end enum obitFFTdir */
00090 typedef enum obitFFTdir ObitFFTdir;
00091 
00097 enum obitFFTtype {
00099   OBIT_FFT_FullComplex,
00101   OBIT_FFT_HalfComplex
00102 }; /* end enum obitFFTtype */
00104 typedef enum obitFFTtype ObitFFTtype;
00105 
00106 /*--------------Class definitions-------------------------------------*/
00108 typedef struct {
00109 #include "ObitFFTDef.h"   /* this class definition */
00110 } ObitFFT;
00111 
00112 /*----------------- Macroes ---------------------------*/
00118 #define ObitFFTUnref(in) ObitUnref (in)
00119 
00125 #define ObitFFTRef(in) ObitRef (in)
00126 
00133 #define ObitFFTIsA(in) ObitIsA (in, ObitFFTGetClass())
00134 
00135 /*---------------Public functions---------------------------*/
00137 void ObitFFTClassInit (void);
00138 
00140 ObitFFT* newObitFFT (gchar* name, ObitFFTdir dir, ObitFFTtype type, 
00141                      gint rank, gint *dim);
00143 typedef ObitFFT* (*newObitFFTFP) (gchar *name, ObitFFTdir dir, 
00144                                   ObitFFTtype type, 
00145                                   gint rank, gint *dim);
00146 
00148 gconstpointer ObitFFTGetClass (void);
00149 
00151 gint ObitFFTSuggestSize (gint length);
00152 
00154 void ObitFFTR2C (ObitFFT *in, ObitFArray *inArray, ObitCArray *outArray);
00155 typedef void (*ObitFFTR2CFP) (ObitFFT *in, ObitFArray *inArray, 
00156                             ObitCArray *outArray);
00157 
00159 void ObitFFTC2R (ObitFFT *in, ObitCArray *inArray, ObitFArray *outArray);
00160 typedef void (*ObitFFTC2RFP) (ObitFFT *in, ObitCArray *inArray, 
00161                             ObitFArray *outArray);
00162 
00164 void ObitFFTC2C (ObitFFT *in, ObitCArray *inArray, ObitCArray *outArray);
00165 typedef void (*ObitFFTC2CFP) (ObitFFT *in, ObitCArray *inArray, 
00166                             ObitCArray *outArray);
00167 
00168 /*----------- ClassInfo Structure -----------------------------------*/
00174 typedef struct  {
00175 #include "ObitFFTClassDef.h"
00176 } ObitFFTClassInfo; 
00177 
00178 #endif /* OBITFFT_H */ 

Generated on Fri Aug 31 22:13:04 2007 for Obit by  doxygen 1.3.9.1