Changeset 2061 for trunk/GSASII.py


Ignore:
Timestamp:
Nov 19, 2015 9:15:05 AM (7 years ago)
Author:
vondreele
Message:

modify export app peak lists to include d-spacing as a column
fix 2x error in U2Uij & Uij2U in G2spc - now same as one in G2lat
fix math errors for Uij modulation derivatives - all ok now

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASII.py

    r2056 r2061  
    31393139                            file.write('#wavelength = %10.6f\n'%(wave))
    31403140                        if 'T' in Type:
    3141                             file.write('#%10s %12s %10s %10s %10s %10s %10s\n'%('pos','int','alp','bet','sig','gam','FWHM'))                                   
     3141                            file.write('#%9s %10s %12s %10s %10s %10s %10s %10s\n'%('pos','dsp','int','alp','bet','sig','gam','FWHM'))                                   
    31423142                        else:
    3143                             file.write('#%10s %12s %10s %10s %10s\n'%('pos','int','sig','gam','FWHM'))
     3143                            file.write('#%9s %10s %12s %10s %10s %10s\n'%('pos','dsp','int','sig','gam','FWHM'))
    31443144                        for peak in peaks:
     3145                            dsp = G2lat.Pos2dsp(Inst,peak[0])
    31453146                            if 'T' in Type:  #TOF - more cols
    31463147                                FWHM = 2.*G2pwd.getgamFW(peak[10],peak[8])      #to get delta-TOF from Gam(peak)
    3147                                 file.write("%10.5f %12.2f %10.3f %10.3f %10.3f %10.3f %10.3f\n" % \
    3148                                     (peak[0],peak[2],np.sqrt(max(0.0001,peak[4])),peak[6],peak[8],peak[10],FWHM))
     3148                                file.write("%10.2f %10.5f %12.2f %10.3f %10.3f %10.3f %10.3f %10.3f\n" % \
     3149                                    (peak[0],dsp,peak[2],np.sqrt(max(0.0001,peak[4])),peak[6],peak[8],peak[10],FWHM))
    31493150                            else:               #CW
    31503151                                FWHM = 2.*G2pwd.getgamFW(peak[6],peak[4])      #to get delta-2-theta in deg. from Gam(peak)
    3151                                 file.write("%10.5f %12.2f %10.5f %10.5f %10.5f \n" % \
    3152                                     (peak[0],peak[2],np.sqrt(max(0.0001,peak[4]))/100.,peak[6]/100.,FWHM/100.)) #convert to deg
     3152                                file.write("%10.3f %10.5f %12.2f %10.5f %10.5f %10.5f \n" % \
     3153                                    (peak[0],dsp,peak[2],np.sqrt(max(0.0001,peak[4]))/100.,peak[6]/100.,FWHM/100.)) #convert to deg
    31533154                    item, cookie = self.PatternTree.GetNextChild(self.root, cookie)                           
    31543155                file.close()
Note: See TracChangeset for help on using the changeset viewer.