We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

AR# 36355

FIR Compiler 5.0 block: ERROR: Coefficients provided do not match coefficient structure 'Hilbert', number of coefficients is incorrect


When using the FDATool block to create filter coefficients for a Hilbert Transform, the "xlfda_numberator('FDATool')" option is not usable. I get the following error:

ERROR: Coefficients provided do not match coefficient structure 'Hilbert', number of coefficients is incorrect.


The Hilbert Transform has zeros for every other coefficient, but the FDATool does not actually write out '0', except for the middle coefficient. The others are close to zero, but not precisely zero. For the attached example, if one tries to pass the coefficients from the FDATool to the FIR Compiler block using the traditional argument above, the error message below is displayed.

One workaround is to export the coefficients to a variable (Num), then run this script:

Num(2:2:end) = 0;

This will make the coefficients '0' versus "close to zero". Then, if you use 'Num' in the Fir Compiler coefficient field, things will work.

Note that if you change the filter order from 10 (11 taps) to 12 (13 taps), then the outer coefficients would be zero. In that case, you would have to use this:

Num(1:2:end) = 0;

A CR has been filed against the FIR Compiler block to be able to support this.

Another workaround:

In place of Matab Fdatool . you can use scilab
Software freely available for download from following link


Use this software for generating Hilbert coefficient

for example


It will generate the coefficient

- 0.0424413, 0., - 0.0489708, 0.,- 0.0578745,0.,- 0.0707355,
0., - 0.0909457, 0., - 0.1273240,0.,- 0.2122066,0., -
0.6366198,0.,0.6366198,0.,0.2122066,0., 0.1273240,0.,0.0909457,0.,

You can use these coefficients as shown in snap shot. These coefficients infer Hilbert transform.
AR# 36355
Date Created 01/21/2011
Last Updated 12/15/2012
Status Active
Type General Article
  • FIR Compiler