[Meep-discuss] Gaissian Distribution of Phase

2015-02-10 Thread Yousuf Khan
Dear Steven and meep users,
I already saw some examples of oblique source by introducing a phase shift in 
source function. Is it possible to construct a focused source by Gaussian 
distribution of phase ? If yes, can anybody give an example please. Regards,
Yousuf Khan___
meep-discuss mailing list
meep-discuss@ab-initio.mit.edu
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss

[Meep-discuss] h5topng with material as gold

2014-07-30 Thread Yousuf Khan
Hi dear meep users,

I am using the following (given below) material property for GOLD as define in 
notes on metals in meep. All goes well but I can see the field distribution in  
png file. It appers very dark. I have tried different color schemes in h5topng 
command but unable to fix it. Also looked up in discussion forum and didn't 
find anything working so far.
Can anyone suggest how to deal with this problem ?

(define myAg (make dielectric (epsilon 1)
 (polarizations
  (make polarizability
 (omega 1e-20) (gamma 0.038715) (sigma 4.4625e+41))
 (make polarizability
 (omega 0.65815) (gamma 3.1343) (sigma 7.9247))
 (make polarizability
 (omega 3.6142) (gamma 0.36456) (sigma 0.50133))
 (make polarizability
 (omega 6.6017) (gamma 0.052426) (sigma 0.013329))
 (make polarizability
 (omega 7.3259) (gamma 0.7388) (sigma 0.82655))
 (make polarizability
 (omega 16.365) (gamma 1.9511) (sigma 1.1133))
 )))

 
Regards,
Yousuf Khan___
meep-discuss mailing list
meep-discuss@ab-initio.mit.edu
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss

[Meep-discuss] Phase Plotting

2014-07-22 Thread Yousuf Khan


Dear meep users, I am calculating reflection phase of a plane wave source by 
tilting it. I am 
following the previous discussion about the reflection phase calculation 
mentioned below: 
https://www.mail-archive.com/meep-discuss@ab-initio.mit.edu/msg00849.html
But when I draw the normilized frequency (X-axis) v.s phase (Y-axis) in matlab, 
I dont get the phase scale. It varies from -200 to 600. Can anybody help how 
can I chage it to pi units, degrees or wavelength unit ? I am plotting using 
the following method suggested by Steven G. Johnson         N = length(R); 
Rangle = phase(fft(R - R0)); Rangle = Rangle(1:N/2); % 
frequencies above Nyquist are redundant freq = [0:length(Rangle)-1] / (N * dt); 
plot(freq, Rangle)
 
Regards,
Yousuf Khan___
meep-discuss mailing list
meep-discuss@ab-initio.mit.edu
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss

[Meep-discuss] Units while Plotting Reflection Phase

2014-07-15 Thread Yousuf Khan
Dear meep users,

I am calculating reflection phase of a plane wave source by tilting it. I am 
following the previous discussion about the reflection phase calculation 
mentioned below: 
https://www.mail-archive.com/meep-discuss@ab-initio.mit.edu/msg00849.html

But when I draw the normilized frequency (X-axis) v.s phase (Y-axis) in matlab, 
I dont get the phase scale. It varies from -200 to 600. Can anybody help how 
can I chage it to pi units, degrees or wavelength unit ?

I am plotting using the following method suggested by Steven G. Johnson

        N = length(R); Rangle = phase(fft(R - R0)); Rangle = Rangle(1:N/2); % 
frequencies above Nyquist are redundant freq = [0:length(Rangle)-1] / (N * dt); 
plot(freq, Rangle)
 
Regards,
Yousuf Khan
Institute of Nanostructure Technologies and Analytics (INA)
Technological Electronics - University of Kassel
___
meep-discuss mailing list
meep-discuss@ab-initio.mit.edu
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss

[Meep-discuss] Check for imagianray number

2013-12-18 Thread Yousuf Khan
Hi dear Steven and meep users,
I want to convert imaginary output to a real number or zero in meep.  For 
example checking in a loop 
if x is imaginary
    set it to zero

I tired if complex? x conditon but it is not working. Can anybody help or 
suggest how to write the code for it. 

Regards,

Yousuf Khan___
meep-discuss mailing list
meep-discuss@ab-initio.mit.edu
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss

[Meep-discuss] Numerical Erros while keeping the source inside the material

2013-08-01 Thread Yousuf Khan

Hello dear meep users,

I am simulating an optical fiber structure having a grating layer on its 
tip. A circular source is placed inside the core and transmissiom and 
reflection flux is measured above and below the grating layer on the tip of 
fiber. In this senario, transmission 
monitor layer is placed in the air just above the grating and reflection 
monitir layer is placed inside the core and cladding just below the 
grating layer. 

The refrective indices of the structures are core: 1.468, cladding: 1.4613, 
grating layer: 2.134. 

If i simulate just the grating suspended in the air, the transmission and 
reflection spectra are symmetric. While if i include core and cladding 
transmission spectrum remains the same but reflection sprectrum show strange 
graph. It 
ossicilates between -3 to 0.2 reflection values instead of staying in 
between 0 and 1. 

Can any body suggest what is the problem.  The ctl file is attached.



 
Regards,
Yousuf Khan


fibertip.ctl
Description: Binary data
___
meep-discuss mailing list
meep-discuss@ab-initio.mit.edu
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss

[Meep-discuss] Numerical Erros while keeping the source inside the material

2013-07-30 Thread Yousuf Khan
Hello dear meep users,


I am simulating an optical fiber structure having a grating layer on its tip. A 
circular source is placed inside the core and transmissiom and reflection flux 
is measured above and below the grating layer on the tip of fiber. In this 
senario, transmission monitor layer is placed in the air just above the grating 
and reflection monitir layer is placed inside the core and cladding just below 
the grating layer. 

The refrective indices of the structures are core: 1.468, cladding: 1.4613, 
grating layer: 2.134. 

If i simulate just the grating suspended in the air, the transmission and 
reflection spectra are symmetric. While if i include core and cladding 
transmission spectrum remains the same but reflection sprectrum show strange 
graph. It ossicilates between -3 to 0.2 reflection values instead of staying in 
between 0 and 1. 


Can any body suggest what is the problem. 

  __
  |_| PML

  |    |           air    |    |

  |---| -- |---| Trans monitor layer

  |==|== = =| = = |= = = |==| Grating layer

  |---|-|--|--- |---| Refl monitor layer

  |    |     |core|  |    |

  |    |  clad    |___ |      |    | Source

                  |__|__ |___ |_|__|
  |_|   PML
   


 
Regards,
Yousuf
 Khan___
meep-discuss mailing list
meep-discuss@ab-initio.mit.edu
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss