astar=2*math.pi/3.95 cstar=2*math.pi/12.06556 eps=0.0011 Q=Numeric.array( [ [astar*0.5*i+eps,-astar*0.5*i+eps,0] for i in range(1,2)] ) debyerange=[ -12, -12, -6] debye=astar/4 SMcellrange=[2,2,2] cellrange= [-1,-1,-1] Kcellrange=[-6,-6,-12] sigmacellrange=[-4,-4,-2] sigmacharge=0.5 IS_IT_SCREENED=0 USE_SCREENING_FUNCTION =1 ScreenKrange = [6,6,12] selectors=[(1.0,1.0,0.0), (1.0,-1.0,0.0), (1.0,0.0,1.0), (-1.0,1.0,0.0)]
Note the range that is specified by the variable ScreenKrange.
The contribution from Coulomb interaction without screening function is still
active (note IS_IT_SCREENED=0) but gives zero contributions
as Kcellrange and sigmacellrange are set to zero.
one could still calculate both contribution if the inputted screening function
is
The screening function must be set in the parinputedit with the following format :
def SCREENING_FUNCTION(self, Q): moduli2 = Numeric.sum(Numeric.transpose(Q*Q)) astar=2*math.pi/3.95 debye=astar/4 debye=debye*debye # res=(1.0/(1.0+debye/moduli2) )-1 # debye=0.0 res=(1.0/(1.0+debye/moduli2) ) return resThats just an example. You can write whatever function you whish provided that you return either an array of scalars or an array of