Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Problems with reflectivity spectrum calculations in MEEP

Status
Not open for further replies.

in_the_edn

Newbie level 1
Newbie level 1
Joined
Mar 27, 2013
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Visit site
Activity points
1,285
I am trying to calculate the reflectivity spectrum for a dielectric mirror, but i get unrealistic results. Mazbe someone can help me and tell me where the mistake is.
Code:
(reset-meep)

(define-param sx 50)                                                                ; size of cell in X direction
(define-param sy 50)                                                                ; size of cell in Y direction
(define-param N 15)                                                                 ; number of layers
(define-param xsiz 10)                                                              ; xsize of the layers 
(define-param ysiz 0.25)                                                            ; ysize of the layers
(define-param yq 4)
(define-param exist? true)                                                                 ; ysize of the quartz substrate 

(set! geometry-lattice (make lattice (size sx sy no-size)))
(set! geometry (if exist? 
      	 (append
      	  (list
	    (make block 
	      (center 0 -2)
	      (size xsiz yq)
	      (material (make dielectric (epsilon 3.5)))))
          (geometric-object-duplicates (vector3 0 0.5 0) 0 (- N 1)
	    (make block 
	      (center 0 (* 1.5 ysiz))
	      (size xsiz ysiz)
	      (material (make dielectric (epsilon 1.69)))))
	   (geometric-object-duplicates (vector3 0 0.5 0) 0 (- N 1)
	    (make block 
	      (center 0 (/ ysiz 2))
	      (size xsiz ysiz)
	      (material (make dielectric (epsilon 4.84))))))
	      (list)))
  
(define-param fcen 2.9167) ; pulse center frequency
(define-param df 4.1667)  ; pulse width in frequency
(set! sources (list
	       (make source 
		 (src (make gaussian-src (frequency fcen) (fwidth df)))
		 (component Ez)
                 (center 0 20)
		 (size xsiz 0))))

(set! pml-layers (list (make pml (thickness 1.0))))
(set-param! resolution 10)


(define-param nfreq 100) ; number of frequencies at which to compute flux
(define trans ; transmitted flux
	   (add-flux fcen df nfreq
		    (make flux-region
	      (center 0 -5) (size xsiz 0))))
(define refl; reflected flux
                    (add-flux fcen df nfreq
		    (make flux-region 
		      (center 0 12) (size xsiz 0))))


(if (not exist?) (load-minus-flux "refl-flux" refl))

(run-sources+ 500 
(at-beginning output-epsilon)
(to-appended "ez" (at-every 0.6 output-efield-z)))


(if exist? (save-flux "refl-flux" refl))

(display-fluxes trans refl)
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top