Re: [Meep-discuss] bragg structure with kerr effect ....

2015-06-16 Thread Mohammad alshikh
Filip Dominec filip.dominec@... writes: Hi, Alshikh, from what I understand, you shall introduce another callback function like your eps_bragg(const vec pt), which will return the value of the Kerr coefficient. It should be called in a similar manner as e.g. the susceptibilities are. I

[Meep-discuss] bragg structure with kerr effect ....

2015-06-15 Thread alshikh
Hello, I have a bragg structure like the one defined in the example  bragg_transmission.cpp double eps_bragg(const vec pt) {   double z = pt.z() - zsize * 0.5;   if (fabs(z)*2 Nperiods) return nlo*nlo;   else { double zi; double zf = modf(z, zi); if (zf 0) zf += 1; if (zf wlo)  

[Meep-discuss] bragg structure with kerr effect ....

2015-06-15 Thread Mohammad alshikh
Hello, I have a bragg structure like the one defined in the meep example bragg_transmission.cpp double eps_bragg(const vec pt) { double z = pt.z() - zsize * 0.5; if (fabs(z)*2 Nperiods) return nlo*nlo; else { double zi; double zf = modf(z, zi); if (zf 0)

Re: [Meep-discuss] bragg structure with kerr effect ....

2015-06-15 Thread Filip Dominec
Hi, Alshikh, from what I understand, you shall introduce another callback function like your eps_bragg(const vec pt), which will return the value of the Kerr coefficient. It should be called in a similar manner as e.g. the susceptibilities are. I always found it useful to test out the Kerr