On Mon, 14 May 2007, Nicolas Tetreault wrote:
> just to be sure, my system is made of 3 objects, the first is the
> background material, no polarization.  The second and third are made of
> the same material with polarization parameters. the second is just a
> cube while the third is a function, described before.  As you say, I
> need one fixed object with the polarization parameters.  That would be
> the second object.  But how will meep know that the third object,
> defined by the dielectric function, is the same?  Should I make a fourth
> object, hidden behind the third and with no size?  I have attached a
> very, very crude figure showing by cell.

Meep will know that the third object is the same because it returns that 
polarization material.  No worries.

What is happening here is that things like polarizations (dispersive 
media) in Meep aren't enabled point-by-point.  It assumes that you are 
going to use the same omega, gamma, etcetera over whole regions and 
optimizes for that case.  (So, for example, it does not need to store 
gamma for each grid point individually.)  This is almost always true, 
because one's materials are usually piecewise constant.

However, that means that Meep has to initialize some data structures for 
the dispersive materials *before* evaluating the material at every grid 
point.  Since it doesn't know what your material-function will return 
before calling it at every grid point, Meep cannot initialize dispersive 
materials that are *only* returned from a material-function.  Instead, 
Meep just goes through the list of objects with fixed materials and 
initializes those dispersive materials it finds.

Therefore, it is sufficient to provide a single "hidden" object, anywhere, 
for each dispersive material you intend to use.  Meep will then initialize 
that material properly, and *then* it will evaluate the materials at every 
grid point by calling material-functions etcetera to figure out what 
things go where.

Cordially,
Steven G. Johnson

_______________________________________________
meep-discuss mailing list
[email protected]
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss

Reply via email to