Contenu principal

La traduction de cette page n'est pas à jour. Cliquez ici pour voir la dernière version en anglais.

Opérations mathématiques en virgule fixe dans MATLAB et Simulink

Opérations mathématiques basées sur CORDIC ou autre et optimisées pour les dispositifs embarqués pour du code C/C++ et HDL efficace

La bibliothèque de blocs Fixed-Point Designer™ permet une implémentation hardware efficace des opérations mathématiques et matricielles courantes avec des algorithmes comme CORDIC. Générez du code HDL pour les designs qui intègrent ces blocs en utilisant HDL Coder™. La bibliothèque de fonctions Fixed-Point Designer comprend des implémentations hardware efficaces, basées sur CORDIC ou autre, d’opérations mathématiques telles que des divisions, des opérations exponentielles et des fonctions trigonométriques. Utilisez un codeur pour générer du code C/C++ pour les designs qui intègrent ces fonctions.

Les algorithmes qui s’appuient sur CORDIC (COordinate Rotation DIgital Computer) comptent parmi les algorithmes les plus efficaces au niveau hardware, car ils nécessitent uniquement des opérations itératives de décalage et d'ajout. Avec l'algorithme CORDIC, il n’est plus nécessaire d'utiliser des multiplicateurs explicites. Il permet en outre de calculer un grand nombre de fonctions.

Pour les implémentations d’opérations matricielles basées sur CORDIC, y compris les solveurs de systèmes linéaires et les décompositions de matrices dans MATLAB® et Simulink®, consultez Opérations matricielles en virgule fixe dans MATLAB et Opérations matricielles en virgule fixe dans Simulink.

Fonctions

développer tout

cordicsigmoidCORDIC-based approximation of sigmoid activation (depuis R2023b)
ceilDivRound the result of division toward positive infinity (depuis R2021a)
fixDivRound the result of division toward zero (depuis R2021a)
floorDivRound the result of division toward negative infinity (depuis R2021a)
nearestDivRound the result of division toward the nearest integer (depuis R2021a)
modByConstantModulus after division by a constant denominator (depuis R2021a)
fixed.cordicDivideCORDIC-based fixed-point divide
fixed.cordicReciprocalCORDIC-based fixed-point reciprocal (depuis R2021b)
cordicsqrtCORDIC-based approximation of square root
cordicabsCORDIC-based absolute value
cordicangleCORDIC-based phase angle
cordiccexpCORDIC-based approximation of complex exponential
cordicacosCORDIC-based approximation of inverse cosine
cordicasinCORDIC-based approximation of inverse sine
cordicatan2CORDIC-based four quadrant inverse tangent
cordiccosCORDIC-based approximation of cosine
cordicsinCORDIC-based approximation of sine
cordicsincosCORDIC-based approximation of sine and cosine
cordicsinhcoshCORDIC-based approximation of hyperbolic sine and cosine (depuis R2023b)
cordictanhCORDIC-based hyperbolic tangent
cordiccart2polCORDIC-based transformation of Cartesian coordinates to polar
cordicpol2cartCORDIC-based approximation of polar-to-Cartesian conversion
cordicrotateCORDIC-based approximation of rotation of input

Blocs

développer tout

CORDIC Sigmoid HDL OptimizedCompute CORDIC-based sigmoid activation and generate optimized HDL code (depuis R2024a)
Complex Divide HDL OptimizedDivide one input by another using CORDIC algorithm and generate optimized HDL code (depuis R2021a)
Real Divide HDL OptimizedDivide one real input by another using CORDIC algorithm and generate optimized HDL code (depuis R2021a)
Divide by Constant HDL OptimizedDivide input by a constant and round to integer and generate optimized HDL code (depuis R2021a)
Divide by Constant and RoundDivide input by a constant and round to integer (depuis R2021a)
Modulo by Constant HDL OptimizedPerform mod operation with a constant denominator and generate optimized HDL code (depuis R2021a)
Modulo by ConstantPerform modulo operation with a constant denominator (depuis R2021a)
Normalized Reciprocal HDL OptimizedComputes normalized reciprocal using CORDIC algorithm and generates optimized HDL code
Real Reciprocal HDL OptimizedCompute reciprocal using CORDIC algorithm and generate optimized HDL code (depuis R2021a)
CORDIC Square Root HDL OptimizedCORDIC-based approximation of square root (depuis R2024a)
Complex to Magnitude-AngleCompute magnitude and phase angle of complex signal using CORDIC algorithm
Magnitude-Angle to ComplexConvert magnitude and/or a phase angle signal to complex signal
Hyperbolic Tangent HDL OptimizedComputes CORDIC-based hyperbolic tangent and generates optimized HDL code
Trigonometric FunctionSpecified trigonometric function on input
Euler to NED Transformation HDL OptimizedComputes Euler to North-East-Down transformation using pipelined or burst architecture and generates optimized HDL code (depuis R2022b)

Rubriques

Sélection d՚exemples