📄 filtering.h
字号:
#ifndef _FILTERING_H__#define _FILTERING_H__#include "midamble.h"/** * @author Alessandro Nordio 03/04/2001 * * This function builds the matched filter. The matched filter (MF) * is in general a complex vector. In order to simplify the matched * filtering operation, this routine computes separately the real and * imaginary parts of the MFs and store it into two different vectors * * @param m the pointer to the midamble used in this slot * @param est pointer to the channel estimation structure. * (Where this function reads the channel estimates and where * it writes the real and imaginary parts of the matched filters) * @param midamble_index the indexe of the midamble shift used */int matched_filter_build(midamble_t *m, estimation_vars_t *est, unsigned int midamble_index );/** * @author Alessandro Nordio 04/04/2001 * * This routine performs the matched filtering operation filtering * the same input x with two filters h1 and h2 (main application: * h1 and h2 are the real and imaginary parts of a complex matched filter) * * It computes the output y1 and y2 as * y1[n] = \sum_{k=0}^{length-1} x[shift*n+k]*h1[k] for n=0..n_y-1 * y2[n] = \sum_{k=0}^{length-1} x[shift*n+k]*h2[k] for n=0..n_y-1 * * The elements x,h1,h2 and y are real and are represented on a * short integer (16 bit). The elements of x, h1 and h2 are stored * four by four in mmx_t structures so they are loaded 4 at a time * into the MMX registers. The length of the vector h (the MF) is * 'length' that we assume a multiple of 4. The routine computes * n_y output. * * @param x the input vector in the format [x0,x1,x2,x3,x4,x5,x6,x7,...] * where xn is a real short integer (16 bit) with * 12 bit dynamic (-2048, +2047) * @param h1 the real filter coefficients in the same format as x. * @param h2 the real (imaginary?) filter coefficients in the same format as x. * @param length the length of h * @param downsample_factor the shift on x between one output and the other * @param n_y the number of output computed by the routine * @param y the output of the filters in the format * [y10,y20,y11,y21,.....y1n,y2n,....] where y1n is the n-th output of * the first filter and is on 16 bit * @param wrap_point a pointer to the end of the input array. Used * to force the filter to wrap back to the beginning of the buffer. * @param wrap_period the length of the input buffer */int matched_filtering( mmx_t *x, mmx_t *h1, mmx_t *h2, SYMBOL_COMPLEX *y, unsigned int length, unsigned int downsample_factor, unsigned int n_y );#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -