椭圆偏振光的仿真计算.doc

上传人:精*** 文档编号:829937 上传时间:2023-09-06 格式:DOC 页数:30 大小:448KB
下载 相关 举报
椭圆偏振光的仿真计算.doc_第1页
第1页 / 共30页
椭圆偏振光的仿真计算.doc_第2页
第2页 / 共30页
椭圆偏振光的仿真计算.doc_第3页
第3页 / 共30页
椭圆偏振光的仿真计算.doc_第4页
第4页 / 共30页
椭圆偏振光的仿真计算.doc_第5页
第5页 / 共30页
点击查看更多>>
资源描述

1、目 录一、课题1:课题名称11.1.课题任务要求及技术指标11.2.课题分析及设计思路11.3.系统设计(建模)11.4.仿真结果与结果分析1二、课题2:课题名称22.1.课题任务要求及技术指标22.2.课题分析及设计思路22.3.系统设计(建模)22.4.仿真结果与结果分析2三、课题3:课题名称33.1.课题任务要求及技术指标33.2.课题分析及设计思路33.3.系统设计(建模)33.4.仿真结果与结果分析3四、课程设计小结4一、课题1:课题名称1.1.课题任务要求及技术指标椭圆偏振光的仿真计算设计任务:根据椭圆偏振光公式:(1)做出对应不同值的椭圆偏振图;(2)两椭圆(包括圆)偏振光的叠加

