You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Based on the current setup of the DiffractedPlanewave and EigenModeSource objects, it is not possible to launch planewave sources (by passing a DiffractedPlanewave object as the eig_band property of an EigenModeSource) with a negative propagation constant $\beta$ (the wavevector component in the direction perpendicular to the source plane).
$\beta$ is always chosen to be positive on line 660 of fields::get_eigenmode:
double nn = sqrt(real(get_eps(cen, frequency)) * real(get_mu(cen, frequency)));
double k2 = frequency * frequency * nn * nn - k2sum;
if (k2 < 0) {
master_printf("WARNING: diffraction order for g=(%d,%d,%d) is "
"evanescent!\n",
dp->get_g()[0], dp->get_g()[1], dp->get_g()[2]);
returnNULL;
}
elseif (k2 > 0)
k[dd - X] = sqrt(k2);
}
This missing property of DiffractedPlanewave sources is necessary for the adjoint solver (#2054).
(Note: for mode decomposition, obtaining the mode coefficient for the $-\beta$ mode is simply a matter of choosing the second of two elements of the third dimension of the alpha array returned by get_eigenmode_coefficient.)
The text was updated successfully, but these errors were encountered:
Based on the current setup of the$\beta$ (the wavevector component in the direction perpendicular to the source plane).
DiffractedPlanewave
andEigenModeSource
objects, it is not possible to launch planewave sources (by passing aDiffractedPlanewave
object as theeig_band
property of anEigenModeSource
) with a negative propagation constantfields::get_eigenmode
:meep/src/mpb.cpp
Lines 649 to 661 in b065eae
This missing property of
DiffractedPlanewave
sources is necessary for the adjoint solver (#2054).(Note: for mode decomposition, obtaining the mode coefficient for the$-\beta$ mode is simply a matter of choosing the second of two elements of the third dimension of the
alpha
array returned byget_eigenmode_coefficient
.)The text was updated successfully, but these errors were encountered: