Matlab:绘制透反射光波的幅度与相位随入射角的变化

  本文根据菲涅尔公式简单绘制介质分界面处折反射光波的幅度、相位变化与入射角的关系。

代码如下:

%% ******************绘制反射率与相位值随入射角的变化——用于课程作业***********
% 1.菲涅尔定律

clear,clc,close all;
n1 = 1.44;
n2 = 1.00;               %介质折射率
n = n2/n1;
theta = linspace(0,pi/2,900);
theta_i = theta*180/pi;
%电场的反射和透射系数
r_E = (cos(theta)-sqrt(abs(n).^2-abs(sin(theta)).^2))./(cos(theta)+sqrt(abs(n).^2-abs(sin(theta)).^2));
t_E = 2*cos(theta)./(cos(theta)+sqrt(abs(n).^2-abs(sin(theta)).^2));
r_B = (sqrt(abs(n).^2-abs(sin(theta)).^2)-abs(n).^2*cos(theta))./(sqrt(abs(n).^2-abs(sin(theta)).^2)+abs(n).^2*cos(theta));
t_B = 2*n*cos(theta)./(abs(n).^2*cos(theta)+sqrt(abs(n).^2-abs(sin(theta)).^2));

figure;
plot(theta_i,abs(r_E),'--',theta_i,abs(r_B),'-','LineWidth',2);
legend('r_E电场','r_B磁场');
xlabel('入射角/theta_i'),ylabel('相对反射系数幅度');
axis([0 90 0 1]);
title(['n1 = ',num2str(n1),'n2 = ',num2str(n2),'时反射系数幅度r_E电场、r_B磁场和入射角theta_i的关系']);

figure;
plot(theta_i,-angle(r_E)*180/pi,'--',theta_i,-angle(r_B)*180/pi,'-','LineWidth',2);
legend('phi_E电场','phi_B磁场');
xlabel('入射角/theta_i'),ylabel('相位变化/(°)');
axis([0 90 -180 180]);
title('对应相位变化phi_E电场、phi_B磁场和入射角的关系');

反射光波的幅度变化如下:

 

 反射光波的相位变化如下:

 

同理可得透射光波的幅度和相位随入射角的变化~ 

  • 7
    点赞
  • 21
    收藏
    觉得还不错? 一键收藏
  • 2
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值