HomerReid / scuff-em

A comprehensive and full-featured computational physics suite for boundary-element analysis of electromagnetic scattering, fluctuation-induced phenomena (Casimir forces and radiative heat transfer), nanophotonics, RF device engineering, electrostatics, and more. Includes a core library with C++ and python APIs as well as many command-line applications.
http://www.homerreid.com/scuff-em
GNU General Public License v2.0
125 stars 50 forks source link

SiliconBeams example in wiki #95

Closed cyhng closed 7 years ago

cyhng commented 8 years ago

We run your 1D periodic SiliconBeams from wiki page. We have a question about that.

Here is the result in wiki page. problem3b

Here is the result we got. problem3

Two results agree but when separation goes beyond 4.5 micron, the force rises strangely. Do you think this a numerical error or not.

Thanks in advance

HomerReid commented 8 years ago

Yes, this looks like a numerical artifact, which may be due to a couple of different sources. How does it vary with (a) mesh resolution, (b) unit-cell length, (c) the value of the --RelTol command-line argument?

I actually think the most likely culprit here is insufficient accuracy in the Xi (imaginary frequency) integration. You can increase this with the --RelTol command-line argument, which sets the relative tolerance for this integration. (The default is --RelTol 1.0e-2; you might try --RelTol 1.0e-3.) It would be useful to look at the Xi integrand (as reported in the .byXi output file) to see what the curves for different separation distances look like as functions of Xi; probably what is happening is that the integrand is being undersampled for d=5 um.

Another possibility is insufficient accuracy in the Brillouin-zone (BZ) integration. Try --BZIRelTol 1.0e-3, or try looking the curves of BZ integrand vs. (Xi, kx) as reported in the .byXikBloch file.