Changeset 3164 for trunk/GSASIIElem.py


Ignore:
Timestamp:
Nov 28, 2017 11:32:31 AM (4 years ago)
Author:
vondreele
Message:

fix neutron resonant scattering factor calcs. - neglected constant term
put tyr/except around import pypowder in G2pwd & G2math - to allow testing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIElem.py

    r3136 r3164  
    396396            D1 = T1**2+gam**2
    397397            D2 = T2**2+gam**2
    398             FP[i] = Re*(T0/D0+A*T1/D1+B*T2/D2)
    399             FPP[i] = Im*(1/D0+A/D1+B/D2)
     398            FP[i] = Re*(T0/D0+A*T1/D1+B*T2/D2)+BL[i]['BW-LS'][0]
     399            FPP[i] = -Im*(1/D0+A/D1+B/D2)
    400400        else:
    401401            FPP[i] = BL['SL'][1]    #for Li, B, etc.
     
    416416            D1 = T1**2+gam**2
    417417            D2 = T2**2+gam**2
    418             FP[i] = Re*(T0/D0+A*T1/D1+B*T2/D2)
    419             FPP[i] = Im*(1/D0+A/D1+B/D2)
     418            FP[i] = Re*(T0/D0+A*T1/D1+B*T2/D2)+BL[i]['BW-LS'][0]
     419            FPP[i] = -Im*(1/D0+A/D1+B/D2)
    420420        else:
    421421            FPP[i] = np.ones(len(wave))*BL[i]['SL'][1]    #for Li, B, etc.
Note: See TracChangeset for help on using the changeset viewer.