2、。设计要求:(1)具有友好输入输出界面;(2)可根据输入的不同参数值,查看结果。参考:物理光学椭圆偏振光1.2.课题分析及设计思路 1.3.系统设计(建模)function varargout = wxy3(varargin)gui_Singleton = 1;gui_State = struct(gui_Name, mfilename, . gui_Singleton, gui_Singleton, . gui_OpeningFcn, wxy3_OpeningFcn, . gui_OutputFcn, wxy3_OutputFcn, . gui_LayoutFcn, , . gui_Call

3、back, );if nargin & ischar(varargin1) gui_State.gui_Callback = str2func(varargin1);endif nargout varargout1:nargout = gui_mainfcn(gui_State, varargin:);else gui_mainfcn(gui_State, varargin:);end function wxy3_OpeningFcn(hObject, eventdata, handles, varargin)handles.output = hObject;guidata(hObject,

4、handles);function varargout = wxy3_OutputFcn(hObject, eventdata, handles) varargout1 = handles.output;function editx_Callback(hObject, eventdata, handles)input = str2num(get(hObject,String);if (isempty(input) set(hObject,String,);endguidata(hObject, handles); function editx_CreateFcn(hObject, eventd

5、ata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);end function edity_Callback(hObject, eventdata, handles)input = str2num(get(hObject,String);if (isempty(input) set(hObject,String,);endguidata(hObject, handles);function ed

6、ity_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);Else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction edita_Callback(hObject, eventdata, handles)input = str2num(get(hObject,String);if (isempty(input) set(hObject,String,);endguidata(h

7、Object, handles);function edita_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction pushbutton1_Callback(hObject, eventdata, handles)X=str2num(get(handles.editx,String);Y=str2num(get(hand

8、les.edity,String);a=str2num(get(handles.edita,String);syms x yf=(x./X).2+(y./Y).2-2.*(x./X).*(y./Y).*cos(a)-sin(a).*sin(a);axes(handles.axes1);ezplot(f,-2*X,2*X);grid on;guidata(hObject, handles); function editx2_Callback(hObject, eventdata, handles) function editx2_CreateFcn(hObject, eventdata, han

9、dles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction edity2_Callback(hObject, eventdata, handles)function edity2_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);elseset(hObject,BackgroundC

10、olor,get(0,defaultUicontrolBackgroundColor);endfunction edita2_Callback(hObject, eventdata, handles) function edita2_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction pushbutton2_Callba

11、ck(hObject, eventdata, handles)X=str2num(get(handles.editx2,String);Y=str2num(get(handles.edity2,String);a=str2num(get(handles.edita2,String);syms x yf=(x./X).2+(y./Y).2-2.*(x./X).*(y./Y).*cos(a)-sin(a).*sin(a);axes(handles.axes2);ezplot(f,-2*X,2*X);grid on;guidata(hObject, handles); function pushbu

12、tton3_Callback(hObject, eventdata, handles)X=str2num(get(handles.editx,String);Y=str2num(get(handles.edity,String);a=str2num(get(handles.edita,String);syms x yf1=(x./X).2+(y./Y).2-2.*(x./X).*(y./Y).*cos(a)-sin(a).*sin(a);X2=str2num(get(handles.editx2,String);Y=str2num(get(handles.edity2,String);a=st

13、r2num(get(handles.edita2,String);syms x yf2=(x./X2).2+(y./Y).2-2.*(x./X2).*(y./Y).*cos(a)-sin(a).*sin(a);f=f1+f2;axes(handles.axes3);ezplot(f,-2*(X+X2),2*(X+X2);grid on;guidata(hObject, handles);1.4.仿真结果与结果分析 二、课题2:课题名称2.1.课题任务要求及技术指标高斯光束特性参数的仿真计算设计任务:某平凹腔激光器,若已知凹面镜曲率半径,腔长及激光波长。求它所产生的高斯光束的腰斑半径的大小和位置

14、,以及该高斯光束发散角的大小。设计要求:(1)具有友好输入输出界面;(2)可改变参数值(曲率半径,腔长、激光波长),查看结果变化情况;(3)比较所得结果,分析曲率半径、腔长以及激光波长分别对高斯光束的腰斑半径和发散角有何影响。参考:激光原理高斯光束2.2.课题分析及设计思路 2.3.系统设计(建模)function varargout = wxy6(varargin)gui_Singleton = 1;gui_State = struct(gui_Name, mfilename, . gui_Singleton, gui_Singleton, . gui_OpeningFcn, wxy6_Op

15、eningFcn, . gui_OutputFcn, wxy6_OutputFcn, . gui_LayoutFcn, , . gui_Callback, );if nargin & ischar(varargin1) gui_State.gui_Callback = str2func(varargin1);endif nargout varargout1:nargout = gui_mainfcn(gui_State, varargin:);else gui_mainfcn(gui_State, varargin:);end function wxy6_OpeningFcn(hObject,

16、 , handles, varargin)handles.output = hObject;guidata(hObject, handles);function varargout = wxy6_OutputFcn(, , handles)varargout1 = handles.output;function popupmenuB_Callback(hObject, , handles)index=get(hObject,Value);set(handles.uipanelbc,Visible,off);switch(index) case 6 set(handles.uipanelbc,V

17、isible,on); otherwiseendfunction popupmenuB_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);Endfunction editR_Callback(hObject, eventdata, handles)input = str2num(get(hObject,String);if (isempty(

18、input) set(hObject,String,);endguidata(hObject, handles); function editR_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);end function editL_Callback(hObject, eventdata, handles)input = str2num(ge

19、t(hObject,String);if (isempty(input) set(hObject,String,);endguidata(hObject, handles);function editL_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction editW_Callback(hObject, eventdata

20、, handles)function editW_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);end function editJ_Callback(hObject, eventdata, handles)function editJ_CreateFcn(hObject, eventdata, handles)if ispc set(h

21、Object,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction pushbuttonCalc_Callback(hObject, eventdata, handles)R = str2double(get(handles.editR,String);L = str2double(get(handles.editL,String);if(isempty(get(handles.editR,String) msgbox(请输入曲率半径,

22、出错.);elseif(isempty(get(handles.editL,String) msgbox(请输入腔长,出错.);elseif(R=L) msgbox(平凹稳定腔的曲率半径应大于腔长,请重新输入,出错啦.); set(handles.editR,String,); set(handles.editL,String,)else B=0; index=get(handles.popupmenuB,Value); switch(index) case 1 B=441.6; case 2 B=632.8; case 3 B=694.3; case 4 B=1060.0; case 5 B

23、=10600; case 6 B=str2double(get(handles.editB,String); otherwise end f = sqrt(L*(R-L); w = sqrt(f*B*0.000000001/3.14); j=2*sqrt(B*0.000000001/(3.14*f); w j set(handles.editW,String,num2str(w); set(handles.editJ,String,num2str(j); guidata(hObject, handles);endfunction editB_Callback(hObject, eventdat

24、a, handles)input = str2num(get(hObject,String);if (isempty(input) set(hObject,String,);endguidata(hObject, handles);function editB_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction push

25、buttonwb_Callback(hObject, eventdata, handles)function editR2_Callback(hObject, eventdata, handles)function editR2_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction editL2_Callback(hObj

26、ect, eventdata, handles)function editL2_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction pushbutton6_Callback(hObject, eventdata, handles)function edit16_Callback(hObject, eventdata, h

27、andles)function edit16_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction edit17_Callback(hObject, eventdata, handles)function edit17_CreateFcn(hObject, eventdata, handles)if ispc set(hO

28、bject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction edit18_Callback(hObject, eventdata, handles)function edit18_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,default

29、UicontrolBackgroundColor);endfunction edit19_Callback(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction axes1_CreateFcn(hObject, eventdata, handles)function editB4_Callback(hObject, eventdata, ha

30、ndles)function editB4_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction editB3_Callback(hObject, eventdata, handles)function editB3_CreateFcn(hObject, eventdata, handles)if ispc set(hOb

31、ject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction edit22_Callback(hObject, eventdata, handles)function edit22_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultU

32、icontrolBackgroundColor);endfunction editL4_Callback(hObject, eventdata, handles)function editL4_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction editR3_CreateFcn(hObject, eventdata, h

33、andles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction popupmenu3_Callback(hObject, eventdata, handles)function popupmenu3_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,

34、BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction popupmenu2_Callback(hObject, eventdata, handles)function popupmenu2_CreateFcn(hObject, eventdata, handles)if ispc set(hObject,BackgroundColor,white);else set(hObject,BackgroundColor,get(0,defaultUicontrolBackgroundColor);endfunction

35、pushbutton7_Callback(hObject, eventdata, handles)i1=get(handles.popupmenu2,Value)i2=get(handles.popupmenu3,Value)if(i1=1) if(i2=1) L=str2double(get(handles.editL,String); i3=get(handles.popupmenuB,Value) switch(i3) case 1 B=441.6; case 2 B=632.8; case 3 B=694.3; case 4 B=1060.0; case 5 B=10600; case

36、 6 B=str2double(get(handles.editB,String); end R=L:1:4*L; f=sqrt(L.*(R-L); w=sqrt(f*B.*L/31.4).*0.0001; axes(handles.axes1); plot(R,w); title(腰斑半径跟曲率半径的关系图); xlabel(曲率半径); ylabel(腰斑半径); grid on; else if(i2=2) R=str2double(get(handles.editR,String); i3=get(handles.popupmenuB,Value) switch(i3) case 1 B=441.6; case 2 B=632.8; case 3 B=694.3; case 4 B=1060.0; case 5 B=10600; case 6 B=str2double(get(handles.editB,String); end L=0:R/10:R; f=sqrt(L.*(R-L

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 学术论文 > 毕业设计

版权声明:以上文章中所选用的图片及文字来源于网络以及用户投稿,由于未联系到知识产权人或未发现有关知识产权的登记,如有知识产权人并不愿意我们使用,如有侵权请立即联系:2622162128@qq.com ,我们立即下架或删除。

Copyright© 2022-2024 www.wodocx.com ,All Rights Reserved |陕ICP备19002583号-1 

陕公网安备 61072602000132号     违法和不良信息举报:0916-4228922