Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc example for oblique flux #399

Closed
stevengj opened this issue Jun 29, 2018 · 3 comments
Closed

doc example for oblique flux #399

stevengj opened this issue Jun 29, 2018 · 3 comments
Assignees

Comments

@stevengj
Copy link
Collaborator

Some users are confused by the fact that our flux planes must be aligned with x/y/z. Because of energy conservation, however, you don't need a different orientation even for waveguides that are at an oblique angle.

It might be nice to have a tutorial example illustrating this.

I was thinking of an example that looked at transmission around a gradual bend, i.e. a straight waveguide into a circular bend of radius R, coming out at a 45-degree angle. As the radius R increases, the transmission should go exponentially to 100% (in the limit of infinite resolution, of course).

So, you could have a 2d example:

  1. a straight-waveguide simulation (along the x direction) to get the incident power (for normalization) alo

  2. a bent-waveguide simulation to get the transmitted power into the waveguide exiting at a 45-degree angle, but using a Cartesian flux plane (e.g. perpendicular to x). even though you compute the flux "at an angle" the power should divided by the incident power from (1) as R increases.

(Of course, PML doesn't quite work for a waveguide exiting at a 45-degree angle either, but we can cite our paper here, and simply use a thick enough pPML.)

@oskooi
Copy link
Collaborator

oskooi commented Aug 16, 2018

A simpler example which does not involve a circular bend would be the following: a 1d computational cell of homogeneous index n with a source planewave at angle θ near one end of the cell and a flux monitor near the other (i.e., separated by several wavelengths); demonstrate that the total flux is a constant independent of θ. A schematic is shown below. f is the frequency of the source/monitor.

pwave_1d

We can also demonstrate this in 2d although terminating the simulation for a Gaussian source at large oblique angles via the stop_when_fields_decayed routine becomes challenging since a large fraction of the field propagates perpendicular to the PML and therefore remains unabsorbed.

@stevengj
Copy link
Collaborator Author

@oskooi, that example is a little tricky because you effectively have an infinite (planewave) source, and your flux monitor is effectively not computing total power but rather power per unit length.

I suggested the bend example because (a) it is total power and (b) it is clear that (for negligible bending loss) the straight and oblique waveguide sections should carry the same power.

@niloufar60
Copy link

niloufar60 commented Jun 17, 2022

Hi,
My FluxRegion is rotated with respect to the cartesian coordinates (coordinates of the device). I can build the geometry of that region using Block by determining e1, e2 and e3 but FluxRegion does not have this option. I was wondering how I can calculate the flux in a rotated (with respect to the cartesian coordinates) 2d plane? My device is a rectangle, while I want to calculate the flux only in a region along the diameter of the rectangle. I am not sure how I can do this. I would appreciate your comment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants