Sum of harmonics

버전 1.0.0.0 (6.71 KB) 작성자: Gabriele
Sum of harmonic components through FORTRAN MEX file
다운로드 수: 1.4K
업데이트 날짜: 2006/10/12

라이선스 보기

For several different reasons it could occur that we need to produce a signal from the sum of several harmonic components. In the usual case of Fourier analysis, FFT and IFFT are likely the best choice. However it could happen that:
- The frequencies of the harmonic components are unevenly spaced
- The time vector is unevenly spaced
In such cases we could be in the need of coding the summation directly in Matlab, that is quite slow in performing this tasks.
The provided function is simply a MEX file that performs the signal generation through a compiled FORTRAN code.
Nothing special, but at least I run the generation almost three times faster than in Matlab. Not as good as in the cases where you can use IFFT directly in Matlab, but at least a little bit better than using a "for" loop directly in Matlab.

인용 양식

Gabriele (2024). Sum of harmonics (https://www.mathworks.com/matlabcentral/fileexchange/12508-sum-of-harmonics), MATLAB Central File Exchange. 검색됨 .

MATLAB 릴리스 호환 정보
개발 환경: R13
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
카테고리
Help CenterMATLAB Answers에서 Fortran with MATLAB에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!
버전 게시됨 릴리스 정보
1.0.0.0

Better explanation of the fact that the speed is increased with respect to the standard for loop in matlab