[Meep-discuss] (no subject)
Hi Meep users, I am relatively new to meep. Could anyone show me how to employ the perfect-electric-conductor/ perfect-magnetic-conductor/metal boundary condition in meep? I could not find an example in the meep-examples and everything I tried seems to have the wrong syntax. Thanks, Yonatan. ___ meep-discuss mailing list meep-discuss@ab-initio.mit.edu http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss
Re: [Meep-discuss] (no subject)
Hi, Have a look at this thread: http://www.mail-archive.com/meep-discuss@ab-initio.mit.edu/msg00412.html Best, Matt On Mon, 2 Feb 2009, Sivan, Yonatan wrote: Hi Meep users, I am relatively new to meep. Could anyone show me how to employ the perfect-electric-conductor/ perfect-magnetic-conductor/metal boundary condition in meep? I could not find an example in the meep-examples and everything I tried seems to have the wrong syntax. Thanks, Yonatan. ___ meep-discuss mailing list meep-discuss@ab-initio.mit.edu http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss ___ meep-discuss mailing list meep-discuss@ab-initio.mit.edu http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss
[Meep-discuss] Unknown source of error
Hi Nathan, Just remove the (set! n (sqrt eps))) and (set! n 1) sentences in the geometry definition. Regards. I am trying to get a model for a source that launches at oblique angles while embedded inside a medium. I have found the great code in the archives for launching at arbitrary angles, and stole it outright. I noticed though that when I embedded the source it launched at the 'wrong' angle. Examining hte code I figured that I needed to add the index of the material in the definition of the k vector. After making this modificaiton though, the code errors on me. The exact error message is ERROR: Wrong type (expecting pair): #unspecified Even for meep this an obscure error message. I have tried commenting out as much as I can but nothing seems to work. All of hte print statements in the code also execute. Any help would be appreciated. Thank you, Nathan ___ meep-discuss mailing list meep-discuss@ab-initio.mit.edu http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss
[Meep-discuss] Solution: meep 0.20.3 - error when there is an if in set! geometry (list ...
Dear All, Thank you to those who responded directly regarding this issue - it was my lack of understanding of Scheme that was my problem, not meep. One way to solve my problem of conditionally appending another geometry element to the geometry list that works (I am sure there are others) is: (define-param blk1-xcen 0) (define-param blk1-ycen 0) (define-param blk1-xsize 10) (define-param blk1-ysize 1) (define-param blk1-eps 12) (define-param blk2-xcen 0) (define-param blk2-ycen 2) (define-param blk2-xsize 10) (define-param blk2-ysize 1) (define-param blk2-eps 6) (set! geometry (list (make block (center blk1-xcen blk1-ycen) (size blk1-xsize blk1-ysize infinity) (material (make dielectric (epsilon blk1-eps)) (if blk2? (begin (display blk2 being made) (newline) (newline) (set! geometry (append geometry (list (make block (center blk2-xcen blk2-ycen) (size blk2-xsize blk2-ysize infinity) (material (make dielectric (epsilon blk2-eps) ___ meep-discuss mailing list meep-discuss@ab-initio.mit.edu http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss
[Meep-discuss] Command line arguments to change filename-prefix
Hello all, I am trying to write a ctl file that will allow me to change the filename prefix using a command line parameter. I want to do a series of simulations that compute the reflected flux from a variety of material systems, but all using the same reference run. My plan is to write the ctl file such that all of the material parameters are (define-param var value), then write a bash script that will run through all of the different cases by calling meep from the command line and piping the data out. I need two things to accomplish this that are giving me trouble. The first is, I would like the output files for each run to go to their own directory, so I need to either change filename-prefix or pass some string that can be evaluated in (use-output-directory). As of now, I can't get a string to be passed in via the command line. I have tried the following In the .ctl file (define-param output_dir ) (set! filename-prefix dir) On the command line meep output_dir=reference .. This returns an Unbound Variable: reference On the command line meep output_dir=reference This also returns an Unbound variable: reference I also tried in the .ctl (define-param output_dir (get-filename-prefix)) (set! filename-prefix dir) On the command line I repeated the above commands with the same results. Does anyone know how to do this? My second issue is I need to have each each instance of the simulation call the same reference file, and I want to store that reference file in the above mentioned reference directory. When I use the command (load-minus-flux refl-flux refl) can I use (load-minus-flux /reference/refl-flux refl) ? Right now I have a soft link pointing from the standard output directory to the reference directory, but I feel uncomfortable with this as it's still possible to overwrite the reference flux. I want to ensure that I can't overwrite it by accident. Thanks for you help, Nathan Huntoon ___ meep-discuss mailing list meep-discuss@ab-initio.mit.edu http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss