Hi,
I am simulating a pulse propagating through a dielectric cone array.
Although in meep manual it's said that the default value for radius2 is 0,
in my simulation I found if this value was 0, then there existed an epsilon
singularity in the simulation which led to divergence finally. So in order
to have a correct simulation result, the radius2 must be assigned a number,
even if it's very small, i.e., 0.01. Does anyone have similar problems? Is
this a bug?
My script is attached here:
(use-output-directory)
(set! progress-interval 30)
(define-param eps-Si 11.56)
(define-param h 1); thickness of slab
(define-param h1 1); the height of the cone
(define-param r 0.34) ; radius of base
(define-param structure? false) ; determine the structure, false for air,
true for cone
; The cell dimensions
(define-param pad 2) ; the length between the cones and the pml
(define-param dpml 1) ; PML thickness
(set-param! resolution 20)
(define sx 1) ; size of cell in x direction
(define sy 1) ; size of cell in y direction
(define sz (+ (* 2 (+ pad dpml) ) h h1 h1)) ; size of cell
in z direction
(set! geometry-lattice (make lattice (size sx sy sz)))
(set! geometry
(if structure?
(list (make block (center 0 0 0) (size sx sy h) (material (make
dielectric (epsilon eps-Si))))
(make cone (center 0 0 (/ (+ h h1) -2)) (radius r) (radius2
0.1) (height h1) (axis 0 0 -1) (material (make dielectric (epsilon
eps-Si))))
)
(list (make block (center 0 0 0) (size sx sy h) (material (make
dielectric (epsilon eps-Si)))))
)
)
(set! pml-layers (list (make pml (direction Z) (thickness dpml)))) ;setting
periodic condiction in the z direction
(set! k-point (vector3 0 0 0))
(define-param fcen 0.5)
(define-param df 0.2)
(define-param nfreq 1000)
(set! sources
(list (make source (src (make gaussian-src (frequency fcen) (fwidth
df))) (component Ex) (center 0 0 (+ (* sz -0.5) dpml (* pad 0.5))) (size 1 1
0)))
)
(define trans
(add-flux fcen df nfreq
(make flux-region (center 0 0 (- (* sz 0.5) dpml (* pad
0.5))) (size 1 1 0))
)
)
(define refl
(add-flux fcen df nfreq
(make flux-region (center 0 0 (+ (* sz -0.5) dpml (/
pad 4) )) (size 1 1 0)))
)
(if structure? (load-minus-flux "refl-flux" refl))
(if (not structure?) (save-flux "refl-flux" refl))
(define (my-getpoint) (print "getfield: " (meep-time) " " (get-field-point
Ex (vector3 0 0 (- (* sz 0.5) dpml (* pad 0.5)))) " \n"))
(run-sources+ 1000
(at-beginning output-epsilon)
(at-every 0.05 my-getpoint)
)
(display-fluxes trans refl)
--
Regards,
Yimin
_______________________________________________
meep-discuss mailing list
[email protected]
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss