Simulating TPA after each propagation step

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Simulating TPA after each propagation step

Jassim
Hi Tino,

Iam trying to simulate the losses of trasnmitted energy due to two photon absorption in the UV.
Iam simulating SHG from 508 nm to 254 nm, and iam currently estimating TPA using the following formula:

Fomula
here is the source:
DOI: 10.1007/s00340-005-1954-7

I want to know if i can simulate the effect of TPA after each propagation step, for that i would need the peak intensity of each step during propagation.
I think this is possible ( correct me if iam wrong) to do this by converting the electric field using the formula :


I have attached the script iam using for yoru reference .
FHG_TPA.m


Looking forward to your reply
Best Regards
Jassim

Reply | Threaded
Open this post in threaded view
|

Re: Simulating TPA after each propagation step

tinolang
Administrator
Hi Jassim,

I suggest the following implementation:

- use the 'inloopFun' method of chi3D which is explained here: here

Basically, it executes a function which is defined in the ‘inloopFun’ parameter under obj.simProp, for every step during the propagation.

Here an example for your TPA case:

Before you run your simulation you define the inloopFun parameter:
obj = chi3D(); %greate a chi3D object
obj('inloopFun','[Eftfxfy_o Eftfxfy_e]=TPA(obj,Eftfxfy_o,Eftfxfy_e);'); %this points to a function named TPA which needs to be in the same working folder

% now you can simply run the simulation 
obj.run({'pulse1','Ny',1,'propagationLength',1e-3});

The TPA function (TPA.m) can look like this:
function [Eftfxfy_o Eftfxfy_e]=TPA(obj,Eftfxfy_o,Eftfxfy_e)

ce0=299792458/2*8.854e-12; %needed later for getting the intensity distribution; n is different for ordinary and extra-ordinary field
beta_o = 0; %TPA coefficient for the ordinary field
beta_e = .34e-11; %TPA coefficient for the extra-ordinary field


dz=obj.constVars.dz; %step size in z direction

n = meshgrid(obj.constVect.no,[1:obj.simProp.Nx])'; %ordinary refractiv index field in frequency domain; for 3D simulation this needs to be 3D as well
Etxy = ifftn(Eftfxfy_o.*sqrt(n));  %electrical field in vacuum -> intensity is independent on the refractive index
I_txy = abs(Etxy).^2 *ce0; %convert to intensity
dItx = -beta_o*I_txy.^2*obj.constVars.dz; %TPA -> dI = - beta * I^2 *dz
Ftx = 1+dItx./I_txy; %is is the time and spatial dependen two photon absorption factor for the propagation step dz
Eftfxfy_o = fftn(Etxy.*sqrt(Ftx))./sqrt(n); %applying the factor and transformation back to the spectral domain -> this field now is send back to the main loop in chi3D

%doing the same for the extra-ordinary field
n = obj.constVect.ne';
Etxy = ifftn(Eftfxfy_e.*sqrt(n));
I_txy = abs(Etxy).^2 *ce0;
dItx = -beta_e*I_txy.^2*obj.constVars.dz; % dI = - beta * I^2 *dz
Ftx = 1+dItx./I_txy;
Eftfxfy_e = fftn(Etxy.*sqrt(Ftx))./sqrt(n);

For the high green intensity in the SHG standard example this is a suprisingly strong effect.
Thanks for this question!

Best,
Tino
Tino Lang