Closed flaport closed 2 years ago
Can you update the docs as well?
done!
Yes, if the caller provides mepsilon
, they are responsible for disabling (or not) subpixel smoothing themselves.
(meep_mpb_eps
doesn't do any of its own subpixel averaging, it just samples the pre-existing Meep ε, which may already have some smoothing)
Currently it was not possible to disable subpixel smoothing in mpb (closes NanoComp/meep#2167).
This PR fixes this.
Here is a plot that shows the convergence of the mode calculation of a simple circular cross section before and after introducing the fix. You can clearly see that convergence is now slower for mesh_size=1, which is actually the behavior you'd want.
Moreover, looking at an image of the crossection at resolution 16 clearly shows that subpixel smoothing is now disabled:
before:
after: