이 번역 페이지는 최신 내용을 담고 있지 않습니다. 최신 내용을 영문으로 보려면 여기를 클릭하십시오.
데이터 형변환 및 양자화하기
고정소수점 알고리즘을 설계할 때, cast
, zeros
, ones
, eye
및 subsasgn
을 사용하여 데이터형 정의와 핵심 알고리즘을 분리할 수 있습니다. 이러한 함수에서는 동일한 코드에 배정밀도, 단정밀도, 고정소수점 데이터형을 사용할 수 있습니다. Manual Fixed-Point Conversion Best Practices 항목에서는 일반 MATLAB® 코드에서 효율적인 고정소수점 구현을 생성하는 방법을 설명합니다.
double형을 사용한 최대 정밀도 연산방식을 시뮬레이션하고 알고리즘의 출력에서만 양자화하려면 quantizenumeric
을 사용하십시오.
임의의 워드 길이와 지수 길이를 가진 부동소수점 데이터를 시뮬레이션하려면 quantizer
객체 및 관련 객체 함수를 사용하십시오.
함수
도움말 항목
- Transformations for Quantized Data
How to transform quantized data between representations.
- Compute Quantization Error
This example shows how to compute and compare the statistics of the signal quantization error when using various rounding methods.
- Manual Fixed-Point Conversion Best Practices
Get from generic MATLAB code to an efficient fixed-point implementation using manual fixed-point conversion.