Lecture 19 (CEM) -- Formulation of Rigorous Coupled-Wave Analysis

This lecture steps the student through the formulation of rigorous coupled-wave analysis. It parallels the lecture on the transfer matrix method and adopts the same formalism for scattering matrices. A bonus section discusses the enhanced transmittance matrix approach.
Prerequisite Lectures: 2, 3, 6, 7, 17, and 18

Пікірлер: 149

  • @mythofyht
    @mythofyht8 жыл бұрын

    I'm a graduate student working on micro/nano-scale optics and radiative transfer. The online course by UTEP is the best step-by-step learning materials I have ever found and helped me greatly in FDTD and RCWA coding. Thanks sincerely!

  • @empossible1577

    @empossible1577

    8 жыл бұрын

    +Haitong Yu Thank you for the compliment!

  • @mahmoudelzouka5689

    @mahmoudelzouka5689

    8 жыл бұрын

    +CEM Lectures same here! I work on near-field thermal radiation, and those lectures are extremely helpful.

  • @wolfwolf7121
    @wolfwolf71215 жыл бұрын

    Hi, thank you for your lectures! If we take the minus from the P matrix (or Q matrix) and then derive to the matrix wave equation we will get (d2/dz2)*E+omega^2=0 . The solution then becomes C1*exp(i*lamda*z)+c2*exp(-i*lamda*z). Can the problem of the growing exponentials be solved this way?

  • @empossible1577

    @empossible1577

    3 жыл бұрын

    This is very close to just using the positive sign convention instead of the negative sign convention. Both work, just stay consistent.

  • @atsul.7943
    @atsul.79435 жыл бұрын

    Hi Ray, would it be possible to provide some bench mark for the visualization of the field as well. I followed your TMM Extras to achieve this but it appears there is quite a lot that is probably going wrong with what I am doing. What I observe in my code is that, when I increase the spatial harmonics, the field values become unstable. I have sent you an email. As always, much gratitude for your unique effort.

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    I am slowly working on this. Right now, I have just finished revising the notes on how to modify our scattering matrix technique to visualize the fields for the transfer matrix method. The algorithm is essentially the same for RCWA. You can get to those notes here: emlab.utep.edu/ee5390cem.htm See Lecture 6 TMM Extras

  • @HCho-xe1cj
    @HCho-xe1cj3 жыл бұрын

    Hi, professor! I have a question about 3D RCWA. What if one of the layers consists of highly anisotropic material in z-direction? As far as I can understand, I think I just have to build new convolution matrix for \epsilon_r of the layer. Do you think it's correct? Did I miss something? Thank you for your reading!

  • @empossible1577

    @empossible1577

    3 жыл бұрын

    Uhg. Somehow I missed your question. I try to answer everything within 24 hours. Very sorry! If the anisotropy aligns with the xyz axes, there is little modification of the code. The only thing that happens is that you have ERxx, ERyy and ERzz convolution matrices instead of the single ER convolution matrix. On slide 18 of RCWA formulation, your equations would look something like... -j*Ky*uz - d/dz*uy = [ERxx]*sx d/dz*ux + j*Kx*uz = [ERyy]*sy Kx*uz - Ky*uy = [ERzz]*sz The only difference in these equations is the convolution matrices. Proceed with the formulation to arrive at new expressions for the P and Q matrices. After that, nothing else changes. If the anisotropy is not aligned with the xyz axes, the problem becomes more difficult. I cover this a bit in the transfer matrix method, but I don't think is your case. I should include a slide about this, but I do not have anything.

  • @HCho-xe1cj

    @HCho-xe1cj

    3 жыл бұрын

    Thank you so much :D

  • @wolfwolf7121
    @wolfwolf71214 жыл бұрын

    Hi, Dr. Rumpf thank you a lot for your lectures! I wrote my RCWA code with help of your lectures and it works very well. But I have a question. Is it possible to analyze waveguides or resonators with this method?

  • @empossible1577

    @empossible1577

    4 жыл бұрын

    Yes! I don't really have any notes on doing this, but you can look at Lecture 2d on using TMM to calculate slab waveguide modes here: empossible.net/academics/emp5337/ The very short story is that you will guess at the value for the propagation constant, solve for the global scattering matrix, and then iterate the propagation constant until the determinant of the global scattering matrix is zero. It is sort of a weird way to identify modes on a waveguide. It may be easier for you to just use a different method entirely, like PWEM or the finite-difference method. These can identify the modes directly.

  • @wolfwolf7121

    @wolfwolf7121

    4 жыл бұрын

    @@empossible1577 Thank you for your answer. I also use the PWEM that I also wrote with help of your lectures. I need to analyze a rectangular resonator (closed metallic waveguide, it is a 3D problem) with metallic strips within it and I thought it will be better to use RCWA to avoid problems with big matrices using FDM. And it is not so comfortable to built this problematic geometry to use PWEM. That is why I decided to use RCWA.

  • @soroushmehravar3598
    @soroushmehravar35987 жыл бұрын

    Thanks for the great lectures. I was wondering if there is any reason to have similar initial values (c+ and c-) in 21:40 for magnetic fields compared to electric fields?

  • @empossible1577

    @empossible1577

    7 жыл бұрын

    The magnetic field was normalized to be as equal to the electric field as possible. In air, they will be the same. In another medium, they will be slightly different.

  • @soroushmehravar3598

    @soroushmehravar3598

    7 жыл бұрын

    I see! Thanks

  • @soroushmehravar3598

    @soroushmehravar3598

    7 жыл бұрын

    In writing electric fields in Fourier space (8:17) why exp(-jk_z*z) is not in the expansion. Is it absorbed in S(m,n,z) or will be considered when solving ODE later? I assume that according to Bloch theorem we should write the E field as E(x,y,z) = A(x,y) exp(-jbeta.r) in which we can expand A(x,y) in Fourier series and it will result in E(x,y,z) = sum{sum[S(m,n,z) exp(-j(kxpq*x + kypq*y + kz*z)]}. Thanks!

  • @empossible1577

    @empossible1577

    7 жыл бұрын

    Yes, it is part of S(z) and U(z) at this step. Later, it arises after solving the differential equation.

  • @levionelevis5883
    @levionelevis58835 жыл бұрын

    Hello Prof Rumpf, By far, you are the best teacher in electromagnetics. Your materials are coherent and very well organized. I got this code running perfectly well against the benchmark thanks to you. However, I am trying to also implement the enhanced transmittance approach (ETM) by Moharam since it is faster than the scattering matrix approach but my results are just over the board. I am trying to trouble shoot what may be missing or what I may be overlooking. At 39.00 in the "s" column vectors, are the Px, Py and Pz the same regular (polarization vectors) Px, Py and Pz we used in the scattering matrix formulation? And please, do you have any hint for implementing the ETM for this problem? As always, thank you so much.

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    P is the same polarization vector. I have no other tricks or secrets. To help you, I have added a block diagram of my ETM code. that should help. It is the very last slide in Lecture 23. Hope this helps!!

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    Just in case you do not know, here is the link to the course website where you can get the electronic notes with the block diagram. emlab.utep.edu/ee5390cem.htm

  • @levionelevis5883

    @levionelevis5883

    5 жыл бұрын

    Okay. I'll suppose A B and s are properly constructed then. Could you kindly remark on the snippet of code for the ETM implementation I sent you. Would greatly appreciate that. Thanks a tonne.

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    @@levionelevis5883 I don't recall getting that code. Sorry if I missed it. Can you resend?

  • @julesbilluart9688
    @julesbilluart96885 жыл бұрын

    Dear Sir, How to plot the electromagnetic fields in real Space from the mode coefficients in the modal basis? By an inverse Fourier transform? Thanks

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    I have some notes on how to do this for the plane wave expansion method. See the notes for Lecture 20 here: emlab.utep.edu/ee5390cem.htm The material you are looking for is in the second section. You essentially reshape the mode coefficients into a 2D array, pad that array with lots of zeros, inverse FFT the padded array to get the fields in real-space, and then multiply those real-space fields by a phase term to account for angle of incidence.

  • @ManderSeis
    @ManderSeis Жыл бұрын

    Dear Professor, how could I best cite this work, and specifically the enhanced transmittance part? Your 2011 paper on scattering matrices does not cover ETM, and it seems that you addded quite a bit to the formulation from Moharam's original paper.

  • @empossible1577

    @empossible1577

    Жыл бұрын

    I don't think my ETM is different than Moharam's (great person BTW). At some point I switched to scattering matrices because I was simulating photonic crystals with hundreds of layers and was running out of memory with ETM. I was using a computer with only 512 Mb of RAM (poor grad student). I switched to scattering matrices, got much better computers, and never looked back. However, in my experience ETM is faster but that comes from implementing in MATLAB many versions ago. It is probably still faster, but I am less confident without trying it again. Anyway, just reference Moharam's paper for ETM. I have no publications on that technique. Thank you for asking!

  • @julesbilluart9688
    @julesbilluart96885 жыл бұрын

    Wow, I just finish to write my code , test it and compare it with a commercial modal method, giving the same results :D thank you so much for this well-explained lecture, everything is derived in a so simple way :D I would like to enhance my code with the Enhance Transmittance Matrix Approach, to get results faster, but one equation still remains unclear for me. On slide 51, how can I solve the matrix equation for r and t1 in Matlab? Because t1 is also expressed in B'... Don't you have a benchmark file on utep.edu that would help on that? Best, Jules

  • @versatile_gentlemen

    @versatile_gentlemen

    5 жыл бұрын

    Hi Jules, could you please guide me to implement RCWA into MATLAB?

  • @atsul.7943
    @atsul.79435 жыл бұрын

    Hi Dr. Ray. Thanks again for this great resources. I would say I am about 96% done with the implementation but there is a problem with the calculation of the eigen vectors/values of the looped layers. In my case, the eigenvectors of OMEGA_SQ matrix agreed with your values but the eigenvalues had some sign discrepancies. For example in column 12 row 12, your result was 0.0000 - 2.2778i and mine was 0.0000 + 2.2778i and vice versa throughout the eigenvalue matrix ( this behavior is random though, some of the diagonal elements have their signs matching well with yours). I am suspecting the sqrt function of matlab is causing this behavior. Any pointers from you would be greatly appreciated. Also, if I could see your intermediate LAM values ( LAM values before the matlab sqrt function). This could also be helpful. And ooooh, am referring to the 3 x 3 oblique incidence case.

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    The order of the eigen-vectors/eigen-values can change around, making it difficult to compare. There is a good chance that everything is correct with your code. One thing you can do is hard-code my numbers in your code to check intermediate results that come later.

  • @atsul.7943

    @atsul.7943

    5 жыл бұрын

    Thank you so much Dr. I just got my rcwa working so perfectly. All thanks to you.

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    @@atsul.7943 Great job!!

  • @ykh9313
    @ykh93135 жыл бұрын

    how can we calculate the Hy(x,z) from the RCWA method?

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    Do you want to plot the fields? This requires calculating the mode coefficients inside your device. I outline how to do this in the electronic notes for Lecture 6 here: emlab.utep.edu/ee5390cem.htm The lecture reads that is for TMM, but it applies equally well to RCWA.

  • @Liangyu-claude
    @Liangyu-claude2 жыл бұрын

    Hi Dr. Rumpf, thanks a lot for the video and all the courses available on EMpossible. I have a quick question about RCWA: if I want to speed up a 2D RCWA code for high index contrast design optimization, where should I start? Mode truncation? ETM?

  • @empossible1577

    @empossible1577

    2 жыл бұрын

    Truncation -- The modifications to the code are minimal so it is an easy tweak once you figure it out. Expect a 10% to 20% speed up. ETM -- This will force you to reformulate how you combine multiple layers. It requires that you store information from each layer, so if you have hundreds of layers you may run into a memory issue. Expect maybe a 5x to 10x speed improvement. I also use ETM instead of scattering matrices when I visualize internal fields. FFF -- You should also consider incorporating fast Fourier factorization. This helps with Gibb's phenomenon which is worst for high contrast devices. Depending on what your device looks like, there are other tricks to speed things up. A lazy code with repeated layers may analyze each layer independently. If you can reuse any scattering matrices, that will speed things up. If you are simulating slowly varying curved structures like a photonic crystal, you may be able to combine adjacent layers that are very similar. In this way, you can reduce the number of layers with excellent accuracy. You may also be able to parallelize your codes or employ GPU computing.

  • @Liangyu-claude

    @Liangyu-claude

    2 жыл бұрын

    @@empossible1577 I do have one question about ETM speed enhancement. In the scattering matrix approach, the most time-consuming step is to construct W and V from eig(P*Q), but in ETM, it is also necessary to construct the eigenmodes, which takes the same amount of time as the scattering matrix approach...

  • @empossible1577

    @empossible1577

    2 жыл бұрын

    @@Liangyu-claude All network approaches involve calculating the eigen-modes so we can ignore that. The equations used to calculate and combine scattering matrices are also a bottleneck. They are far more computationally intense than the equations used in ETM. The benefits of scattering matrices are memory efficiency, consistency with physical measurements, and the terms having physical meaning.

  • @Liangyu-claude

    @Liangyu-claude

    2 жыл бұрын

    @@empossible1577 I see what you mean. Like the Redheffer star product.

  • @empossible1577

    @empossible1577

    2 жыл бұрын

    @@Liangyu-claude Correct! That is a very expensive computation.

  • @wolfwolf7121
    @wolfwolf71212 жыл бұрын

    Hi, Dr Rumpf! If I understand it right the diffraction effiencies (Ref(p,q) or Trn(p,q)) has the same meaning like the UV-plane using in radioastronomy to restore the source form?

  • @empossible1577

    @empossible1577

    2 жыл бұрын

    Very sorry, but KZread is not giving me the "Read more" option to read your whole message. Can you try posting it again?

  • @wolfwolf7121

    @wolfwolf7121

    2 жыл бұрын

    ​@@empossible1577 Yes, sure. If I understand it right the diffraction effiencies (Ref(p,q) or Trn(p,q)) has the same meaning like the UV-plane using in radioastronomy to restore the source form?

  • @empossible1577

    @empossible1577

    2 жыл бұрын

    @@wolfwolf7121 Now the "Read more" thing is working for your original message. Crazy! If I understand your question, you are asking if you can recover the grating given the diffraction efficiencies? In my experience, not exactly. Electromagnetics is not scalar so a direct translation from diffraction efficiencies to the grating is not entirely possible. Also, there are multiple gratings that will give very close diffraction efficiencies. I have designed gratings starting with the phase using scalar techniques and the grating works surprisingly close, but is not controlling polarization. If I understand your question, you are describing an inverse problem. I have only solved those through optimizations, but there are other techniques.

  • @wolfwolf7121

    @wolfwolf7121

    2 жыл бұрын

    @@empossible1577 Thank you for your answer. Yes you understand right my question. Since the UV plane (that is calculated from radiotelescopes) and the diffraction efficiencies (from RCWA) means the same - dependece of power from spatial harmonics, I thought it will be possible to reconstruct the grating. I tried to IFFT the R(p,q) and T(p,q) for some gratings but it didnt worked. It is very interesting because the UV-plane and diffraction efficiencies is the same far field concept and I thought it should work

  • @user-gs2lp6zi1i
    @user-gs2lp6zi1i6 жыл бұрын

    Dear Dr. Rumpf, if we have a general incident fields defined on 2D(x,y) plane in real space, in principle we should be able to decompose it directly into RCWA's modal basis, right? However I cannot find any material or papers describing this(most of them are assuming center-mode excitation as in slides.40), could you give some advice?

  • @empossible1577

    @empossible1577

    6 жыл бұрын

    Happy to help! I have not ever done this so there may be some details I am missing. As I envision it, the process will be... 1. Create the cross section of your course in real-space in the x-y plane. 2. Fourier transform this source to get the Fourier coefficients. 3. Arrange the Fourier coefficients into a column vector called s_inc in the notes. 4. Last you will calculate the source mode coefficient, called c_inc in the notes as c_inc = inv(W_ref)*s_inc. It is likely that your W_ref will be identify matrix so Step 4 can be simplified. You can partly test the above by using a just a plane wave. Your c_inc should reduce to the c_inc the standard algorithm would use. Hope this helps!

  • @user-gs2lp6zi1i

    @user-gs2lp6zi1i

    6 жыл бұрын

    Wow, thanks for prompt answer! this's also more or less I'm considering, my only detailed concern is: if we have arranged the Fourier coefficients as a column vector, how can we match the size of this vector with the size of the scattering matrix? suppose the scattering object is a 2D grating where we only have modes in one direction.

  • @empossible1577

    @empossible1577

    6 жыл бұрын

    You should only retain the same Fourier coefficients that you retained when describing your materials. Which Fourier coefficients you retained must match.

  • @user-gs2lp6zi1i

    @user-gs2lp6zi1i

    6 жыл бұрын

    Thanks! I agree, I was expecting there's some kind of projection matrix that could project the Fourier coefficients onto the modal basis, perhaps I'm asking too much and this even seems to be a research topic....

  • @empossible1577

    @empossible1577

    6 жыл бұрын

    You can certainly come up with such a matrix. In fact, you can use different Fourier coefficients in each layer if you wish. You can just to do some math wizardry to match them. In my experience, it is not worth the trouble.

  • @jordanedmunds4460
    @jordanedmunds44604 жыл бұрын

    Why does the Kz matrix have the conjugate of the er and ur terms inside the square root in its definition and a conjugate outside the square root?

  • @empossible1577

    @empossible1577

    4 жыл бұрын

    For RCWA I chose to use the negative sign convention. This is done to stay consistent with that convention. Let me point you to the official course website where you can get the latest version of the electronic notes. They have seen a lot of corrections and revisions since the videos were recorded. I really need to rerecord them! empossible.net/academics/emp5337/

  • @RaviShivaraman
    @RaviShivaraman5 жыл бұрын

    Hi, thank you kindly for your lectures. I am trying to implement the RCWA for a 1D grating. However, I am using the full code (as opposed to the FFF approach mentioned in lecture 21). I am having trouble calculating the A & B Matrices (slide 37, lecture 19), since my V matrix in the layer (and also incidentally in free space) are turning out to be singular. Could you please provide a physical insight on why this might be happening in my case, and where I should look to resolve this? My W matrices seem quite fine.

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    At some frequencies, you could have wave vector components that equal zero and will cause singularities. Try changing the frequency slightly and see if that fixes it. If not, there is another problem with your code.

  • @RaviShivaraman

    @RaviShivaraman

    5 жыл бұрын

    @@empossible1577 Hello, changing the frequencies didn't seem to fix it. My apologies as this is my first introduction to performing such calculations. I would like to verify the size of my matrices to see if they are accurate. For the given scenario, Number of harmonics along Kx = M Number of harmonics along Ky = N after calculating Kx, Ky, and Kz, it has been suggested to put them in diagonal form. And since all the Kx_mn values reside on the diagonal, the size of the Kx & Ky matrices will be (M*N) x (M*N). In which case the size of the P and Q matrices (in free space) will be (2*M*N) x (2*M*N) Am I okay till this part? Because the size of the Omega2 matrix will be the same as the P & Q matrices and will result in 2*M*N eigenvalues. Are half of these for the backward propagating modes and half for the forward ones? Thank you once again kindly, the lectures are fabulous, but such one to one clarifications also help immensely, and I acknowledge the investment and am grateful for the same.

  • @RaviShivaraman

    @RaviShivaraman

    5 жыл бұрын

    @@empossible1577 I am implementing the Code in Python, so the eigenvectors of Omega2 matrix come out normalized using the "Numpy.linalg" package. Do the matrix of vectors V = Q*W*(lambda)^-1 need to be normalized before calculating the Matrices A & B?

  • @empossible1577

    @empossible1577

    5 жыл бұрын

    @@RaviShivaraman Have you seen the RCWA benchmarking documents on the course website? These show almost all of the intermediate results from my RCWA code. I suggest going through these to verify your data. This is even more useful since you are developing your code in a different language.

  • @RaviShivaraman

    @RaviShivaraman

    5 жыл бұрын

    @@empossible1577 Hi, thanks a lot for the pointer. I was able to use the bench-marking documents to guide me in my python implementation. There are some differences: 1. the 3x3 grid does not lead to energy conservation (slightly over 1), but a 5x5 grid does. I have also implemented RCWA calculations for the following geometry: Device Stack: ------------------------------------------------------------------ ------------------------------------- Semi-infinite Reflection Zone (Air) ------------------------------------------------------------------ ------------------------------------- Diffraction Grating on Surface (~200 nm tall & 600 nm Period) ------------------------------------------------------------------ ------------------------------------- Uniform Dielectric Layer (~1 mm) ------------------------------------------------------------------ ------------------------------------- Semi-infinite Transmission Zone (Air) ------------------------------------------------------------------ ------------------------------------- The issue with the above stack is that I am unable to get sensible results, I believe the issue arising from the X matrix: exp(-lambda_dielectric * k0 * t_dielectric) due to a large difference in the thickness of the uniform dielectric region compared to the grating region (> Million). I found that as long as the uniform dielectric thickness remains under a maximum value (per my results, a factor of 1000, so about a 20--50 microns - seems to depend on the incident wavelength as well) the calculation produces sensible results. If there 's physics here that I should be aware of , and perhaps if the dielectric is larger than a particular thickness, consider it the semi infinite reflection region, please let me know. Thank you kindly once again for your time.

  • @nth2tell
    @nth2tell7 жыл бұрын

    I tried the solution in homogeneous layers for gold uniform layer on glass and it doesn't agree with neither the fresnel's transfer matrix formalism nor the solution from the eig function in matlab. There must be something different for lossy media because the lossless one works fine.

  • @nth2tell

    @nth2tell

    7 жыл бұрын

    PS. the position that doesn't match well is around plasmon dip.

  • @empossible1577

    @empossible1577

    7 жыл бұрын

    it is hard for me to say what is wrong. The method itself is rigorous so there is nothing fundamental about it that would make it incapable of performing such a simulation. In these notes, the TMM was formulated using the +jkz sign convention while RCWA was formulated using the -jkz convention. This will require you to conjugate your material properties between methods. In other words, you perhaps have incorporated your metal with gain instead of loss. If this is not it, I suggest working your RCWA code through the benchmarking documents on the course website to try to find the error. Here is a link to the course website: emlab.utep.edu/ee5390cem.htm

  • @aaron.becker
    @aaron.becker Жыл бұрын

    Hello -- I'm beginning to use RCWA to model anisotropic gratings and am finding your videos and lecture materials incredibly useful in the process! I have a question I was wondering if you could shed some light on: In the RCWA literature for anisotropic gratings (Gaylord & Glytsis, Rokushima & Yamakita, for instance), it appears that each individual RCWA layer *doesn't* need to be homogeneous the in the z-direction ("slanted" gratings with arbitrary grating vectors are allowed). From watching this video, though, I get the impression the homogeneous z-direction is a limitation. Is there an easy explanation for why RCWA is able to handle those slanted gratings without a "staircase" approximation?

  • @empossible1577

    @empossible1577

    Жыл бұрын

    Can you point me to the paper(s) on the slanted gratings that do not require spatial transforms?

  • @aaron.becker

    @aaron.becker

    Жыл бұрын

    @@empossible1577 (I thought I replied to this earlier, maybe the links to the papers weren't OK to post?) The DOIs of two I've been working from are: 10.1364/JOSA.73.000901 & 10.1364/JOSAA.7.001399. I'm still wrapping my head around RCWA in general, but as I understand it, these papers have you perform Fourier expansions along the grating vector, which can be arbitrary / include a longitudinal component. This seems to violate the principle of the longitudinal direction being homogeneous... If you know of any more modern resources for the sorts of anisotropic RCWA discussed in those papers, I would love to know, too. Thanks again!

  • @empossible1577

    @empossible1577

    Жыл бұрын

    @@aaron.becker Thanks for pointing to these papers so that I can be confident what you are talking about. I should start by say that you can simulate slanted gratings with a staircase approximation using ordinary RCWA. I would not be too paranoid about using the absolute best and most efficient method. What you already have will work fine and will not require you to formulate and implement a new code. That said, this requires a new formulation and slightly different implementation to account for the slant. The key difference is that the since the direction of the grating vector is different, the directions of diffraction orders are different. For this reason, all of the components of the wave vectors are different. I think as long as you calculate these correctly and calculate the correct Fourier coefficients, the rest of the RCWA formulation should be the same. I have not implemented this type of RCWA so there may still be some issues I am not thinking about. If you do implement the method, you can use your ordinary RCWA to benchmark. I wish I could be of more help!

  • @aaron.becker

    @aaron.becker

    Жыл бұрын

    @@empossible1577 Thank you for the advice! If I can impose on your time for one last question-- I believe that for these fully-anisotropic formulations, you typically need to sort the eigenvalues and -modes after solving the characteristic matrix for each layer (otherwise, you won't properly match mode coefficients between layers). I've done this for the transfer matrix method before, but here, when there's an arbitrary number of eigenmodes instead of just 4, I don't know where to begin, and haven't found any procedures anywhere. Any advice on that front?

  • @empossible1577

    @empossible1577

    Жыл бұрын

    @@aaron.becker Yes, you will need to sort the modes. The best way to do this is the calculate the Poynting vector for each mode to identify if it is forward or backward propagating. You only need to z component of the Poynting vector so you only need the x and y components of E and H. Another way to do this is to look at the sign of the eigen-value. However, I think this could run into problems in more exotic media.

  • @dashingQ
    @dashingQАй бұрын

    Hi Prof. Your videos have been very helpful to me. I have a query. I am now trying to model a metallic (e.g. aluminum) grating on a multilayer dielectric film on a glass or silicon substrate using rigorous coupled wave analysis. Do you think it is feasible. Do I need to count the glass or silicon substrate as a layer or as a transmission region in the modeling process?

  • @empossible1577

    @empossible1577

    Ай бұрын

    This is absolutely possible, especially for ruled gratings. If you have a doubly-periodic grating it is still possible, but I find RCWA less efficient for metallic devices than real-space methods. You will definitely need to account for the substrate. Is your substrate very thick? If so, it is probably okay to just set your transmission region to the properties of your substrate. In this sense, your RCWA simulation would have only one layer. Let me point you to the official course website. I recommend using this as your main portal to the course materials. You can download the notes, get links to the videos, see the information organized, and get all the other learning resources on the course website. empossible.net/academics/emp5337/

  • @dashingQ

    @dashingQ

    Ай бұрын

    @@empossible1577 Okay, I got it. Thanks again from the bottom of my heart. In fact my device has more than one layer, underneath the grating are several layers of dielectric films with different dielectric constants. So when I use the rigorous coupled wave analysis method to deal with these layers of dielectric film, shouldn't I treat them as if they were homogeneous layers, i.e., when calculating the Q matrix, the relative permittivity and permeability are scalars, and W is the unit matrix. The calculated scattering matrix is then still updated to the global scattering matrix.

  • @empossible1577

    @empossible1577

    Ай бұрын

    @@dashingQ Yes. For homogeneous layers your convolution matrices are just diagonal matrices. Like you said, you can also just calculate the layer parameters directly. I will admit, for my layers I am lazy and don't include special code to handle the homogeneous layers with streamlined code. Good luck and have fun!

  • @dashingQ

    @dashingQ

    Ай бұрын

    @@empossible1577 You are so great, Professor, and you reply so promptly every time. Have a nice life too.

  • @PhysicsMathMan
    @PhysicsMathMan6 жыл бұрын

    Dear Dr. Rumpf,First and foremost, thank you for the lectures and benchmarking. I have my RCWA 99% working! I was wondering if you can help me with the last 1% as I am stumped. It all has to do with the function [V,D] = eig(OM_SQ) and what it returns for the layer calculations (this is not a problem for the transmission and reflection regions, as you don't use this function, and thus I match the benchmark). Basically all the eigenvectors/values are out of order and the imaginary parts sometimes have a sign discrepancy (other than that the values are the same and I confirmed Om_SQ*V - V*D = 0 ). This is confounding because my value of OM_SQ = P*Q matches your benchmark exactly so applying eig(OM_SQ) should work. 1. I feel as if as long as the order is kept consistent, the scattering matrices for the layer should be fine. But unsure of this statement as the S.11, S.12, S.21, and S.22 do not match the benchmark if the ordering isn't the same. 2. I would like to match your benchmark exactly (3x3 oblique RCWA). I can easily sort the eigenvalues/vectors in different ways, but the benchmark provided has seemingly no specific ordering for V and D; I assuming my MATLAB version is different than yours which outputs different orderings?TL;DR. eig() function outputs have no specific ordering -> values now differ from benchmark --> sorting the order makes sense but benchmark doesn't seem to sort in any specific way --> does this matter for S-matrix?Hope to hear back from you

  • @empossible1577

    @empossible1577

    6 жыл бұрын

    Yes, different versions of MATLAB or other very subtle things can change the order that the eigen-modes are calculated. While this makes it more difficult to benchmark, it is not a problem at all in terms of the correctness or robustness of your code. The only important thing is to keep your eigen-values in the same order as the eigen-modes if you choose to sort them for some reason. You do not want to mix up the pairing between the two. I am glad the lectures are helping you! You may also want to visit the official course website. The electronic notes have seen a lot of revisions and improvements since the lectures were recorded. emlab.utep.edu/ee5390cem.htm Hope this helps!!

  • @PhysicsMathMan

    @PhysicsMathMan

    6 жыл бұрын

    It certainly did! My RCWA code is now conserving power and giving the same S-Matrix values. Thanks for the help. Now to figure out how to retrieve metamaterial parameters, onward!

  • @empossible1577

    @empossible1577

    6 жыл бұрын

    What kind of metamaterial are you analyzing? Take a look at Lecture 15 in the 21st Century Electromagnetics course. This lecture covers parameter retrieval and homogenization. emlab.utep.edu/ee5390em21.htm

  • @PhysicsMathMan

    @PhysicsMathMan

    6 жыл бұрын

    I'd love to talk to you about it. Is there an email I can reach you at?

  • @empossible1577

    @empossible1577

    6 жыл бұрын

    Happy to help if I can. All of my contact information is at the following link under Dr. Raymond C. Rumpf: emlab.utep.edu/team.htm

  • @tommichalsen3847
    @tommichalsen38474 жыл бұрын

    It is unclear to me how you solve for r and t1. Anyone wants to elaborate or point to a resource that explains this more explicitly?

  • @empossible1577

    @empossible1577

    4 жыл бұрын

    First, here is a link to a official course website: empossible.net/academics/emp5337/ I think you are asking about the enhanced transmittance matrix approach? This course material has been moved to the last section in Lecture 7c. I have added a block diagram to help illustrate the method. See the electronic notes as I have not yet re-recorded the lectures from the revised notes. Overall, I recommend using scattering matrices instead of transmittance or transfer matrices. Unless you really need the speed, scattering matrices are much better to use. If you want to learn scattering matrices, I recommend working through the lectures on the transfer matrix method in this same course. RCWA is a generalized form of the transfer matrix method.

  • @randomguy7658
    @randomguy7658 Жыл бұрын

    Dear professor, may I ask you if rcwa is suitable for modeling the reflectivity spectrum of silicon hole array with plane wave that has 280nm-800nm range?

  • @empossible1577

    @empossible1577

    Жыл бұрын

    Assuming the hole array has a spacing somewhere close to one wavelength, I think RCWA is ideally suited for this. That said, do not be paranoid about using other numerical techniques that can also give you the answer, but may also offer you other benefits. RCWA is incredibly fast, but visualizing the fields, incorporating high contrast and metals, as well as when problem size grows are the drawbacks of RCWA. I think the best first numerical methods to learn are finite-difference frequency-domain (FDFD) and finite-difference time-domain (FDTD). They can do the same things as RCWA although slower, but they are easier to learn, easier to implement, and can do more than RCWA. I recommend accessing the course through the website. You can download the notes, get links to the latest versions of the notes and videos, and get links to other learning resources. Here is the website: empossible.net/emp5337/ This same course above has FDFD and FDTD.

  • @randomguy7658

    @randomguy7658

    Жыл бұрын

    Thank you very much professor, but as you mentioned in the video, “rcwa is suitable for low to moderate index contrast”,considering the fact that silicon has big contrast both n and k in low wave length range, is it still suitable? Also, I don’t really understand why it is only ideal for low to moderate index contrast? Sincerely, John

  • @randomguy7658

    @randomguy7658

    Жыл бұрын

    Dear professor, I tried rcwa method and fdtd method to simulate the reflectance of plane wave source from 280-800nm, I found out that rcwa gives me very incorrect results in the range of 280-400nm compared with experimental data, however fdtd gives a very good match but is too slow. Is the incorrect results associated with the fact that refractive index are high and change significantly in low wavelength area? Thanks a lot, John

  • @empossible1577

    @empossible1577

    Жыл бұрын

    @@randomguy7658 I think silicon is moderate index contrast. To give you an idea, I have worked with some devices with refractive index approaching 7.0. RCWA discretizes the field by expanding it into a plane wave basis. That means even the materials are represented as a sum of plane waves, although they are more accurately called planar gratings when describing materials. This has a hard time with step discontinuities and the higher the contrast the more a plane wave basis struggles with this. RCWA is still fully capable of analyzing even high refractive index materials. It is just that it may take many spatial harmonics in the expansion to obtain an converged and accurate result.

  • @empossible1577

    @empossible1577

    Жыл бұрын

    @@randomguy7658 Wow. How did you get these implemented so quickly? In general, any method can be made to simulate anything. It is not that RCWA is incapable of analyzing devices with high refractive index contrast. It is just that it do it very slowly and inefficiently compared to other methods. For silicon, you should be fine. I most suspect a convergence issue. Almost all numerical methods have something to adjust to get more accurate results but at the cost of speed and efficiency. In RCWA, this is the number of spatial harmonics. In FDTD, it is the grid resolution and some other things. In a convergence study, you will observe the trend of how your final answer varies as you increase the resolution (or number of spatial harmonics). While the answer may jump around a bit, there will be an overall asymptotic behavior where the answer is converging to some final result if you could run a simulation with infinite resolution. It is up to you to decide where along that curve to obtain your final answer. It is most important that you understand where you are on that convergence curve so you know if you are getting garbage results or not. Never conclude anything about a simulation until convergence. If it is not a convergence issue, you must have some mistake in your code. RCWA should be well suited for simulating silicon devices. I have done it many times.

  • @wolfwolf7121
    @wolfwolf71213 жыл бұрын

    Good day, Dr. Rumpf thank you a lot for your lectures! I wrote my RCWA code with help of your lectures and it works very well. I try to calculate the fields inside my device but I got a problem with continuity. I followed the TMM extra lecture. I fill all my layers with air so I got 100% transmission. I consider the sign convention from the RCWA lectures. The mode coefficients for backward waves (c-) equal 0. I consider only 1 spatial harmonic for testing my code. I really dont understand what can be wrong. The amplitudes of the fields looks reasonably. I will appreciate if you can give me some advice.

  • @empossible1577

    @empossible1577

    3 жыл бұрын

    That is odd. I probably need to create some notes on doing this for RCWA. I am sorry I do not have that yet. Sometimes it is easy to get the spatial harmonics backwards from how they are ordered in the FFT. Try doing things like reversing the order of the K vectors.

  • @wolfwolf7121

    @wolfwolf7121

    3 жыл бұрын

    @@empossible1577 Did you mean to reverse the Kx and Ky vectors? For testing the code I implement the RCWA with P=Q=1 so it works like regular TMM and my Kx and Ky equal 0.

  • @empossible1577

    @empossible1577

    3 жыл бұрын

    @@wolfwolf7121 Yes, I meant once you calculate them, reverse their order in the array relative to the indices of the spatial harmonics. This is just something to try. The codes as I present them are correct, but something like this is easy to mix up once you start messing with the data.

  • @wolfwolf7121

    @wolfwolf7121

    3 жыл бұрын

    ​@@empossible1577 If I understand it right, the matrix B=[Wg Wg; -Vg Vg] is eigen vectors matrix in free space? Or maybe there is somting additional to do with matrix B? In case of P=Q=1 I dont really have what to reverse because Kx=0 and Ky=0 and they are not arrays, but it must work anyway.

  • @empossible1577

    @empossible1577

    3 жыл бұрын

    @@wolfwolf7121 The B you specify I think are the eigen-vectors for the gap medium. I think I am using vacuum here, but you can make it whatever you wish. BTW, did I already point you to the course website? It has the latest version of the notes, links to latest videos, and other resources to help you get codes working. empossible.net/academics/emp5337/

  • @mansoorsultan5796
    @mansoorsultan579610 жыл бұрын

    Thanx Dr. could you post an matlab code example for RCWA calculation

  • @empossible1577

    @empossible1577

    10 жыл бұрын

    Listen to the next couple of lectures and see where you are. The block diagrams are extremely close to codes. As a general rule, I do not give out the codes. I think it shuts down the learning and puts people in a code "hacking" mentality instead of a code writing mentality.

  • @empossible1577

    @empossible1577

    10 жыл бұрын

    Another thing you could do it use the Benchmarking documents that I provide here: emlab.utep.edu/ee5390cem.htm They essentially take your step-by-step through RCWA and provide the intermediate results at each step. This is great for verifying your code and the flow of your algorithm. Hope this helps!

  • @mansoorsultan5796

    @mansoorsultan5796

    10 жыл бұрын

    what I am doing is to use dispersion data file for each layer and I want to do 6 layer structure.

  • @empossible1577

    @empossible1577

    10 жыл бұрын

    What is in your dispersion data file? Is this measured values of n and k? If so, you will setup a loop over frequency. Inside the loop you will look up the material properties for that frequency from your file, build your device using those material properties, model it, and then store the results. The loop iterates through all frequencies this way. If this isn't what you mean, please tell me what is in your dispersion data file.

  • @mansoorsultan5796

    @mansoorsultan5796

    10 жыл бұрын

    The dispersion file has the wavelength n and k and the structure that I want to build is uniform in one direction only

  • @huangshp8820
    @huangshp88202 жыл бұрын

    Hi, professor! Thanks for lecture! I have followed the procedure in this RCWA lecture and I write my code of the scattering matrix successfully. But I have trouble in writing the code of enhanced transmittance matrix(ETM). 1. Could you tell me how to update the B in the 'Work Backward Through All Layers' of the block diagram? 2. When I test my code, the reflectance remain 1 while the transmittance remain 0. Could I send my code to your email and ask for your advice? 3. In slide 71 of the lecture 7(c) note, I found t1 is on the right hand side of the expression of B'. Is it a typo? I appreciate your help. Thanks sincerely!

  • @empossible1577

    @empossible1577

    2 жыл бұрын

    Sorry that is not so clear in the notes. You might be the first to implement the ETM method from my notes! B = F * [II;X*b/a*X]; Here II is the identity matrix.

  • @huangshp8820

    @huangshp8820

    2 жыл бұрын

    @@empossible1577 Thanks for your reply, professor! Now my code of the ETM can work and I can get the same result as the scattering matrix. But I still have confuse in the calculating process. I calculate the matrix A in light of silde 66 but I can't get the right result. So I try to put the minus sign of the third row of matrix A to the fourth row and my code runs successfully. I think I calculate the right result by luck. Do I make a mistake? I should learn more about the construction of the matrix A. Thanks sincerely!

  • @empossible1577

    @empossible1577

    2 жыл бұрын

    @@huangshp8820 This may be because of how you handled the negative sign on teh KzI term. This is the z component of the wave vector in the reflection region. To be strictly correct, it should be negative. Many times I will keep it positive since the negative sign will just need to be removed later anyway. Check into this.

  • @huangshp8820

    @huangshp8820

    2 жыл бұрын

    @@empossible1577 OK, Thanks sincerely for your advice, professor!

  • @huangshp8820

    @huangshp8820

    2 жыл бұрын

    ​@@empossible1577 Hi, professor! Could you give me some advice on how to image the electric field profiles in the x-z and x-y plane? Thanks sincerely as always!