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# 3498

V1.5, V1.4 CORE Generator - Does CORE Generator support floating point values in the COE coefficient files?


Keywords: floating point, fixed point, coefficients, .coe

Urgency: Standard

General Description:
Can I use floating point or fixed point decimals in coefficient files? Do any CORE Generator modules support floating point arithmetic in general?


CORE Generator modules currently do not support floating point arithmetic. However, such support is not absolutely necessary in many cases, as it is possible to emulate "floating point" arithmetic if you have a known, fixed limit of precision that needs to be supported.

Suppose A and B are used in a calculation, and both A and B are 16-bit floating point numbers ranging in value from 0 to 1. It may seem that there is a need to perform floating point arithmetic.

However, just because a number falls between 0 and 1 does not mean that is must be represented as floating point. The only advantage of floating point arithmetic has is that it allows you to trade a large DYNAMIC RANGE for PRECISION in your application. This is because you are usually limited in the number of bits that you can use to represent your coefficient values. If you are restricted to 16 bits to represent your values, and you choose to represent it as a floating point number, the 16-bit floating point number must use some bits for precision (in the Mantissa) and some bits for the exponent. As a result, you cannot obtain both maximum range and precision at the same time.

However, if you know the smallest value that must be represented, you can represent ALL of your values using fixed point integers and perform your calculations using fixed point arithmetic. The results of all calculations are then simply scaled to restore the fractional representation.

For example, a 16-bit integer could represent all values from 0 to 1 in steps of 1/65536. Using this conversion, all processing logic need only work in whole numbers.
AR# 3498
日期 09/04/2002
状态 Archive
Type ??????