How to convert data from floating point to fixed point? Not function, only data.

I want to convert an array of single precision data into fixed point and I have proposed length of the data I want.
How to convert? All the searched answers are about the convertion flow of floating point function/algorithm/design to fixed point implementation.
Can I just convert the data?

 채택된 답변

Try calling the fi function.
q = fi(pi)
q =
3.1416 DataTypeMode: Fixed-point: binary point scaling Signedness: Signed WordLength: 16 FractionLength: 13

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Data Type Conversion에 대해 자세히 알아보기

제품

릴리스

R2022b

질문:

2023년 5월 8일

댓글:

2023년 5월 8일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by