切换到宽版
  • 广告投放
  • 稿件投递
  • 繁體中文
    • 2467阅读
    • 1回复

    [原创]RP Fiber Power仿真设计掺铥光纤激光器代码详解 [复制链接]

    上一主题 下一主题
    离线小火龙果
     
    发帖
    932
    光币
    2176
    光券
    0
    只看楼主 倒序阅读 楼主  发表于: 2020-05-28
    (* n75)%-  
    Demo for program"RP Fiber Power": thulium-doped fiber laser, uNCM,J!#~  
    pumped at 790 nm. Across-relaxation process allows for efficient YbtsJ <w  
    population of theupper laser level. |eykb?j`  
    *)            !(*  *)注释语句 ,`PC^`0c}o  
    Su?e\7aj  
    diagram shown: 1,2,3,4,5  !指定输出图表 .2"-N5Z  
    ; 1: "Powersvs. Position"     !分号是注释;光纤长度对功率的影响 N(uHy@  
    ; 2:"Variation of the Pump Power"  !泵浦光功率变化对信号输出功率的影响 mSLA4[4{  
    ; 3:"Variation of the Fiber Length"!信号输出功率vs 光纤长度的变化,仿真最佳光纤长度 uonCD8  
    ; 4:"Transverse Profiles"             !横向分布,横坐标为半径位置 ?+av9;Kg  
    ; 5:"Transition Cross-sections"    !不同波长的跃迁横截面,横坐标波长,纵坐标为横截面 h ` qlI1]  
    \c}_!.xj"  
    include"Units.inc"         !读取“Units.inc”文件中内容 WoM;)Q  
    X3e&c  
    include"Tm-silicate.inc"    !读取光谱数据 _D~l2M  
    Ipro6 I  
    ; Basic fiberparameters:    !定义基本光纤参数 @<kY,ox@~  
    L_f := 4 { fiberlength }      !光纤长度 oCfO:7  
    No_z_steps := 50 {no steps along the fiber } !光纤步长,大括号{ }是注释,相当于备注 5.ibH  
    r_co := 6 um { coreradius }                !纤芯半径 -Zq\x'  
    N_Tm := 100e24 { Tmdoping concentration }  !纤芯Tm离子掺杂浓度 $B%wK`J  
    hr$Wt ?B  
    ; Parameters of thechannels:                !定义光信道 3LGX ^J<f  
    l_p := 790 nm {pump wavelength }                !泵浦光波长790nm Drm#z05i[g  
    dir_p := forward {pump direction (forward or backward) }   !前向泵浦 /2^"c+/'p  
    P_pump_in := 5 {input pump power }                    !输入泵浦功率5W !LI6_Oq  
    w_p := 50 um {radius of pump cladding }               !包层泵浦相应的半径 50um JLd-{}A""-  
    I_p(r) := (r <=w_p) { pump intensity profile }          !泵浦光强度分布 "5<:Dj/W  
    loss_p := 0 {parasitic losses of pump wave }           !泵浦光寄生损耗为0 &1 /OwTI4J  
    $7h]A$$Fv  
    l_s := 1940 nm {signal wavelength }                   !信号光波长1940nm L~oy|K67  
    w_s := 7 um                          !信号光的半径 m`i_O0T  
    I_s(r) := exp(-2 *(r / w_s)^2)            !信号光的高斯强度分布 P:D;w2'Q  
    loss_s := 0                            !信号光寄生损耗为0 UE9RrfdN  
    ;~D$ rT  
    R_oc := 0.70 {output coupler reflectivity (right side) }      !输出耦合反射率 {zX]4 1T  
    l266ufO.u-  
    ; Function for defining themodel:   !定义模型函数,一定要有calc命令,否则函数只会被定义,但不会被执行 o|:c{pwq  
    calc GY>G}bfh  
      begin fj|b;8_}l  
        global allow all;                   !声明全局变量 M*!WXQlud  
        set_fiber(L_f, No_z_steps, '');        !光纤参数  `j1oxJm  
        add_ring(r_co, N_Tm); }y%c.  
        def_ionsystem();              !光谱数据函数 BLN|QaZ  
        pump := addinputchannel(P_pump_in, l_p,'I_p', loss_p, dir_p);  !泵浦光信道 rJZR8bo  
        signal_fw := addinputchannel(0, l_s, 'I_s',loss_s, forward);      !前向信号光信道 *b'4>U  
        signal_bw := addinputchannel(0, l_s, 'I_s',loss_s, backward);    !后向信号光信道 cY5w,.Q/!  
        set_R(signal_fw, 1, R_oc);                                 !设置反射率函数 ]p8 zT|bv  
        finish_fiber();                                   xi51,y+(5  
      end; 3 ,zW6 -}  
    0iYo&q'n  
    ; Display someoutputs in the Output window (on the right side): !在Output aera区域显示输出 lZAXDxhnT  
    show "Outputpowers:"                                   !输出字符串Output powers: m"@o  
    show"pump:     ", P_out(pump):d3:"W"  !输出字符串pump:和计算值(格式为3个有效数字,单位W) _tUh*"e&  
    show"signal:   ",P_out(signal_fw):d3:"W" !输出字符串signal:和计算值(格式为3个有效数字,单位W) _ amP:h  
    6r|=^3{  
    Y-UXr8  
    ; ------------- rFUR9O.{E  
    diagram 1:                   !输出图表1 @Jx1n Q^  
    b wM?DY  
    "Powers vs.Position"          !图表名称 FsO_|r  
    Fw\g\  
    x: 0, L_f                      !命令x: 定义x坐标范围 A XhP3B]  
    "position infiber (m)", @x      !x轴标签;@x 指示这些字符串沿坐标轴放置 +Xp1=2Mq  
    y: 0, 15                      !命令y: 定义y坐标范围  qJ sH  
    y2: 0, 100                    !命令y2: 定义第二个y坐标范围 6P3h955c  
    frame          !frame改变坐标系的设置 ZIKSHC9  
    legpos 600, 500  !图行在图表窗口中的位置(相对于左上角而言) jDb"|l  
    hx             !平行于x方向网格 WkiPrQ0]:  
    hy              !平行于y方向网格 (3Q$)0t  
    nY7gST  
    f: P(pump, x),    !命令f: 定义函数图;P(pump, x)函数是计算x位置处的泵浦光功率 QChncIqc  
      color = red,  !图形颜色 Esu {c9,  
      width = 3,   !width线条宽度 ^U5Qb"hz  
      "pump"       !相应的文本字符串标签 9: .m]QN  
    f: P(signal_fw, x),  !P(signal_fw ,x) 函数是计算x位置处的前向信号光功率 h%U}Y5Ps~  
      color = blue,     [GPCd@  
      width = 3, Y)@Y$_  
      "fw signal" s7afj t  
    f: P(signal_bw, x),   !P(signal_bw ,x) 函数是计算x位置处的后向信号光功率 MVnN0K4  
      color = blue, xP_/5N=f  
      style = fdashed, O wuc9  
      width = 3, %3O))Ug5  
      "bw signal" ~`Rar2%B  
    KF6C=,Yc%  
    f: 100 * n(x, 2),    !n(x ,2) 函数是计算x位置处激活粒子数在能级2上的占比 NXQ=8o9,9  
      yscale = 2,            !第二个y轴的缩放比例 GGnlkp& E  
      color = magenta, ,f{w@Er  
      width = 3, {nXygg J  
      style = fdashed, @R}3f6@67  
      "n2 (%, right scale)" 5F+G8  
    d)S`.Q  
    f: 100 * n(x, 3),          !n(x ,3) 函数是计算x位置处激活粒子数在能级3上的占比 &8w# 4*W  
      yscale = 2, Y0.'u{J*  
      color = red, ~Th,<w*o  
      width = 3, 5RvE ),  
      style = fdashed, #CPLvg#  
      "n3 (%, right scale)" >s 6ye  
    &e6UEG  
    rf-yUH]&S  
    ; ------------- r<vy6  
    diagram 2:                    !输出图表2 Xp_m=QQsm  
    i(pHJP:a:  
    "Variation ofthe Pump Power" ]+46r!r|  
    {aNpk,n  
    x: 0, 10 /2zan}  
    "pump inputpower (W)", @x Cdib{y<ji  
    y: 0, 10 0Dna+V/jI  
    y2: 0, 100 $,2T~1tE  
    frame 5?F5xiW  
    hx t"Ci1"U  
    hy SOq:!Qt  
    legpos 150, 150 $%q=tn'EX  
    %0}^M1  
    f: (set_P_in(pump, x);P_out(signal_fw)), !set_P_in(pump,x)改变泵浦信道功率;P_out(signal_fw)输出前向信号光 }04mJY[  
      step = 5, w6Nn x5Ay  
      color = blue, vue^bn  
      width = 3, aUzCKX%>C  
      "signal output power (W, leftscale)",     !相应的文本字符串标签 4MS#`E7LrC  
      finish set_P_in(pump, P_pump_in) m)} 01N4  
    p09p/  
    f: (set_P_in(pump,x); 100 * n_av(2)),   !改变泵浦信号功率对能级2上激活粒子占比的影响 9M;t4Um  
      yscale = 2, Qw:!Rw,x  
      step = 5, >xabn*Kq  
      color = magenta, R?O)v Lmd  
      width = 3, +:uz=~m o`  
      "population of level 2 (%, rightscale)", MNWI%*0LO  
      finish set_P_in(pump, P_pump_in) 3q}j"x?  
    /$CTz xd1  
    f: (set_P_in(pump,x); 100 * n_av(3)),   !改变泵浦信号功率对能级3上激活粒子占比的影响 jtlRom}  
      yscale = 2, jOVF+9M  
      step = 5, ~<f[7dBv  
      color = red, Mn(iAsg  
      width = 3, '"fJA/O  
      "population of level 3 (%, rightscale)", V-}}?c1 F  
      finish set_P_in(pump, P_pump_in) IO)#O<  
    @]vY[O!&;  
    >i,_qe?V:w  
    ; ------------- [K.1 X=O}  
    diagram 3:                         !输出图表3 >4jE[$p]"  
    # G 77q$  
    "Variation ofthe Fiber Length" X)[tb]U/Wx  
    HKXC=^}x'  
    x: 0.1, 5 WA8<:#{e  
    "fiber length(m)", @x A}SGw.3  
    y: 0, 10 YND}P9 h  
    "opticalpowers (W)", @y )rK2%\Z  
    frame Os@b8V 8,A  
    hx 6sSwSS  
    hy yl~_~<s6  
    Mg.%&vH\  
    f: (set_L(x);P_out(signal_fw)),     !改变光纤长度对信号光输出功率的影响 ^iMr't\b  
      step = 20,             h<U?WtWT-p  
      color = blue, &7f8\TG|  
      width = 3, m4 (p MrJ  
      "signal output" xKG7d8=  
    w!7ApEH1  
    ;f: (set_L(x);P_out(pump)),                     !改变光纤长度对泵浦信号输出功率的影响 >MHlrSH2  
       step = 20, color = red, width = 3,"residual pump" Bi:lC5d5?  
    rk W7;!  
    ! set_L(L_f) {restore the original fiber length } &rBe -52  
    }yEV&& @  
    93HVx#  
    ; ------------- N s+g9+<A  
    diagram 4:                                  !输出图表4 fz=?QEG  
    #m.e9MU  
    "TransverseProfiles" }_]AQN$'G  
    eo0-aHs  
    I_max :=maxr(I(pump, -1, 0, 0), I(signal_fw, -1, 0, 0)) . ,^WCyvq  
    jr4xh {Z`  
    x: 0, 1.4 * r_co /um D=-}&w_T"  
    "radialposition (µm)", @x @gD) pH  
    y: 0, 1.2 * I_max *cm^2 4GRD- f[  
    "intensity (W/ cm&sup2;)", @y 6P1s*u  
    y2: 0, 1.3 * N_Tm 3F2IL)Hn  
    frame |#@7$#j  
    hx "l56?@-x  
    hy ^)Hf%  
     2h   
    f: N_dop(1, x * um,0),      !掺杂浓度的径向分布 s1D<R,J|H  
      yscale = 2, _]`7et\=  
      color = gray, bQt:=>  
      width = 3, @'R)$:I%L  
      maxconnect = 1, .>B'oD  
      "N_dop (right scale)" h=7q;-@7  
    'Rn-SD~gIr  
    f: I(pump, -1, x *um, 0) * cm^2,    !泵浦光沿光纤径向的强度分布 <?nIO  
      color = red, VI2lw E3  
      maxconnect = 1,           !限制图形区域高度,修正为100%的高度 /I`TN5~  
      width = 3, q H}8TC  
      "pump" <kK>C8+  
    r(>S  
    f: I(signal_fw, -1,x * um, 0) * cm^2,  !信号光沿光纤径向的强度分布 JN0h3nZ_  
      color = blue, Y@+Rb  
      maxconnect = 1, xnY?<?J"!  
      width = 3, '47 b"uV  
      "signal" AHb_BgOU*  
    c@t?R$c  
    _Je 4&KU  
    ; ------------- JI "/,fK^  
    diagram 5:                                  !输出图表5 f$o^Xu  
    P8d  
    "TransitionCross-sections" j<t3bM-G  
    TEC^|U`G  
    I_max :=maxr(I(pump, -1, 0, 0), I(signal_fw, -1, 0, 0)) U**8^:*y#:  
    PM\Ju]  
    x: 1450, 2050 x0 )V o]r  
    "wavelength(nm)", @x E]@&<TFq  
    y: 0, 0.6 (9]Uuvfp6"  
    "cross-sections(1e-24 m&sup2;)", @y aA`eKy) \  
    frame +:FXtO>n"  
    hx :; +!ID_  
    hy ]8p{A#1  
    <Ua~+U(FR0  
    f: s12_Tm(x * nm) /1e-24,      !Tm3+吸收截面与波长的关系 u"v7shRp:  
      color = red, *)Rm X$v3  
      width = 3, UR sx>yx  
      "absorption" U#3N90,N=  
    f: s21_Tm(x * nm) /1e-24,  !Tm3+发射截面与波长的关系 VgH O&vU  
      color = blue, s6 yvq#:  
      width = 3, g*V.u]U!i  
      "emission" NHd@s#@  
    -zg*p&F  
     
    分享到
    离线lileisgsz
    发帖
    14
    光币
    69
    光券
    0
    只看该作者 1楼 发表于: 2021-09-28
    感谢,视频上有点看不清楚