On Jul 14, 2009, at 7:31 PM, Warner Miller wrote:
I have a 3-D rectangular geometry (xgeom ygeom zgeom) and at "the
end" of the simulation I would like to save the z-component of the
electric field in the (ygeom, zgeom) planes at various values of
xgeom. I do not want to store the entire data set as the file is too
large. I know how to do this at one particular value of xgeom, say
xgeom=12
(run-until 40 (at-end
(in-volume (volume (center 12 0 0) (size 0 ygeom zgeom)) output-
efield-z)
))
but how do I do this for say 20 slices between -xgeom/2 to xgeom/2?
Or do I just do something like?
(run-until 40 (at-end
(in-volume (volume (center 1 0 0) (size 0 ygeom zgeom)) output-
efield-z)
(in-volume (volume (center 2 0 0) (size 0 ygeom zgeom)) output-
efield-z)
.
.
.
(in-volume (volume (center 20 0 0) (size 0 ygeom zgeom)) output-
efield-z)
))
That will work, yes.
You could also automate it by, e.g.:
(run-until 40
(apply at-end
(map (lambda (x) (in-volume (volume (center x 0 0) (size 0 ygeom
zgeom)) output-efield-z))
(interpolate 20 (list (* -0.5 xgeom) (* 0.5
xgeom))))))
In addition, is there an easy way to take the 2-d spatial Fourier
transform of the Ez field at each of these slices.
Not inside the .ctl file; the easiest thing is to do any post-
processing in another program, e.g. Matlab.
Steven
_______________________________________________
meep-discuss mailing list
[email protected]
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss