matrix mis-match
이전 댓글 표시
M= 100; % gain for Si and 50 for Ge
R_d= 75; % responsivity for Si and 35A/W for Ge
q= 1.6*10.^-19; % charge
F_noise = 0.5; % nosie figure 0f Si and 0.95 for Ge
I_d = 15 * 10.^-9; % dark Current for Si and 700nA for Ge
B_e = 5*10.^9; % bandwidth for Si and 0.2GHz for Ge
k_B = 1.38*10.^-23; % boltzmann constant
T = 298 ; % tamperature in kelvins
R = 10*10.^3; % APD load resistance
k = -40:20:80;
K_w = 1*10.^-3 * 10.^( k / 10);
Pr1 = (K_w*0.75*0.75*(exp(-0.003*25./cos(pi/36))) .* 0.01 .* cos(pi/36) ./ ((2*pi*25.^2)*(1-cos(pi/3))));
I_p= sqrt(M*R_d*Pr1); %average photocurrent
I_short= sqrt(2*q*I_p*M.^2*F_noise);
I_dark = sqrt(2*q*I_d*M.^2*F_noise*B_e);
I_thermal = sqrt((4*k_B*T/R)*B_e);
I_noise1 = sqrt(I_short1 + I_dark + I_thermal);
SNR1 = I_p.^2*M^2/I_noise1;
SNR_db1 = 1.*log(SNR1);
figure
plot(k,SNR_db1,'-ro')
Error using /
Matrix dimensions must agree.
댓글 수: 1
Adam Danz
2019년 9월 12일
We don't have the value for "I_short1" so we cannot run your code.
However, if I give it a scalar value, the code runs without error.
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 MATLAB에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!