Specifiche della virgola mobile in Simulink
Creare e utilizzare tipi di dati in virgola mobile a singola precisione e a mezza precisione
Poiché i numeri a singola precisione utilizzano solo 32 bit, richiedono meno memoria dei numeri a doppia precisione, pur offrendo molti dei vantaggi dell'aritmetica in virgola mobile. Il tipo di dati a mezza precisione occupa solo 16 bit di memoria, ma la sua rappresentazione in virgola mobile consente di gestire intervalli dinamici più ampi rispetto ai tipi di dati interi o in virgola fissa della stessa grandezza.
Classi
Simulink.NumericType | Specify floating-point, integer, or fixed-point data type |
target.FloatingPointDataType | Describe floating point data type implemented by compiler for target hardware (Da R2021b) |
Funzioni
ssGetDataTypeIsDoubleSingleorHalf | Determine whether registered data type is double, single, or half-precision data type |
ssGetDataTypeIsHalfPrecision | Determine whether registered data type is half-precision data type |
ssRegisterDataTypeHalfPrecision | Register half-precision data type and return its data type ID |
target.add | Add target object to internal database |
target.create | Create target object |
target.get | Retrieve target objects from internal database |
target.remove | Remove target object from internal database |
Namespaces
target | Manage target hardware and build tool information |
Argomenti
- What Is Half Precision?
Introduction to the half-precision data type in MATLAB® and Simulink®.
- The Half-Precision Data Type in Simulink
Simulink software features supported for the half-precision data type.
- Generate Native Half-Precision C Code from Simulink Models
Generate C code for embedded hardware targets that natively supports half precision floating-point data types.



