# Changeset 942 for trunk/GSASIIstrMath.py

Ignore:
Timestamp:
Jun 5, 2013 9:26:36 AM (9 years ago)
Message:

mods for MC/SA:
moved scat fac routines from GSASIIstrIO.py & GSASIIstrMath.py to GSASIIElem.py

File:
1 edited

Unmodified
Added
Removed
• ## trunk/GSASIIstrMath.py

 r939 return Tdata,Mdata,Fdata,Xdata,dXdata,IAdata,Uisodata,Uijdata def getFFvalues(FFtables,SQ): 'Needs a doc string' FFvals = {} for El in FFtables: FFvals[El] = G2el.ScatFac(FFtables[El],SQ)[0] return FFvals def getBLvalues(BLtables): 'Needs a doc string' BLvals = {} for El in BLtables: BLvals[El] = BLtables[El][1][1] return BLvals def StructureFactor(refList,G,hfx,pfx,SGData,calcControls,parmDict): ''' Compute structure factors for all h,k,l for phase FP = np.array([FFtables[El][hfx+'FP'] for El in Tdata]) FPP = np.array([FFtables[El][hfx+'FPP'] for El in Tdata]) maxPos = len(SGData['SGOps']) Uij = np.array(G2lat.U6toUij(Uijdata)) bij = Mast*Uij.T if not len(refl[-1]):                #no form factors if 'N' in parmDict[hfx+'Type']: refl[-1] = getBLvalues(BLtables) refl[-1] = G2el.getBLvalues(BLtables) else:       #'X' refl[-1] = getFFvalues(FFtables,SQ) refl[-1] = G2el.getFFvalues(FFtables,SQ) for i,El in enumerate(Tdata): FF[i] = refl[-1][El] FP = np.array([FFtables[El][hfx+'FP'] for El in Tdata]) FPP = np.array([FFtables[El][hfx+'FPP'] for El in Tdata]) maxPos = len(SGData['SGOps']) Uij = np.array(G2lat.U6toUij(Uijdata)) bij = Mast*Uij.T
Note: See TracChangeset for help on using the changeset viewer.