How to convert fixed point definitions (for example 'fixdt(0,32,1,-50)' to 'fixdt('ufix32_Bn50')')?
7 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
MathWorks Support Team
am 4 Jul. 2019
Beantwortet: MathWorks Support Team
am 4 Jul. 2019
How to convert fixed point definitions (for example 'fixdt(0,32,1,-50)' to 'fixdt('ufix32_Bn50')')?
This means I would like to get the 'DataTypeNameString' while I have the information about:
a = fixdt(Signed, WordLength, SlopeAdjustmentFactor, FixedExponent, Bias)
Akzeptierte Antwort
MathWorks Support Team
am 4 Jul. 2019
This can be done by an undocumented method of the class which is created while calling 'fixdt'.
Please be aware, that this method can be removed in a future release and if there are any issues while using it, our support is limited.
Here is the workflow:
Create the data type:
a = fixdt(0,32,1,-50)
Now you can get the 'DataTypeNameString' with the following:
a.tostringInternalSlName
Which will result in:
ans = 'ufix32_Bn50'
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Fixed Point finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!