Defining and plotting a function using symsum
1 回表示 (過去 30 日間)
古いコメントを表示
Hello
I am trying to plot the array factor for a uniform linear antenna array using this code:
syms k
psi = -pi: .05: pi;
AF = symsum(exp(1i*(k-1).*psi), k, 1, 10)
AF_dB = 10.*log10(AF);
figure(1)
plot(psi, AF_dB)
I can tell that something is wrong with the way I am defining the summation for AF because when k is 1, AF is evaluated to be 0 when it should be 1.
I am trying to figure out how to define a function, in this case AF, as a summation so that I can define more complicated array factors and do things like determine side lobe level by using findpeaks, etc. Is there a better way to do that than what I have tried to implement here?
Thank you
0 件のコメント
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Analysis についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!