Hi Aayushi,
Kindly follow the below steps to achieve time dependent group velocity dispersion parameter and plot the graph between intensity and T/To. Set physical constants and parameters such as the speed of light 'c', central angular frequency 'omega0', and pulse width 'To'.
Define the Range for Time 'T':
- Create a range for 'T' from (-10 \times T_0) to (10 \times T_0).
- Compute 'T_div_To' as T divided by To for plotting.
Calculate the Group Velocity Dispersion Parameter 'beta2':
- Define a frequency range 'omega' around 'omega0'.
- Calculate the term involving 'omega' and its second derivative with respect to 'omega' using numerical differentiation.
- Compute 'beta2' using the expression derived from the second derivative.
Interpolate 'beta2' at 'omega0':
- Use interpolation to find the value of 'beta2' at 'omega0' to ensure it is compatible with the size of the time array T.
Calculate the Intensity of the Gaussian Pulse:
- Use the Gaussian pulse equation to calculate the field 'U' as a function of 'T'.
- Compute the intensity as the squared magnitude of 'U'.
Kindly refer to the below code for better understanding of the steps metioned above.
omega = linspace(omega0 - 5e13, omega0 + 5e13, 1000);
term = 1 - mu * (omega - omega0) ./ sqrt((omega - omega0).^2 + L^2);
d_term_domega = gradient(term, omega);
d2_term_domega2 = gradient(d_term_domega, omega);
beta2 = (omega/c) .* d2_term_domega2;
beta2_interp = interp1(omega, beta2, omega0, 'linear', 'extrap');
U = To ./ sqrt(To^2 - 1i * beta2_interp * z) .* exp(-T.^2 ./ (2 * (To^2 - 1i * beta2_interp * z)));
'For more information regarding the "gradient" function, kindly refer to the following MATLAB documentation: