The method you're looking for is "set_boundary":
void fields::set_boundary(boundary_side b, direction d,boundary_condition){
if (boundaries[b][d] != cond) {
boundaries[b][d] = cond;
chunk_connections_valid = false;
}
}
You can invoke it like this:
f.set_boundary(High, X, Metallic);
Side can be High or Low,
Direction X,Y,Z,R, or P,
Boundary condition Periodic, Metallic, or Magnetic
The most efficient way to define a waveguide is with metallic boundary
conditions, which let you trim the computation domain down to a minimum.
Cheers,
Matt
On Sat, 9 Feb 2008, Mani Chandra wrote:
> Hi How does one set metal as the boundary condition of the waveguide
> in the C++ interface. I mean what argument does structure take for
> metals and also how does one set the dimensions of the boundary layer.
> Can one set the boundaries of the waveguide as metal and avoid having
> to even specify the boundaries of the computational cell? (cause
> metals will not allow electric fields to pass anyway)
>
> Thanking you,
> Mani chandra
>
_______________________________________________
meep-discuss mailing list
[email protected]
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss