Open jphaupt opened 4 years ago
Luckily, all of the storage for that extra numerator term seems to be already built into the lorentzian_susceptibility
class and its corresponding data structure. It's just not used:
https://github.com/NanoComp/meep/blob/df5552d9e1021012ab938b3bfdbf1cbe270f1204/src/susceptibility.cpp#L196
So you would "just" have to modify the update equation to include this term:
Plus you would have to modify the interface (swig and python) to include the changes.
(void)W_prev; // unused;
This is actually NULL
(because it is not stored) unless you override the susceptibility::needs_W_prev()
method to return true
(which is easy, of course). This is the electric (or magnetic) field from the previous timestep, which we don't want to store unless we actually need it.
Thanks a lot !
------------------ 原始邮件 ------------------ 发件人: "NanoComp/meep" <notifications@github.com>; 发送时间: 2020年8月13日(星期四) 凌晨1:04 收件人: "NanoComp/meep"<meep@noreply.github.com>; 抄送: "hae"<hauehaue@qq.com>;"Comment"<comment@noreply.github.com>; 主题: Re: [NanoComp/meep] Modified Lorentz Material Dispersion (#1201)
(void)W_prev; // unused;
This is actually NULL (because it is not stored) unless you override the susceptibility::needs_W_prev() method to return true (which is easy, of course). This is the electric (or magnetic) field from the previous timestep, which we don't want to store unless we actually need it.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
Hi all,
While I am aware that Meep has the functionality to model dielectric dispersion quite neatly using a Lorentzian susceptibility profile, it would be useful (certainly for my own research) if I could instead use the "modified Lorentz model," which is similar, as described in this paper (equation 3): https://www.osapublishing.org/ol/abstract.cfm?uri=ol-37-1-112
I imagine this may be reasonably easy to implement, as it seems to amount to just adding one extra parameter to the LorentzianSusceptibility function.
Cheers, jph