필터 지우기
필터 지우기

code vs written formula

조회 수: 2 (최근 30일)
Ashis Pandey
Ashis Pandey 2022년 6월 14일
편집: Torsten 2022년 6월 14일
I am trying to understand what calxculation the code is doing.. can you breakdown the formuola in the first line like how it looks when written in mathematical form?
Nfft = 2^(ceil(log2(size(freq,2)))+1);
Ts = 1/Nfft/(freq(2)-freq(1)+1e-16); %Avoid nan checks
time_vec = (0:Ts:Ts*(Nfft-1));
dist_vec = time_vec*1.5e8; %distance in meters
  댓글 수: 1
Torsten
Torsten 2022년 6월 14일
편집: Torsten 2022년 6월 14일
Take the number of columns of the matrix "freq", take the log to the basis 2 of this number, take the nearest positive integer (>= this number), take (2^this number) and multiply the result by 2.
E.g. if freq has 64 columns, you get 64 = 2^6 -> 6 -> 6 -> 2^6 = 64 -> 2*64=128 = Nfft.

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Antenna and Array Analysis에 대해 자세히 알아보기

제품


릴리스

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by