Main Content

Hyperbolic Tangent HDL Optimized

Computes CORDIC-based hyperbolic tangent and generates optimized HDL code

  • Library:
  • Fixed-Point Designer / Math Operations

  • Hyperbolic Tangent HDL Optimized block

Description

The Hyperbolic Tangent HDL Optimized block returns the hyperbolic tangent of x, computed using a CORDIC-based implementation optimized for HDL code generation.

Ports

Input

expand all

Angle in radians, specified as a real finite scalar. If x is a fixed-point or scaled double data type, x must use binary-point scaling. Slope-bias representation is not supported for fixed-point data types.

Data Types: single | double | fixed point

Whether input is valid, specified as a Boolean scalar. This control signal indicates when the data from the x input port is valid. When this value is 1 (true), the block captures the value on the x input port. When this value is 0 (false), the block ignores the input samples.

Data Types: Boolean

Output

expand all

Hyperbolic tangent of the value at x, returned as a scalar. The value at y is the CORDIC-based approximation of the hyperbolic tangent of x. When the input to the function is floating point, the output data type is the same as the input data type. When the input is a fixed-point data type, the output has the same word length as the input and a fraction length equal to 2 less than the word length.

Data Types: single | double | fixed point

Whether the output data is valid, returned as a Boolean scalar. When the value of this control signal is 1 (true), the block has successfully computed the output y. When this value is 0 (false), the output data is not valid.

Data Types: Boolean

Whether the block is ready, returned as a Boolean scalar. This control signal indicates when the block is ready for new input data. When this value is 1 (true), and the validIn value is 1 (true), the block accepts input data in the next time step. When this value is 0 (false), the block ignores input data in the next time step.

Data Types: Boolean

Algorithms

expand all

References

[1] Volder, JE. “The CORDIC Trigonometric Computing Technique.” IRE Transactions on Electronic Computers. Vol. EC-8, September 1959, pp. 330–334.

[2] Andraka, R. “A survey of CORDIC algorithm for FPGA based computers.” Proceedings of the 1998 ACM/SIGDA sixth international symposium on Field programmable gate arrays. Feb. 22–24, 1998, pp. 191–200.

[3] Walther, J.S. “A Unified Algorithm for Elementary Functions.” Hewlett-Packard Company, Palo Alto. Spring Joint Computer Conference, 1971, pp. 379–386. (from the collection of the Computer History Museum). www.computer.org/csdl/proceedings/afips/1971/5077/00/50770379.pdf

[4] Schelin, Charles W. “Calculator Function Approximation.” The American Mathematical Monthly. Vol. 90, No. 5, May 1983, pp. 317–325.

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.

Introduced in R2020a