dmrt_shortrange.py 文件源码

python
阅读 23 收藏 0 点赞 0 评论 0

项目:smrt 作者: smrt-model 项目源码 文件源码
def basic_check(self):
        # TODO Ghi: check the microstructure model is compatible.
        # if we want to be strict, only IndependentShpere should be valid, but in pratice any
        # model of sphere with a radius can make it!
        if not hasattr(self.layer.microstructure, "radius"):
            raise SMRTError("Only microstructure_model which defined a `radius` can be used with Rayleigh scattering")

    # The phase function is inherited from Rayleigh  // Don't remove the commented code
    #    def phase(self, m, mhu):

    # The ke function is inherited from Rayleigh  // Don't remove the commented code
    # def ke(self, mhu):
    #    return np.full(2*len(mhu), self.ks+self.ka)

    # The effective_permittivity is inherited from Rayleigh  // Don't remove the commented code
    # def effective_permittivity(self):
    #    return self._effective_permittivity
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号