필터 지우기
필터 지우기

I'm a beginner in matlab. I would like to plot a function as function in frequency..

조회 수: 1 (최근 30일)
my function is:
capacity(fk)=deltaf*sum*sum [log2(1-PTx(fk)*lamdai(fk)*/(M(fk)*N))];
plot(fk,capacity) f=(1:100MHz)
Where M is the number of transmit ports, lamdai denote the eigenvalues of HH, H(f) is the MIMO-PLC channel matrix and the superscript H represents the matrix Hermitian.
thank you.

채택된 답변

David Hill
David Hill 2021년 3월 3일
f=1:100e6;
capacity=(@f) ;%you need to describe your equation better. The sum*sum is confusing and the size of each variable should be noted
plot(f,capacity(f)); ​​
  댓글 수: 1
abdelmounim HMAMOU
abdelmounim HMAMOU 2021년 3월 3일
fmin=1e6;
fmax=1e8;
f2=3e7;
f1=10^7;
nf=4096;
for k=1:nf
f=fmin*df^(k-1);
v(k)=f;
MT=M0*ML1*Mb1*ML2;
H=inv(MT(1:2,1:2)+MT(1:2,3:4)*(YL)); %transfer function
H11=H(1,1); H22=H(2,2);H12=H(1,2);H21=H(2,1);
capacity=deltaf*sum(sum(log2(1+P(fk)*phi(fk))/(M(fk)*N(fk))));
cap(k)=capacity
% sum is: sumation from k=1 to k=nf and second sum from 1 to 2
% phi denote the eigenvalues of HH' ( H' is Hermitian matrix)
end
plot(k,cap)

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Programming에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by