1 #ifndef _LTFAT_DGT_COMMON_H 2 #define _LTFAT_DGT_COMMON_H 3 #include "ltfat/basicmacros.h" 4 /** \addtogroup dgt 5 * @{ 6 */ 7 8 /** \name Phase convention 9 * @{ */ 10 11 /** Discrete Gabor Transform Phase convention 12 * 13 * There are two commonly used phase conventions. 14 * 15 * Frequency invariant: 16 * \anchor dgtfreqinv 17 * \f[ 18 * c(m,n) 19 * = \sum_{l=0}^{L-1}\! f(l) 20 * \overline{g(l-na)} \me^{-\mi 2\pi l m/M } \, 21 * \f] 22 * This is commonly used by mathematicans. Effectivelly, each 23 * frequency channel is demodulated to the baseband. 24 * 25 * Time invatiant: 26 * \anchor dgttimeinv 27 * \f[ 28 * c(m,n) 29 * = \sum_{l=0}^{L-1}\! f(l) 30 * \overline{g(l-na)} \me^{-\mi 2\pi (l-na) m/M } \, 31 * \f] 32 * This is commonly used by engineers. This is equivalent to 33 * a filterbank. 34 * 35 * \see dgt_phaselock dgtreal_phaselock dgt_phaseunlock dgtreal_phaseunlock 36 * 37 */ 38 typedef enum 39 { 40 LTFAT_TIMEINV = 0, 41 LTFAT_FREQINV = 1, 42 LTFAT_POPULAR = 2 43 } ltfat_phaseconvention; 44 45 /** @}*/ 46 /** @}*/ 47 48 #ifdef __cplusplus 49 extern "C" 50 { 51 #endif 52 53 LTFAT_API int 54 ltfat_phaseconvention_is_valid(ltfat_phaseconvention in); 55 56 #ifdef __cplusplus 57 } // extern "C" 58 #endif 59 60 #endif 61