meent.on_torch.emsolver package#
Submodules#
meent.on_torch.emsolver.convolution_matrix module#
meent.on_torch.emsolver.field_distribution module#
meent.on_torch.emsolver.primitives module#
meent.on_torch.emsolver.rcwa module#
meent.on_torch.emsolver.scattering_method module#
currently SMM is not supported
- meent.on_torch.emsolver.scattering_method.scattering_1d_1(k0, n_I, n_II, theta, phi, fourier_indices, period, pol, wl=None)#
- meent.on_torch.emsolver.scattering_method.scattering_1d_2(W, Wg, V, Vg, d, k0, LAMBDA, Sg)#
- meent.on_torch.emsolver.scattering_method.scattering_1d_3(Wt, Wg, Vt, Vg, Sg, ff, Wr, fourier_order, Kzr, Kzt, n_I, n_II, theta, pol)#
- meent.on_torch.emsolver.scattering_method.scattering_2d_1(n_I, n_II, theta, phi, k0, period, fourier_order)#
- meent.on_torch.emsolver.scattering_method.scattering_2d_2(W, Wg, V, Vg, d, k0, Sg, LAMBDA)#
- meent.on_torch.emsolver.scattering_method.scattering_2d_3(Wt, Wg, Vt, Vg, Sg, Wr, Kx, Ky, Kzr, Kzt, kz_inc, n_I, pol, theta, phi, fourier_order, ff)#
- meent.on_torch.emsolver.scattering_method.scattering_2d_wv(ff, Kx, Ky, E_conv, oneover_E_conv, oneover_E_conv_i, E_i, mu_conv=None)#
meent.on_torch.emsolver.smm_util module#
currently SMM is not supported
- meent.on_torch.emsolver.smm_util.A_B_matrices(W_layer, Wg, V_layer, Vg)#
single function to output the a and b matrices needed for the scatter matrices :param W_layer: gap :param Wg: :param V_layer: gap :param Vg: :return:
- meent.on_torch.emsolver.smm_util.A_B_matrices_half_space(V_layer, Vg)#
- meent.on_torch.emsolver.smm_util.K_matrix_cubic_2D(beta_x, beta_y, k0, a_x, a_y, N_p, N_q)#
- Parameters:
beta_x – input k_x,inc/k0
beta_y – k_y,inc/k0; #already normalized…k0 is needed to normalize the 2*pi*lambda/a however such normalization can cause singular matrices in the homogeneous module (specifically with eigenvalues)
:param T1:reciprocal lattice vector 1 :param T2: :param T3: :return:
- meent.on_torch.emsolver.smm_util.P_Q_kz(Kx, Ky, e_conv, mu_conv, oneover_E_conv, oneover_E_conv_i, E_i)#
r is for relative so do not put epsilon_0 or mu_0 here :param Kx: NM x NM matrix :param Ky: :param e_conv: (NM x NM) conv matrix :param mu_r: :return:
- meent.on_torch.emsolver.smm_util.RedhefferStar(SA, SB)#
RedhefferStar for arbitrarily sized 2x2 block matrices for RCWA :param SA: dictionary containing the four sub-blocks :param SB: dictionary containing the four sub-blocks, keys are ‘S11’, ‘S12’, ‘S21’, ‘S22’ :return:
- meent.on_torch.emsolver.smm_util.S_RT(A, B, ref_mode)#
- meent.on_torch.emsolver.smm_util.S_layer(A, B, d, k0, modes)#
function to create scatter matrix in the ith layer of the uniform layer structure we assume that gap layers are used so we need only one A and one B :param A: function A = :param B: function B :param k0 #free -space wavevector magnitude (normalization constant) in Si Units :param Li #length of ith layer (in Si units) :param modes, eigenvalue matrix :return: S (4x4 scatter matrix) and Sdict, which contains the 2x2 block matrix as a dictionary
- meent.on_torch.emsolver.smm_util.construct_global_scatter(scatter_list)#
this function assumes an RCWA implementation where all the scatter matrices are stored in a list and the global scatter matrix is constructed at the end :param scatter_list: list of scatter matrices of the form [Sr, S1, S2, … , SN, ST] :return:
- meent.on_torch.emsolver.smm_util.delta_vector(P, Q)#
create a vector with a 1 corresponding to the 0th order #input P = 2*(num_ord_specified)+1
- meent.on_torch.emsolver.smm_util.homogeneous_1D(Kx, n_index, m_r=1, pol=None, perturbation=1e-10, wl=None, comment=None)#
efficient homogeneous 1D module :param Kx: :param e_r: :param m_r: :return:
- meent.on_torch.emsolver.smm_util.homogeneous_module(Kx, Ky, e_r, m_r=1, perturbation=1e-10, wl=None, comment=None)#
homogeneous layer is much simpler to do, so we will create an isolated module to deal with it :return:
- meent.on_torch.emsolver.smm_util.initial_conditions(K_inc_vector, theta, normal_vector, pte, ptm, P, Q)#
- Parameters:
K_inc_vector – whether it’s normalized or not is not important…
theta – angle of incience
normal_vector – pointing into z direction
pte – te pol amplitude
ptm – tm pol amplitude
- Returns:
calculates the incident E field, cinc, and the pol fro the initial condition vectors