GNU Radio Manual and C++ API Reference  3.7.13.4
The Free & Open Software Radio Ecosystem
mmse_interp_differentiator_ff.h
Go to the documentation of this file.
1 /* -*- c++ -*- */
2 /*
3  * Copyright (C) 2002,2007,2012,2017 Free Software Foundation, Inc.
4  *
5  * This file is part of GNU Radio
6  *
7  * GNU Radio is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation; either version 3, or (at your option)
10  * any later version.
11  *
12  * GNU Radio is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this file; see the file COPYING. If not, write to
19  * the Free Software Foundation, Inc., 51 Franklin Street,
20  * Boston, MA 02110-1301, USA.
21  */
22 #ifndef _MMSE_INTERP_DIFFERENTIATOR_FF_H_
23 #define _MMSE_INTERP_DIFFERENTIATOR_FF_H_
24 
25 #include <gnuradio/filter/api.h>
27 #include <vector>
28 
29 namespace gr {
30  namespace filter {
31 
32  /*!
33  * \brief Compute intermediate samples of the derivative of a signal
34  * between signal samples x(k*Ts)
35  * \ingroup filter_primitive
36  *
37  * \details
38  * This implements a Minimum Mean Squared Error interpolating
39  * differentiator with 8 taps. It is suitable for signals where the
40  * derivative of a signal has a bandwidth of interest in the range
41  * (-Fs/4, Fs/4), where Fs is the samples rate.
42  *
43  * Although mu, the fractional delay, is specified as a float, in
44  * the range [0.0, 1.0], it is actually quantized. That is, mu is
45  * quantized in the differentiate method to 128th's of a sample.
46  *
47  */
49  {
50  public:
53 
54  unsigned ntaps() const;
55  unsigned nsteps() const;
56 
57  /*!
58  * \brief compute a single interpolated differentiated output value.
59  *
60  * \p input must have ntaps() valid entries.
61  * input[0] .. input[ntaps() - 1] are referenced to compute the output
62  * value.
63  *
64  * \p mu must be in the range [0, 1] and specifies the fractional delay.
65  *
66  * \throws std::runtime_error if mu is not in the range [0, 1].
67  *
68  * \returns the interpolated differentiated output value.
69  */
70  float differentiate(const float input[], float mu) const;
71 
72  protected:
73  std::vector<kernel::fir_filter_fff *> filters;
74  };
75 
76  } /* namespace filter */
77 } /* namespace gr */
78 
79 #endif /* _MMSE_INTERP_DIFFERENTIATOR_FF_H_ */
std::vector< kernel::fir_filter_fff * > filters
Definition: mmse_interp_differentiator_ff.h:73
Compute intermediate samples of the derivative of a signal between signal samples x(k*Ts) ...
Definition: mmse_interp_differentiator_ff.h:48
Include this header to use the message passing features.
Definition: logger.h:695
#define FILTER_API
Definition: gr-filter/include/gnuradio/filter/api.h:30