complex_vector_float.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #if !defined(_SPANDSP_COMPLEX_VECTOR_FLOAT_H_)
00029 #define _SPANDSP_COMPLEX_VECTOR_FLOAT_H_
00030
00031 #if defined(__cplusplus)
00032 extern "C"
00033 {
00034 #endif
00035
00036 static __inline__ void cvec_copyf(complexf_t z[], const complexf_t x[], int n)
00037 {
00038 int i;
00039
00040 for (i = 0; i < n; i++)
00041 z[i] = x[i];
00042 }
00043
00044
00045 static __inline__ void cvec_copy(complex_t z[], const complex_t x[], int n)
00046 {
00047 int i;
00048
00049 for (i = 0; i < n; i++)
00050 z[i] = x[i];
00051 }
00052
00053
00054 #if defined(HAVE_LONG_DOUBLE)
00055 static __inline__ void cvec_copyl(complexl_t z[], const complexl_t x[], int n)
00056 {
00057 int i;
00058
00059 for (i = 0; i < n; i++)
00060 z[i] = x[i];
00061 }
00062
00063 #endif
00064
00065 static __inline__ void cvec_zerof(complexf_t z[], int n)
00066 {
00067 int i;
00068
00069 for (i = 0; i < n; i++)
00070 z[i] = complex_setf(0.0f, 0.0f);
00071 }
00072
00073
00074 static __inline__ void cvec_zero(complex_t z[], int n)
00075 {
00076 int i;
00077
00078 for (i = 0; i < n; i++)
00079 z[i] = complex_set(0.0, 0.0);
00080 }
00081
00082
00083 #if defined(HAVE_LONG_DOUBLE)
00084 static __inline__ void cvec_zerol(complexl_t z[], int n)
00085 {
00086 int i;
00087
00088 for (i = 0; i < n; i++)
00089 z[i] = complex_setl(0.0, 0.0);
00090 }
00091
00092 #endif
00093
00094 static __inline__ void cvec_setf(complexf_t z[], complexf_t *x, int n)
00095 {
00096 int i;
00097
00098 for (i = 0; i < n; i++)
00099 z[i] = *x;
00100 }
00101
00102
00103 static __inline__ void cvec_set(complex_t z[], complex_t *x, int n)
00104 {
00105 int i;
00106
00107 for (i = 0; i < n; i++)
00108 z[i] = *x;
00109 }
00110
00111
00112 #if defined(HAVE_LONG_DOUBLE)
00113 static __inline__ void cvec_setl(complexl_t z[], complexl_t *x, int n)
00114 {
00115 int i;
00116
00117 for (i = 0; i < n; i++)
00118 z[i] = *x;
00119 }
00120
00121 #endif
00122
00123
00124
00125
00126
00127
00128 complexf_t cvec_dot_prodf(const complexf_t x[], const complexf_t y[], int n);
00129
00130
00131
00132
00133
00134
00135 complex_t cvec_dot_prod(const complex_t x[], const complex_t y[], int n);
00136
00137 #if defined(HAVE_LONG_DOUBLE)
00138
00139
00140
00141
00142
00143 complexl_t cvec_dot_prodl(const complexl_t x[], const complexl_t y[], int n);
00144 #endif
00145
00146
00147
00148
00149
00150
00151
00152
00153 complexf_t cvec_circular_dot_prodf(const complexf_t x[], const complexf_t y[], int n, int pos);
00154
00155 void cvec_lmsf(const complexf_t x[], complexf_t y[], int n, const complexf_t *error);
00156
00157 void cvec_circular_lmsf(const complexf_t x[], complexf_t y[], int n, int pos, const complexf_t *error);
00158
00159 #if defined(__cplusplus)
00160 }
00161 #endif
00162
00163 #endif
00164